diff options
author | Iain Buclaw <ibuclaw@gdcproject.org> | 2023-08-15 16:29:08 +0200 |
---|---|---|
committer | Iain Buclaw <ibuclaw@gdcproject.org> | 2023-08-20 11:20:00 +0200 |
commit | d77c280454cfba48ef38357145cecdabc8c1b05c (patch) | |
tree | 49e02afce6ab03a3405752c963b6ffb225012a40 /gcc/testsuite/gdc.test/runnable | |
parent | ce33bbfcbc7dd3afc6c96fb48a19ed00f0c598ce (diff) | |
download | gcc-d77c280454cfba48ef38357145cecdabc8c1b05c.zip gcc-d77c280454cfba48ef38357145cecdabc8c1b05c.tar.gz gcc-d77c280454cfba48ef38357145cecdabc8c1b05c.tar.bz2 |
d: Merge upstream dmd, druntime 26f049fb26, phobos 330d6a4fd.
D front-end changes:
- Import dmd v2.105.0-beta.1.
- Added predefined version identifier VisionOS (ignored by GDC).
- Functions can no longer have `enum` storage class.
- The deprecation of the `body` keyword has been reverted, it is
now an obsolete feature.
- The error for `scope class` has been reverted, it is now an
obsolete feature.
D runtime changes:
- Import druntime v2.105.0-beta.1.
Phobos changes:
- Import phobos v2.105.0-beta.1.
- AliasSeq has been removed from std.math.
- extern(C) getdelim and getline have been removed from
std.stdio.
gcc/d/ChangeLog:
* dmd/MERGE: Merge upstream dmd 26f049fb26.
* dmd/VERSION: Bump version to v2.105.0-beta.1.
* d-codegen.cc (get_frameinfo): Check useGC in condition.
* d-lang.cc (d_handle_option): Set obsolete parameter when compiling
with -Wall.
(d_post_options): Set useGC to false when compiling with
-fno-druntime. Propagate obsolete flag to compileEnv.
* expr.cc (ExprVisitor::visit (CatExp *)): Check useGC in condition.
libphobos/ChangeLog:
* libdruntime/MERGE: Merge upstream druntime 26f049fb26.
* src/MERGE: Merge upstream phobos 330d6a4fd.
Diffstat (limited to 'gcc/testsuite/gdc.test/runnable')
-rw-r--r-- | gcc/testsuite/gdc.test/runnable/betterc.d | 11 | ||||
-rw-r--r-- | gcc/testsuite/gdc.test/runnable/sctor2.d | 5 | ||||
-rw-r--r-- | gcc/testsuite/gdc.test/runnable/test24029.c | 23 | ||||
-rw-r--r-- | gcc/testsuite/gdc.test/runnable/testcontracts.d | 16 |
4 files changed, 34 insertions, 21 deletions
diff --git a/gcc/testsuite/gdc.test/runnable/betterc.d b/gcc/testsuite/gdc.test/runnable/betterc.d index 3d8f7da..0fc32c7 100644 --- a/gcc/testsuite/gdc.test/runnable/betterc.d +++ b/gcc/testsuite/gdc.test/runnable/betterc.d @@ -210,3 +210,14 @@ int test20737() tlsVar = 123; return 0; } + +/*******************************************/ +// https://issues.dlang.org/show_bug.cgi?id=22427 +void test22427() +{ + if("a" == "a") + return; + + char[] p; + auto a = cast(int[])p; +} diff --git a/gcc/testsuite/gdc.test/runnable/sctor2.d b/gcc/testsuite/gdc.test/runnable/sctor2.d index bd820e4..a574c3e 100644 --- a/gcc/testsuite/gdc.test/runnable/sctor2.d +++ b/gcc/testsuite/gdc.test/runnable/sctor2.d @@ -1,10 +1,5 @@ // REQUIRED_ARGS: -w -dw // PERMUTE_ARGS: -/* TEST_OUTPUT: ---- -runnable/sctor2.d(12): Deprecation: `scope` as a type constraint is deprecated. Use `scope` at the usage site. ---- -*/ /***************************************************/ // 15665 diff --git a/gcc/testsuite/gdc.test/runnable/test24029.c b/gcc/testsuite/gdc.test/runnable/test24029.c new file mode 100644 index 0000000..145f2c2 --- /dev/null +++ b/gcc/testsuite/gdc.test/runnable/test24029.c @@ -0,0 +1,23 @@ +// https://issues.dlang.org/show_bug.cgi?id=24029 + +int x = 0; +int y = 0; + +void a() +{ + (__extension__ ({ x += 2; })); // test.a.__dgliteral1 +} + +void b() +{ + (__extension__ ({ y += 1; })); // test.b.__dgliteral1 +} + +int main(void) +{ + a(); + b(); + __check(x == 2); + __check(y == 1); + return 0; +} diff --git a/gcc/testsuite/gdc.test/runnable/testcontracts.d b/gcc/testsuite/gdc.test/runnable/testcontracts.d index 439040b..63d18fc 100644 --- a/gcc/testsuite/gdc.test/runnable/testcontracts.d +++ b/gcc/testsuite/gdc.test/runnable/testcontracts.d @@ -1,20 +1,4 @@ /* PERMUTE_ARGS: -inline -g -O -TEST_OUTPUT: ---- -runnable/testcontracts.d(323): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(324): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(325): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(326): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(328): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(329): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(330): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(331): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(502): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(503): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(504): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(505): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. -runnable/testcontracts.d(505): Deprecation: usage of the `body` keyword is deprecated. Use `do` instead. ---- */ extern(C) int printf(const char*, ...); |