diff options
| author | Johannes Oertel <johannes.oertel@uni-due.de> | 2015-05-11 12:54:59 +0200 |
|---|---|---|
| committer | Johannes Oertel <johannes.oertel@uni-due.de> | 2015-05-11 12:54:59 +0200 |
| commit | 5b0e19794efe6d2d7f225df57505205627103f32 (patch) | |
| tree | 6e473c7b378b14ec770f098b20e7070d16ef5225 /src/test/codegen/stack-alloc-string-slice.rs | |
| parent | c44d84da981c14cdaa144aa7b0f1109578ed72c3 (diff) | |
| download | rust-5b0e19794efe6d2d7f225df57505205627103f32.tar.gz rust-5b0e19794efe6d2d7f225df57505205627103f32.zip | |
Minor optimization for `VecMap::split_off`
We don't need to copy any elements if `at` is behind the last element in the map. The last element is at index `self.v.len() - 1`, so we should not copy if `at` is greater or equals `self.v.len()`.
Diffstat (limited to 'src/test/codegen/stack-alloc-string-slice.rs')
0 files changed, 0 insertions, 0 deletions
