Alex Hoppen
c5aa49ba64
Revert "Isolated synchronous deinit"
2024-09-03 18:11:26 -07:00
Mykola Pokhylets
e0ad7bde82
Merge branch 'main' into mpokhylets/isolated-deinit
...
# Conflicts:
# include/swift/Basic/Features.def
# lib/AST/ASTPrinter.cpp
# lib/AST/FeatureSet.cpp
2024-08-29 11:28:43 +02:00
Doug Gregor
571859f294
Move "unsafe" diagnostics from errors to warnings
...
Warnings fit better with the approach we're going for, and can be
escalated to errors by `-warnings-as-errors` for clients that need it.
2024-08-19 14:34:00 -07:00
Doug Gregor
cccf6c1114
Introduce @unsafe and the ability to prohibit use of unsafe declarations
...
Allow any declaration to be marked with `@unsafe`, meaning that it
involves unsafe code. This also extends to C declarations marked with
the `swift_attr("unsafe")` attribute.
Under a separate experimental flag (`DisallowUnsafe`), diagnose any
attempt to use an `@unsafe` declaration or any unsafe language feature
(such as `unowned(unsafe)`, `@unchecked Sendable`). This begins to
define a "safe" mode in Swift that prohibits memory-unsafe constructs.
2024-08-19 14:33:07 -07:00
Mykola Pokhylets
50b1313175
Merge branch 'main' into mpokhylets/isolated-deinit
...
# Conflicts:
# lib/SILGen/SILGenDistributed.cpp
# lib/Sema/TypeCheckConcurrency.cpp
2024-08-15 16:58:43 +02:00
Alex Hoppen
dcee673688
Merge pull request #74522 from mateusrodriguesxyz/trailing-comma
2024-08-06 18:51:18 -07:00
Sima Nerush
6400a294a8
Merge pull request #70227 from simanerush/same-element-requirements
...
[Requirement Machine] Implement same-element requirements.
2024-08-06 14:24:33 -07:00
Mateus Rodrigues
ac57e61278
Merge branch 'main' into trailing-comma
2024-08-06 09:34:43 -03:00
Joe Groff
de687db20f
Disallow consuming self in a noncopyable deinit again.
...
The changes to allow for partial consumption unintentionally also allowed for
`self` to be consumed as a whole during `deinit`, which we don't yet want to
allow because it could lead to accidental "resurrection" and/or accidental
infinite recursion if the consuming method lets `deinit` be implicitly run
again. This makes it an error again. The experimental feature
`ConsumeSelfInDeinit` will allow it for test coverage or experimentation
purposes. rdar://132761460
2024-07-29 21:20:14 -07:00
Joe Groff
51829c17bf
@_extern is an experimental feature.
...
Mark it as such. rdar://132013078
2024-07-18 11:46:16 -07:00
Holly Borla
dbda2738a6
[Features] Gate same-element requirements behind an experimental feature flag.
2024-07-15 10:19:32 -07:00
Kavon Farvardin
4529f3b295
Merge pull request #75183 from kavon/remove-reverse-condfail-workaround
...
NCGenerics: remove the reverse-condfail workaround
2024-07-12 09:39:12 -07:00
Kavon Farvardin
5b2f2cbfcf
NCGenerics: remove the reverse-condfail workaround
...
This should no longer be needed, after having staged the first set of
changes in, as it was a temporary workaround.
resolves rdar://131560183
2024-07-11 14:30:27 -07:00
Mykola Pokhylets
816d62c972
Merge remote-tracking branch 'upstream/main' into mpokhylets/isolated-deinit
...
# Conflicts:
# include/swift/Basic/Features.def
# lib/SILGen/SILGenDestructor.cpp
# test/Concurrency/flow_isolation.swift
# test/abi/macOS/arm64/concurrency.swift
# test/abi/macOS/x86_64/concurrency.swift
2024-07-11 13:11:59 +02:00
Mykola Pokhylets
2cb7e8d7b8
Implemented suppressing isolated deinit for compatibility with older compiler versions
2024-07-11 13:09:08 +02:00
Allan Shortlidge
ab68c29701
AST: Remove interface guards for a bunch of experimental features.
...
Since these features are experimental features, they can't be catagorized as
"baseline" features. However, there is no need to guard code in swiftinterfaces
that potentially uses syntax related to these features since all supported
compilers can parse the syntax.
2024-07-09 14:29:31 -07:00
Allan Shortlidge
d944488a86
AST: Promote NewCxxMethodSafetyHeuristics feature to baseline.
2024-07-09 14:29:31 -07:00
Allan Shortlidge
aab4f1051c
AST: Promote BodyMacros feature to baseline.
2024-07-09 14:29:30 -07:00
Allan Shortlidge
0ba007661a
AST: Promote BuiltinAddressOfRawLayout to baseline.
2024-07-09 14:29:30 -07:00
Allan Shortlidge
45f3e94b46
AST: Promote AssociatedTypeImplements feature to baseline.
2024-07-09 14:28:30 -07:00
Allan Shortlidge
b71e73d04c
AST: Promote RetroactiveAttribute feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
e7ae787516
AST: Promote ConformanceSuppression feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
b46f23b502
AST: Promote BitwiseCopyable feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
b85da32707
AST: Promote OptionalIsolatedParameters feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
b39637159c
AST: Promote RethrowsProtocol feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
8093783e21
AST: Promote ExtensionMacroAttr feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
99dbbe4a12
AST: Promote BuiltinStoreRaw feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
8dad141136
AST: Promote Extern feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
365d26e323
AST: Promote ExpressionMacroDefaultArguments feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
ec13858479
AST: Promote BorrowingSwitch feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
c8a6a5041a
AST: Remove unused functions in FeatureSet.cpp.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
731d91f590
AST: Promote TypedThrows features to the baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
9717961202
AST: Promote BuiltinAllocVector feature to baseline.
2024-07-09 14:28:29 -07:00
Allan Shortlidge
ab99cac77d
AST: Promote BuiltinUnprotectedStackAlloc feature to baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
53451caf49
AST: Promote LexicalLifetimes feature to baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
5fb8082cc2
AST: Promote various move-only features to the baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
e1082bb8be
AST: Promote various macro features to baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
b517a44528
AST: Promote ParameterPacks feature to the baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
6b9b7bcd83
AST: Promote PrimaryAssociatedTypes2 feature to the baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
b5acc6b07d
AST: Promote AsyncSequenceFailure feature to the baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
6f972fc275
AST: Promote AssociatedTypeAvailability feature to the baseline.
2024-07-09 14:28:28 -07:00
Allan Shortlidge
9e5a9b963f
AST: Remove NoncopyableGenerics feature suppression.
...
It is no longer necessary to produce `.swiftinterface` files the support older
compilers that lack support for the NoncopyableGenerics feature. Cleaning this
up makes the stdlib `.swiftinterface` far more readable.
2024-07-08 17:44:24 -07:00
Allan Shortlidge
ee8a1152b2
Concurrency: Promote BuiltinCreateTask feature to baseline.
2024-07-02 22:26:55 -07:00
Allan Shortlidge
7e181d17e5
Concurrency: Promote BuiltinCreateAsyncDiscardingTaskInGroupWithExecutor feature to baseline.
2024-07-02 22:26:55 -07:00
Allan Shortlidge
e5744f04d6
Concurrency: Promote BuiltinCreateAsyncDiscardingTaskInGroup feature to baseline.
2024-07-02 22:26:55 -07:00
Allan Shortlidge
a4d58671ba
Concurrency: Promote BuiltinCreateAsyncTaskInGroupWithExecutor feature to baseline.
2024-07-02 22:26:54 -07:00
Allan Shortlidge
f2519650ae
Concurrency: Promote BuiltinBuildComplexEqualityExecutor feature to baseline.
2024-07-02 22:26:54 -07:00
Allan Shortlidge
ba630c0da5
Concurrency: Promote BuiltinBuildTaskExecutorRef feature to baseline.
2024-07-02 22:26:54 -07:00
Michael Gottesman
34195ff213
Merge pull request #74610 from gottesmm/pr-324fd70c13e87a329334341aae4667f2d1be152c
...
[sending] Remove transferring.
2024-07-02 14:02:18 -07:00
Xiaodi Wu
e1f537107f
Merge branch 'main' into trailing-comma
2024-06-29 16:36:06 -04:00