git.iko.soy/rowtype-yoga/psfp
on 6e3d5f6 help sign in
44 lines 861 B history raw
1module Shared.Models.Body where
3import Data.Maybe (Maybe)
5type CompileRequest
6 = { code ∷ String }
8type CompileResult
9 = { result ∷ PursResult }
11type RunResult
12 = { code ∷ Maybe Int, stdout ∷ String, stderr ∷ String }
14type Suggestion
15 = { replaceRange :: Position , replacement :: String }
17type Span
18 = { end :: Array Int
19 , name :: String
20 , start :: Array Int
21 }
23type Position
24 = { endColumn :: Int
25 , endLine :: Int
26 , startColumn :: Int
27 , startLine :: Int
28 }
30type ErrorOrWarning
31 = { allSpans :: Array Span
32 , errorCode :: String
33 , errorLink :: String
34 , filename :: String
35 , message :: String
36 , moduleName :: Maybe String
37 , position :: Position
38 , suggestion :: Maybe Suggestion
39 }
41type PursResult
42 = { errors :: Array ErrorOrWarning
43 , warnings :: Array ErrorOrWarning
44 }