Commit Graph

16 Commits

Author SHA1 Message Date
Slava Pestov
1159af50d9 Rename -enable-resilience to -enable-library-evolution and make it a driver flag
Fixes <rdar://problem/47679085>.
2019-03-14 22:24:26 -04:00
Michael Gottesman
40a09c9c21 Fixup tests for -assume-parsing-unqualified-ownership-sil => [ossa] transition. 2018-12-18 00:49:32 -08:00
Michael Gottesman
9e13779702 [ownership] Remove most -enable-sil-ownership from SILGen now that %target-swift-emit-silgen does it automatically.
I did this using a sed pattern and verified by hand that I was only touching
target-swift-emit-silgen lines.
2018-12-13 11:54:54 -08:00
Erik Eckstein
39bb14b094 change mangling prefix from $S to $s
This is the final ABI mangling prefix

rdar://problem/38471478
2018-09-19 13:55:11 -07:00
Alex Hoppen
560c22b18e [tests] Verify the libSyntax tree on SILGen tests
The SILGen testsuite consists of valid Swift code covering most language
features. We use these tests to verify that no unknown nodes are in the
file's libSyntax tree. That way we will (hopefully) catch any future
changes or additions to the language which are not implemented in
libSyntax.
2018-04-27 09:33:03 -07:00
Slava Pestov
e85b20f019 SIL: Stored property initializers in non-resilient modules might need public linkage
Because of a ill-advised core team decision, Swift now
allows @_inlineable root initializers on types that
are not @_fixed_layout (aa85e4512f).

Since stored property initializers of types that are not
@_fixed_layout are permitted to reference non-public symbols,
they cannot be serialized and must instead have public
linkage. This negates most of the benefit of inlining the
constructor in the first place, but oh well.

This does not affect resilient builds.

Fixes <rdar://problem/38439363>.
2018-03-14 18:28:14 -07:00
Erik Eckstein
cd3d50a5d9 ABI: Change the mangling prefix from _T0 to $S 2018-01-06 13:55:59 -08:00
Pavel Yaskevich
6519d99736 [Mangling/ABI] NFC: Fix SILGen tests to reflect label mangling changes 2017-12-18 15:44:24 -08:00
Alex Hoppen
1c7e289b96 [Mangling] Adjust subscript mangling to not include "subscript"
Change the mangling of accessors to have a variable or subscript node
as their only child node, while subscript nodes no longer contain a decl
name.
2017-09-10 19:44:07 +02:00
Michael Gottesman
4ea0a402e1 [silgen] Update 31 more tests to run with the ownership verifier enabled.
Now ~32% of the SILGen tests run with the ownership verifier enabled.

rdar://33358110
2017-08-21 16:40:22 -07:00
Slava Pestov
e03e77d5a1 SILGen: Fix linkage for stored property initializers of private properties
Always give stored property initializers the linkage of the type
that contains them, even if the property is less visible than the
type.

This fixes the case where a type defines a private property, and an
extension in a different file from the same module defines a
constructor.

Fixes <rdar://problem/32743703>.
2017-06-28 02:13:35 -04:00
Erik Eckstein
c4a11f4c92 tests: remove the now unused option -new-mangling-for-tests 2017-03-22 11:28:43 -07:00
Slava Pestov
2fac86496f SILGen: Fix corner-case in emission of extension initializer
If the initializer is in a different file than the original
type, and the original type contains a stored property that
has both an initializer *and* a declared type, then the
initializer expression will not have been type checked.

So we must look at the type of pattern, which should still
be correct.

Fixes <https://bugs.swift.org/browse/SR-3942> and
<rdar://problem/25705157>.
2017-02-13 16:27:40 -08:00
Slava Pestov
a073f66aaf SILGen: Remove accidental check-in from a test 2017-02-03 16:22:58 -08:00
Erik Eckstein
1d3724666f tests: convert about 400 tests to the new mangling by using the -new-mangling-for-tests option
When the new mangling is enabled permanently, the option can be removed from the RUN command lines again.
2017-01-24 15:27:45 -08:00
Slava Pestov
f28f1158de SILGen: Fix emission of stored property initializers from different files
Fixes <https://bugs.swift.org/browse/SR-2982>.
2016-12-22 15:13:38 -05:00