Skip to content

Commit 7885a6a

Browse files
sjrdKordyjan
authored andcommitted
Spec: Apply changes to wildcards.
[Cherry-picked 0d61167]
1 parent 5203e3c commit 7885a6a

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

docs/_spec/03-types.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,9 @@ All parameterized class types are value types.
493493
In the concrete syntax of wildcard type arguments, if both bounds are omitted, the real bounds are inferred from the bounds of the corresponding type parameter in the target type constructor (which must be concrete).
494494
If only one bound is omitted, `Nothing` or `Any` is used, as usual.
495495

496+
Also in the concrete syntax, `_` can be used instead of `?` for compatibility reasons, with the same meaning.
497+
This alternative will be deprecated in the future, and is already deprecated under `-source:future`.
498+
496499
#### Simplification Rules
497500

498501
Wildcard type arguments used in covariant or contravariant positions can always be simplified to regular types.

0 commit comments

Comments
 (0)