[Issue 12314] Allow Duplicate Renamed Imports

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Aug 22 12:08:37 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=12314

RazvanN <razvan.nitu1305 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |razvan.nitu1305 at gmail.com
         Resolution|---                         |WONTFIX

--- Comment #8 from RazvanN <razvan.nitu1305 at gmail.com> ---
I don't really see any benefit in allowing this sort of behavior. If you have
only 2-3 modules that you are importing you can either just put those imports
top-level or just use them selectively inside the functions that require them.
I think that D already provides plenty of options for such scenarios, therefore
it is not needed to further complicate the language implementation to allow
such a narrow use case.

If needed, the workaround presented by Nick is applicable.

--


More information about the Digitalmars-d-bugs mailing list