-
Notifications
You must be signed in to change notification settings - Fork 48
Closed
Labels
Description
Various string formatting operations are among the most common operations, so it would be useful to speed them up.
The relevant operations are f-strings, the % operator, and .format(...)
. The % operator can also be used with bytes
objects.
Initially it would be sufficient to optimize simple formats that only include string and integer arguments, as this covers a lot of ground (we'd use slower, generic fallbacks for other formats). Also it may be fine to optimize only/primarily for string literal format strings.