Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 32 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,39 @@ object Hello extends IOApp.Simple {
```
@:@

### Native Image
### Scala Native usage

When building GraalVM Native Image the --no-fallback option is required, otherwise native-image will try searching
Since the native flavour of most of the **Typelevel libraries** is, at the moment, built against Scala Native 0.4.15, when using [Scala CLI] you have to declare the Scala native's version, i.e.

@:select(scala-version)
@:choice(scala-3)
```scala mdoc:reset:silent
//> using toolkit typelevel:latest
//> using platform native
//> using nativeVersion 0.4.15

import cats.effect.*

object Hello extends IOApp.Simple:
def run = IO.println("Hello toolkit!")
```
@:choice(scala-2)
```scala mdoc:reset:silent
//> using toolkit typelevel:latest
//> using platform native
//> using nativeVersion 0.4.15

import cats.effect._

object Hello extends IOApp.Simple {
def run = IO.println("Hello toolkit!")
}
```
@:@

## Native Image

When building GraalVM Native Image the `--no-fallback` option is required, otherwise native-image will try searching
a static reflection configuration for [this Enumeration method]. Thus using this flag is safe only if you're not using
Enumerations in your codebase, see [this comment] for more info.

Expand Down