Bug 13026 – object.get cannot be called with [] as "defaultValue" argument

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-07-02T23:43:00Z
Last change time
2014-08-22T08:04:05Z
Keywords
pull, rejects-valid
Assigned to
nobody
Creator
briancschott

Comments

Comment #0 by briancschott — 2014-07-02T23:43:08Z
void main() { int[][string] mapping; int[] v = get(mapping, "test", []); } does not compile with 2.066 (git master) Changing the code to this allows compilation to succeed: void main() { int[][string] mapping; int[] v = get(mapping, "test", (int[]).init); }
Comment #1 by hsteoh — 2014-07-03T16:46:13Z
This used to work in 2.064.
Comment #2 by k.hara.pg — 2014-07-04T19:45:49Z
Comment #3 by hsteoh — 2014-07-04T20:18:47Z
Wow that was fast. Thanks, Kenji!!!
Comment #4 by github-bugzilla — 2014-07-04T21:22:53Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/7b494aae863640bceb658d291b5f03d51ac0992f fix Issue 13026 - object.get cannot be called with [] as "defaultValue" argument https://github.com/D-Programming-Language/dmd/commit/0eaf76437dc992f7eb2f9ac1b840f1df3b4b9354 Merge pull request #3717 from 9rnsr/fix13026 [REG2.066a] Issue 13026 - object.get cannot be called with [] as "defaultValue" argument
Comment #5 by github-bugzilla — 2014-07-08T01:25:03Z
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/a8dd4dcf3cf30c75960c9b65d8a0d98f27c65e76 Merge pull request #3717 from 9rnsr/fix13026 [REG2.066a] Issue 13026 - object.get cannot be called with [] as "defaultValue" argument
Comment #6 by github-bugzilla — 2014-08-22T08:04:05Z