pythonizer
pythonizer copied to clipboard
Condition on generated code for function() or die() is backwards
Given this perl code:
open(FILE,'<',$file) or die("cannot open $file $!");
The generated python code is calling the die() routine if the open succeeds, instead of fails:
if(FILE:=open(file,'r')):
sys.exit(f"cannot open {file} {sys.last_value}")
Fixed in https://github.com/snoopyjc/pythonizer