diff src/main.mlton.sml @ 1809:b8fa7441e637

Add list of files to new error message
author Adam Chlipala <adam@chlipala.net>
date Sat, 18 Aug 2012 13:57:48 -0400
parents 90ebfac7e1a3
children d636d33fd8a2
line wrap: on
line diff
--- a/src/main.mlton.sml	Sat Aug 18 13:51:41 2012 -0400
+++ b/src/main.mlton.sml	Sat Aug 18 13:57:48 2012 -0400
@@ -169,9 +169,10 @@
         val job =
             case !sources of
                 [file] => file
-              | _ =>
+              | files =>
                 if List.exists (fn s => s <> "-version") args then
-                    raise Fail "Zero or multiple input files specified; only one is allowed."
+                    raise Fail ("Zero or multiple input files specified; only one is allowed.\nFiles: "
+                                ^ String.concatWith ", " files)
                 else
                     printVersion ()
     in