diff options
author | Iain Buclaw <ibuclaw@gdcproject.org> | 2022-02-20 20:02:23 +0100 |
---|---|---|
committer | Iain Buclaw <ibuclaw@gdcproject.org> | 2022-02-20 23:37:32 +0100 |
commit | 6384eff56dba1fac071c1b525f7e49cf03f2737f (patch) | |
tree | 7263a4a6ec603a81f6df660f4f6b19a4607513fc /gcc/testsuite/gdc.dg | |
parent | e49508ac6b36adb8a2056c5a1fb6e0178de2439d (diff) | |
download | gcc-6384eff56dba1fac071c1b525f7e49cf03f2737f.zip gcc-6384eff56dba1fac071c1b525f7e49cf03f2737f.tar.gz gcc-6384eff56dba1fac071c1b525f7e49cf03f2737f.tar.bz2 |
d: Merge upstream dmd cb49e99f8, druntime 55528bd1, phobos 1a3e80ec2.
D front-end changes:
- Import dmd v2.099.0-beta.1.
- It's now an error to use `alias this' for partial assignment.
- The `delete' keyword has been removed from the language.
- Using `this' and `super' as types has been removed from the
language, the parser no longer specially handles this wrong code
with an informative error.
D Runtime changes:
- Import druntime v2.099.0-beta.1.
Phobos changes:
- Import phobos v2.099.0-beta.1.
gcc/d/ChangeLog:
* dmd/MERGE: Merge upstream dmd cb49e99f8.
* dmd/VERSION: Update version to v2.099.0-beta.1.
* decl.cc (layout_class_initializer): Update call to NewExp::create.
* expr.cc (ExprVisitor::visit (DeleteExp *)): Remove handling of
deleting arrays and pointers.
(ExprVisitor::visit (DotVarExp *)): Convert complex types to the
front-end library type representing them.
(ExprVisitor::visit (StringExp *)): Use getCodeUnit instead of charAt
to get the value of each index in a string expression.
* runtime.def (DELMEMORY): Remove.
(DELARRAYT): Remove.
* types.cc (TypeVisitor::visit (TypeEnum *)): Handle anonymous enums.
libphobos/ChangeLog:
* libdruntime/MERGE: Merge upstream druntime 55528bd1.
* src/MERGE: Merge upstream phobos 1a3e80ec2.
* testsuite/libphobos.hash/test_hash.d: Update.
* testsuite/libphobos.betterc/test19933.d: New test.
Diffstat (limited to 'gcc/testsuite/gdc.dg')
-rw-r--r-- | gcc/testsuite/gdc.dg/special1.d | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/testsuite/gdc.dg/special1.d b/gcc/testsuite/gdc.dg/special1.d new file mode 100644 index 0000000..8881dd0 --- /dev/null +++ b/gcc/testsuite/gdc.dg/special1.d @@ -0,0 +1,12 @@ +// { dg-do compile } + +struct _Complex(T) { T re; T im; } +enum __c_complex_float : _Complex!float; + +bool equals(__c_complex_float[] lhs, __c_complex_float[] rhs) +{ + foreach (i; 0 .. lhs.length) + if (lhs.ptr[i] != rhs.ptr[i]) + return false; + return true; +} |