mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
MSVC 2013 does not ICE on this code in the same fashion that MSVC 2012 did; NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229422 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -385,8 +385,7 @@ static bool isObjectStart(tgtok::TokKind K) {
|
|||||||
/// GetNewAnonymousName - Generate a unique anonymous name that can be used as
|
/// GetNewAnonymousName - Generate a unique anonymous name that can be used as
|
||||||
/// an identifier.
|
/// an identifier.
|
||||||
std::string TGParser::GetNewAnonymousName() {
|
std::string TGParser::GetNewAnonymousName() {
|
||||||
unsigned Tmp = AnonCounter++; // MSVC2012 ICEs without this.
|
return "anonymous_" + utostr(AnonCounter++);
|
||||||
return "anonymous_" + utostr(Tmp);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// ParseObjectName - If an object name is specified, return it. Otherwise,
|
/// ParseObjectName - If an object name is specified, return it. Otherwise,
|
||||||
|
@@ -656,9 +656,7 @@ CodeGenRegisterClass::CodeGenRegisterClass(CodeGenRegBank &RegBank, Record *R)
|
|||||||
// Rename anonymous register classes.
|
// Rename anonymous register classes.
|
||||||
if (R->getName().size() > 9 && R->getName()[9] == '.') {
|
if (R->getName().size() > 9 && R->getName()[9] == '.') {
|
||||||
static unsigned AnonCounter = 0;
|
static unsigned AnonCounter = 0;
|
||||||
R->setName("AnonRegClass_" + utostr(AnonCounter));
|
R->setName("AnonRegClass_" + utostr(AnonCounter++));
|
||||||
// MSVC2012 ICEs if AnonCounter++ is directly passed to utostr.
|
|
||||||
++AnonCounter;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<Record*> TypeList = R->getValueAsListOfDefs("RegTypes");
|
std::vector<Record*> TypeList = R->getValueAsListOfDefs("RegTypes");
|
||||||
|
Reference in New Issue
Block a user