Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fatalerror with cyrillic string #172

Open
tureck1y opened this issue May 3, 2019 · 2 comments
Open

fatalerror with cyrillic string #172

tureck1y opened this issue May 3, 2019 · 2 comments

Comments

@tureck1y
Copy link

tureck1y commented May 3, 2019

I get the fatal error while trying to init itemSuffix: Can't form Range with upperBound < lowerBound. Reproducing with same Cyrillic string inside text and suggestion ( "Москва" for example) I can suggest this fix:

fileprivate func filter(forceShowAll addAll: Bool) {
...
if item.title.lowercased().hasPrefix(textToFilter) {
...
  let itemSuffix: Substring = indexFrom < item.title.endIndex ? item.title.suffix(from: indexFrom) : ""
...
  }
}
@tureck1y
Copy link
Author

tureck1y commented May 6, 2019

Xcode version 10.2.1

@innvonix6166
Copy link

i have same Error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants