Skip to content

Commit 2cf0015

Browse files
committed
Merge remote-tracking branch 'origin/master' into master-next
2 parents 738ff03 + 9e7d7d0 commit 2cf0015

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

stdlib/public/core/Policy.swift

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ precedencegroup BitwiseShiftPrecedence {
384384
// Standard postfix operators.
385385
postfix operator ++
386386
postfix operator --
387-
postfix operator ...
387+
postfix operator ... : Comparable
388388

389389
// Optional<T> unwrapping operator is built into the compiler as a part of
390390
// postfix expression grammar.
@@ -394,12 +394,12 @@ postfix operator ...
394394
// Standard prefix operators.
395395
prefix operator ++
396396
prefix operator --
397-
prefix operator !
397+
prefix operator ! : Bool
398398
prefix operator ~ : BinaryInteger
399399
prefix operator + : AdditiveArithmetic
400400
prefix operator - : SignedNumeric
401-
prefix operator ...
402-
prefix operator ..<
401+
prefix operator ... : Comparable
402+
prefix operator ..< : Comparable
403403

404404
// Standard infix operators.
405405

@@ -428,8 +428,8 @@ infix operator | : AdditionPrecedence, BinaryInteger
428428
infix operator ^ : AdditionPrecedence, BinaryInteger
429429

430430
// FIXME: is this the right precedence level for "..." ?
431-
infix operator ... : RangeFormationPrecedence
432-
infix operator ..< : RangeFormationPrecedence
431+
infix operator ... : RangeFormationPrecedence, Comparable
432+
infix operator ..< : RangeFormationPrecedence, Comparable
433433

434434
// The cast operators 'as' and 'is' are hardcoded as if they had the
435435
// following attributes:
@@ -454,11 +454,11 @@ infix operator ~= : ComparisonPrecedence
454454

455455
// "Conjunctive"
456456

457-
infix operator && : LogicalConjunctionPrecedence
457+
infix operator && : LogicalConjunctionPrecedence, Bool
458458

459459
// "Disjunctive"
460460

461-
infix operator || : LogicalDisjunctionPrecedence
461+
infix operator || : LogicalDisjunctionPrecedence, Bool
462462

463463
// User-defined ternary operators are not supported. The ? : operator is
464464
// hardcoded as if it had the following attributes:

0 commit comments

Comments
 (0)