From: Adam Chlipala Date: Sun, 24 Feb 2008 21:58:17 +0000 (+0000) Subject: Improve some error messages X-Git-Tag: release_2010-11-19~45 X-Git-Url: https://git.hcoop.net/hcoop/domtool2.git/commitdiff_plain/a7951e95f170a9e3534e8b36787a5af1d353156f Improve some error messages --- diff --git a/src/describe.sml b/src/describe.sml index 1e81550..11194af 100644 --- a/src/describe.sml +++ b/src/describe.sml @@ -137,7 +137,7 @@ fun describe_type_error' loc te = Option.app (describe_unification_error t1) ueo) | WrongForm (place, form, e, t, ueo) => if form = "action" andalso will_be_action t then - (ErrorMsg.error (SOME loc) "Not enough arguments passed to configuration function."; + (ErrorMsg.error (SOME loc) ("Not enough arguments passed to configuration function. (" ^ place ^ ")"); preface (" Expression so far:", p_exp e); preface ("Next argument type:", p_typ (get_first_arg t))) else diff --git a/src/tycheck.sml b/src/tycheck.sml index d83a5c0..12efce3 100644 --- a/src/tycheck.sml +++ b/src/tycheck.sml @@ -443,14 +443,14 @@ fun checkExp G (eAll as (e, loc)) = (TAction (p', d', r'), loc) end | (TError, _) => t2 - | _ => (dte (WrongForm ("Action to be sequenced", + | _ => (dte (WrongForm ("First action to be sequenced", "action", e2, t2, NONE)); (TError, loc))) | (TError, _) => t1 - | _ => (dte (WrongForm ("Action to be sequenced", + | _ => (dte (WrongForm ("Second action to be sequenced", "action", e1, t1, @@ -502,14 +502,14 @@ fun checkExp G (eAll as (e, loc)) = (TAction (p', d', r2), loc) end | (TError, _) => t2 - | _ => (dte (WrongForm ("Action to be sequenced", + | _ => (dte (WrongForm ("Body of local settings", "action", e2, t2, NONE)); (TError, loc))) | (TError, _) => t1 - | _ => (dte (WrongForm ("Action to be sequenced", + | _ => (dte (WrongForm ("Local settings", "action", e1, t1,