Commit Graph

675 Commits

Author SHA1 Message Date
Dmitri Gribenko
b9f412974b StdlibUnittest: remove unused API 2016-07-18 02:41:19 -07:00
Chris Lattner
af30ae3222 Remove the last parts of the Boolean protocol, finishing up:
SE-0109: Remove the Boolean protocol.

We still love you George, even if we forgot your e.
2016-07-17 22:18:17 -07:00
Chris Lattner
a0d34852bb Revert "Fix the build."
This reverts commit 932fe9d6b9.
2016-07-17 12:35:42 -07:00
Michael Gottesman
932fe9d6b9 Fix the build.
This reverts commit 4242af7503.
This reverts commit 76cf339694.
This reverts commit e97ed133a8.
This reverts commit 66961fcda8.
2016-07-17 01:02:48 -07:00
Chris Lattner
76cf339694 Implement the first half of SE-0109: Remove the Boolean protocol
This removes conformance of DarwinBool and ObjCBool to the Boolean protocol,
and makes the &&/||/! operators be concrete w.r.t. Bool instead of abstract
on Boolean.

This fixes some outstanding bugs w.r.t diagnostics, but exposes some cases
where an existing diagnostic is not great.  I'll fix that in a later patch
(tracked by rdar://27391581).
2016-07-16 23:23:45 -07:00
Dmitri Gribenko
8c14b7dee0 StdlibUnittest: improve failure message 2016-07-16 13:31:21 -07:00
Michael Gottesman
40e1991e12 Revert "Name and label changes for closure parameters (for review only) (#2981)"
This reverts commit 18406900ba.
2016-07-15 19:45:26 -07:00
Dmitri Gribenko
c7b1ef8833 Merge pull request #3535 from apple/stdlib-StdlibUnittest-better-error-messages
StdlibUnittest: improve error messages in checkEquatable() and checkHashable()
2016-07-15 17:43:20 -07:00
Dave Abrahams
18406900ba Name and label changes for closure parameters (for review only) (#2981)
Implement SE-0118 Name and label changes for closure parameters

[SE-0118](https://github.com/apple/swift-evolution/blob/master/proposals/0118-closure-parameter-names-and-labels.md)
2016-07-15 15:31:48 -07:00
Dmitri Gribenko
bd0a638d79 StdlibUnittest: improve error messages in checkEquatable() and checkHashable() 2016-07-15 13:44:07 -07:00
Doug Gregor
823c24b355 [SE-0112] Rename ErrorProtocol to Error.
This is bullet (5) of the proposed solution in SE-0112, and the last
major piece to be implemented.
2016-07-12 10:53:52 -07:00
Saleem Abdulrasool
4a4b54ea73 stdlib: clean up framework depends
This is no longer necessary as the imports will correctly create the dependency.
Clean up the unnecessary dependencies.  Noticed by Dimitri Gribenko.
2016-07-10 17:54:36 -07:00
Saleem Abdulrasool
65fd24de5c stdlib: restrict pthreads to POSIX platforms
pthreads is not available on non-POSIX platforms (i.e. Windows).  Restrict the
target platforms that we build SwiftPrivatePthreadExtras and things which depend
on it.
2016-07-08 09:38:02 -07:00
practicalswift
9a8bbe0014 [gardening] Fix recently introduced typos. 2016-07-07 13:14:25 +02:00
Saleem Abdulrasool
34dce93062 Merge pull request #3316 from compnerd/multiple-platforms
stdlib: build multiple platform libraries simultaneously
2016-07-06 21:25:47 -07:00
Dmitri Gribenko
fd7f55d5a2 stdlib: replace 'forAllPermutations()' with a non-recursive implementation 2016-07-06 02:53:27 -07:00
Saleem Abdulrasool
7e229f7247 build: support multiple builds of StdlibUnittest 2016-07-05 17:33:56 -07:00
Chris Lattner
45f2cfaaa0 Implement SE-0099, but where the migration diagnostics are left as warnings
for now.  I'll upgrade them to errors in a week or two to give downstream
projects a chance to update.
2016-07-02 15:44:57 -07:00
Saleem Abdulrasool
83901998c9 Port for PS4
Add support for the PS4 OS.  Update the standard library and add a target unit
test.
2016-06-30 20:14:50 -07:00
swift-ci
1419fc962c Merge pull request #3178 from CodaFi/leak-by-example 2016-06-30 18:24:51 -07:00
Dmitri Gribenko
b8ba955198 stdlib: add a prototype implementation of a persistent vector 2016-06-30 00:49:02 -07:00
Robert Widmann
56f495c170 [WIP] Enable leaks tracking
This is part 1 of many to enable leaks tracking in the unit test suite.
 To compile with leak tracking enabled run

swift/utils/build-script -- --swift-runtime-enable-leak-checker
2016-06-28 19:22:54 -07:00
Brian Gesiak
328de9e280 [SR-1738] add_swift_library takes SHARED/STATIC arg
As a first step to allowing the build script to build *only*
static library versions of the stdlib, change `add_swift_library`
such that callers must pass in `SHARED`, `STATIC`, or `OBJECT_LIBRARY`.

Ideally, only these flags would be used to determine whether to
build shared, static, or object libraries, but that is not currently
the case -- `add_swift_library` also checks whether the library
`IS_STDLIB` before performing certain additional actions. This will be
cleaned up in a future commit.
2016-06-16 13:15:58 -04:00
Dmitri Gribenko
6f139d7b5a Merge pull request #2975 from trentxintong/MISC
Limit inlining for stdlibunittest. This saves a lot of compilation time
2016-06-09 18:29:44 -07:00
Xin Tong
6430525edc Limit inlining for stdlibunittest. This saves a lot of compilation time
for some of the stdlibunittests.

i.e. For the FixPoint benchmark, from 256s on my machine to 27s.

rdar://26688483
2016-06-09 16:04:43 -07:00
Dave Abrahams
4fbed473e2 Add a missing @discardableResult 2016-06-08 11:35:16 -07:00
Dmitri Gribenko
8f118750a4 StdlibUnittest: add tests for expectEqual() on tuples 2016-06-04 02:33:30 -07:00
Dmitri Gribenko
fb6fb95fe2 Merge pull request #2801 from natecook1000/nc-nextup
[stdlib] Fix error in nextUp and nextDown
2016-06-02 14:31:45 -07:00
swift-ci
7c98b492e8 Merge pull request #2841 from ahoppen/SR-1236-tests-update 2016-06-02 11:38:34 -07:00
Nate Cook
b76630735a [stdlib] Add tests for FloatingPoint's nextUp and nextDown 2016-06-02 11:11:07 -05:00
Alex Hoppen
2108a235df [Tests] Update existing tests for the upcoming implementation of SE-0036 2016-06-02 17:50:55 +02:00
rintaro ishizaki
6401324993 [stdlib] Apply tail style "where" clause to stdlib/{internal,private} 2016-06-02 12:01:21 +09:00
Dmitri Gribenko
a1e73a6b0d CMake: remove dead code 2016-05-31 21:57:07 -07:00
Dmitri Gribenko
9574d03dfa StdlibUnittest: ask the child process to terminate, and check its termination status
If a child process crashes outside of a test context, the parent process
should signal test failure. This behavior is a sign of something bad
happening in the child (for example, memory corruption), and should not
go unnoticed.
2016-05-22 17:17:16 -07:00
Dmitri Gribenko
27a6be9897 StdlibUnittest: add labels to boolean return values 2016-05-22 14:37:53 -07:00
Dmitri Gribenko
d7dd6bdae3 StdlibUnittest: replace a magic value with an optional 2016-05-22 14:37:53 -07:00
Dmitri Gribenko
cd312ae12c StdlibUnittest: refactor child I/O code
Detangle protocol parsing logic from I/O handling.
2016-05-22 14:37:53 -07:00
Dmitri Gribenko
227cfa1695 StdlibUnittest: add a simple API for race tests 2016-05-20 14:23:31 -07:00
Dmitri Gribenko
d591f9cf7a stdlib: remove most uses of @warn_unused_result, which does nothing now
I kept the one on sorted(), because that one requires a less trivial
change.
2016-05-19 18:39:39 -07:00
Trent Nadeau
0cc851568a Updated tests to use @discardableResult and _ = . 2016-05-11 22:53:38 -04:00
Ted Kremenek
942e524285 Revert "SE-0036: Requiring Leading Dot Prefixes for Enum Instance Member Implementations" (#2477) 2016-05-11 11:02:37 -07:00
Jordan Rose
14a7334aef Merge pull request #2224: SE-0036: Requiring Leading Dot Prefixes for Enum Instance Member Implementations
from @ahoppen
2016-05-10 19:58:09 -07:00
Doug Gregor
c808b00314 Merge pull request #2423 from koke/sr-1395
SE-0070: Make Optional Requirements Objective-C-only.
2016-05-07 20:27:32 -07:00
Alex Hoppen
0e8c69c56f [SE-0036]: Requiring Leading Dot Prefixes for Enum Instance Member Implementations 2016-05-07 22:39:26 +02:00
Ted Kremenek
d3c41c4668 Revert "Revert "SE-0072: Fully eliminate implicit bridging conversions from Swift"" (#2441) 2016-05-06 23:26:45 -07:00
Ted Kremenek
4df003c291 Revert "SE-0072: Fully eliminate implicit bridging conversions from Swift" (#2440) 2016-05-06 23:22:56 -07:00
Joe Pamer
6af546e89e Merge pull request #2419 from apple/se-0072
SE-0072: Fully eliminate implicit bridging conversions from Swift
2016-05-06 22:14:13 -07:00
Chris Lattner
8d3f88735d Add parens to the few cases in the stdlib that lack them for function types. 2016-05-06 21:07:08 -07:00
Jorge Bernal
0a3f913b20 SE-0070: Make Optional Requirements Objective-C-only.
Optional protocol requirements now require an explicit @objc attribute.

Fixes SR-1395
2016-05-06 11:05:52 +02:00
Joe Pamer
3b4d98445e SE-0072: Fully eliminate implicit bridging conversions from Swift
Per Swift Evolution proposal SE-0072, these changes prevent the compiler from introducing implicit bridging conversions during type checking.
2016-05-05 19:36:33 -07:00