MCPcopy Create free account
hub / github.com/beefytech/Beef / BfIdentifierCast

Method BfIdentifierCast

IDEHelper/Compiler/BfAst.cpp:774–782  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

772}
773
774BfIdentifierNode* Beefy::BfIdentifierCast(BfAstNode* node)
775{
776 if (node == NULL)
777 return NULL;
778 if (node->GetTypeId() == BfAttributedIdentifierNode::sTypeInfo.mTypeId)
779 return ((BfAttributedIdentifierNode*)node)->mIdentifier;
780 bool canCast = (uint)node->GetTypeId() - (uint)BfIdentifierNode::sTypeInfo.mTypeId <= (uint)BfIdentifierNode::sTypeInfo.mFullDerivedCount;
781 return canCast ? (BfIdentifierNode*)node : NULL;
782}
783
784BfAstNode* Beefy::BfNodeToNonTemporary(BfAstNode* node)
785{

Callers

nothing calls this directly

Calls 1

GetTypeIdMethod · 0.45

Tested by

no test coverage detected