Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/cppmangle.d
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,10 @@ static if (TARGET_LINUX || TARGET_OSX || TARGET_FREEBSD || TARGET_OPENBSD || TAR
}
if (p && !p.isModule())
{
prefix_name(p);
if (p.ident == Id.std && is_initial_qualifier(p))
buf.writestring("St");
else
prefix_name(p);
}
if (!(s.ident == Id.std && is_initial_qualifier(s)))
store(s);
Expand Down
12 changes: 12 additions & 0 deletions test/runnable/cppa.d
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,12 @@ extern (C++, std)
}

class exception { }

// 14956
extern(C++, N14956)
{
struct S14956 { }
}
}

extern (C++)
Expand Down Expand Up @@ -759,6 +765,11 @@ void test14200()
test14200b(1.0f, 1, 1.0);
}

/****************************************/
// 14956

extern(C++) void test14956(S14956 s);

/****************************************/
// check order of overloads in vtable

Expand Down Expand Up @@ -1104,6 +1115,7 @@ void main()
foo13337(S13337());
test14195();
test14200();
test14956(S14956());
testVtable();
fuzz();
testeh();
Expand Down
11 changes: 11 additions & 0 deletions test/runnable/extra-files/cppb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,17 @@ void test14195b(Delegate2<int(float, double), int(float, double)> func) {}
void test14200a(int a) {};
void test14200b(float a, int b, double c) {};

/******************************************/
// 14956

namespace std {
namespace N14956 {
struct S14956 { };
}
}

void test14956(std::N14956::S14956 s) { }

/******************************************/
// check order of overloads in vtable

Expand Down