Improved error reporting, including file paths. Removed non-working repl. Various cleanups.