Skip to main content

name_error

Function name_error 

Source
pub fn name_error(
    a: &AssetDecl,
    prev_asset: Option<&Ident>,
    prev_fn: Option<&Ident>,
    prev_type: Option<&Ident>,
) -> Option<CompileError>
Expand description

The name rule for asset a, given what its unit already declares under that name: an earlier asset is bynk.asset.duplicate; a free function or a type is bynk.resolve.name_conflict (an asset is a value, in the function namespace, and a type name in value position is an error). None when the name is free. One rule for the project pipeline (symbols::build_unit_table) and the single-file compile, which has no unit table (review of #1903).