Commit Graph

1962 Commits

Author SHA1 Message Date
Doug Gregor
1b3fda7857 Merge pull request #64060 from DougGregor/enable-swift-syntax-formatter 2023-03-03 06:24:29 -08:00
Doug Gregor
53989ad72c [Diagnostics] Use the new swift-syntax formatter for -diagnostic-style swift.
We're going to move toward the new swift-syntax formatter. Use it for
the "swift" diagnostic style instead of the experimental formatter
written in C++.

There are some tests for the experimental formatter in C++ that test
precise formatting of diagnostics. I've disabled them in the same
places where the new swift-syntax formatter is enabled, for now. We
may choose to remove them entirely, because swift-syntax itself is
where the specific format is defined, and has those same kinds of
tests already.
2023-03-02 21:58:27 -08:00
Mishal Shah
e256b56545 Merge branch 'main' into rebranch 2023-03-02 18:25:09 -08:00
Andrew Trick
bffe0e7736 Merge pull request #64022 from atrick/ossa-complete-util
[NFC] Add SILGenCleanup::completeOSSLifetimes
2023-03-02 08:53:44 -08:00
Andrew Trick
2743b83b8e Added option: -enable-ossa-complete-lifetimes
Disabled by default during initial testing.
2023-03-01 21:41:46 -08:00
Ben Barham
59afba5bf9 Manually merge branch 'main' into rebranch 2023-03-01 14:13:50 -08:00
Artem Chikin
1600bee812 Merge pull request #63975 from artemcm/ClangModuleValidatePerSeshhhh
Add Swift compilation flags to enable Clang's validate-per-build-session module behavior
2023-03-01 08:40:37 -08:00
Artem Chikin
3ea5087e2f Add Swift compilation flags to enable Clang's validate-per-build-session module behavior
Add '-validate-clang-modules-once' and '-clang-build-session-file' corresponding to Clang's '-fmodules-validate-once-per-build-session' and '-fbuild-session-file='. Ensure they are propagated to module interface build sub-invocations.

We require these to be first-class Swift options in order to ensure they are propagated to both: ClangImporter and implicit interface build compiler sub-invocations.

Compiler portion of rdar://105982120
2023-02-28 13:19:05 -08:00
QuietMisdreavus
164e93e0a7 Merge pull request #63726 from apple/QuietMisdreavus/skip-proto-impls
[SymbolGraphGen] add new flag to skip "protocol implementation" symbols

rdar://59899968
2023-02-28 10:50:01 -07:00
Arnold Schwaighofer
1dfc30eb1f Merge remote-tracking branch 'origin/main' into rebranch 2023-02-27 09:18:56 -08:00
Arnold Schwaighofer
8a7b8dc39c IRGen: Put type descriptors in their own section to collocated them
rdar://104697150
2023-02-25 07:51:30 -08:00
swift-ci
76b7966ccb Merge remote-tracking branch 'origin/main' into rebranch 2023-02-20 22:16:03 -08:00
Alejandro Alonso
10f85db170 Merge pull request #63734 from Azoy/builtin-flag
[Frontend] Add option to explicitly import Builtin
2023-02-20 22:08:02 -08:00
swift-ci
2f942098d5 Merge remote-tracking branch 'origin/main' into rebranch 2023-02-20 15:33:54 -08:00
Doug Gregor
165827ce9d Use -strict-concurrency=minimal as the default for Swift 5.x mode.
Emulate the behavior of Swift 5.5/5.6 by default, using
`-strict-concurrency=minimal`.
2023-02-20 11:14:46 -08:00
Alejandro Alonso
023c40c809 Add option to explicitly import Builtin 2023-02-16 15:23:45 -08:00
Victoria Mitchell
4ec3e5291f add new flag to skip "protocol implementation" symbols
rdar://59899968
2023-02-16 14:00:04 -07:00
swift-ci
5acf1c372e Merge remote-tracking branch 'origin/main' into rebranch 2023-02-16 12:54:58 -08:00
Rintaro Ishizaki
c82e17acb7 Merge pull request #63695 from rintaro/options-load-plugin-executable
[Option] Add compiler option to specify executable plugins
2023-02-16 12:35:35 -08:00
swift-ci
3d54aef31f Merge remote-tracking branch 'origin/main' into rebranch 2023-02-16 07:14:44 -08:00
Nate Chandler
1246a152a4 [Frontend] Relaxed flag combination check.
Previously, combining `-enable-lexical-lifetimes=false` with
`-enable-experimental-move-only` resulted in an error.  But this is a
valid combination: the former sets the `LexicalLifetimes` option to
`DiagnosticMarkersOnly`, which is what `-enable-experimental-move-only`
relies on.
2023-02-15 16:13:47 -08:00
Rintaro Ishizaki
bf0a62f3ce [Option] Add compiler option to specify executable plugins
Add a compiler option `-load-plugin-executable <path>#<module names>`.
Where '<path>' is a path to a plugin executable, '<module-name>' is a
comma-separated module names the plugin provides.

Nothing is using it at this point. Actual plugin infratructure are
introduced in follow-up commits
2023-02-15 14:43:21 -08:00
swift-ci
e1cd7779f7 Merge remote-tracking branch 'origin/main' into rebranch 2023-02-10 00:35:26 -08:00
Doug Gregor
4705183149 [Macros] Add plugin search paths to load plugin modules by name.
Introduce `-plugin-path <path>` to add a search path where we will look
for compiler plugins. When resolving an external macro definition, look
for libraries in these search paths whose names match the module name
of the macro.

