-
-
Notifications
You must be signed in to change notification settings - Fork 608
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4691 from 9rnsr/fix_casting
Exhaustive fix for minor ICE "e2ir: cannot cast" (and fixes one reopened regression)
- Loading branch information
Showing
10 changed files
with
545 additions
and
58 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
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 |
|---|---|---|
| @@ -1,10 +1,12 @@ | ||
| void bug1176(){ | ||
| // REQUIRED_ARGS: -o- | ||
| /* | ||
| Error: void does not have a default initializer | ||
| Error: integral constant must be scalar type, not void | ||
| Error: cannot implicitly convert expression (0) of type int to const(void[]) | ||
| Error: cannot cast int to const(void[]) | ||
| Error: integral constant must be scalar type, not const(void[]) | ||
| TEST_OUTPUT: | ||
| --- | ||
| fail_compilation/fail233.d(11): Error: variable fail233.bug1176.v void[1] does not have a default initializer | ||
| --- | ||
| */ | ||
| void[1] v; | ||
|
|
||
| void bug1176() | ||
| { | ||
| void[1] v; | ||
| } |
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
Oops, something went wrong.