cat > enh.d << CODE struct Foo { deprecated("use foo() instead") this(); } CODE dmd -c enh ---- Error: constructor enh.Foo.this default constructor for structs only allowed with @disable and no body ---- There is no mean to deprecate default construction of a struct before finally disabling it. We should enhance the compiler so that the above declaration is valid and using `Foo foo;` would emit a deprecation warning.
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18986 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB