More assertion cleanups. Thanks, Joe!

Swift SVN r15842
This commit is contained in:
Adrian Prantl
2014-04-02 23:06:13 +00:00
parent b941c8640f
commit 47bf136af5
4 changed files with 16 additions and 12 deletions

View File

@@ -654,11 +654,12 @@ protected:
static SILFunction *initCloned(SILFunction *OrigF, StringRef NewName) {
SILModule &M = OrigF->getModule();
assert((OrigF->isTransparent() || OrigF->isBare() || OrigF->getLocation())
&& "SILFunction missing location");
assert((OrigF->isTransparent() || OrigF->isBare() || OrigF->getDebugScope())
&& "SILFunction missing DebugScope");
// Create a new empty function.
// TODO: Use getSpecializedLinkage() once we mangle properly.
assert(OrigF->isTransparent() ||
OrigF->isBare() ||
OrigF->getLocation() && "SILFunction missing location");
SILFunction *NewF =
SILFunction::create(M, SILLinkage::Private,
NewName,