diff options
author | Abramo Bagnara <abramo.bagnara@bugseng.com> | 2012-10-15 21:07:44 +0000 |
---|---|---|
committer | Abramo Bagnara <abramo.bagnara@bugseng.com> | 2012-10-15 21:07:44 +0000 |
commit | ac7027872b55c43389308b51b36ade04bb50081f (patch) | |
tree | 49c4525c95d186895691ecebc1d38a8ce900ab6f /lib | |
parent | b2e80013dbf316f83716a9d9cdc9a6ed5a5a8e2a (diff) |
Fixed LabelDecl source range.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165976 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Sema/SemaStmt.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Sema/SemaStmt.cpp b/lib/Sema/SemaStmt.cpp index 70ece511d1..f55174e05c 100644 --- a/lib/Sema/SemaStmt.cpp +++ b/lib/Sema/SemaStmt.cpp @@ -371,8 +371,10 @@ Sema::ActOnLabelStmt(SourceLocation IdentLoc, LabelDecl *TheDecl, // Otherwise, things are good. Fill in the declaration and return it. LabelStmt *LS = new (Context) LabelStmt(IdentLoc, TheDecl, SubStmt); TheDecl->setStmt(LS); - if (!TheDecl->isGnuLocal()) + if (!TheDecl->isGnuLocal()) { + TheDecl->setLocStart(IdentLoc); TheDecl->setLocation(IdentLoc); + } return Owned(LS); } |