-
Notifications
You must be signed in to change notification settings - Fork 25
Closed
Description
We have to test this scenario:
2 programs:
PGM1defines public typeTypeAPGM2defines public procedureProcAwith at least one of its param of typePGM1::TypeA
Now load both programs as dependencies in LanguageServer and then open 'PGM1' as main program to edit it. If PGM1 contains a call to PGM2::ProcA, it will likely produce an error on call statement saying that the types don't match.
This is because we probably end with 2 distinct TypeDefinition instances for the same type PGM1::TypeA, one comes from the 'dependency load' (and is kept somehow), the second one comes from the 'edit load'.
TODO:
- test the scenario and confirm that 2 instances of TypeA are kept, also test what happens when its a type reference instead of a procedure (i.e.
PGM2::TypeBusesPGM1::TypeA) - possibles fixes
a. ensure we always have one single instance for symbol definitions
b. Change reference comparison intoEqualscall to avoid the error