Skip to content

Commit 96f554b

Browse files
Aggelos Biboudisnicolasstucki
andauthored
Apply suggestions from code review
Co-Authored-By: Nicolas Stucki <nicolas.stucki@gmail.com>
1 parent 674451f commit 96f554b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/docs/reference/metaprogramming/inline.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -230,9 +230,9 @@ Example:
230230
```scala
231231
inline def update(delta: Int) =
232232
inline if (delta >= 0) increaseBy(delta)
233-
else decreaseByf(delta)
233+
else decreaseBy(-delta)
234234
```
235-
A call `update(22)` would rewrite to `increaseBy(22`. But if `update` was called with
235+
A call `update(22)` would rewrite to `increaseBy(22)`. But if `update` was called with
236236
a value that was not a compile-time constant, we would get a compile time error like the one
237237
below:
238238
```
@@ -289,7 +289,7 @@ val intTwo: 2 = natTwo
289289

290290
`natTwo` is inferred to have the singleton type 2.
291291

292-
## The scala.compiletime Package
292+
## The `scala.compiletime` Package
293293

294294
The `scala.compiletime` package contains helper definitions that provide support for compile time operations over values. They are described in the following.
295295

@@ -473,4 +473,4 @@ inline def f: Any = implicit match {
473473

474474
For more info, see [PR #4927](https://github.com/lampepfl/dotty/pull/4768),
475475
which explains how inline methods can be used for typelevel programming and code
476-
specialization.
476+
specialization.

0 commit comments

Comments
 (0)