Commit Graph

35 Commits

Author SHA1 Message Date
Andrew Trick
1f5133c28c Temporarily disable this test until it can be updated.
It looks like this only fails on stdlib+debuginfo builds after:
8a5ed4 Make var parameters an error for Swift 3

<rdar://problem/24428756> DebugInfo/basic.swift test fails after fixing var params
2016-01-31 02:02:46 -08:00
David Farler
8a5ed405bf Make var parameters an error for Swift 3
This finishes up revisions to SE-0003 - only var function parameters
are disallowed for Swift 3.
2016-01-30 12:39:17 -08:00
David Farler
3f635d04c7 Reinstante var bindings in refutable patterns, except function parameters.
This reverts commits: b96e06da44,
                      8f2fbdc93a,
                      93b6962478,
                      64024118f4,
                      a759ca9141,
                      3434f9642b,
                      9f33429891,
                      47c043e8a6.

This commit leaves 'var' on function parameters as a warning to be
merged into Swift 2.2. For Swift 3, this will be an error, to be
converted in a follow-up.
2016-01-29 15:27:08 -08:00
David Farler
8f2fbdc93a Make function parameters and refutable patterns always immutable
All refutable patterns and function parameters marked with 'var'
is now an error.

- Using explicit 'let' keyword on function parameters causes a warning.
- Don't suggest making function parameters mutable
- Remove uses in the standard library
- Update tests

rdar://problem/23378003
2015-11-09 16:56:13 -08:00
Adrian Prantl
3356f7ac59 Pass the debug info settings through to Clang and ensure that compile units
created by Swift and Clang set the CU's compilation dir similarly.

rdar://problem/22692266

Swift SVN r32637
2015-10-12 22:20:58 +00:00
Joe Groff
0cd5aa8c7c Change mangling for the Swift module from 'Ss' to 's'.
'Ss' appears in manglings tens of thousands of times in the standard library and is also incredibly frequent in other modules. This alone is enough to shrink the standard library by 59KB.

Swift SVN r32409
2015-10-02 22:39:44 +00:00
Michael Gottesman
6d74962918 Adapt all DebugInfo testcases to the new upstream LLVM metadata format.
Swift SVN r31813
2015-09-09 04:37:34 +00:00
Adrian Prantl
c5dd8bea82 Debug Info: Migrate from MDModule to DIModule.
MDModule was a bitcode-incompatible internal-only extension that has
since been replaced with a blessed IR node on trunk.

<rdar://problem/20965932> Upstream DIModule and support it in clang-700, swiftlang-700, and lldb-700

Swift SVN r29832
2015-07-01 02:25:22 +00:00
Adrian Prantl
301aae1492 Promote the "true"-Scope of a condition to an actual lexical scope.
<rdar://problem/20394204> Scoping of if/let declarations too broad

Swift SVN r28203
2015-05-06 16:40:11 +00:00
Duncan Exon Smith
c6d42db070 Adapt to MD* => DI* renaming of debug info types
Applied the upgrade script from r236120 (LLVM) and r236121 (CFE).  This is the
final step of rdar://problem/20434113.



Swift SVN r27925
2015-04-29 21:40:21 +00:00
Doug Gregor
793b3326af Implement the new rules for argument label defaults.
The rule changes are as follows:
  * All functions (introduced with the 'func' keyword) have argument
  labels for arguments beyond the first, by default. Methods are no
  longer special in this regard.
  * The presence of a default argument no longer implies an argument
  label.

The actual changes to the parser and printer are fairly simple; the
rest of the noise is updating the standard library, overlays, tests,
etc.

With the standard library, this change is intended to be API neutral:
I've added/removed #'s and _'s as appropriate to keep the user
interface the same. If we want to separately consider using argument
labels for more free functions now that the defaults in the language
have shifted, we can tackle that separately.

Fixes rdar://problem/17218256.

Swift SVN r27704
2015-04-24 19:03:30 +00:00
Adrian Prantl
2a4c39ddd9 Also accept "Apple Swift" as a valid producer.
Swift SVN r25728
2015-03-04 00:15:13 +00:00
Adrian Prantl
f5432e4a3b remove stale comment
Swift SVN r25727
2015-03-04 00:05:26 +00:00
Duncan Exon Smith
093eb3c365 DebugInfo: Hand-update testcases after LLVM r231082
Update debug info testcases after moving the new hierarchy into place in
upstream LLVM r231082.

rdar://problem/19720042



Swift SVN r25715
2015-03-03 19:15:31 +00:00
Dmitri Hrybenko
ab5dfa0cd0 Adjust tests for the upstream changes in the LLVM IR syntax
Swift SVN r25655
2015-03-01 09:28:51 +00:00
Joe Groff
63463f54ac SIL: Mangle the static-ness of declarations.
This lets us disambiguate the symbols for static and instance properties, and enables us to eventually leave the useless "self" type mangling out of method symbols. Fixes rdar://19012022 and dupes thereof, including crasher #1341.

