skx / gobasic

A BASIC interpreter written in golang.
https://blog.steve.fi/tags/basic/
GNU General Public License v2.0
331 stars 27 forks source link

117 fuzzing #119

Closed skx closed 2 years ago

skx commented 2 years ago

This pull-request updates our fuzz-testing to use the new support which is available with golang 1.18+, rather than relying upon an external tool.

The fuzzing function was updated appropriately, the documentation was updated, and we've fixed a bug where the following code took too long:

 PRINT "" * 4544444444444

(The issue here is that this expands to "" + "" + "" + "" .., but the count is so large that it essentially takes forever. Given that an empty string multiplied by an integer remains an empty-string we can skip that whole mess!)

This will close #117, once complete.