[Snek] [keith-packard/snek] 9bd0d4: In non-interactive mode, stop after first syntax e...

Keith Packard noreply at github.com
Tue Jun 25 12:07:16 PDT 2019


  Branch: refs/heads/master
  Home:   https://github.com/keith-packard/snek
  Commit: 9bd0d4881a074ef0b5fd283dd2d9fb5d0904091b
      https://github.com/keith-packard/snek/commit/9bd0d4881a074ef0b5fd283dd2d9fb5d0904091b
  Author: Keith Packard <keithp at keithp.com>
  Date:   2019-06-25 (Tue, 25 Jun 2019)

  Changed paths:
    M snek-parse.c

  Log Message:
  -----------
  In non-interactive mode, stop after first syntax error

Don't keep going in this case; let the user fix the first error.

Signed-off-by: Keith Packard <keithp at keithp.com>


  Commit: eb37e203a84fb9c18e65cf8f38d60cebabaaab49
      https://github.com/keith-packard/snek/commit/eb37e203a84fb9c18e65cf8f38d60cebabaaab49
  Author: Keith Packard <keithp at keithp.com>
  Date:   2019-06-25 (Tue, 25 Jun 2019)

  Changed paths:
    M test/Makefile
    A test/actual-named-first.py
    A test/formal-named-first.py
    A test/list-named.py
    A test/range-named.py
    A test/tuple-named.py

  Log Message:
  -----------
  test: Add tests to catch named parameter in wrong place

Snek had a bug where it would allow named parameters in weird places. These
tests make sure that doesn't happen again. Checks for

	> [x=1]
	> (1,y=1)
	> for i in range(x=1): print(i)
	> def foo(x=1,y): return x+y
	> foo(x=1,12)

Signed-off-by: Keith Packard <keithp at keithp.com>


Compare: https://github.com/keith-packard/snek/compare/5077a8defb57...eb37e203a84f


More information about the Snek mailing list