]> granicus.if.org Git - clang/commitdiff
Remove an unused variable.
authorHaojian Wu <hokein@google.com>
Fri, 13 Oct 2017 15:34:03 +0000 (15:34 +0000)
committerHaojian Wu <hokein@google.com>
Fri, 13 Oct 2017 15:34:03 +0000 (15:34 +0000)
Fix -Wunused-but-set-variable warning.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@315688 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaType.cpp

index c741f84ad3fcf5a1c8c44835945a467bf8dde49e..d3f63b4f9f9c64ac6a06e830a1a1a17ef2cd352d 100644 (file)
@@ -7079,7 +7079,6 @@ static void processTypeAttrs(TypeProcessingState &state, QualType &type,
   // type, but others can be present in the type specifiers even though they
   // apply to the decl.  Here we apply type attributes and ignore the rest.
 
-  bool hasOpenCLAddressSpace = false;
   while (attrs) {
     AttributeList &attr = *attrs;
     attrs = attr.getNext(); // reset to the next here due to early loop continue
@@ -7142,7 +7141,6 @@ static void processTypeAttrs(TypeProcessingState &state, QualType &type,
     case AttributeList::AT_AddressSpace:
       HandleAddressSpaceTypeAttribute(type, attr, state.getSema());
       attr.setUsedAsTypeAttr();
-      hasOpenCLAddressSpace = true;
       break;
     OBJC_POINTER_TYPE_ATTRS_CASELIST:
       if (!handleObjCPointerTypeAttr(state, attr, type))