1
0
Fork 0
mirror of https://github.com/luau-lang/luau.git synced 2025-04-04 19:00:54 +01:00

Make definitionLocation optional

This commit is contained in:
JohnnyMorganz 2024-07-13 10:06:16 +02:00
parent 5208aba6ac
commit 39dd9e09aa

View file

@ -499,11 +499,11 @@ struct ClassType
Tags tags;
std::shared_ptr<ClassUserData> userData;
ModuleName definitionModuleName;
Location definitionLocation;
std::optional<Location> definitionLocation;
std::optional<TableIndexer> indexer;
ClassType(Name name, Props props, std::optional<TypeId> parent, std::optional<TypeId> metatable, Tags tags,
std::shared_ptr<ClassUserData> userData, ModuleName definitionModuleName, Location definitionLocation)
std::shared_ptr<ClassUserData> userData, ModuleName definitionModuleName, std::optional<Location> definitionLocation)
: name(name)
, props(props)
, parent(parent)
@ -516,7 +516,8 @@ struct ClassType
}
ClassType(Name name, Props props, std::optional<TypeId> parent, std::optional<TypeId> metatable, Tags tags,
std::shared_ptr<ClassUserData> userData, ModuleName definitionModuleName, Location definitionLocation, std::optional<TableIndexer> indexer)
std::shared_ptr<ClassUserData> userData, ModuleName definitionModuleName, std::optional<Location> definitionLocation,
std::optional<TableIndexer> indexer)
: name(name)
, props(props)
, parent(parent)