You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/reference/metaprogramming/inline.md
+51-3Lines changed: 51 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -295,7 +295,7 @@ val intTwo: 2 = natTwo
295
295
296
296
The `scala.compiletime` package contains helper definitions that provide support for compile time operations over values. They are described in the following.
297
297
298
-
####`constValue`, `constValueOpt`, and the `S` combinator
298
+
### `constValue`, `constValueOpt`, and the `S` combinator
299
299
300
300
`constvalue` is a function that produces the constant value represented by a
301
301
type.
@@ -317,7 +317,7 @@ enabling us to handle situations where a value is not present. Note that `S` is
317
317
the type of the successor of some singleton type. For example the type `S[1]` is
318
318
the singleton type `2`.
319
319
320
-
####`erasedValue`
320
+
### `erasedValue`
321
321
322
322
So far we have seen inline methods that take terms (tuples and integers) as
323
323
parameters. What if we want to base case distinctions on types instead? For
@@ -381,7 +381,7 @@ final val two = toIntT[Succ[Succ[Zero.type]]]
381
381
behavior. Since `toInt` performs static checks over the static type of `N` we
382
382
can safely use it to scrutinize its return type (`S[S[Z]]` in this case).
383
383
384
-
####`error`
384
+
### `error`
385
385
386
386
The `error` method is used to produce user-defined compile errors during inline expansion.
0 commit comments