]> git.lyx.org Git - lyx.git/commit
FindAdv: Optimization
authorKornel Benko <kornel@lyx.org>
Sun, 31 Jan 2021 08:53:06 +0000 (09:53 +0100)
committerKornel Benko <kornel@lyx.org>
Sun, 31 Jan 2021 08:53:06 +0000 (09:53 +0100)
commit3a1b19c5c363428f424180270e32bc8b468ea54f
tree25fc8980340f1e6d2465f710d3f59f49a53581d0
parentc79ec4114e419ae8f4711c4c07ab0df19dafaaa3
FindAdv: Optimization

Using unordered_map instead of map.
Reasons:
1.) The relevant maps contain 166(Keys) and 649(Accents) entries.
  This mean that average access with 'map' needs 8 to 10 compares to find the value.
2.) Since we are using at least c++11, the unordered_map is available
2.) increasing the maps (in future) needs not to be considered anymore, because
  the access-time will not increase.
src/lyxfind.cpp