Thread overview
[Issue 9809] Need a better diagnostic on accessing 'alias this' to private symbols
Sep 06, 2022
Nick Treleaven
Dec 17, 2022
Iain Buclaw
September 06, 2022
https://issues.dlang.org/show_bug.cgi?id=9809

Nick Treleaven <nick@geany.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
                 CC|                            |nick@geany.org
         Resolution|WORKSFORME                  |---

--- Comment #3 from Nick Treleaven <nick@geany.org> ---
(In reply to Andrej Mitrovic from comment #2)
> The diagnostic in 2.063.2 is now:
> 
> > Error: struct foo.X member s is not accessible

Can't reproduce that with v2.100.2-beta.1-dirty:

privaliasthis.d(6): Error: no property `func` for type `foo.X`

> perhaps the public alias to a private symbol should be disallowed in the first place.

I think a warning for that is needed, because people might not always test their type outside the module it's defined in.

--
December 17, 2022
https://issues.dlang.org/show_bug.cgi?id=9809

Iain Buclaw <ibuclaw@gdcproject.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P2                          |P3

--
December 13
https://issues.dlang.org/show_bug.cgi?id=9809

--- Comment #4 from dlangBugzillaToGithub <robert.schadek@posteo.de> ---
THIS ISSUE HAS BEEN MOVED TO GITHUB

https://github.com/dlang/dmd/issues/18545

DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB

--