Dmitri Gribenko
77376883f4
Collection.sortInPlace() => .sort()
2015-12-18 16:20:01 -08:00
Dmitri Gribenko
8f7c9ae3fd
Collection.sort() => .sorted()
2015-12-18 16:20:01 -08:00
Dmitri Gribenko
5b728dc859
Remove Range<Index> argument from Collection.partition()
...
collection.partition(i..<j) => collection[i..<j].partition()
2015-12-18 16:20:01 -08:00
Alex Chan
ce7ce98a01
Update Python build scripts to use the print function
...
In Python 3, 'print' was changed from a statement to a function. Using
the __future__ module allows scripts to use print function whether
running with Python 2.6+ or Python 3.x. This commit changes as many
instances of print as I could find to use the print function and the
__future__ module.
2015-12-18 23:00:55 +00:00
Doug Gregor
2091e7f852
Merge remote-tracking branch 'origin/swift-3-api-guidelines' into swift-3-omit-needless-words
2015-12-18 10:54:46 -08:00
Max Moiseev
f4aaece75e
revisiting CString related String extensions
2015-12-17 17:27:29 -08:00
Dmitri Gribenko
ebb3e45886
Sequence.{min,max}Element() => .min(), .max()
2015-12-17 17:07:01 -08:00
Maxim Moiseev
9e50505970
internal or public // @testable initializers
2015-12-17 17:02:49 -08:00
Dmitri Gribenko
6eedc99016
UnicodeDecodingResult: case Result(...) => case ScalarValue(...)
2015-12-17 16:31:49 -08:00
Maxim Moiseev
9d8755511d
fixing validation tests
2015-12-17 16:26:43 -08:00
Dmitri Gribenko
15a9649062
Repeated(repeating:length:) => repeatElement(_:count:)
2015-12-17 16:24:47 -08:00
Dmitri Gribenko
86f1258810
Repeat => Repeated
2015-12-17 16:24:11 -08:00
Dmitri Gribenko
73ce9ae7e9
Collection.count => .length
...
And other API changes that naturally fall out from this, like
Array(repeating:count:) => Array(repeating:length:).
2015-12-17 15:55:29 -08:00
Doug Gregor
f245f18a09
Merge remote-tracking branch 'origin/swift-3-api-guidelines' into swift-3-omit-needless-words
2015-12-17 11:35:58 -08:00
Max Moiseev
3fe0c60d7f
Merge remote-tracking branch 'origin/master' into swift-3-api-guidelines
2015-12-17 11:00:02 -08:00
Max Moiseev
a28a510407
Fixing tests
2015-12-17 10:24:40 -08:00
Maxim Moiseev
fc65e676cd
fixing validation tests
2015-12-16 17:21:57 -08:00
Maxim Moiseev
c4763ae686
_debugPrecondition => _debugRequire
2015-12-16 17:20:40 -08:00
Maxim Moiseev
e6468a0eca
_precondition => _require
2015-12-16 17:19:01 -08:00
Maxim Moiseev
f2f50d6a9d
precondition => require
2015-12-16 17:16:08 -08:00
Maxim Moiseev
6c50752aed
UnsafePointer: initializeMemory and deinitializePointee
2015-12-16 17:11:57 -08:00
Maxim Moiseev
0e54467bfa
Final bulk removal of Type suffix
2015-12-16 17:06:19 -08:00
Maxim Moiseev
ca932fca5a
CVarArgType => CVarArg
2015-12-16 15:52:01 -08:00
Dmitri Gribenko
3d0ad16094
Unsafe[Mutable]Pointer.memory => .pointee
2015-12-16 15:50:31 -08:00
Dmitri Gribenko
f1dbe205a3
UnsafeMutablePointer.dealloc(_:) => .deallocateCapacity(_:)
2015-12-16 15:47:58 -08:00
Dmitri Gribenko
1f70e25899
UnsafeMutablePointer.alloc(_:) => UnsafeMutablePointer(allocatingCapacity:)
2015-12-16 15:45:48 -08:00
Dmitri Gribenko
339c7a99dc
Remove no-argument initializers from unsafe pointer types
...
The preferred way to create a nil pointer is to use the 'nil' literal.
Affected types:
AutoreleasingUnsafeMutablePointer
OpaquePointer
UnsafeMutablePointer
UnsafePointer
2015-12-16 14:59:50 -08:00
Arsen Gasparyan
9f728c6dbd
[stdlib] Make comparison operator choices consistent
2015-12-16 22:50:36 +03:00
Dmitri Gribenko
d864cfcf3d
Merge pull request #556 from dduan/increment_decrement_search_replace
...
replace singular statement ++/-- with += 1/-= 1 for integer variables
2015-12-15 17:39:29 -08:00
Doug Gregor
2f5f94a12c
Merge remote-tracking branch 'origin/swift-3-api-guidelines' into swift-3-omit-needless-words
2015-12-15 17:11:37 -08:00
Doug Gregor
1ba7b5d98d
Merge remote-tracking branch 'origin/master' into swift-3-api-guidelines
2015-12-15 16:01:48 -08:00
Erik Eckstein
6e763b7c4f
[tests] add import statements (for fixing linker errors) also in the slice generator script.
...
And re-generated all files.
2015-12-15 13:21:15 -08:00
Max Moiseev
2021dd5a4d
Merge remote-tracking branch 'origin/master' into swift-3-api-guidelines
2015-12-15 12:49:22 -08:00
Erik Eckstein
0830c36974
[tests] add import statements to prevent unresolved symbols when compiling StdlibUnittest with -sil-serialize-all.
...
This is the second part of 308f39fe56 .
It fixes (better: works-around) linker errors when testing in optimized mode.
2015-12-15 10:46:10 -08:00
Daniel Duan
ebb0c3a204
replaced single-line ++/-- with +=/-=
2015-12-15 09:05:37 -08:00
Max Moiseev
806be29941
Merge remote-tracking branch 'origin' into swift-3-api-guidelines
2015-12-14 12:05:35 -08:00
practicalswift
c6e8459187
Fix typos.
2015-12-14 11:13:30 +01:00
Arsen Gasparyan
52890e5c30
Replace if true {} with do {}
2015-12-13 10:54:54 +03:00
Arsen Gasparyan
3961b71e4e
Use real arc4random_uniform() instead of just random() % max
2015-12-13 10:17:35 +03:00
Doug Gregor
06c5e9cd5b
Enable "omit needless words" by default.
...
Most of this is in updating the standard library, SDK overlays, and
piles of test cases to use the new names. No surprises here, although
this shows us some potential heuristic tweaks.
There is one substantive compiler change that needs to be factored out
involving synthesizing calls to copyWithZone()/copy(zone:). Aside from
that, there are four failing tests:
Swift :: ClangModules/objc_parse.swift
Swift :: Interpreter/SDK/Foundation_test.swift
Swift :: Interpreter/SDK/archiving_generic_swift_class.swift
Swift :: Interpreter/SDK/objc_currying.swift
due to two independent remaining compiler bugs:
* We're not getting partial ordering between NSCoder's
encode(AnyObject, forKey: String) and NSKeyedArchiver's version of
that method, and
* Dynamic lookup (into AnyObject) doesn't know how to find the new
names. We need the Swift name lookup tables enabled to address this.
2015-12-11 14:46:50 -08:00
Maxim Moiseev
b702b1a903
more number type renames
2015-12-10 17:08:41 -08:00
Maxim Moiseev
1b6244f3ee
integer types renamed
2015-12-10 17:03:40 -08:00
Maxim Moiseev
2c95bb6d51
BooleanType => Boolean
2015-12-10 14:56:32 -08:00
Dmitri Gribenko
78930e7fac
Remove MutableSliceable
2015-12-10 14:50:12 -08:00
Max Moiseev
d610fa0d1c
Merge remote-tracking branch 'origin' into swift-3-api-guidelines
2015-12-10 10:29:52 -08:00
Dmitri Gribenko
f3ecc3cdc5
transcode(..., stopOnError:) => transcode(..., stoppingOnError:)
2015-12-09 17:18:55 -08:00
Dmitri Gribenko
9ca2775aa1
String.appendContentsOf() => .append()
...
We don't want to imply that String argument is a collection of anything.
2015-12-09 17:18:33 -08:00
Dmitri Gribenko
b7f3d54f4d
removeAll(keepCapacity:) => removeAll(keepingCapacity:)
2015-12-09 17:18:08 -08:00
Dmitri Gribenko
f846ef6fd1
RangeReplaceableCollection.removeRange() => .removeSubrange()
2015-12-09 17:17:51 -08:00
Dmitri Gribenko
727f011314
RangeReplaceableCollection.insert(_:atIndex:) => .insert(_:at:)
2015-12-09 17:17:41 -08:00