Commit Graph

2015 Commits

Author SHA1 Message Date
Dmitri Hrybenko
71c5bb9371 CoreMedia overlay: change CMTimeMakeWithSeconds into an initializer
Patch by Adam Sonnanstine.

rdar://20940262

Swift SVN r30271
2015-07-16 20:24:47 +00:00
Dmitri Hrybenko
e5e4335fad stdlib: Slice: trap on out-of-bounds indices
rdar://21822657

Swift SVN r30269
2015-07-16 18:22:40 +00:00
Dmitri Hrybenko
a41d7b7292 SDK overlay tests: disable a certain SceneKit test on non-OS X
Only OS X targets support COLLADA files.

rdar://20738811

Swift SVN r30265
2015-07-16 15:21:18 +00:00
David Farler
91b89b8956 Add SequenceType.forEach requirement and default implementation
rdar://problem/21663830

Swift SVN r30236
2015-07-15 23:36:23 +00:00
Dmitri Hrybenko
9d27519a69 SDK overlay: fix a bug in the SceneKit overlay and re-enable the test
Patch by Amaury Balliet.

Part of rdar://20738811

Swift SVN r30234
2015-07-15 23:29:09 +00:00
Dmitri Hrybenko
7ae303aeb3 Update Unicode data files to 8.0.0
rdar://19582621

Swift SVN r30141
2015-07-13 08:00:39 +00:00
Dmitri Hrybenko
4cfe818c43 StdlibUnittest: extract collection tests into a reusable generic testsuite
Swift SVN r30124
2015-07-12 01:04:38 +00:00
Dmitri Hrybenko
1d38db56da StdlibUnittest: add {Minimal|Default}***MutableCollection types
Swift SVN r30115
2015-07-11 08:48:38 +00:00
Dmitri Hrybenko
b4ec45d625 stdlib: make Slice.init(base:bounds:) public
Swift SVN r30113
2015-07-11 05:58:06 +00:00
Dmitri Hrybenko
be5ef02bd0 Revert "stdlib: make Slice.init(base:bounds:) public"
This reverts commit 30111.  It broke the buildbots.

Swift SVN r30112
2015-07-11 05:34:05 +00:00
Dmitri Hrybenko
26ebe14178 stdlib: make Slice.init(base:bounds:) public
Swift SVN r30111
2015-07-11 05:20:41 +00:00
Arnold Schwaighofer
ec686f2861 FixedPointDiagnostics.swift.gyb update expected error/note output
Swift SVN r30070
2015-07-10 15:01:19 +00:00
Arnold Schwaighofer
21ce6cdaa0 XFAIL while I update the expected diagnostic strings
No radar - I am working on updating now.

Swift SVN r30069
2015-07-10 14:34:57 +00:00
Chris Lattner
ceeb309e47 update validation test for diagnostics change. I still think that these are massive overkill...
Swift SVN r30063
2015-07-10 05:09:19 +00:00
Jordan Rose
bee5114781 Update validation-test/stdlib/Unicode.swift for DarwinBoolean.
rdar://problem/19013551

Swift SVN r30053
2015-07-10 01:39:10 +00:00
Dave Abrahams
68a86ca798 Clean up a test slightly.
Swift SVN r30023
2015-07-09 17:10:31 +00:00
Dave Abrahams
ef198daa2b [stdlibunittest] Finish threading new trace facility through
Swift SVN r29955
2015-07-08 02:52:27 +00:00
Dave Abrahams
3179f78cbd Fix up stdlibunittest validation test
This should make the bot happier.

Swift SVN r29954
2015-07-08 01:34:30 +00:00
Dave Abrahams
ce93b0a9e0 [stdlibunittest] Still more de-boilerplating WIP
Swift SVN r29951
2015-07-08 00:28:33 +00:00
Dave Abrahams
70ee2adc84 [stdlibunittest] More de-boilerplating WIP
Step 2.

Swift SVN r29936
2015-07-07 04:54:03 +00:00
Dave Abrahams
9abf32d521 [stdlibunittest] WIP uniformity/de-boilerplating
The way we pass and compose source locations, messages, etc. needs to be
brought under control before too many more tests get written.  This is
the first step.

