diff --git a/compiler/src/dotty/tools/dotc/printing/PlainPrinter.scala b/compiler/src/dotty/tools/dotc/printing/PlainPrinter.scala index 3ed0fe647096..f8151fb89e7d 100644 --- a/compiler/src/dotty/tools/dotc/printing/PlainPrinter.scala +++ b/compiler/src/dotty/tools/dotc/printing/PlainPrinter.scala @@ -219,7 +219,8 @@ class PlainPrinter(_ctx: Context) extends Printer { toTextGlobal(tp.resultType) } case AnnotatedType(tpe, annot) => - toTextLocal(tpe) ~ " " ~ toText(annot) + if annot.symbol == defn.InlineParamAnnot then toText(tpe) + else toTextLocal(tpe) ~ " " ~ toText(annot) case tp: TypeVar => if (tp.isInstantiated) toTextLocal(tp.instanceOpt) ~ (Str("^") provided printDebug) diff --git a/library/src/scala/runtime/stdLibPatches/Predef.scala b/library/src/scala/runtime/stdLibPatches/Predef.scala index fbadd3c9cdd9..d811d7d2e3fb 100644 --- a/library/src/scala/runtime/stdLibPatches/Predef.scala +++ b/library/src/scala/runtime/stdLibPatches/Predef.scala @@ -31,7 +31,7 @@ object Predef: * @tparam T the type of the value to be summoned * @return the given value typed: the provided type parameter */ - inline def summon[T](using x: T): x.type = x + transparent inline def summon[T](using inline x: T): x.type = x // Extension methods for working with explicit nulls