rascal icon indicating copy to clipboard operation
rascal copied to clipboard

Collection fields do not have defs or uses in TModel

Open toinehartman opened this issue 8 months ago • 0 comments

Describe the bug

Collection fields do not have defs or uses in TModel.

To Reproduce

void collectionField() {
    println("== Collection fields =");
    tm = typeCheck(
        "rel[int foo, str bar] r = {};
        'set[int] is = r.foo;"
    );

    // No defs for collection fields
    defs = {<d, role> | Define _:<_, _, _, role, d, _> <- tm.defines};
    print("Defs with roles: ");
    iprintln(defs);

    // No uses for collection fields
    uses = tm.useDef o defs;
    print("Uses: ");
    iprintln(uses);
    println("======================\n");
}

Expected behavior Defs and uses to exist.

toinehartman avatar Mar 11 '25 16:03 toinehartman