dsl: don't crash in the lexer on empty token list
dsl: don't crash if NewASTRoot() passed an empty list of children
runtime: don't crash attempting to report the error in an empty script
merge
dsl,runtime: report errors like "no main phase" as though they are at EOF

Need to add EOF() method to ASTRoot, set it in dsl.parseTokens(), and
use it when generating a location-specific error object to report the
problem.
dag: correctly stop DFS (and thus the build) early on failure
dag: simplify error handling in DFS()