title: SML/NJ using CM.make: "Error: illegal character"
body: <p>I'm trying to compile the following program from Shipman's <a href="http://mlton.org/References.attachments/Shipman02.pdf#page=32" rel="nofollow">Unix System Programming with Standard ML</a>:</p>
  
  <pre><code>structure Main=
  struct
  
      fun main(arg0, argv) =
      (
          case argv of
            [] =&gt; ()
          | (first::rest) =&gt;
          (
              print first;
              app (fn arg =&gt; (print " "; print arg)) rest;
              print "\n"
          );
  
          OS.Process.success
      )
  
      val _ = SMLofNJ.exportFn("echo", main)
  end
  </code></pre>
  
  <p>My .cm file looks like:</p>
  
  <pre><code>group is
      $/basis.cm
      echo.sml
  </code></pre>
  
  <p>When I run <code>CM.make "echo.sml";</code> I get the following error message:</p>
  
  <pre><code>gotchops@gotchops-vm:~/Documents/USPwSML/Ch2/echo$ CM_ROOT=echo.cm sml
  Standard ML of New Jersey v110.80 [built: Fri Sep 16 22:36:30 2016]
  - CM.make "echo.sml";
  [autoloading]
  [library $smlnj/cm/cm.cm is stable]
  [library $smlnj/internal/cm-sig-lib.cm is stable]
  [library $/pgraph.cm is stable]
  [library $smlnj/internal/srcpath-lib.cm is stable]
  [library $SMLNJ-BASIS/basis.cm is stable]
  [library $SMLNJ-BASIS/(basis.cm):basis-common.cm is stable]
  [autoloading done]
  [scanning echo.sml]
  echo.sml:7.11 Error: illegal character: [
  echo.sml:7.12 Error: illegal character: ]
  echo.sml:1.2-1.16 Error: syntax error: deleting  STRUCTURE ML_ID
  echo.sml:6.9 Error: syntax error: inserting  RPAREN
  echo.sml:8.17-8.19 Error: syntax error: deleting  COLON COLON
  echo.sml:11.14 Error: syntax error: replacing  LPAREN with  RPAREN
  echo.sml:11.32-11.34 Error: syntax error: deleting  FILE_NATIVE
  echo.sml:11.47 Error: syntax error: inserting  LPAREN
  echo.sml:12.16-12.19 Error: syntax error: replacing  FILE_NATIVE with LPAREN
  echo.sml:13.10 Error: syntax error: inserting  LPAREN
  echo.sml:17.30-17.35 Error: syntax error: deleting  FILE_NATIVE
  echo.sml:19.1 Error: syntax error found at EOF
  val it = false : bool
  </code></pre>
  
  <p>However, when I run <code>use "echo.sml";</code> from the toplevel I can compile just fine. Anyone know what's wrong?</p>