Skip to content

Commit

Permalink
Merge pull request #4792 from kinke/merge_stable
Browse files Browse the repository at this point in the history
Merge upstream stable
  • Loading branch information
kinke authored Dec 1, 2024
2 parents 6c519ec + fbe4c6f commit a1e694c
Show file tree
Hide file tree
Showing 55 changed files with 198 additions and 103 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# LDC master

#### Big news
- Frontend, druntime and Phobos are at version [2.110.0](https://dlang.org/changelog/2.110.0.html). (#4707, #4737, #4749, #4768, #4784)
- Frontend, druntime and Phobos are at version [2.110.0](https://dlang.org/changelog/2.110.0.html). (#4707, #4737, #4749, #4768, #4784, #4792)
- Support for [LLVM 19](https://releases.llvm.org/19.1.0/docs/ReleaseNotes.html); LLVM for prebuilt packages bumped to v19.1.3 (incl. macOS arm64). (#4712, #4735, #4763, #4772)
- Android: NDK for prebuilt package bumped from r26d to r27c. (#4711, #4772)
- ldc2.conf: %%ldcconfigpath%% placeholder added - specifies the directory where current configuration file is located. (#4717)
Expand Down
4 changes: 2 additions & 2 deletions dmd/expressionsem.d
Original file line number Diff line number Diff line change
Expand Up @@ -5554,7 +5554,7 @@ private extern (C++) final class ExpressionSemanticVisitor : Visitor
{
if (exp.fd.ident == Id.empty)
{
const(char)[] s;
string s;
if (exp.fd.fes)
s = "__foreachbody";
else if (exp.fd.tok == TOK.reserved)
Expand Down Expand Up @@ -5588,7 +5588,7 @@ private extern (C++) final class ExpressionSemanticVisitor : Visitor
symtab = sds.symtab;
}
assert(symtab);
Identifier id = Identifier.generateId(s, symtab.length() + 1);
Identifier id = Identifier.generateIdWithLoc(s, exp.loc);
exp.fd.ident = id;
if (exp.td)
exp.td.ident = id;
Expand Down
1 change: 1 addition & 0 deletions dmd/frontend.h
Original file line number Diff line number Diff line change
Expand Up @@ -8692,6 +8692,7 @@ struct Id final
static Identifier* isRef;
static Identifier* isOut;
static Identifier* isLazy;
static Identifier* isCOMClass;
static Identifier* hasMember;
static Identifier* identifier;
static Identifier* fullyQualifiedName;
Expand Down
1 change: 1 addition & 0 deletions dmd/id.d
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,7 @@ immutable Msgtable[] msgtable =
{ "isRef" },
{ "isOut" },
{ "isLazy" },
{ "isCOMClass" },
{ "hasMember" },
{ "identifier" },
{ "fullyQualifiedName" },
Expand Down
20 changes: 20 additions & 0 deletions dmd/traits.d
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,26 @@ Expression semanticTraits(TraitsExp e, Scope* sc)

return isDeclX(d => (d.storage_class & STC.lazy_) != 0);
}
if (e.ident == Id.isCOMClass)
{
if (dim != 1)
return dimError(1);

auto o = (*e.args)[0];
auto s = getDsymbol(o);
AggregateDeclaration agg;

if (!s || ((agg = s.isAggregateDeclaration()) is null))
{
error(e.loc, "argument to `__traits(isCOMClass, %s)` is not a declaration", o.toChars());
return ErrorExp.get();
}

if (ClassDeclaration cd = agg.isClassDeclaration())
return cd.com ? True() : False();
else
return False();
}
if (e.ident == Id.identifier)
{
// Get identifier for symbol as a string literal
Expand Down
16 changes: 15 additions & 1 deletion runtime/druntime/src/core/internal/array/arrayassign.d
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ Tarr _d_arraysetassign(Tarr : T[], T)(return scope Tarr to, scope ref T value) @
static if (__traits(isCopyable, T))
copyEmplace(value, dst);
else
memcpy(cast(void*) &value, cast(void*) &dst, elemSize);
memcpy(cast(void*) &dst, cast(void*) &value, elemSize);
auto elem = cast(Unqual!T*) &tmp;
destroy(*elem);
}
Expand Down Expand Up @@ -395,6 +395,20 @@ Tarr _d_arraysetassign(Tarr : T[], T)(return scope Tarr to, scope ref T value) @
assert(arr == [S(1234), S(1234), S(1234), S(1234)]);
}

// disabled copy constructor
@safe unittest
{
static struct S
{
int val;
@disable this(ref S);
}
S[1] arr;
S s = S(1234);
_d_arraysetassign(arr[], s);
assert(arr[0].val == 1234);
}

// throwing and `nothrow`
@safe nothrow unittest
{
Expand Down
5 changes: 4 additions & 1 deletion runtime/druntime/src/core/lifetime.d
Original file line number Diff line number Diff line change
Expand Up @@ -2739,8 +2739,11 @@ if (is(T == class))
auto init = __traits(initSymbol, T);
void* p;

static if (__traits(getLinkage, T) == "Windows")
static if (__traits(isCOMClass, T))
{
// If this is a COM class we allocate it using malloc.
// This allows the reference counting to outlive the reference known about by the GC.

p = pureMalloc(init.length);
if (!p)
onOutOfMemoryError();
Expand Down
6 changes: 3 additions & 3 deletions tests/codegen/funcliteral_defaultarg_gh1634.d
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,17 @@ int foo(int function() d = () { return 123; })
// CHECK-LABEL: define{{.*}} @{{.*}}D3mod8call_fooFZi
int call_foo()
{
// CHECK: call {{.*}}D3mod3fooFPFZiZi{{.*}}D3mod9__lambda5FNaNbNiNfZi
// CHECK: call {{.*}}D3mod3fooFPFZiZi{{.*}}D3mod15__lambda_L9_C28FNaNbNiNfZi
return foo();
}

// The lambda is defined by the first call to foo with default arguments.
// CHECK-LABEL: define{{.*}} @{{.*}}D3mod9__lambda5FNaNbNiNfZi
// CHECK-LABEL: define{{.*}} @{{.*}}D3mod15__lambda_L9_C28FNaNbNiNfZi
// CHECK: ret i32 123

// CHECK-LABEL: define{{.*}} @{{.*}}Dmain
void main()
{
// CHECK: call {{.*}}D3mod3fooFPFZiZi{{.*}}D3mod9__lambda5FNaNbNiNfZi
// CHECK: call {{.*}}D3mod3fooFPFZiZi{{.*}}D3mod15__lambda_L9_C28FNaNbNiNfZi
assert(foo() == 123);
}
16 changes: 8 additions & 8 deletions tests/codegen/lambdas_gh3648.d
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,21 @@ void foo()
}

// the global variables should be defined as internal:
// CHECK: _D14lambdas_gh36489__lambda5FZ10global_bari{{.*}} = internal thread_local global
// CHECK: _D14lambdas_gh36489__lambda6FZ18global_bar_inlinedOi{{.*}} = internal global
// CHECK: _D14lambdas_gh36483fooFZ__T9__lambda1TiZQnFiZ12lambda_templi{{.*}} = internal global
// CHECK: _D14lambdas_gh364815__lambda_L5_C12FZ10global_bari{{.*}} = internal thread_local global
// CHECK: _D14lambdas_gh364816__lambda_L10_C20FZ18global_bar_inlinedOi{{.*}} = internal global
// CHECK: _D14lambdas_gh36483fooFZ__T15__lambda_L21_C5TiZQuFiZ12lambda_templi{{.*}} = internal global

// foo() should only call two lambdas:
// CHECK: define {{.*}}_D14lambdas_gh36483fooFZv
// CHECK-NEXT: call {{.*}}__lambda5
// CHECK-NEXT: call {{.*}}__T9__lambda1
// CHECK-NEXT: call {{.*}}__lambda_L5_C12
// CHECK-NEXT: call {{.*}}__T15__lambda_L21_C5
// CHECK-NEXT: ret void

// bar() should be defined as internal:
// CHECK: define internal {{.*}}__lambda5
// CHECK: define internal {{.*}}__lambda_L5_C12

// bar_inlined() should NOT have made it to the .ll:
// CHECK-NOT: define {{.*}}__lambda6
// CHECK-NOT: define {{.*}}__lambda_L10_C20

// the template lambda instance should be defined as internal:
// CHECK: define internal {{.*}}__T9__lambda1
// CHECK: define internal {{.*}}__T15__lambda_L21_C5
10 changes: 5 additions & 5 deletions tests/codegen/lambdas_gh3648b.d
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ void foo()
}

// the global variables should be defined as internal:
// CHECK: _D14lambdas_gh36489__lambda5FZ10global_bari{{.*}} = internal thread_local global
// CHECK: _D14lambdas_gh36489__lambda6FZ18global_bar_inlinedOi{{.*}} = internal global
// CHECK: _D14lambdas_gh364815__lambda_L5_C12FZ10global_bari{{.*}} = internal thread_local global
// CHECK: _D14lambdas_gh364816__lambda_L10_C20FZ18global_bar_inlinedOi{{.*}} = internal global

// foo() should only call one lambda:
// CHECK: define {{.*}}_D15lambdas_gh3648b3fooFZv
// CHECK-NEXT: call {{.*}}__lambda5
// CHECK-NEXT: call {{.*}}__lambda_L5_C12
// CHECK-NEXT: ret void

// bar() should be defined as internal:
// CHECK: define internal {{.*}}__lambda5
// CHECK: define internal {{.*}}__lambda_L5_C12

// bar_inlined() should NOT have made it to the .ll:
// CHECK-NOT: define {{.*}}__lambda6
// CHECK-NOT: define {{.*}}__lambda_L10_C20
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/b19523.d
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ TEST_OUTPUT:
----
fail_compilation/b19523.d(13): Error: undefined identifier `SomeStruct`
fail_compilation/b19523.d(14): Error: function `foo` is not callable using argument types `(_error_)`
fail_compilation/b19523.d(14): cannot pass argument `__lambda2` of type `_error_` to parameter `int delegate() arg`
fail_compilation/b19523.d(14): cannot pass argument `__lambda_L14_C6` of type `_error_` to parameter `int delegate() arg`
fail_compilation/b19523.d(19): `b19523.foo(int delegate() arg)` declared here
----
*/
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/bug9631.d
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ TEST_OUTPUT:
fail_compilation/bug9631.d(80): Error: function `f` is not callable using argument types `(int, S)`
fail_compilation/bug9631.d(80): cannot pass argument `y` of type `bug9631.tem!().S` to parameter `bug9631.S s`
fail_compilation/bug9631.d(79): `bug9631.arg.f(int i, S s)` declared here
fail_compilation/bug9631.d(81): Error: function literal `__lambda4(S s)` is not callable using argument types `(S)`
fail_compilation/bug9631.d(81): Error: function literal `__lambda_L81_C5(S s)` is not callable using argument types `(S)`
fail_compilation/bug9631.d(81): cannot pass argument `x` of type `bug9631.S` to parameter `bug9631.tem!().S s`
fail_compilation/bug9631.d(87): Error: constructor `bug9631.arg.A.this(S __param_0)` is not callable using argument types `(S)`
fail_compilation/bug9631.d(87): cannot pass argument `S(0)` of type `bug9631.tem!().S` to parameter `bug9631.S __param_0`
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/constraints_defs.d
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ TEST_OUTPUT:
fail_compilation/constraints_defs.d(49): Error: template instance `constraints_defs.main.def!(int, 0, (a) => a)` does not match template declaration `def(T, int i = 5, alias R)()`
with `T = int,
i = 0,
R = __lambda1`
R = __lambda_L49_C18`
must satisfy the following constraint:
` N!T`
fail_compilation/constraints_defs.d(50): Error: template instance `imports.constraints.defa!int` does not match template declaration `defa(T, U = int)()`
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/constraints_tmpl.d
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ fail_compilation/constraints_tmpl.d(41): Error: template instance `imports.const
` N!T
N!U`
fail_compilation/constraints_tmpl.d(43): Error: template instance `constraints_tmpl.main.lambda!((a) => a)` does not match template declaration `lambda(alias pred)()`
with `pred = __lambda1`
with `pred = __lambda_L43_C13`
must satisfy the following constraint:
` N!int`
---
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/cppvar.d
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ fail_compilation/cppvar.d(21): Error: variable `cppvar.staticVar` cannot have `e
fail_compilation/cppvar.d(21): perhaps declare it as `__gshared` instead
fail_compilation/cppvar.d(22): Error: variable `cppvar.sharedVar` cannot have `extern(C++)` linkage because it is `shared`
fail_compilation/cppvar.d(22): perhaps declare it as `__gshared` instead
fail_compilation/cppvar.d(30): Error: delegate `cppvar.__lambda7` cannot return type `bool[3]` because its linkage is `extern(C++)`
fail_compilation/cppvar.d(30): Error: delegate `cppvar.__lambda_L30_C46` cannot return type `bool[3]` because its linkage is `extern(C++)`
---
*/
#line 10
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/diag12829.d
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
TEST_OUTPUT:
---
fail_compilation/diag12829.d(15): Error: function `diag12829.test1` is `@nogc` yet allocates closure for `test1()` with the GC
fail_compilation/diag12829.d(18): delegate `diag12829.test1.__lambda2` closes over variable `x`
fail_compilation/diag12829.d(18): delegate `diag12829.test1.__lambda_L18_C33` closes over variable `x`
fail_compilation/diag12829.d(17): `x` declared here
fail_compilation/diag12829.d(22): function `diag12829.test1.bar` closes over variable `x`
fail_compilation/diag12829.d(17): `x` declared here
Expand Down
4 changes: 2 additions & 2 deletions tests/dmd/fail_compilation/diag15411.d
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
/*
TEST_OUTPUT:
---
fail_compilation/diag15411.d(17): Error: function `diag15411.test15411.__funcliteral2` cannot access variable `i` in frame of function `diag15411.test15411`
fail_compilation/diag15411.d(17): Error: function `diag15411.test15411.__funcliteral_L17_C15` cannot access variable `i` in frame of function `diag15411.test15411`
fail_compilation/diag15411.d(16): `i` declared here
fail_compilation/diag15411.d(18): Error: function `diag15411.test15411.__funcliteral4` cannot access variable `i` in frame of function `diag15411.test15411`
fail_compilation/diag15411.d(18): Error: function `diag15411.test15411.__funcliteral_L18_C15` cannot access variable `i` in frame of function `diag15411.test15411`
fail_compilation/diag15411.d(16): `i` declared here
fail_compilation/diag15411.d(26): Error: `static` function `diag15411.testNestedFunction.myFunc2` cannot access function `myFunc1` in frame of function `diag15411.testNestedFunction`
fail_compilation/diag15411.d(25): `myFunc1` declared here
Expand Down
4 changes: 2 additions & 2 deletions tests/dmd/fail_compilation/diag20268.d
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
/*
TEST_OUTPUT:
---
fail_compilation/diag20268.d(12): Error: template `__lambda4` is not callable using argument types `!()(int)`
fail_compilation/diag20268.d(11): Candidate is: `__lambda4(__T1, __T2)(x, y)`
fail_compilation/diag20268.d(12): Error: template `__lambda_L11_C1` is not callable using argument types `!()(int)`
fail_compilation/diag20268.d(11): Candidate is: `__lambda_L11_C1(__T1, __T2)(x, y)`
---
*/

Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/diag9831.d
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
TEST_OUTPUT:
---
fail_compilation/diag9831.d(13): Error: function `diag9831.main.__lambda3(__T1)(x)` cannot access variable `c` in frame of function `D main`
fail_compilation/diag9831.d(13): Error: function `diag9831.main.__lambda_L13_C12(__T1)(x)` cannot access variable `c` in frame of function `D main`
fail_compilation/diag9831.d(11): `c` declared here
---
*/
Expand Down
14 changes: 7 additions & 7 deletions tests/dmd/fail_compilation/diag_funclit.d
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
/**
TEST_OUTPUT:
---
fail_compilation/diag_funclit.d(103): Error: function literal `__lambda1(x, y, z)` is not callable using argument types `()`
fail_compilation/diag_funclit.d(103): Error: function literal `__lambda_L103_C5(x, y, z)` is not callable using argument types `()`
fail_compilation/diag_funclit.d(103): too few arguments, expected 3, got 0
fail_compilation/diag_funclit.d(106): Error: function literal `__lambda2(x, y, z)` is not callable using argument types `(int, string, int, int)`
fail_compilation/diag_funclit.d(106): Error: function literal `__lambda_L106_C5(x, y, z)` is not callable using argument types `(int, string, int, int)`
fail_compilation/diag_funclit.d(106): too many arguments, expected 3, got 4
fail_compilation/diag_funclit.d(108): Error: function literal `__lambda3(x, y, string z = "Hello")` is not callable using argument types `(int, int, string, string)`
fail_compilation/diag_funclit.d(108): Error: function literal `__lambda_L108_C5(x, y, string z = "Hello")` is not callable using argument types `(int, int, string, string)`
fail_compilation/diag_funclit.d(108): too many arguments, expected 3, got 4
fail_compilation/diag_funclit.d(110): Error: function literal `__lambda4(x, y, string z = "Hello")` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(110): Error: function literal `__lambda_L110_C5(x, y, string z = "Hello")` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(110): too few arguments, expected 3, got 1
fail_compilation/diag_funclit.d(112): Error: function literal `__lambda5(x, y, z)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(112): Error: function literal `__lambda_L112_C5(x, y, z)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(112): too few arguments, expected 3, got 1
fail_compilation/diag_funclit.d(115): Error: function literal `__lambda6(x, y, ...)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(115): Error: function literal `__lambda_L115_C5(x, y, ...)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(115): too few arguments, expected 2, got 1
fail_compilation/diag_funclit.d(117): Error: function literal `__lambda7(x, y, string z = "Hey", ...)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(117): Error: function literal `__lambda_L117_C5(x, y, string z = "Hey", ...)` is not callable using argument types `(int)`
fail_compilation/diag_funclit.d(117): too few arguments, expected 3, got 1
---
*/
Expand Down
4 changes: 2 additions & 2 deletions tests/dmd/fail_compilation/fail11125.d
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
TEST_OUTPUT:
---
fail_compilation/fail11125.d(26): Error: template instance `fail11125.filter!(function (int a) pure nothrow @nogc @safe => a + 1)` does not match template declaration `filter(alias predfun)`
with `predfun = __lambda1`
with `predfun = __lambda_L26_C13`
must satisfy the following constraint:
` is(ReturnType!predfun == bool)`
fail_compilation/fail11125.d(27): Error: template instance `fail11125.filter!(function (int a) pure nothrow @nogc @safe => a + 1)` does not match template declaration `filter(alias predfun)`
with `predfun = __lambda2`
with `predfun = __lambda_L27_C17`
must satisfy the following constraint:
` is(ReturnType!predfun == bool)`
---
Expand Down
4 changes: 2 additions & 2 deletions tests/dmd/fail_compilation/fail12236.d
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ fail_compilation/fail12236.d(16): while evaluating `pragma(msg, f1.mangle
fail_compilation/fail12236.d(21): Error: forward reference to inferred return type of function `f2`
fail_compilation/fail12236.d(21): while evaluating `pragma(msg, f2(T)(T).mangleof)`
fail_compilation/fail12236.d(27): Error: template instance `fail12236.f2!int` error instantiating
fail_compilation/fail12236.d(31): Error: forward reference to inferred return type of function `__lambda1`
fail_compilation/fail12236.d(31): while evaluating `pragma(msg, __lambda1(__T1)(a).mangleof)`
fail_compilation/fail12236.d(31): Error: forward reference to inferred return type of function `__lambda_L29_C5`
fail_compilation/fail12236.d(31): while evaluating `pragma(msg, __lambda_L29_C5(__T1)(a).mangleof)`
---
*/

Expand Down
6 changes: 3 additions & 3 deletions tests/dmd/fail_compilation/fail12378.d
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ fail_compilation/fail12378.d(18): Error: undefined identifier `ANYTHING`
fail_compilation/fail12378.d(18): Error: undefined identifier `GOES`
fail_compilation/fail12378.d(91): instantiated from here: `MapResultS!((x0) => ANYTHING - GOES, Result)`
fail_compilation/fail12378.d(17): instantiated from here: `mapS!(Result)`
fail_compilation/fail12378.d(100): instantiated from here: `__lambda1!int`
fail_compilation/fail12378.d(100): instantiated from here: `__lambda_L16_C19!int`
fail_compilation/fail12378.d(91): instantiated from here: `MapResultS!((y0) => iota(2).mapS!((x0) => ANYTHING - GOES), Result)`
fail_compilation/fail12378.d(16): instantiated from here: `mapS!(Result)`
---
Expand All @@ -27,7 +27,7 @@ fail_compilation/fail12378.d(40): Error: undefined identifier `ANYTHING`
fail_compilation/fail12378.d(40): Error: undefined identifier `GOES`
fail_compilation/fail12378.d(112): instantiated from here: `MapResultC!((x0) => ANYTHING - GOES, Result)`
fail_compilation/fail12378.d(39): instantiated from here: `mapC!(Result)`
fail_compilation/fail12378.d(123): instantiated from here: `__lambda1!int`
fail_compilation/fail12378.d(123): instantiated from here: `__lambda_L38_C19!int`
fail_compilation/fail12378.d(112): instantiated from here: `MapResultC!((y0) => iota(2).mapC!((x0) => ANYTHING - GOES), Result)`
fail_compilation/fail12378.d(38): instantiated from here: `mapC!(Result)`
---
Expand All @@ -49,7 +49,7 @@ fail_compilation/fail12378.d(64): Error: undefined identifier `ANYTHING`
fail_compilation/fail12378.d(64): Error: undefined identifier `GOES`
fail_compilation/fail12378.d(135): instantiated from here: `MapResultI!((x0) => ANYTHING - GOES, Result)`
fail_compilation/fail12378.d(63): instantiated from here: `mapI!(Result)`
fail_compilation/fail12378.d(143): instantiated from here: `__lambda1!int`
fail_compilation/fail12378.d(143): instantiated from here: `__lambda_L62_C19!int`
fail_compilation/fail12378.d(135): instantiated from here: `MapResultI!((y0) => iota(2).mapI!((x0) => ANYTHING - GOES), Result)`
fail_compilation/fail12378.d(62): instantiated from here: `mapI!(Result)`
---
Expand Down
2 changes: 1 addition & 1 deletion tests/dmd/fail_compilation/fail12908.d
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
TEST_OUTPUT:
---
fail_compilation/fail12908.d(14): Error: `pure` delegate `fail12908.main.__foreachbody1` cannot call impure function `fail12908.g`
fail_compilation/fail12908.d(14): Error: `pure` delegate `fail12908.main.__foreachbody_L12_C5` cannot call impure function `fail12908.g`
---
*/

Expand Down
4 changes: 2 additions & 2 deletions tests/dmd/fail_compilation/fail13120.d
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*
TEST_OUTPUT:
---
fail_compilation/fail13120.d(13): Error: `pure` delegate `fail13120.g1.__foreachbody2` cannot call impure function `fail13120.f1`
fail_compilation/fail13120.d(13): Error: `@nogc` delegate `fail13120.g1.__foreachbody2` cannot call non-@nogc function `fail13120.f1`
fail_compilation/fail13120.d(13): Error: `pure` delegate `fail13120.g1.__foreachbody_L12_C5` cannot call impure function `fail13120.f1`
fail_compilation/fail13120.d(13): Error: `@nogc` delegate `fail13120.g1.__foreachbody_L12_C5` cannot call non-@nogc function `fail13120.f1`
---
*/
void f1() {}
Expand Down
Loading

0 comments on commit a1e694c

Please sign in to comment.