'The opposite of compiletime.constValue[T] in Scala 3
If we have a transparent inline def f(...): Boolean = ..., is it possible to convert the result of f to true or false types, assuming the result of f is known at compile-time? I would like to use those types in an implicit search.
For example,
given [A](using f(5) <:< true): MyTypeClass with ...
However, the problem is that f(5) is a value, not a type. So the above code won't compile.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
