summaryrefslogtreecommitdiff
path: root/src/compiler.sml
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adamc@hcoop.net>2010-02-27 16:49:11 -0500
committerGravatar Adam Chlipala <adamc@hcoop.net>2010-02-27 16:49:11 -0500
commitf59bbf0b942cd888c798c06ba6841bf94562a438 (patch)
tree64c89f63745865e9d0e443dc8cc8ecc2cac7900b /src/compiler.sml
parent1607362ff628b9a1476679fbf9146b66ce92a3ee (diff)
benignEffectful
Diffstat (limited to 'src/compiler.sml')
-rw-r--r--src/compiler.sml9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/compiler.sml b/src/compiler.sml
index c74a0915..f0313c8b 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -48,6 +48,7 @@ type job = {
scripts : string list,
clientToServer : Settings.ffi list,
effectful : Settings.ffi list,
+ benignEffectful : Settings.ffi list,
clientOnly : Settings.ffi list,
serverOnly : Settings.ffi list,
jsFuncs : (Settings.ffi * string) list,
@@ -212,7 +213,7 @@ val parseUr = {
fun p_job ({prefix, database, exe, sql, sources, debug, profile,
timeout, ffi, link, headers, scripts,
- clientToServer, effectful, clientOnly, serverOnly, jsFuncs, ...} : job) =
+ clientToServer, effectful, benignEffectful, clientOnly, serverOnly, jsFuncs, ...} : job) =
let
open Print.PD
open Print
@@ -248,6 +249,7 @@ fun p_job ({prefix, database, exe, sql, sources, debug, profile,
p_list_sep (box []) (fn s => box [string "Link", space, string s, newline]) link,
p_ffi "ClientToServer" clientToServer,
p_ffi "Effectful" effectful,
+ p_ffi "BenignEffectful" benignEffectful,
p_ffi "ClientOnly" clientOnly,
p_ffi "ServerOnly" serverOnly,
p_list_sep (box []) (fn ((m, s), s') =>
@@ -371,6 +373,7 @@ fun parseUrp' accLibs fname =
val scripts = ref []
val clientToServer = ref []
val effectful = ref []
+ val benignEffectful = ref []
val clientOnly = ref []
val serverOnly = ref []
val jsFuncs = ref []
@@ -399,6 +402,7 @@ fun parseUrp' accLibs fname =
scripts = rev (!scripts),
clientToServer = rev (!clientToServer),
effectful = rev (!effectful),
+ benignEffectful = rev (!benignEffectful),
clientOnly = rev (!clientOnly),
serverOnly = rev (!serverOnly),
jsFuncs = rev (!jsFuncs),
@@ -439,6 +443,7 @@ fun parseUrp' accLibs fname =
scripts = #scripts old @ #scripts new,
clientToServer = #clientToServer old @ #clientToServer new,
effectful = #effectful old @ #effectful new,
+ benignEffectful = #benignEffectful old @ #benignEffectful new,
clientOnly = #clientOnly old @ #clientOnly new,
serverOnly = #serverOnly old @ #serverOnly new,
jsFuncs = #jsFuncs old @ #jsFuncs new,
@@ -564,6 +569,7 @@ fun parseUrp' accLibs fname =
| "script" => scripts := arg :: !scripts
| "clientToServer" => clientToServer := ffiS () :: !clientToServer
| "effectful" => effectful := ffiS () :: !effectful
+ | "benignEffectful" => benignEffectful := ffiS () :: !benignEffectful
| "clientOnly" => clientOnly := ffiS () :: !clientOnly
| "serverOnly" => serverOnly := ffiS () :: !serverOnly
| "jsFunc" => jsFuncs := ffiM () :: !jsFuncs
@@ -626,6 +632,7 @@ fun parseUrp' accLibs fname =
Settings.setScripts (#scripts job);
Settings.setClientToServer (#clientToServer job);
Settings.setEffectful (#effectful job);
+ Settings.setBenignEffectful (#benignEffectful job);
Settings.setClientOnly (#clientOnly job);
Settings.setServerOnly (#serverOnly job);
Settings.setJsFuncs (#jsFuncs job);