pythonizer icon indicating copy to clipboard operation
pythonizer copied to clipboard

Regex with local sub call generates bad code

Open snoopyjc opened this issue 3 years ago • 1 comments

Regex with local sub call generates bad code. For example:

next if exists $cl{$k} and strip($fac) =~ /^OC/;

Generates:

if k in cl and strip([fac])re.search(r'^OC',:

snoopyjc avatar Dec 14 '21 04:12 snoopyjc

Fixed in https://github.com/snoopyjc/pythonizer

snoopyjc avatar Feb 07 '22 15:02 snoopyjc