Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue 2350 - Contracts with a naked body are indecent
Error on a naked function with contracts instead of generating wrong code
- Loading branch information
Showing
2 changed files
with
19 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
TEST_OUTPUT: | ||
--- | ||
fail_compilation/fail2350.d(8): Error: function fail2350.test2350 naked assembly functions with contracts are not supported | ||
--- | ||
*/ | ||
|
||
void test2350() | ||
in | ||
{ | ||
} | ||
body | ||
{ | ||
asm { naked; } | ||
} |