an-cabal / an-rope

an rope data structure
https://docs.rs/an-rope
MIT License
11 stars 2 forks source link

Rope indexing doesn't handle pathologically evil strings #54

Open hawkw opened 7 years ago

hawkw commented 7 years ago

I've disabled the QuickCheck rope indexing tests in my dev branch, because although we can now handle a lot of weird unicode graphemes, the tests like to make strings consisting entirely of nulls or entirely of control characters.

We should eventually work on more robust handling of strings like

"\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}"
hawkw commented 7 years ago

We should probably be testing against the Big List of Naughty Strings at some point.