[Issue 24327] New: LDC --nogc
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Jan 11 07:00:16 UTC 2024
https://issues.dlang.org/show_bug.cgi?id=24327
Issue ID: 24327
Summary: LDC --nogc
Product: D
Version: D2
Hardware: x86_64
OS: Windows
Status: NEW
Severity: minor
Priority: P1
Component: tools
Assignee: nobody at puremagic.com
Reporter: black80 at bk.ru
import core.stdc.stdio;
class C {
@nogc:
public:
this() { printf( "C.C\n"); }
~this() { printf( "C.~C\n"); }
}
void main() @nogc {
printf( "=> main\n");
scope(exit) printf( "<= main\n");
scope c = new C(); // LOC 14
}
//-------------------------
ldc2 file.d - OK
ldc2 --nogc file.d: file.d(14): Error: No implicit garbage collector calls
allowed with -nogc option enabled: `_d_callfinalizer`
shouldn't check/call GC for scope vars
--
More information about the Digitalmars-d-bugs
mailing list