Bug 17496 – Ambiguous address taking of overloaded function is not rejected.

Status
NEW
Severity
normal
Priority
P3
Component
dmd
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2017-06-12T19:45:29Z
Last change time
2024-12-13T18:52:36Z
Assigned to
No Owner
Creator
Eyal
Moved to GitHub: dmd#19262 →

Comments

Comment #0 by eyal — 2017-06-12T19:45:29Z
struct S { int f() { return 4; } int f() { return 5; } } unittest { S s; static assert(!is(typeof(s.f()))); static assert(!is(typeof({ int delegate() foo = &s.f; }))); // fails, it ambiguously takes address }
Comment #1 by robert.schadek — 2024-12-13T18:52:36Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/19262 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB