stil4m/elm-syntax/7.3.8

NOTE: the latest version is 7.3.9

Elm.Parser

parseToFile : String -> Result (List DeadEnd) File

Parse some text as if it is an Elm source file. When parsing fails, the result will contain a list of errors indicating what went wrong (and/or where).

parse : String -> Result (List DeadEnd) RawFile

@deprecated Use parseToFile instead, which is simpler and doesn't require post-processing. Since v7.3.3, post-processing is unnecessary.

Parse some text as if it is an Elm source file. When parsing fails, the result will contain a list of errors indicating what went wrong (and/or where). If it succeeds, you will get a RawFile. This RawFile will require some post-processing to properly setup documentation and ensure that operator precedence is applied correctly (based on dependencies). To process a RawFile, check out the Processing module.