[llvm-bugs] [Bug 36181] New: Microsoft mangling cannot mangle injected class name type
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Jan 31 14:58:15 PST 2018
https://bugs.llvm.org/show_bug.cgi?id=36181
Bug ID: 36181
Summary: Microsoft mangling cannot mangle injected class name
type
Product: clang
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: C++
Assignee: unassignedclangbugs at nondot.org
Reporter: smeenai at fb.com
CC: compnerd at compnerd.org, david.majnemer at gmail.com,
dgregor at apple.com, llvm-bugs at lists.llvm.org,
rnk at google.com
Using the reduced test case from https://bugs.llvm.org/show_bug.cgi?id=16887 (I
independently arrived at an almost equivalent reduced test case before finding
that one, sigh):
% cat reduced.h
template <typename T> struct A {
friend void f(A<T>) {}
};
void g() { f(A<int>()); }
% touch empty.cpp
% clang -cc1 -triple x86_64-windows-msvc -emit-pch -o reduced.h.pch -x
c++-header reduced.h
% clang -cc1 -triple x86_64-windows-msvc -emit-llvm -include-pch reduced.h.pch
empty.cpp
Cannot mangle injected class name type.
UNREACHABLE executed
https://reviews.llvm.org/rL188536 changed this from an error to an unreachable.
It should indeed be unreachable for -fdelayed-template-parsing (and running
both of the above clang invocations with -fdelayed-template-parsing doesn't
crash), but it is reachable otherwise.
This is the same underlying issue as
https://bugs.llvm.org/show_bug.cgi?id=35473 and
https://bugs.llvm.org/show_bug.cgi?id=35939. I'm reporting this separately
because this is triggered with a precompiled header vs. modules, and there's a
reduced standalone test case.
--
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/20180131/5a3f6cbe/attachment-0001.html>
More information about the llvm-bugs
mailing list