Implements rdar://105095761.
2023-02-09 13:47:26 -08:00
swift-ci
8e7eae199e Merge remote-tracking branch 'origin/main' into rebranch 2023-02-08 07:33:02 -08:00
Artem Chikin
c1599fede4 Add -swift-module-file frontend flag for explicit Swift module dependencies 2023-02-07 11:29:09 -07:00
swift-ci
d4f981232a Merge remote-tracking branch 'origin/main' into rebranch 2023-02-03 15:35:20 -08:00
Ellie Shin
258b13b05d Merge pull request #63355 from apple/es-export-pr
Add access level and scope checks to package types
2023-02-03 15:20:29 -08:00
Ellie Shin
be20333a87 Add access level and scope checks to package types
Resolves rdar://104617227
2023-02-02 16:51:17 -08:00
swift-ci
409f9c7f40 Merge remote-tracking branch 'origin/main' into rebranch 2023-02-01 14:34:59 -08:00
Ben Barham
8c7f331ba7 Merge pull request #63339 from bnbarham/wd-hack
[Frontend] Split -working-directory<path>
2023-02-01 14:16:47 -08:00
Ben Barham
b5caa97b6b [Frontend] Split -working-directory<path>
Clang no longer supports `-working-directory<path>`. Split this argument
into `-working-directory <path>` so that clients passing the old
argument still work.
2023-01-31 16:17:11 -08:00
swift-ci
ef62fdf232 Merge remote-tracking branch 'origin/main' into rebranch 2023-01-31 11:53:53 -08:00
Doug Gregor
8871129896 [Macros] Add frontend flag to dump macro expansions for diagnostics.
Add frontend flag `-emit-macro-expansion-files diagnostics` to emit any
macro expansion buffers referenced by diagnostics into files in a
temporary directory. This makes debugging type-checking failures in
macro expansions far easier, because you can see them after the
compiler process has exited.
2023-01-30 18:05:53 -08:00
swift-ci
df75f6ee09 Merge remote-tracking branch 'origin/main' into rebranch 2023-01-25 22:33:52 -08:00
swift-ci
281088eb73 Merge pull request #63204 from meg-gupta/ptrauthcodegenpr
Initial support for ptrauth qualified function pointers in C
2023-01-25 22:19:34 -08:00
Meghana Gupta
a515e0db8e Add EnableImportPtrauthFieldFunctionPointers flag 2023-01-25 12:37:57 -08:00
Erik Eckstein
87ed8b4dc3 Merge remote-tracking branch 'origin/main' into rebranch 2023-01-24 08:58:16 +01:00
Doug Gregor
fa845d8eb2 Merge pull request #63153 from DougGregor/swift-syntax-diagnostic-style
[Diagnostics] Add a swift-syntax diagnostic style
2023-01-22 13:44:14 -08:00
Doug Gregor
bdf1183757 [Diagnostics] Add a swift-syntax diagnostic style
The SwiftDiagnostics module within swift-syntax has a diagnostic
pretty-printer that does a nice rendering of the source code with
diagnostics placed inside gaps between the code lines.
Introduce another `-diagnostic-style` argument, `swift-syntax`,
to bridge from the pretty-printed C++ diagnostics over to the
swift-syntax diagnostics engine.
2023-01-21 23:09:56 -08:00
swift-ci
5388055f12 Merge remote-tracking branch 'origin/main' into rebranch 2023-01-19 09:14:10 -08:00
Arnold Schwaighofer
8a38738abf IRGen: Initial support for relative protocol witness table emission 2023-01-18 13:43:25 -08:00
Erik Eckstein
712fd7922b Merge remote-tracking branch 'origin/main' into rebranch 2023-01-09 08:48:47 +01:00
Alexis Laferrière
d1343c86fb [Frontend] Intro flags to control deserialization safety
Deserialization safety remains off by default at the moment.
2023-01-06 12:02:47 -08:00
swift-ci
dcfb01cfb3 Merge remote-tracking branch 'origin/main' into rebranch 2022-12-13 09:16:29 -08:00
Alexis Laferrière
010973c276 [Frontend|NFC] Rename ModuleInterfaceOptions::PrintPrivateInterfaceContent 2022-12-08 15:10:03 -08:00
Ben Barham
68d5d1f9ca Merge remote-tracking branch 'origin/main' into rebranch
Conflicts:
  lib/Frontend/CompilerInvocation.cpp - legacy pass manager removed
2022-12-07 10:13:47 -08:00
Arnold Schwaighofer
39e5e3990d IRGen: Co-locate metadata instatiation/completions/accessor functions in a special section
For spatial locality on startup.

Hide collocating metadata functions in a separate section behind a flag.
The default is not to collocate functions.

rdar://101593202
2022-12-05 09:52:04 -08:00
swift-ci
4e20be1f15 Merge remote-tracking branch 'origin/main' into rebranch 2022-12-01 01:34:17 -08:00
Franklin Schrans
d3e96590d9 Merge pull request #61637 from theMomax/extension-block-symbols-deactivation-flag
Make emission of extension block symbols a formal feature
2022-12-01 08:18:24 +01:00