diff --git a/compiler/test/compilable/cppmangle.d b/compiler/test/compilable/cppmangle.d index 264b374dd5..948fee2cfd 100644 --- a/compiler/test/compilable/cppmangle.d +++ b/compiler/test/compilable/cppmangle.d @@ -8,7 +8,6 @@ import core.stdc.stdio; version (CppRuntime_Clang) version = CppMangle_Itanium; -version (CppRuntime_DigitalMars) version = CppMangle_MSVC; version (CppRuntime_Gcc) version = CppMangle_Itanium; version (CppRuntime_Microsoft) version = CppMangle_MSVC; version (CppRuntime_Sun) version = CppMangle_Itanium; diff --git a/compiler/test/compilable/cppmangle3.d b/compiler/test/compilable/cppmangle3.d index 82c68f7a3a..92c858854f 100644 --- a/compiler/test/compilable/cppmangle3.d +++ b/compiler/test/compilable/cppmangle3.d @@ -4,7 +4,6 @@ module cppmangle3; version (CppRuntime_Clang) version = CppMangle_Itanium; -version (CppRuntime_DigitalMars) version = CppMangle_MSVC; version (CppRuntime_Gcc) version = CppMangle_Itanium; version (CppRuntime_Microsoft) version = CppMangle_MSVC; version (CppRuntime_Sun) version = CppMangle_Itanium; diff --git a/compiler/test/dshell/extra-files/dll_cxx/cppnew.d b/compiler/test/dshell/extra-files/dll_cxx/cppnew.d index cae1822404..7d440077e3 100644 --- a/compiler/test/dshell/extra-files/dll_cxx/cppnew.d +++ b/compiler/test/dshell/extra-files/dll_cxx/cppnew.d @@ -53,19 +53,6 @@ version (CppRuntime_Microsoft) enum __delete_mangle = "??3@YAXPAX@Z"; } } -else version (CppRuntime_DigitalMars) -{ - version (D_LP64) - { - enum __new_mangle = "??2@YAPEAX_K@Z"; - enum __delete_mangle = "??3@YAXPEAX@Z"; - } - else - { - enum __new_mangle = "??2@YAPAXI@Z"; - enum __delete_mangle = "??3@YAXPAX@Z"; - } -} else { version (D_LP64) diff --git a/compiler/test/runnable_cxx/cpp_abi_tests.d b/compiler/test/runnable_cxx/cpp_abi_tests.d index c0f4e6dd78..5d4bc99c1b 100644 --- a/compiler/test/runnable_cxx/cpp_abi_tests.d +++ b/compiler/test/runnable_cxx/cpp_abi_tests.d @@ -272,7 +272,6 @@ void main() foreach(byte val; values!byte()) check(val); foreach(ubyte val; values!ubyte()) check(val); foreach(char val; values!char()) check(val); -version(CppRuntime_DigitalMars){} else version(CppRuntime_Microsoft) { // TODO: figure out how to detect VS2013 which doesn't support char16_t/char32_t diff --git a/compiler/test/runnable_cxx/cppa.d b/compiler/test/runnable_cxx/cppa.d index cb268af062..58facc52ae 100644 --- a/compiler/test/runnable_cxx/cppa.d +++ b/compiler/test/runnable_cxx/cppa.d @@ -908,9 +908,7 @@ void fuzz2() } //////// -version(CppRuntime_DigitalMars) - enum UNICODE = false; -else version(CppRuntime_Microsoft) +version(CppRuntime_Microsoft) enum UNICODE = false; //VS2013 doesn't support them else enum UNICODE = true; diff --git a/compiler/test/runnable_cxx/externmangle.d b/compiler/test/runnable_cxx/externmangle.d index ef132dcca7..266cad9f6c 100644 --- a/compiler/test/runnable_cxx/externmangle.d +++ b/compiler/test/runnable_cxx/externmangle.d @@ -239,38 +239,30 @@ void test39() extern(C++, "foo", "bar", "baz") int doStuff(int); -version(CppRuntime_DigitalMars) // DMC doesn't support c++11 +void test40(); + +void foovargs(T...)(T args) { - void test40() {} - void test41() {} + static if (is(T[0] == char*)) + { + assert(*args[0] == 'a'); + } + else + { + float ret = args[0] + args[1]; + assert(ret == 3.0f); + } } -else + +alias FooVargs = foovargs!(int, float); +alias FooVargs2 = foovargs!(char*); + +void test41(); +void make_shared_poc(T, Args...)(ref Args args) { - void test40(); - - void foovargs(T...)(T args) - { - static if (is(T[0] == char*)) - { - assert(*args[0] == 'a'); - } - else - { - float ret = args[0] + args[1]; - assert(ret == 3.0f); - } - } - - alias FooVargs = foovargs!(int, float); - alias FooVargs2 = foovargs!(char*); - - void test41(); - void make_shared_poc(T, Args...)(ref Args args) - { - assert(args[0] + args[1] == 3); - } - alias Make_Shared_Poc = make_shared_poc!(int, int, int); + assert(args[0] + args[1] == 3); } +alias Make_Shared_Poc = make_shared_poc!(int, int, int); void main() { diff --git a/druntime/src/core/stdcpp/array.d b/druntime/src/core/stdcpp/array.d index eb63d4ccaa..4cb0c56ec5 100644 --- a/druntime/src/core/stdcpp/array.d +++ b/druntime/src/core/stdcpp/array.d @@ -13,17 +13,6 @@ module core.stdcpp.array; import core.stdcpp.xutility : StdNamespace; -// hacks to support DMD on Win32 -version (CppRuntime_Microsoft) -{ - version = CppRuntime_Windows; // use the MS runtime ABI for win32 -} -else version (CppRuntime_DigitalMars) -{ - version = CppRuntime_Windows; // use the MS runtime ABI for win32 - pragma(msg, "std::array not supported by DMC"); -} - extern(C++, (StdNamespace)): /** @@ -73,7 +62,7 @@ pure nothrow @nogc: /// ref inout(T) back() inout @safe { static if (N > 0) { return this[N-1]; } else { return as_array()[][0]; /* HACK: force OOB */ } } - version (CppRuntime_Windows) + version (CppRuntime_Microsoft) { /// inout(T)* data() inout @safe { return &_Elems[0]; } diff --git a/druntime/src/core/stdcpp/exception.d b/druntime/src/core/stdcpp/exception.d index d5339964e3..4774b98615 100644 --- a/druntime/src/core/stdcpp/exception.d +++ b/druntime/src/core/stdcpp/exception.d @@ -80,24 +80,6 @@ version (GenericBaseException) extern(D) this(const(char)*, int = 1) nothrow { this(); } // compat with MS derived classes } } -else version (CppRuntime_DigitalMars) -{ - /// - class exception - { - @nogc: - /// - extern(D) this() nothrow {} - //virtual ~this(); - void dtor() { } // reserve slot in vtbl[] - - /// - const(char)* what() const nothrow; - - protected: - this(const(char)*, int = 1) nothrow { this(); } // compat with MS derived classes - } -} else version (CppRuntime_Microsoft) { /// diff --git a/druntime/src/core/stdcpp/string_view.d b/druntime/src/core/stdcpp/string_view.d index 172c170444..47f58b014e 100644 --- a/druntime/src/core/stdcpp/string_view.d +++ b/druntime/src/core/stdcpp/string_view.d @@ -14,17 +14,6 @@ module core.stdcpp.string_view; import core.stdc.stddef : wchar_t; import core.stdcpp.xutility : StdNamespace; -// hacks to support DMD on Win32 -version (CppRuntime_Microsoft) -{ - version = CppRuntime_Windows; // use the MS runtime ABI for win32 -} -else version (CppRuntime_DigitalMars) -{ - version = CppRuntime_Windows; // use the MS runtime ABI for win32 - pragma(msg, "std::basic_string_view not supported by DMC"); -} - extern(C++, (StdNamespace)): @nogc: @@ -102,7 +91,7 @@ pure nothrow @nogc: private: // use the proper field names from C++ so debugging doesn't get weird - version (CppRuntime_Windows) + version (CppRuntime_Microsoft) { const_pointer _Mydata; size_type _Mysize; diff --git a/druntime/src/core/stdcpp/typeinfo.d b/druntime/src/core/stdcpp/typeinfo.d index 24f2938cca..b8478b3941 100644 --- a/druntime/src/core/stdcpp/typeinfo.d +++ b/druntime/src/core/stdcpp/typeinfo.d @@ -13,53 +13,7 @@ module core.stdcpp.typeinfo; import core.attribute : weak; -version (CppRuntime_DigitalMars) -{ - import core.stdcpp.exception; - - extern (C++, "std"): - - class type_info - { - @nogc: - void* pdata; - - public: - //virtual ~this(); - void dtor() { } // reserve slot in vtbl[] - - //bool operator==(const type_info rhs) const; - //bool operator!=(const type_info rhs) const; - final bool before(const type_info rhs) const nothrow; - final const(char)* name() const nothrow; - protected: - //type_info(); - private: - //this(const type_info rhs); - //type_info operator=(const type_info rhs); - } - - class bad_cast : exception - { - @nogc: - extern(D) this() nothrow { } - extern(D) this(const bad_cast) nothrow { } - //bad_cast operator=(const bad_cast) nothrow { return this; } - //virtual ~this() nothrow; - override const(char)* what() const nothrow; - } - - class bad_typeid : exception - { - @nogc: - extern(D) this() nothrow { } - extern(D) this(const bad_typeid) nothrow { } - //bad_typeid operator=(const bad_typeid) nothrow { return this; } - //virtual ~this() nothrow; - override const (char)* what() const nothrow; - } -} -else version (CppRuntime_Microsoft) +version (CppRuntime_Microsoft) { import core.stdcpp.exception;