mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-12 17:32:19 +00:00
eliminate some #if 0 code I added in r96905, type inference
now enforces that input/output named values have hte same type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98535 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2cacec55f9
commit
e002da34ef
@ -2332,24 +2332,6 @@ void CodeGenDAGPatterns::AddPatternToMatch(const TreePattern *Pattern,
|
|||||||
if (SrcNames[I->first].first == 0)
|
if (SrcNames[I->first].first == 0)
|
||||||
Pattern->error("Pattern has input without matching name in output: $" +
|
Pattern->error("Pattern has input without matching name in output: $" +
|
||||||
I->first);
|
I->first);
|
||||||
|
|
||||||
#if 0
|
|
||||||
const std::vector<unsigned char> &SrcTypeVec =
|
|
||||||
SrcNames[I->first].first->getExtTypes();
|
|
||||||
const std::vector<unsigned char> &DstTypeVec =
|
|
||||||
I->second.first->getExtTypes();
|
|
||||||
if (SrcTypeVec == DstTypeVec) continue;
|
|
||||||
|
|
||||||
std::string SrcType, DstType;
|
|
||||||
for (unsigned i = 0, e = SrcTypeVec.size(); i != e; ++i)
|
|
||||||
SrcType += ":" + GetTypeName(SrcTypeVec[i]);
|
|
||||||
for (unsigned i = 0, e = DstTypeVec.size(); i != e; ++i)
|
|
||||||
DstType += ":" + GetTypeName(DstTypeVec[i]);
|
|
||||||
|
|
||||||
Pattern->error("Variable $" + I->first +
|
|
||||||
" has different types in source (" + SrcType +
|
|
||||||
") and dest (" + DstType + ") pattern!");
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scan all of the named values in the source pattern, rejecting them if the
|
// Scan all of the named values in the source pattern, rejecting them if the
|
||||||
|
Loading…
x
Reference in New Issue
Block a user