Skip to content

Commit c58c65f

Browse files
Merge pull request #8315 from lampepfl/nicolasstucki-patch-1
Updated assert example to inline parameters
2 parents 26de50a + 5708a56 commit c58c65f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/docs/reference/metaprogramming/macros.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ prints it again in an error message if it evaluates to `false`.
3333
```scala
3434
import scala.quoted._
3535

36-
inline def assert(expr: => Boolean): Unit =
36+
inline def assert(inline expr: Boolean): Unit =
3737
${ assertImpl('expr) }
3838

3939
def assertImpl(expr: Expr[Boolean])(using QuoteContext) = '{

0 commit comments

Comments
 (0)