Commit Graph

26 Commits

Author SHA1 Message Date
Kim Topley
1da4b04d99 Fixes overflow trap when creating DispatchTime objects with large uptimeNanoseconds values and re-enables the tests that failed.
Adds some additional tests.
2017-10-16 07:09:05 -07:00
Kim Topley
c5af2799c1 Fix overflow traps in DispatchTime/DispatchWallTime/DispatchTimeInterval.
rdar://problem/32678302
2017-09-20 12:16:05 -07:00
Max Moiseev
eaf20b23ba [overlay] Rename scheduleOneShot and scheduleRepeating
rdar://29587696
2017-06-26 15:38:21 -07:00
Max Moiseev
835b8809d2 Merge branch 'master' into new-integer-protocols 2017-03-07 16:18:54 -08:00
Kim Topley
fe8d8bb88a Fix the DispatchTime.init(uptimeNanoseconds:) initializer to convert its argument to Mach absolute time instead of treating it as Mach absolute time.
(Radar 29660448)
2017-02-13 12:24:38 -08:00
Kim Topley
5229d1a777 Revert "Fix the DispatchTime.init(uptimeNanoseconds:) initializer to convert its argument to Mach absolute time instead of treating it as Mach absolute time."
This reverts commit 1377cae2b9.
2017-02-13 12:22:06 -08:00
Kim Topley
1377cae2b9 Fix the DispatchTime.init(uptimeNanoseconds:) initializer to convert its argument to Mach absolute time instead of treating it as Mach absolute time.
(Radar 29660448)
2017-02-13 11:19:40 -08:00
swift-ci
fd6b9fe0ec Merge pull request #7338 from ktopley-apple/dispatch-time-nanos 2017-02-10 13:29:49 -08:00
ktopley-apple
0cb1561035 Adding documentation to clarify the result of DispatchTime(uptimeNanoseconds: 0) (#7342)
(Radar 28814085)
(SR-2807)
2017-02-10 12:37:57 -08:00
Kim Topley
65032a6898 DispatchTime.uptimeNanoseconds returns incorrect value on some platforms.
(Radar 30332506)
2017-02-08 10:34:08 -08:00
Max Moiseev
b5ab7263c1 Merge remote-tracking branch 'origin/master' into new-integer-protocols 2017-01-23 11:00:33 -08:00
Maxim Moiseev
89840c738a [dispatch] Fix + and - operations on DispatchTime and DispatchWallTime (#6961)
... for the cases where `seconds` parameter is NaN or infinite.
Fixes <rdar://problem/29764171>
2017-01-20 21:44:47 -08:00
Max Moiseev
27889c6376 Merge remote-tracking branch 'origin/master' into new-integer-protocols 2017-01-06 15:54:44 -08:00
practicalswift
6d1ae2a39c [gardening] 2016 → 2017 2017-01-06 16:41:22 +01:00
Max Moiseev
356c15cb4a Merge remote-tracking branch 'origin/master' into new-integer-protocols 2016-12-06 10:35:27 -08:00
Jordan Rose
7d61a5e6a2 [SDK] Use an extra shims header to remove _silgen_name from Dispatch.
We still have a bunch of redeclarations of Dispatch functions to avoid
the automatic bridging of dispatch_data_t and dispatch_block_t, but
mostly this is a vast reduction in complexity (and increase in safety).
2016-12-01 16:06:15 -08:00
Max Moiseev
70b2343626 Merge branch 'master' into new-integer-protocols 2016-11-28 15:25:01 -08:00
practicalswift
797b80765f [gardening] Use the correct base URL (https://swift.org) in references to the Swift website
Remove all references to the old non-TLS enabled base URL (http://swift.org)
2016-11-20 17:36:03 +01:00
Max Moiseev
d1cc46d7ce Fixing Dispatch tests 2016-10-24 11:40:03 -07:00
Kevin Ballard
301510e9d4 Fix dispatch time comparisons (#5078)
* [Dispatch] Don't crash when comparing DispatchWallTimes with <

* [Dispatch] Make comparisons with distantFuture work as expected
2016-10-13 11:32:24 -07:00
Kevin Ballard
2530957bc6 Use shims for all calls to Dispatch APIs that take blocks
This ensures that blocks that come from `DispatchWorkItem`s will
function correctly.

The only exception is __dispatch_barrier_sync() as the block passed to
that call is not `@convention(block)` so it doesn't matter.

Fixes SR-2246.
2016-08-01 17:08:14 -07:00
Matt Wright
e32016ffd7 [libdispatch-time-signedness] Correct signedness handling of DispatchTimeInterval
* DispatchTimeInterval's internal interval computation should be
    done with signed integers to allow for negative intervals. This
    moves all the unsigned conversions out to the API calls that can
    only accept positive intervals (timer sources and IO interval) and
    allows intermediate TimeIntervals to have a negative value.
2016-07-28 15:00:44 -07:00
Jordan Rose
0712ffcb07 Convert the Dispatch and Foundation overlays to 'fileprivate'. (#3753)
Similar to the work in apple/swift-corelibs-foundation#445.

Groundwork for SE-0025 ('private' and 'fileprivate').
No intended functionality change.
2016-07-25 20:58:06 -07:00
Matt Wright
11a6dcd2b7 [libdispatch] Remove deprecated methods
* Removes methods introduces in Swift3 that were already marked
    deprecated based on pre-release review feedback.

    Fixes <rdar://problem/26479523>
2016-07-18 13:22:23 -07:00
Matt Wright
8ac413a0b5 [libdispatch] Post-beta API changes and bug fixes
* Fix DispatchSourceSignal initialisation such that it no longer
    registers for the wrong source type.

    * Remove (group:) option from DispatchWorkItem, introduce group
    options to `.async` methods that accept DispatchWorkItem.

    * Rename `DispatchSourceType` to `DispatchSourceProtocol`

    * Rework DispatchQueue attributes and flags into a less confusing
    approach.

    * Fixes:

	SR-1817, SR-1771, SR-1770, SR-1769

	<rdar://problem/26725156> <rdar://problem/26873917>
	<rdar://problem/26918843> <rdar://problem/26810149>
	<rdar://problem/27117023> <rdar://problem/27121422>
	<rdar://problem/27236887> <rdar://problem/27337555>
2016-07-18 13:22:23 -07:00
Mishal Shah
87b7bcfd3e Update master to build with Xcode 8 beta 1, OS X 10.12, iOS 10, tvOS 10, and watchOS 3 SDKs. 2016-06-14 14:53:55 -07:00