mirror of
https://github.com/fmtlib/fmt.git
synced 2026-10-29 02:17:28 +08:00
Hoist the loop-invariant is_constant_evaluated check into a guard, matching the fill_n overload for pointers. This lets the runtime path return out directly instead of relying on the scalar fallback being a no-op once n reaches 0, and leaves the fallback call only in the branch that needs it. Also cache buf.size() per iteration as buffer::append does, so the fill pointer is computed after try_resize rather than depending on it not reallocating. |
||
|---|---|---|
| .. | ||
| fmt | ||