Skip to content

Commit aa990c6

Browse files
authored
Merge pull request swiftlang#35175 from mdznr/typos
[NFC] Fix typos
2 parents 3e91c41 + be13b47 commit aa990c6

24 files changed

+35
-35
lines changed

lib/AST/Attr.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ bool DeclAttribute::printImpl(ASTPrinter &Printer, const PrintOptions &Options,
721721
// if the overriden decl is invisible from the interface. Otherwise, an error
722722
// will occur while building the Swift module because the overriding decl
723723
// doesn't override anything.
724-
// We couldn't skip every `override` keywords becuase they change the
724+
// We couldn't skip every `override` keywords because they change the
725725
// ABI if the overriden decl is also publically visible.
726726
// For public-override-internal case, having `override` doesn't have ABI
727727
// implication. Thus we can skip them.

stdlib/public/Darwin/Foundation/Data.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ internal final class __DataStorage {
183183
@inlinable // This is inlinable as trivially computable.
184184
var isExternallyOwned: Bool {
185185
// all __DataStorages will have some sort of capacity, because empty cases hit the .empty enum _Representation
186-
// anything with 0 capacity means that we have not allocated this pointer and concequently mutation is not ours to make.
186+
// anything with 0 capacity means that we have not allocated this pointer and consequently mutation is not ours to make.
187187
return _capacity == 0
188188
}
189189

stdlib/public/Darwin/Foundation/DateInterval.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,8 @@ public struct DateInterval : ReferenceConvertible, Comparable, Hashable, Codable
145145
public func contains(_ date: Date) -> Bool {
146146
let timeIntervalForGivenDate = date.timeIntervalSinceReferenceDate
147147
let timeIntervalForSelfStart = start.timeIntervalSinceReferenceDate
148-
let timeIntervalforSelfEnd = end.timeIntervalSinceReferenceDate
149-
if (timeIntervalForGivenDate >= timeIntervalForSelfStart) && (timeIntervalForGivenDate <= timeIntervalforSelfEnd) {
148+
let timeIntervalForSelfEnd = end.timeIntervalSinceReferenceDate
149+
if (timeIntervalForGivenDate >= timeIntervalForSelfStart) && (timeIntervalForGivenDate <= timeIntervalForSelfEnd) {
150150
return true
151151
}
152152
return false

stdlib/public/Darwin/Foundation/NSStringAPI.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ extension String {
205205
///
206206
/// - Parameters:
207207
/// - bytes: A sequence of bytes to interpret using `encoding`.
208-
/// - encoding: The ecoding to use to interpret `bytes`.
208+
/// - encoding: The encoding to use to interpret `bytes`.
209209
public init?<S: Sequence>(bytes: __shared S, encoding: Encoding)
210210
where S.Iterator.Element == UInt8 {
211211
let byteArray = Array(bytes)

stdlib/public/Darwin/Foundation/Publishers+NotificationCenter.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ extension NotificationCenter {
2222
///
2323
/// - Parameters:
2424
/// - name: The name of the notification to publish.
25-
/// - object: The object posting the named notfication. If `nil`, the publisher emits elements for any object producing a notification with the given name.
25+
/// - object: The object posting the named notification. If `nil`, the publisher emits elements for any object producing a notification with the given name.
2626
/// - Returns: A publisher that emits events when broadcasting notifications.
2727
public func publisher(
2828
for name: Notification.Name,
@@ -43,15 +43,15 @@ extension NotificationCenter {
4343
public let center: NotificationCenter
4444
/// The name of notifications published by this publisher.
4545
public let name: Notification.Name
46-
/// The object posting the named notfication.
46+
/// The object posting the named notification.
4747
public let object: AnyObject?
4848

4949
/// Creates a publisher that emits events when broadcasting notifications.
5050
///
5151
/// - Parameters:
5252
/// - center: The notification center to publish notifications for.
5353
/// - name: The name of the notification to publish.
54-
/// - object: The object posting the named notfication. If `nil`, the publisher emits elements for any object producing a notification with the given name.
54+
/// - object: The object posting the named notification. If `nil`, the publisher emits elements for any object producing a notification with the given name.
5555
public init(center: NotificationCenter, name: Notification.Name, object: AnyObject? = nil) {
5656
self.center = center
5757
self.name = name

stdlib/public/SwiftOnoneSupport/SwiftOnoneSupport.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import Swift
1515

1616
// =============================================================================
1717
// Definitions of proxy functions that mimic a generic function signature in the
18-
// standard library and are annotated with the standard libary's
18+
// standard library and are annotated with the standard library's
1919
// actual generic function name. The "prespecialize" annotation forces
2020
// the actual generic function to be specialized based on the argument
2121
// types passed to the proxy function.

stdlib/public/core/Array.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1111,7 +1111,7 @@ extension Array: RangeReplaceableCollection {
11111111
internal mutating func _reserveCapacityAssumingUniqueBuffer(oldCount: Int) {
11121112
// Due to make_mutable hoisting the situation can arise where we hoist
11131113
// _makeMutableAndUnique out of loop and use it to replace
1114-
// _makeUniqueAndReserveCapacityIfNotUnique that preceeds this call. If the
1114+
// _makeUniqueAndReserveCapacityIfNotUnique that precedes this call. If the
11151115
// array was empty _makeMutableAndUnique does not replace the empty array
11161116
// buffer by a unique buffer (it just replaces it by the empty array
11171117
// singleton).

stdlib/public/core/ArraySlice.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ extension ArraySlice: RangeReplaceableCollection {
867867
internal mutating func _reserveCapacityAssumingUniqueBuffer(oldCount: Int) {
868868
// Due to make_mutable hoisting the situation can arise where we hoist
869869
// _makeMutableAndUnique out of loop and use it to replace
870-
// _makeUniqueAndReserveCapacityIfNotUnique that preceeds this call. If the
870+
// _makeUniqueAndReserveCapacityIfNotUnique that precedes this call. If the
871871
// array was empty _makeMutableAndUnique does not replace the empty array
872872
// buffer by a unique buffer (it just replaces it by the empty array
873873
// singleton).

stdlib/public/core/Character.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ extension Character :
145145

146146
/// Creates a character with the specified value.
147147
///
148-
/// Do not call this initalizer directly. It is used by the compiler when
148+
/// Do not call this initializer directly. It is used by the compiler when
149149
/// you use a string literal to initialize a `Character` instance. For
150150
/// example:
151151
///

stdlib/public/core/ContiguousArray.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -746,7 +746,7 @@ extension ContiguousArray: RangeReplaceableCollection {
746746
internal mutating func _reserveCapacityAssumingUniqueBuffer(oldCount: Int) {
747747
// Due to make_mutable hoisting the situation can arise where we hoist
748748
// _makeMutableAndUnique out of loop and use it to replace
749-
// _makeUniqueAndReserveCapacityIfNotUnique that preceeds this call. If the
749+
// _makeUniqueAndReserveCapacityIfNotUnique that precedes this call. If the
750750
// array was empty _makeMutableAndUnique does not replace the empty array
751751
// buffer by a unique buffer (it just replaces it by the empty array
752752
// singleton).

0 commit comments

Comments
 (0)