Bug 21726 – Wrong comparison in package(...) visibilities
Status
RESOLVED
Resolution
FIXED
Severity
major
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2021-03-17T16:17:16Z
Last change time
2021-04-02T05:45:34Z
Keywords
pull
Assigned to
No Owner
Creator
Berni44
Comments
Comment #0 by bugzilla — 2021-03-17T16:17:16Z
Compare
```
package(std.format):
package(std) someSymbol;
```
with
```
private:
public someSymbol;
```
In second case `someSymbol` is `public`, while in first case `someSymbol` is `package(std.format)`. IMHO it should be `package(std)`.
Comment #1 by dlang-bot — 2021-03-17T19:09:18Z
@ibuclaw created dlang/dmd pull request #12282 "fix Issue 21726 - Wrong comparison in package(...) visibilities" fixing this issue:
- fix Issue 21726 - Wrong comparison in package(...) visibilities
For the purpose of creating a new scope, it makes no sense to let the
most restrictive package attributes override any other nested visibility
attributes. As there is no other use of isSubsetOf(), the entire
function has been removed.
https://github.com/dlang/dmd/pull/12282
Comment #2 by dlang-bot — 2021-03-18T08:25:01Z
dlang/dmd pull request #12282 "fix Issue 21726 - Wrong comparison in package(...) visibilities" was merged into master:
- 35558cc21178142be008a82b8c41157e7337afb4 by Iain Buclaw:
fix Issue 21726 - Wrong comparison in package(...) visibilities
For the purpose of creating a new scope, it makes no sense to let the
most restrictive package attributes override any other nested visibility
attributes. As there is no other use of isSubsetOf(), the entire
function has been removed.
https://github.com/dlang/dmd/pull/12282
Comment #3 by dlang-bot — 2021-04-02T05:45:34Z
dlang/dmd pull request #12339 "[dmd-cxx] Backport fixes and trivial features from upstream dmd" was merged into dmd-cxx:
- 9450325e3e411cca5fb665d5f2c14387195503aa by Iain Buclaw:
[dmd-cxx] fix Issue 21726 - Wrong comparison in package(...) visibilities
For the purpose of creating a new scope, it makes no sense to let the
most restrictive package attributes override any other nested visibility
attributes. As there is no other use of isSubsetOf(), the entire
function has been removed.
https://github.com/dlang/dmd/pull/12339