Skip to content

Commit 7c6b559

Browse files
committed
split comment for each method, not whole extension block
1 parent 03b391c commit 7c6b559

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

library/src/scala/runtime/stdLibPatches/Predef.scala

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,16 @@ object Predef:
5050
extension [T](x: T | Null) inline def nn: x.type & T =
5151
scala.runtime.Scala3RunTime.nn(x)
5252

53-
/** Enables an expression of type `T|Null`, where `T` is a subtype of `AnyRef`, to be checked for `null`
54-
* using `eq` and `ne`, rather than only `==` and `!=`. This is needed because `Null` no longer has
55-
* `eq` or `ne` methods, only `==` and `!=` inherited from `Any`. */
5653
extension (inline x: AnyRef | Null)
54+
/** Enables an expression of type `T|Null`, where `T` is a subtype of `AnyRef`, to be checked for `null`
55+
* using `eq` rather than only `==`. This is needed because `Null` no longer has
56+
* `eq` or `ne` methods, only `==` and `!=` inherited from `Any`. */
5757
@experimental
5858
inline def eq(inline y: AnyRef | Null): Boolean =
5959
x.asInstanceOf[AnyRef] eq y.asInstanceOf[AnyRef]
60+
/** Enables an expression of type `T|Null`, where `T` is a subtype of `AnyRef`, to be checked for `null`
61+
* using `ne` rather than only `!=`. This is needed because `Null` no longer has
62+
* `eq` or `ne` methods, only `==` and `!=` inherited from `Any`. */
6063
@experimental
6164
inline def ne(inline y: AnyRef | Null): Boolean =
6265
!(x eq y)

0 commit comments

Comments
 (0)