June 08, 2010 [Issue 4297] New: Nothrow functions cannot use constant dynamic array | ||||
---|---|---|---|---|
| ||||
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: nobody@puremagic.com ReportedBy: rsinfu@gmail.com --- Comment #0 from Shin Fujishiro <rsinfu@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: ------- |
November 03, 2010 [Issue 4297] Nothrow functions cannot use constant dynamic array | ||||
---|---|---|---|---|
| ||||
Posted in reply to Shin Fujishiro | http://d.puremagic.com/issues/show_bug.cgi?id=4297 Don <clugdbug@yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |clugdbug@yahoo.com.au Resolution| |FIXED --- Comment #1 from Don <clugdbug@yahoo.com.au> 2010-11-03 06:35:59 PDT --- Fixed svn 736. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation