-
-
Notifications
You must be signed in to change notification settings - Fork 609
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Issue 18219 - Private import inside struct leaks symbols when use…
…d as VarDeclaration types
- Loading branch information
Showing
7 changed files
with
50 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| // EXTRA_SOURCES: imports/b18219.d | ||
| /* | ||
| TEST_OUTPUT: | ||
| --- | ||
| fail_compilation/fail18219.d(15): Error: no property 'Foobar' for type 'AST', did you mean 'b18219.Foobar'? | ||
| fail_compilation/fail18219.d(16): Error: no property 'Bar' for type 'AST' | ||
| fail_compilation/fail18219.d(17): Error: no property 'fun' for type 'AST', did you mean 'b18219.fun'? | ||
| fail_compilation/fail18219.d(18): Error: no property 'Foobar' for type 'AST', did you mean 'b18219.Foobar'? | ||
| --- | ||
| */ | ||
| import imports.a18219; | ||
|
|
||
| void main() | ||
| { | ||
| AST.Foobar t; | ||
| AST.Bar l; | ||
| AST.fun(); | ||
| AST.Foobar.smeth(); | ||
| } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| module a18219; | ||
|
|
||
| struct AST | ||
| { | ||
| import b18219; | ||
| } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| module b18219; | ||
|
|
||
| class Foobar | ||
| { | ||
| int a; | ||
| this(int a) | ||
| { | ||
| this.a = a; | ||
| } | ||
| static int smeth() | ||
| { | ||
| return 1; | ||
| } | ||
| } | ||
| void fun() {} |