Skip to content

Commit d5d9729

Browse files
committed
Fix tests
1 parent c8a56d0 commit d5d9729

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

tests/neg-macros/annot-crash.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@
33
|^^^^^^
44
|Failed to evaluate macro annotation '@crash'.
55
| Caused by class scala.NotImplementedError: an implementation is missing
6-
| scala.Predef$.$qmark$qmark$qmark(Predef.scala:400)
6+
| scala.Predef$.$qmark$qmark$qmark(Predef.scala:401)
77
| crash.transform(Macro_1.scala:7)

tests/neg-macros/i23008.check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
| ^^^^^^^^^^^^^^^^^^
44
| Exception occurred while executing macro expansion.
55
| java.lang.IllegalArgumentException: requirement failed: value of StringConstant cannot be `null`
6-
| at scala.Predef$.require(Predef.scala:393)
6+
| at scala.Predef$.require(Predef.scala:394)
77
| at scala.quoted.runtime.impl.QuotesImpl$reflect$StringConstant$.apply(QuotesImpl.scala:2542)
88
| at scala.quoted.runtime.impl.QuotesImpl$reflect$StringConstant$.apply(QuotesImpl.scala:2541)
99
| at scala.quoted.ToExpr$StringToExpr.apply(ToExpr.scala:82)

tests/run-tasty-inspector/stdlibExperimentalDefinitions.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,9 @@ val experimentalDefinitionInLibrary = Set(
9090
"scala.quoted.Quotes.reflectModule.RenameSelectorModule.apply",
9191
"scala.quoted.Quotes.reflectModule.SimpleSelectorModule.apply",
9292

93+
// New feature: fromNullable for explicit nulls
94+
"scala.Predef$.fromNullable",
95+
9396
// New feature: modularity
9497
"scala.Precise",
9598
"scala.annotation.internal.WitnessNames",

tests/warn/i15503f.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ object Example:
2828
import scala.quoted.*
2929
given OptionFromExpr[T](using Type[T], FromExpr[T]): FromExpr[Option[T]] with
3030
def unapply(x: Expr[Option[T]])(using Quotes) = x match
31-
case '{ Option[T](${Expr(y)}) } => Some(Option(y))
31+
case '{ Option[T](${Expr(y)}: T) } => Some(Option(y))
3232
case '{ None } => Some(None)
3333
case '{ ${Expr(opt)} : Some[T] } => Some(opt)
3434
case _ => None
@@ -37,7 +37,7 @@ object ExampleWithoutWith:
3737
import scala.quoted.*
3838
given [T] => (Type[T], FromExpr[T]) => FromExpr[Option[T]]:
3939
def unapply(x: Expr[Option[T]])(using Quotes) = x match
40-
case '{ Option[T](${Expr(y)}) } => Some(Option(y))
40+
case '{ Option[T](${Expr(y)}: T) } => Some(Option(y))
4141
case '{ None } => Some(None)
4242
case '{ ${Expr(opt)} : Some[T] } => Some(opt)
4343
case _ => None

0 commit comments

Comments
 (0)