Skip to main content

compose_unit_consts

Function compose_unit_consts 

Source
pub fn compose_unit_consts(
    name: &str,
    unit_info: &BTreeMap<String, UnitInfo>,
) -> HashMap<String, ConstDecl>
Expand description

Every constant visible in unit name: its own, plus the public ones of each commons it uses (one level, the mixin rule crate::embeds::compose_unit_embeds applies to embeds). A local declaration of any kind wins over an imported constant of the same name; two used commons declaring the same name is bynk.uses.name_conflict, so which is kept here is never observable in a program that checks.