diff options
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r-- | lib/CodeGen/CGDecl.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp index ee2516a850..d8123c8ec1 100644 --- a/lib/CodeGen/CGDecl.cpp +++ b/lib/CodeGen/CGDecl.cpp @@ -88,6 +88,10 @@ CodeGenFunction::CreateStaticBlockVarDecl(const VarDecl &D, else if (isa<ObjCMethodDecl>(CurFuncDecl)) ContextName = std::string(CurFn->getNameStart(), CurFn->getNameStart() + CurFn->getNameLen()); + else if (isa<BlockDecl>(CurFuncDecl)) + // FIXME: We want to traverse up and pick a name based upon where we came + // from. + ContextName = "block"; else assert(0 && "Unknown context for block var decl"); |