Swift SVN r29928
2015-07-07 00:46:54 +00:00
David Farler
4d17bf0691 Remove SinkType and SinkOf
Remove these standard library types in favor of (T) -> () closures.

It was originally believed that generic optimizations would make these
types profitable, however:

// FIXME: Insert benchmarks here.

rdar://problem/21663799

Swift SVN r29927
2015-07-07 00:36:12 +00:00
Dmitri Hrybenko
4603431bd4 StdlibUnittest: implement more strict checks for using invalid indices
Add a shared buffer to every range replaceable mutable collection to
track logical mutations, and invalidate all indices on every mutation.

Swift SVN r29917
2015-07-06 16:12:03 +00:00
Chris Lattner
59527f0a0b Fix for 21643437. Because of weirdness in this test (tracked by 19434979), the diagnostics on these lines are
different on iOS and the Mac, so just relax the checks back to the way they were.


Swift SVN r29899
2015-07-02 21:15:28 +00:00
Dmitri Hrybenko
1edcc49ff9 stdlib: remove Slice.Element typealias
It is misleading in generic code.  A testcase that was failing:

  expectEqualType(C.Generator.Element.self, Slice<C>.Element.self)

Swift SVN r29887
2015-07-02 06:44:38 +00:00
Dmitri Hrybenko
d16c27886a stdlib tests: Doug fixed the blocking bugs, so we can simplify tests
Swift SVN r29886
2015-07-02 05:24:46 +00:00
Andrew Trick
59b6dff24e Temporarily disableFixedPointDiagnostics test on iOS.
<rdar://problem/21643437> FixedPointDiagnostics regression on iOS

Swift SVN r29865
2015-07-01 23:52:30 +00:00
Dmitri Hrybenko
fc0fa96371 stdlib: de-underscore Indexable and add tests for it
Swift SVN r29847
2015-07-01 18:31:31 +00:00
Dmitri Hrybenko
76f5706b50 stdlib: de-underscore the Slice type and add tests for it
Swift SVN r29846
2015-07-01 18:31:29 +00:00
Dmitri Hrybenko
80b1380fe8 stdlib: fold Sliceable into CollectionType and de-underscore SubSequence
Swift SVN r29845
2015-07-01 18:31:25 +00:00
Chris Lattner
762cb3fa62 start loosening up getTypeOfIndependentSubExpression() to walk into more kinds of
expressions.  Broadening from callexpr to apply expr (picking up operators) improves
several diagnostics in the testsuite, and is important to avoid regressions from an 
upcoming patch.


Swift SVN r29821
2015-06-30 23:25:47 +00:00
Chris Lattner
77fce6b76c update notes to go with r29810
Swift SVN r29820
2015-06-30 23:20:24 +00:00
Dave Abrahams
4b4510e79a [stdlib] Simplifying filter tests (WIP)
Swift SVN r29790
2015-06-29 20:45:51 +00:00
Dave Abrahams
8c855e1ecf [stdlibunittest] automatic LifetimeTracked checking/setup
In setup and teardown, we can initialize and check for leaks

Swift SVN r29789
2015-06-29 20:45:50 +00:00
Dave Abrahams
7aed41190f [stdlibunittest] Automatically reset common test environment
Swift SVN r29787
2015-06-29 20:45:48 +00:00
Dave Abrahams
a35204ca55 [stdlibunittest] logging sequence/generator wrappers
Swift SVN r29786
2015-06-29 20:45:46 +00:00
Dave Abrahams
dcd46ea6df [stdlib] A system for concise testing of customization points.
This approach should help us massively reduce the amount of code it
takes to verify that the architecture of our protocols works as
expected.  Pair-programmed with Dmitri Hrybenko.

Swift SVN r29752
2015-06-27 02:31:26 +00:00
Dave Abrahams
1c5f805074 [stdlib] Protocol Extension-ize CollectionType
Eliminates _CollectionDefaultsType and _CollectionGeneratorDefaultsType
and creates sanity that should allow us to Protocol Extension-ize the
lazy operations, which have been blocked on inscrutable errors due in
part to the existing complexity.

Note: names beginning with "_prext_" are intended to be public after API
review and removal of the "_prext_" prefix.

