# HG changeset patch # User Adam Chlipala # Date 1388330966 18000 # Node ID f1485ed65d6c6e7b5f62dd8825a885b3e3db651b # Parent 8b1692660dacc9ea1f7bc441a493ed6c9e23ad52 Avoid some spurious error messages about link/form incompatibility; change the text of that error message to include RPC handlers diff -r 8b1692660dac -r f1485ed65d6c src/tag.sml --- a/src/tag.sml Sat Dec 28 06:30:21 2013 -0500 +++ b/src/tag.sml Sun Dec 29 10:29:26 2013 -0500 @@ -41,9 +41,9 @@ fun kind (k, s) = (k, s) fun con (c, s) = (c, s) -fun both (loc, f) = (ErrorMsg.errorAt loc ("Function " ^ f ^ " needed for both a link and a form"); +fun both (loc, f) = (ErrorMsg.errorAt loc ("Function " ^ f ^ " needed for multiple modes (link, form, RPC handler)."); TextIO.output (TextIO.stdErr, - "Make sure that the signature of the containing module hides any form handlers.\n")) + "Make sure that the signature of the containing module hides any form/RPC handlers.\n")) fun exp env (e, s) = let @@ -145,7 +145,7 @@ end in case x of - (CName "Link", _) => tagIt' (Link ReadWrite, "Link") + (CName "Link", _) => tagIt' (Link ReadCookieWrite, "Link") | (CName "Action", _) => tagIt' (Action ReadWrite, "Action") | _ => ((x, e, t), s) end) @@ -180,7 +180,7 @@ | EFfiApp ("Basis", "url", [(e, t)]) => let - val (e, s) = tagIt (e, Link ReadWrite, "Url", s) + val (e, s) = tagIt (e, Link ReadCookieWrite, "Url", s) in (EFfiApp ("Basis", "url", [(e, t)]), s) end @@ -201,7 +201,7 @@ case eo of SOME (EAbs (_, _, _, (EFfiApp ("Basis", "url", [((ERel 0, _), t)]), _)), _) => let - val (e, s) = tagIt (e', Link ReadWrite, "Url", s) + val (e, s) = tagIt (e', Link ReadCookieWrite, "Url", s) in (EFfiApp ("Basis", "url", [(e, t)]), s) end