4 ms·
Native vs. non-native is irrelevant. A non-native formatting system could have the features of the python formatter that are dangerous. Or, if Python's native f
by obstinate 10y ago
Native vs. non-native is irrelevant. A non-native formatting system could have the features of the python formatter that are dangerous. Or, if Python's native formatter lacked these dangerous features, there'd be no reason not to use it.
- coldtea 10y ago>Native vs. non-native is irrelevant. A non-native formatting system could have the features of the python formatter that are dangerous. Hardly irrelevant. The idea is that a non-native formatting system is build specifically for the templating engine, and so the developers controls what it can do and gives it non-dangerous features. >Or, if Python's native formatter lacked these dangerous features, there'd be no reason not to use it Even if it did lack them, it's not under the control of the template platform author, so they should not rely on it for such a crucial part of the template engine as string formatting. (Which is exactly the case here: Python lacked those features before, but got them, and bit the template engine in the back).
- obstinate 10y ago> it's not under the control of the template platform author This doesn't really matter. If it does what you want, it's not like they're going to change the formatter's behavior from under your feet if it's part of the language's default runtime.