You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be nice to be able to link the Types in Types.Foo to the local definition.
Use case: if a user requests to rename the "Types" local variable, it should rename the imported type prefix (and vice versa).
From first glance, I think this is doable by storing the prefix as an AstLocal here, and tracking it appropriately:
JohnnyMorganz
changed the title
Track the local binding that a type reference is linked to
Track the local binding that a prefixed type reference is linked to
Dec 26, 2023
Right now, all local bindings are nicely linked together as they share a pointer to the same
AstLocal
. But the same is not true for type referencesConsider the following code:
It would be nice to be able to link the
Types
inTypes.Foo
to the local definition.Use case: if a user requests to rename the "Types" local variable, it should rename the imported type prefix (and vice versa).
From first glance, I think this is doable by storing the prefix as an
AstLocal
here, and tracking it appropriately:luau/Ast/include/Luau/Ast.h
Lines 883 to 899 in 74c5320
Or maybe you have other ideas
The text was updated successfully, but these errors were encountered: