[LLVMbugs] [Bug 13573] New: crash-on-invalid: extern "C" deleted template function.

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Aug 10 10:56:21 PDT 2012


             Bug #: 13573
           Summary: crash-on-invalid: extern "C" deleted template
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++11
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: benny.kra at gmail.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

$ cat t.cpp
extern "C" {
  template<typename _Tp>
  void ref(const _Tp&) = delete;

$ clang -std=c++11 t.cpp
t.cpp:2:3: error: templates must have C++ linkage
  template<typename _Tp>
Stack dump:
0.    Program arguments: /Users/d0k/build/llvm/Debug+Asserts/bin/clang -cc1
-triple x86_64-apple-macosx10.8.0 -emit-obj -mrelax-all -disable-free
-main-file-name t.cpp -pic-level 2 -mdisable-fp-elim -masm-verbose
-munwind-tables -target-cpu core2 -target-linker-version 133.3 -resource-dir
/Users/d0k/build/llvm/Debug+Asserts/bin/../lib/clang/3.2 -fmodule-cache-path
/var/folders/lt/l_19g5c51sdbnz6zp3px4bpw0000gn/T/clang-module-cache -std=c++11
-fdeprecated-macro -fdebug-compilation-dir /tmp -ferror-limit 19
-fmessage-length 110 -stack-protector 1 -mstackrealign -fblocks
-fobjc-runtime=macosx-10.8.0 -fobjc-dispatch-method=mixed
-fobjc-default-synthesize-properties -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fcolor-diagnostics -o
/var/folders/lt/l_19g5c51sdbnz6zp3px4bpw0000gn/T/t-qdTMZt.o -x c++ t.cpp 
1.    t.cpp:3:32: current parser token ';'
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal (use -v to see
clang version 3.2 (trunk 161655) (llvm/trunk 161654)

Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

More information about the llvm-bugs mailing list