Swift SVN r29689
2015-06-25 21:34:28 +00:00
Dave Abrahams
4056d22a07 Squash warnings in tests
Swift SVN r29688
2015-06-25 21:34:26 +00:00
Dmitri Hrybenko
ba208cd672 stdlib: rename zip generator and collection to a common naming convention
// Renamed from `ZipGenerator2`.
  struct Zip2Generator<Generator1 : GeneratorType, Generator2 : GeneratorType> { ... }

  // Renamed from `Zip2`.
  struct Zip2Sequence<Sequence1 : SequenceType, Sequence2 : SequenceType> { ... }

Part of rdar://21429126

Swift SVN r29636
2015-06-24 20:42:03 +00:00
Dmitri Hrybenko
60ba7be3d1 stdlib: rename the generic parameter from T to Element on GeneratorSequence
Part of rdar://21429126

Swift SVN r29635
2015-06-24 20:42:02 +00:00
Dmitri Hrybenko
71022a46c1 stdlib: rename mapping sequence and collection wrappers to a common naming convention
struct ReverseIndex<Base : BidirectionalIndexType> { ... }
  struct ReverseRandomAccessIndex<Base : RandomAccessIndexType> { ... }

  // Renamed from `BidirectionalReverseView`.
  struct ReverseCollection<Base : CollectionType where T.Index : BidirectionalIndexType> { ... }

  // Renamed from `RandomAccessReverseView`.
  struct ReverseRandomAccessCollection<Base : CollectionType where T.Index : RandomAccessIndexType> { ... }

Also fixed a bug (found by the new tests I added in this commit) in
LazyRandomAccessCollection.reverse(), which mistakenly returned a bidirectional
reversed collection.

Part of rdar://21429126

Swift SVN r29634
2015-06-24 20:42:01 +00:00
Dmitri Hrybenko
fdd73a57b4 stdlib: add tests for generic parameter names on EnumerateGenerator,
EnumerateSequence

Part of rdar://21429126

Swift SVN r29629
2015-06-24 20:41:58 +00:00
Dmitri Hrybenko
d9726efbb2 stdlib: rename Set's generic parameter from T to Element
Same for SetGenerator and SetIndex.

Part of rdar://21429126

Swift SVN r29619
2015-06-24 20:41:51 +00:00
Dmitri Hrybenko
51e236c609 stdlib: rename Array's generic parameter from T to Element
Same for ArraySlice and ContiguousArray.

Part of rdar://21429126

Swift SVN r29618
2015-06-24 20:41:49 +00:00
Dave Abrahams
7d0f0dc461 [stdlib] internal Box<T> should be final
Swift SVN r29533
2015-06-20 02:50:07 +00:00
Chris Willmore
0e05470e5f Take care to preserve parentheses when opening generic types. Consider
lvalues when compiling list of partial-match overloads in diagnosis.
(This is a reapplication of commits r29462 and r29469.)

Also, fix the following tests:

    stdlib/FixedPointDiagnostics.swift.gyb
    stdlib/NumericDiagnostics.swift.gyb

<rdar://problem/17875634> can't append to array of tuples

Swift SVN r29493
2015-06-18 18:58:49 +00:00
Dave Abrahams
f7e0f31627 [stdlib] WIP Refactoring tests
Swift SVN r29479
2015-06-18 05:05:09 +00:00
Dave Abrahams
e8dbf7b38c [stdlib] Squash a warning in a test
Swift SVN r29477
2015-06-18 05:05:07 +00:00
Arnold Schwaighofer
f003bc754d validation-test: Make this test pass in optimized mode
Some test cases where assuming to be compiled in Debug assert configuration.

The test relies on return autorelease optimization to happen. This does not
happen reliable in optimize mode.

I ran the test case under the leaks runner and no leaks are reported yet the
object count is positive. This can happen if some objects are still in a
autorelease pool at the time we count them. Which seems to happen.

I surrounded the code with "autoreleasepool {}" and it would pass which confirms
this assumption. I have looked at both the generated LLVM IR and the otool -tvV
asssembly output and did not see anything that would block the return
autorelease optimization (i.e instructions between the returnautorelease
function call and the retain_returnautorelease call) so I don't believe there is
something the compiler could do better.

rdar://21193916

Swift SVN r29369
2015-06-12 18:41:50 +00:00