futhark-0.25.27: An optimising compiler for a functional, array-oriented language.

Safe Haskell | Safe-Inferred
Language | GHC2021

Futhark.CLI.Literate

Description

    futhark literate

Also contains various utility definitions used by Futhark.CLI.Script.

Synopsis

- main :: String -> [String] -> IO ()
- data Options = Options {
  - scriptBackend :: String
  - scriptFuthark :: Maybe FilePath
  - scriptExtraOptions :: [String]
  - scriptCompilerOptions :: [String]
  - scriptSkipCompilation :: Bool
  - scriptOutput :: Maybe FilePath
  - scriptVerbose :: Int
  - scriptStopOnError :: Bool
  - scriptBinary :: Bool
  - scriptExps :: [Either FilePath Text]
  }
- initialOptions :: Options
- scriptCommandLineOptions :: [FunOptDescr Options]
- prepareServer :: FilePath -> Options -> (ScriptServer -> IO a) -> IO a

# Documentation

main :: String -> [String] -> IO () Source #

Run `futhark literate`.

data Options Source #

Some of these only make sense for `futhark literate`, but enough are also sensible for `futhark script` that we can share them.

Constructors

Options |

Fields

- scriptBackend :: String
- scriptFuthark :: Maybe FilePath
- scriptExtraOptions :: [String]
- scriptCompilerOptions :: [String]
- scriptSkipCompilation :: Bool
- scriptOutput :: Maybe FilePath
- scriptVerbose :: Int
- scriptStopOnError :: Bool
- scriptBinary :: Bool
- scriptExps :: [Either FilePath Text]

initialOptions :: Options Source #

The configuration before any user-provided options are processed.

scriptCommandLineOptions :: [FunOptDescr Options] Source #

Common command line options that transform `Options`.

prepareServer :: FilePath -> Options -> (ScriptServer -> IO a) -> IO a Source #

Start up (and eventually shut down) a Futhark server corresponding to the provided program. If the program has a `.fut` extension, it will be compiled automatically.