diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2021-01-10 09:34:24 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2021-01-10 09:34:24 +0000 |
commit | 4fddf40f5bd51066e3201f319f7a5c1466483b4d (patch) | |
tree | 7aeb7cfd43b5a25f7e06a4e8c1df7cd6eb177f60 /crates/syntax/test_data/lexer/ok/0003_ident.rs | |
parent | d0c2456994848479331c3434631996668039fc3a (diff) | |
parent | 5e81892d4dd3b8353d11df8b9239432b5aa10512 (diff) |
Merge #7224
7224: Remove unnecessary allocation when checking whether to hide argument name hint r=jhpratt a=jhpratt
The case-insensitive prefix/suffix check can be performed
character-by-character. This allows the check to be done without having
to allocate a new string. As a side effect, it's also no longer
necessary to convert the entire string to lowercase, as it's done as
needed. As the only case equality we're handling is ASCII, this
operation can be further optimized by using byte equality, rather than
character equality.
cc @SomeoneToIgnore, as it's an update on my PR from yesterday.
Co-authored-by: Jacob Pratt <[email protected]>
Diffstat (limited to 'crates/syntax/test_data/lexer/ok/0003_ident.rs')
0 files changed, 0 insertions, 0 deletions