[llvm-bugs] [Bug 37935] New: `deprecated` attribute can't take a message when other attribute exists

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jun 25 23:56:45 PDT 2018


            Bug ID: 37935
           Summary: `deprecated` attribute can't take a message when other
                    attribute exists
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: mail+llvm at tzik.jp
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org

Here is a repro. `deprecated` seems not working well with a message when it's
used with another attribute.

---- foo.cc
[[nodiscard, deprecated("")]] int foo();
$ clang++ --version
clang version 7.0.0 (https://llvm.googlesource.com/clang.git
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /home/tzik/toolchain/out/usr/bin
$ clang++ -c foo.cc
foo.cc:1:24: error: attribute 'deprecated' cannot have an argument list
[[nodiscard, deprecated("")]] int foo();

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/20180626/b0294f70/attachment.html>

More information about the llvm-bugs mailing list