Bug 15674 – [REG 2.066] alias this rejected for 'out' parameter

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2016-02-12T14:05:00Z
Last change time
2016-02-24T02:55:29Z
Keywords
pull, rejects-valid
Assigned to
nobody
Creator
mathias.lang

Comments

Comment #0 by mathias.lang — 2016-02-12T14:05:27Z
The following code: ``` void get( out int i) { i = 42; } struct Foo { int v; alias v this; } void main () { Foo f; get(f); assert(f == 42); } ``` Produce the following error: reg.d(14): Error: function reg.get (out int i) is not callable using argument types (Foo) It used to work in 2.066, broke in 2.067, and is still broken. It still works with `ref`, though.
Comment #1 by pro.mathias.lang — 2016-02-13T01:12:06Z
Digger points to #4091
Comment #2 by k.hara.pg — 2016-02-13T06:20:25Z
Comment #3 by github-bugzilla — 2016-02-23T15:13:46Z
Commits pushed to stable at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/89c63bf1e1a508472fc88ac355fa7ccd39fe7802 fix Issue 15674 - alias this rejected for 'out' parameter https://github.com/D-Programming-Language/dmd/commit/7d1e77fe5a84a0eac0e1898b54f7e724302cf409 Merge pull request #5451 from 9rnsr/fix15674 [REG 2.066] Issue 15674 - alias this rejected for 'out' parameter
Comment #4 by github-bugzilla — 2016-02-24T02:55:29Z