mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 13:10:12 +03:00

* Fix Issue 15436 - Compiler still refers to AliasSeq-s as "tuple"-s Replace "tuple type" with "type sequence". Replace "tuple" with "sequence". Pretty print `AliasSeq!(args)`, not `tuple(args)`. Leave json as "tuple" for now. Also mention std.typecons.Tuple when trying to return a sequence. Note: This does not rename any internal compiler symbols. * Update runnable tests * Update stringof tests * Update remaining tests * retrigger tests
25 lines
715 B
D
25 lines
715 B
D
/*
|
|
TEST_OUTPUT:
|
|
---
|
|
fail_compilation/casttuple.d(104): Error: cannot cast `__tup1_field_0` of type `int` to type sequence `(string)`
|
|
fail_compilation/casttuple.d(107): Error: cannot cast `AliasSeq!(__tup2_field_0, __tup2_field_1)` of type `(int, int)` to type sequence `(string, string)`
|
|
fail_compilation/casttuple.d(111): Error: cannot cast `AliasSeq!(foo, 123)` of type `(int, int)` to type sequence `(string, string)`
|
|
---
|
|
*/
|
|
|
|
alias tuple(T...) = T;
|
|
|
|
#line 100
|
|
|
|
void nomatch()
|
|
{
|
|
tuple!int tup1;
|
|
auto x = cast(tuple!string) tup1;
|
|
|
|
tuple!(int, int) tup2;
|
|
auto y = cast(tuple!(string, string)) tup2;
|
|
|
|
int foo;
|
|
alias tup3 = tuple!(foo, 123);
|
|
auto z = cast(tuple!(string, string)) tup3;
|
|
}
|