mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 21:21:48 +03:00
21 lines
615 B
D
21 lines
615 B
D
/*
|
|
TEST_OUTPUT:
|
|
---
|
|
fail_compilation/fail18620.d(14): Error: `strlen` cannot be interpreted at compile time, because it has no available source code
|
|
fail_compilation/fail18620.d(19): compile time context created here
|
|
fail_compilation/fail18620.d(14): Error: `strlen` cannot be interpreted at compile time, because it has no available source code
|
|
fail_compilation/fail18620.d(20): compile time context created here
|
|
---
|
|
*/
|
|
class A{
|
|
this(const(char)* s)
|
|
{
|
|
import core.stdc.string;
|
|
auto a=strlen(s);
|
|
}
|
|
}
|
|
|
|
void main(){
|
|
static a = new A("a");
|
|
__gshared b = new A("b");
|
|
}
|