Skip to content

Commit 17a5845

Browse files
[stdlib] Add terminating period to comments
1 parent 4faa43a commit 17a5845

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

stdlib/public/core/IntegerParsing.swift.gyb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -73,14 +73,14 @@ internal func _parseAsciiAsUIntMax(
7373
utf16: String.UTF16View, _ radix: Int, _ maximum: UIntMax
7474
) -> UIntMax? {
7575
if utf16.isEmpty { return nil }
76-
// Parse (optional) sign
76+
// Parse (optional) sign.
7777
let (digitsUTF16, hasMinus) = _parseOptionalAsciiSign(utf16)
78-
// Parse digits
78+
// Parse digits.
7979
guard let result = _parseUnsignedAsciiAsUIntMax(digitsUTF16, radix, maximum)
8080
else { return nil }
81-
// Disallow < 0
81+
// Disallow < 0.
8282
if hasMinus && result != 0 { return nil }
83-
// Return
83+
// Return.
8484
return result
8585
}
8686

@@ -95,14 +95,14 @@ internal func _parseAsciiAsIntMax(
9595
) -> IntMax? {
9696
_sanityCheck(maximum >= 0, "maximum should be non-negative")
9797
if utf16.isEmpty { return nil }
98-
// Parse (optional) sign
98+
// Parse (optional) sign.
9999
let (digitsUTF16, hasMinus) = _parseOptionalAsciiSign(utf16)
100-
// Parse digits. +1 for negatives because e.g. Int8's range is -128...127.
100+
// Parse digits. +1 for because e.g. Int8's range is -128...127.
101101
let absValueMax = UIntMax(bitPattern: maximum) + (hasMinus ? 1 : 0)
102102
guard let absValue =
103103
_parseUnsignedAsciiAsUIntMax(digitsUTF16, radix, absValueMax)
104104
else { return nil }
105-
// Return signed result
105+
// Return signed result.
106106
return IntMax(bitPattern: hasMinus ? 0 &- absValue : absValue)
107107
}
108108

0 commit comments

Comments
 (0)