mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-29 03:04:38 +08:00
* Fix -m argv[0] and file SyntaxError display Set sys.argv[0] to -m for module execution. Convert an escalated invalid-escape SyntaxWarning into a SyntaxError that spans just the `\X` pair. Report null bytes in source files with filename, lineno, and the truncated line. Enable the four corresponding test_cmd_line_script cases. Assisted-by: Grok:4.6 * Pass SyntaxError text when escalating escape warnings Keep the warning and SyntaxError messages as separate strings at the invalid-escape site. CompileWarningError carries an optional replacement instead of rewriting the warning text later. Assisted-by: Grok:4.6 * Remove expectedFailure from bytes invalid-escape test The invalid-escape SyntaxError path now satisfies test_eval_bytes_invalid_escape. Assisted-by: Grok:4.6