Swift SVN r25111
2015-02-10 02:37:35 +00:00
Dmitri Hrybenko
3b04d1b013 tests: reorganize tests so that they actually use the target platform
Most tests were using %swift or similar substitutions, which did not
include the target triple and SDK.  The driver was defaulting to the
host OS.  Thus, we could not run the tests when the standard library was
not built for OS X.

Swift SVN r24504
2015-01-19 06:52:49 +00:00
Adrian Prantl
d7489b7272 Update testcases for new LLVM IR assembler syntax.
Swift SVN r24428
2015-01-14 23:38:18 +00:00
Adrian Prantl
12838bd2df Manually update testcases where the automatic upgrader wasn't able to.
Swift SVN r23943
2014-12-15 20:47:50 +00:00
Adrian Prantl
162bc8d24c Updated testcases for upstream assembler changes.
Swift SVN r23942
2014-12-15 19:39:21 +00:00
Adrian Prantl
41a30f5988 Support line table only DWARF for Swift. <rdar://problem/19106981>
The new option is called -gline-tables-only to mirror clang.

Swift SVN r23615
2014-12-02 17:44:23 +00:00
Graham Batty
83f27a8af7 Revert "Mark tests that don't pass on linux as XFAIL."
This reverts commit 2711ca86de7bf6a7885ccea24219a48a590b1e95.

Swift SVN r23577
2014-11-24 17:42:13 +00:00
Graham Batty
198402dcfe Mark tests that don't pass on linux as XFAIL.
Swift SVN r23573
2014-11-24 17:40:37 +00:00
Adrian Prantl
7890b01218 Add -gnone to a test that tests that we don't emit debug info if we don't
emit debug info.
<rdar://problem/18636257> ☂ Audit the results of running tests with SWIFT_TEST_OPTIONS=-g

Swift SVN r22789
2014-10-16 00:41:53 +00:00
Adrian Prantl
d1c9f71a73 Enhance SILLocation so it can hold separate locations for diagnostics
and debug info. Drop most of the special SILLocation handling from
IRGenDebugInfo and eliminate lots of redundant code.

Swift SVN r22781
2014-10-15 23:05:57 +00:00
Joe Groff
cac5807ae2 SILGen: Emit "main" as a SIL function.
Eliminate the intermediate top_level_code function. Now that SIL is expressive enough to express a "main" function, there's no reason for it, and this eliminates a bunch of mystery code in IRGen to thunk from main to top_level_code by reaching for hardcoded symbol names. Demystify the special code for setting up C_ARGC and C_ARGV by having SILGen look for a transparent "_didEnterMain" hook in the stdlib and emit a call to it.

Swift SVN r22525
2014-10-05 04:13:24 +00:00
Adrian Prantl
d8551038fe Upgrade debug info tests to the new LLVM debug metadata format.
Thanks to Duncan for helping out with the upgrading!

Swift SVN r22512
2014-10-04 00:25:27 +00:00
Adrian Prantl
d769498ccd Update for upstream LLVM API change.
Swift SVN r22456
2014-10-02 01:33:24 +00:00
Adrian Prantl
9fafa1c13c Make deserialized locations default to line 0, which tells the debugger
to ignore them, while still referencing the module file needed to perform
type lookups, etc.
<rdar://problem/17648201> After setting a breakpoint, the first step action is malfunctioning

Swift SVN r20801
2014-07-31 01:39:12 +00:00
Adrian Prantl
1f20ed3323 [LLVM sync] adapt these tests to upstream LLVM type uniquing goodness.
Swift SVN r20684
2014-07-29 19:34:21 +00:00
Jordan Rose
ac90133b8c Update tests for accessibility modifiers becoming context-sensitive keywords.
Swift SVN r19673
2014-07-08 02:17:49 +00:00
Ted Kremenek
d075f06573 Require a minimum deployment target of iOS 7 or OSX 10.9
Implements <rdar://problem/17532113>

Swift SVN r19451
2014-07-02 06:23:38 +00:00
Jordan Rose
5557c3972b Update tests for accessibility.
In most cases this means adding @public to things that get serialized;
in a few cases it means using a modern public stdlib API instead of
a legacy thing I was trying to keep @internal.

Swift SVN r19350
2014-06-30 18:50:40 +00:00
Ted Kremenek
fad874708e Adjust test cases.
Swift SVN r17964
2014-05-12 22:01:52 +00:00
Adrian Prantl
0f7533dc7e Debug Info! Add basic support for line tables, compilation units, files,
and lexical scopes, which can be enabled through the new -g option.
When -g is enabled, line tables and scopes compile all the way
down to DWARF.

Changes to SIL:
- In addition to a SILLocation, every instruction now also has a pointer
  to a SILDebugScope (its containing lexical scope).
- Added LexicalScope, which is to be used for all Scopes we want to show
  up in the debug info.

Swift SVN r5772
2013-06-23 00:09:17 +00:00