1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 12:32:20 +02:00

Added a fixit for adding a field from an identifier error

This commit is contained in:
Brian Fiete 2020-02-08 06:13:48 -08:00
parent 2fdfc38a28
commit 234b3064ff
2 changed files with 34 additions and 9 deletions

View file

@ -2719,7 +2719,10 @@ void BfAutoComplete::FixitAddMember(BfTypeInstance* typeInst, BfType* fieldType,
}
}
AddEntry(AutoCompleteEntry("fixit", StrFormat("Create field '%s' in '%s'\taddField|%s||%s", fieldName.c_str(), fullName.c_str(),
const char* memberName = "field";
if (isStatic)
memberName = "static field";
AddEntry(AutoCompleteEntry("fixit", StrFormat("Create %s '%s' in '%s'\taddField|%s||%s", memberName, fieldName.c_str(), fullName.c_str(),
FixitGetLocation(parser->mParserData, fileLoc).c_str(), fieldStr.c_str()).c_str()));
}