[LLVMbugs] [Bug 23577] New: [MSVC] #pragma warning works incorrectly for "1-4:" specifiers

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue May 19 08:41:31 PDT 2015


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

            Bug ID: 23577
           Summary: [MSVC] #pragma warning works incorrectly for "1-4:"
                    specifiers
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: andreybokhanko at gmail.com
                CC: llvmbugs at cs.uiuc.edu, rnk at google.com
            Blocks: 13707
    Classification: Unclassified

#pragma warning, while functionally complete (see
https://llvm.org/bugs/show_bug.cgi?id=17145) has a bug -- it works incorrectly
for "1-4:" specifiers:

$ cat warning-test.c
#pragma warning(1: 100)

$ cl warning-test.c -c
Microsoft (R) C/C++ Optimizing Compiler Version 19.00.22310.1 for x64
Copyright (C) Microsoft Corporation.  All rights reserved.

warning-test.c

$ clang-cl warning-test.c -c
warning-test.c(1,17) :  warning: #pragma warning expected 'push', 'pop',
      'default', 'disable', 'error', 'once', 'suppress', 1, 2, 3, or 4
      [-Wunknown-pragmas]
#pragma warning(1: 100)
                ^
1 warning generated.

-- 
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/20150519/5e70d9b6/attachment.html>


More information about the llvm-bugs mailing list