mirror of
https://github.com/facebook/sapling.git
synced 2024-10-10 08:47:12 +03:00
0b39ff42d9
Summary: Handling sections and normal config items. `%` support will be added in an upcoming patch. Note: regex would make the code simpler - the expression `^([^\s=]+)\s*=\s*(.*(?:\n[\t ].*)*)\s*` can extract both config name and multi-line values. However a naive benchmark shows it is 20x slower parsing larger files, and it has some initialization cost. Config parsing is at such a low level and its performance is critical. So the code does its own parsing instead of using regex. Reviewed By: mitrandir77 Differential Revision: D8779051 fbshipit-source-id: a2de698f0676c886737c47891a0400f187bff822 |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |