racket / redex

Other
93 stars 36 forks source link

`variable-not-in` uses wrong prefix when prefix ends in a number #194

Open florence opened 5 years ago

florence commented 5 years ago

(variable-not-in 'S3 'S3)

Gives back S1, rather than S31.

While this still does give back unique identifiers it can make the output harder to read in some cases.

florence commented 5 years ago

An interesting corner case here:

> (variable-not-in '|1| '|1|)
'|12|

Which is the behavior I would expect (if a tad of a silly example).