[llvm-bugs] [Bug 31999] New: _Pragma in submacro

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Feb 17 23:55:02 PST 2017


https://bugs.llvm.org/show_bug.cgi?id=31999

            Bug ID: 31999
           Summary: _Pragma in submacro
           Product: clang
           Version: 4.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: samuel at thimbleby.net
                CC: llvm-bugs at lists.llvm.org

_Pragmas should hide both warnings

clang-4.0 hides one warning, and clang++ hides neither

This is similar to bug 15129, but doesn't depend on concatenation, and is
important to my code
-----------
#define HIDE(...) \
        _Pragma("clang diagnostic push") \
        _Pragma("clang diagnostic ignored \"-Wint-conversion\"") \
        __VA_ARGS__ \
        _Pragma("clang diagnostic pop")

#define A(B) B

int main(void) {
        int a;
        HIDE(a = (int*)0);

        A(HIDE(a = (int*)0)); }

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170218/2659ed35/attachment-0001.html>


More information about the llvm-bugs mailing list