http://d.puremagic.com/issues/show_bug.cgi?id=4297
Summary: Nothrow functions cannot use constant dynamic array Product: D Version: 2.041 Platform: All OS/Version: All Status: NEW Keywords: rejects-valid Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: rsi...@gmail.com --- Comment #0 from Shin Fujishiro <rsi...@gmail.com> 2010-06-08 15:32:21 PDT --- DMD rejects nothrow functions which use compile-time constant dynamic array for violating nothrow. -------------------- immutable TABLE = [ 1, 2, 3 ]; pragma(msg, typeof(TABLE)); // immutable(int[]) void foo() nothrow // Error: function test.foo 'foo' is nothrow yet may throw { const(int)[] tab; tab = TABLE; } -------------------- The error does not occur if TABLE is declared with auto or immutable int[3] (instead of mere "immutable"). -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------