Commit 3cc45f8
Optimize mode filtering
Extract a separate function to allow compilation instead of slow
evaluation. This optimization helps when scrolling through large
documents, where previously the minions mode line eval appeared
in the profile for redisplay.
The bottleneck is `pcase-lambda', which performs horribly when not
compiled. Because the whole file might not be compiled drop using
it altogether. Also use `cl-filter-if-not' instead of `seq-filter',
for an additional, though tiny speedup, and also because it allows
dropping a dependency.1 parent 1be68e8 commit 3cc45f8
1 file changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
45 | 44 | | |
46 | 45 | | |
47 | 46 | | |
| |||
154 | 153 | | |
155 | 154 | | |
156 | 155 | | |
157 | | - | |
158 | | - | |
159 | | - | |
| 156 | + | |
160 | 157 | | |
161 | 158 | | |
162 | 159 | | |
| |||
215 | 212 | | |
216 | 213 | | |
217 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
218 | 220 | | |
219 | 221 | | |
220 | 222 | | |
| |||
0 commit comments