about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorUlrik Sverdrup <bluss@users.noreply.github.com>2016-11-19 23:18:43 +0100
committerUlrik Sverdrup <bluss@users.noreply.github.com>2016-11-19 23:46:39 +0100
commit5a3aa2f73cbb08c6e41418c5378791fa24a66146 (patch)
tree03301105253b3f64744f0c32d7e5f8a5dc4c206c /src/rustllvm/RustWrapper.cpp
parentb1da18fe9be180ecfcfb1691c4eb669c496996f5 (diff)
downloadrust-5a3aa2f73cbb08c6e41418c5378791fa24a66146.tar.gz
rust-5a3aa2f73cbb08c6e41418c5378791fa24a66146.zip
str: Improve .chars().count()
Use a simpler loop to count the `char` of a string: count the
number of non-continuation bytes. Use `count += <conditional>` which the
compiler understands well and can apply loop optimizations to.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions