I found a minor bug that causes the tokenizer.encode() to fail if you pass in code that contains strings that are equal to the inherited properties of javascript objects.
See the included test for one example where the string toString causes problem:
Hi @lhr0909,
I found a minor bug that causes the
tokenizer.encode()
to fail if you pass in code that contains strings that are equal to the inherited properties of javascript objects.See the included test for one example where the string
toString
causes problem:Example error:
Please let me know if I need to adapt anything with the PR.
Thank you ✌🏻 Adam