Bug 6534 – const struct definition inside functions too

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2011-08-19T23:22:00Z
Last change time
2012-10-08T04:44:52Z
Keywords
patch, rejects-valid
Assigned to
nobody
Creator
bearophile_hugs

Comments

Comment #0 by bearophile_hugs — 2011-08-19T23:22:23Z
void foo() { const struct Bar {} } void main() {} DMD 2.055beta: test.d(2): basic type expected, not struct test.d(2): no identifier for declarator int test.d(2): semicolon expected, not 'struct'
Comment #1 by bearophile_hugs — 2011-08-19T23:42:15Z
The same happens with static structs: void foo() { static const struct Bar {} } void main() {}
Comment #2 by bearophile_hugs — 2011-08-29T18:59:50Z
The same happens with immutable: void foo() { immutable struct Bar1 {} static immutable struct Bar2 {} } void main() {}
Comment #3 by bearophile_hugs — 2011-12-15T09:36:17Z
*** Issue 7114 has been marked as a duplicate of this issue. ***
Comment #4 by k.hara.pg — 2011-12-15T19:02:01Z
Comment #5 by k.hara.pg — 2011-12-27T06:26:39Z
*** Issue 5213 has been marked as a duplicate of this issue. ***
Comment #6 by github-bugzilla — 2012-10-08T04:44:21Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/0adbdc1d860a1d718d36fc6a982aaeb7667ed1d8 Issue 6534 - const struct definition inside functions too https://github.com/D-Programming-Language/dmd/commit/381eec8240dcc8eeacd9d81285b77f4324f32090 Merge pull request #562 from 9rnsr/fix6534 Issue 6534 & 7065 & 7172 - Parser improvements for inner aggregates
Comment #7 by yebblies — 2012-10-08T04:44:52Z