Files
c3c/test/test_suite/compile_time/stringify2.c3t
Christoffer Lerno 25bccf4883 New faults and syntax (#2034)
- Remove `[?]` syntax.
- Change `int!` to `int?` syntax.
- New `fault` declarations.
- Enum associated values can reference the calling enum.
2025-03-10 00:11:35 +01:00

20 lines
344 B
Plaintext

// #target: macos-x64
module test;
import std::io;
fn void main()
{
var $s1 = $stringify(1 + 2);
char[*] s2 = $stringify($s1);
char[] s3 = $s1;
io::printfn("$s1 == %s", $s1);
io::printfn("s2 == %s", &s2);
io::printfn("s3 == %s", s3);
}
/* #expect: test.ll
c"$s1\00", align 1
c"1 + 2\00", align 1
c"1 + 2\00", align 1