mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-09 03:52:19 +02:00
Better support for @ name prefixes
This commit is contained in:
parent
7691c414c3
commit
aa56542fae
12 changed files with 158 additions and 40 deletions
|
@ -383,6 +383,30 @@ BfSizedAtomComposite::~BfSizedAtomComposite()
|
|||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void BfMemberDef::SetName(BfAstNode* nameNode)
|
||||
{
|
||||
StringView sv = nameNode->ToStringView();
|
||||
while ((!sv.IsEmpty()) && (sv[0] == '@'))
|
||||
{
|
||||
sv.RemoveFromStart(1);
|
||||
mNamePrefixCount++;
|
||||
}
|
||||
mName = sv;
|
||||
}
|
||||
|
||||
void BfParameterDef::SetName(BfAstNode* nameNode)
|
||||
{
|
||||
StringView sv = nameNode->ToStringView();
|
||||
while ((!sv.IsEmpty()) && (sv[0] == '@'))
|
||||
{
|
||||
sv.RemoveFromStart(1);
|
||||
mNamePrefixCount++;
|
||||
}
|
||||
mName = sv;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
bool BfPropertyDef::IsVirtual()
|
||||
{
|
||||
if (((BfPropertyDeclaration*)mFieldDeclaration)->mVirtualSpecifier)
|
||||
|
@ -4484,3 +4508,5 @@ BF_EXPORT void BF_CALLTYPE BfSystem_Log(BfSystem* bfSystem, char* str)
|
|||
BfLogSys(bfSystem, str);
|
||||
BfLogSys(bfSystem, "\n");
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue