Commit 6f5698c
committed
Avoid re-interning in
The def path printer in `get_def_path` essentially calls
`Symbol::intern(&symbol.to_string())` for simple symbols in a path.
This accounts for ~30% of the runtime of get_def_path.
We can avoid this by simply appending the symbol directly when available.LateContext::get_def_path
1 parent 10fa3c4 commit 6f5698c
1 file changed
+4
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
812 | 812 | | |
813 | 813 | | |
814 | 814 | | |
815 | | - | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
816 | 819 | | |
817 | 820 | | |
818 | 821 | | |
| |||
0 commit comments