1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 19:48:20 +02:00

Sanitize BF_DEPENDS_ defines

This commit is contained in:
Brian Fiete 2024-10-17 18:00:39 -04:00
parent 126943c5bd
commit b9d0dc693f

View file

@ -935,6 +935,11 @@ MaybeBool BfParser::HandleIfDef(const StringImpl& name)
StringT<64> def = "BF_DEPENDS_";
def.Append(project->mName);
MakeUpper(def);
for (auto& c : def)
{
if (!isalnum((uint8)c))
c = '_';
}
mPreprocessorDefines[def] = BfDefineState_FromProject;
}
mAddedDependsDefines = true;