-
-
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 branch 'merge_stable_convert' into merge_stable
Conflicts: src/access.d src/aggregate.d src/aliasthis.d src/apply.d src/argtypes.d src/arrayop.d src/arraytypes.d src/attrib.d src/builtin.d src/canthrow.d src/clone.d src/cond.d src/constfold.d src/cppmangle.d src/ctfeexpr.d src/dcast.d src/dclass.d src/declaration.d src/declaration.h src/delegatize.d src/denum.d src/dimport.d src/dinifile.d src/dinterpret.d src/dmacro.d src/dmangle.d src/dmodule.d src/doc.d src/dscope.d src/dstruct.d src/dsymbol.d src/dtemplate.d src/dunittest.d src/dversion.d src/errors.d src/escape.d src/expression.d src/func.d src/globals.d src/hdrgen.d src/identifier.d src/init.d src/inline.d src/json.d src/lexer.d src/lib.d src/link.d src/magicport.json src/mars.d src/mtype.d src/nogc.d src/nspace.d src/objc.d src/opover.d src/optimize.d src/parse.d src/root/file.d src/root/filename.d src/root/man.d src/root/outbuffer.d src/root/speller.d src/sapply.d src/sideeffect.d src/statement.d src/staticassert.d src/target.d src/tokens.d src/traits.d src/visitor.d test/runnable/sdtor.d
- Loading branch information
Showing
11 changed files
with
198 additions
and
86 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
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,28 @@ | ||
| nothrow: | ||
|
|
||
| version (Windows) | ||
| { | ||
| version (LP_64) | ||
| import core.stdc.stdlib; | ||
| else | ||
| // doesn't currently work b/c SEH remains present even in nothrow code | ||
| void* alloca(size_t) { return null; } | ||
| } | ||
| else | ||
| import core.stdc.stdlib; | ||
|
|
||
| struct S | ||
| { | ||
| ~this() nothrow {} | ||
| } | ||
|
|
||
| S foo(void* p = alloca(1234)) | ||
| { | ||
| return S(); | ||
| } | ||
|
|
||
| int main() | ||
| { | ||
| foo(); | ||
| return 0; | ||
| } |
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,32 @@ | ||
| /* | ||
| TEST_OUTPUT: | ||
| --- | ||
| fail_compilation/fail15044.d(30): Error: function fail15044.V.opAssign is not callable because it is annotated with @disable | ||
| --- | ||
| */ | ||
|
|
||
| struct S | ||
| { | ||
| void opAssign(S) {} | ||
| } | ||
|
|
||
| struct V | ||
| { | ||
| // `s` has opAssign, so struct V needs to generate member-wise opAssign. | ||
| // But S.opAssign is not callable on const object, so V.opAssign should be | ||
| // @disable. | ||
| const S s; | ||
|
|
||
| // Here, the initializer of x is evaluated in V.semantic2. But | ||
| // V.opAssign.semantic3 is not yet invoked, so its attribute should be | ||
| // lazily inferred in functionSemantic even though it's non-instantiated function. | ||
| enum int x = () | ||
| { | ||
| // Here, the initializer of x is evaluated in V.semantic2, and | ||
| // V.opAssign.semantic3 is not yet invoked in this time. | ||
| // Therefore its @disable attribute needs to be inferred by | ||
| // functionSemantic, even though it's non-instantiated function. | ||
| V v; | ||
| v = v; | ||
| }(); | ||
| } |
Oops, something went wrong.