Goose  Diff

Differences From Artifact [d5e2e89b28]:

  • File bs/builtins/types/drop.cpp — part of check-in [7d2def7b75] at 2020-12-27 14:40:24 on branch trunk — Renamed "ir" to "eir" (expression intermediate representation) and "llr" to "cir" (code intermediate representation) for clarity. (user: achavasse size: 2016)

To Artifact [be3c1bc34a]:

  • File bs/builtins/types/drop.cpp — part of check-in [b2945b5bb1] at 2021-03-05 17:56:37 on branch trunk — Implemented refinement type predicate unification. Predicate violations by variable initialization are now properly detected. (user: achavasse size: 2032)

39
40
41
42
43
44
45
46

47
48
49
39
40
41
42
43
44
45

46
47
48
49







-
+



                if( !c.codeBuilder() )
                {
                    DiagnosticsManager::GetInstance().emitSyntaxErrorMessage( 0, "variable declarations are not allowed here." );
                    return PoisonValue();
                }

                auto decl = *FromValue< Decl >( v );
                return DeclareLocalVar( c, decl.type(), decl.name(), nullopt );
                return DeclareLocalVar( c, decl.type(), decl.name(), nullopt, v.locationId() );
            } );
    }
}