Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
gh-103997: Automatically dedent the argument to "-c"#103998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes from1 commit
16be08fe88216bbcb7c77fb8985a26f27a8417eff8924e0a69f956723f4a78b97f207904435eb4c4eca9f9c969b674f1e005d41699d53c4e689a13af0ac7ea71cad014549de80c3b90b1f5b746ca405891f17e232de2e1ec84616ca19b6757ce411fdea4301e06d40ca40d02895696551735d0fd3681b73b4a7bcf355760b1e89c9d1b4cd1e556bbf136c8b08e5cc7fcd14a0007d2273ed6e17bd1edb1b4c78c5738d2a4e42b633098c17e5File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
- Loading branch information
Uh oh!
There was an error while loading.Please reload this page.
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -339,6 +339,12 @@ extern Py_ssize_t _PyUnicode_InsertThousandsGrouping( | ||
| PyObject *thousands_sep, | ||
| Py_UCS4 *maxchar); | ||
| /* Dedent a string. | ||
| Behaviour is expected to be an exact match of `textwrap.dedent`. | ||
| Return a new reference on success, NULL with exception set on error. | ||
| */ | ||
| PyAPI_FUNC(PyObject*) _PyUnicode_Dedent(PyObject *unicode); | ||
sunmy2019 marked this conversation as resolved. OutdatedShow resolvedHide resolvedUh oh!There was an error while loading.Please reload this page. | ||
| /* --- Misc functions ----------------------------------------------------- */ | ||
| extern PyObject* _PyUnicode_FormatLong(PyObject *, int, int, int); | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,6 @@ | ||
| String arguments passed to "-c" are now automatically dedented as if by | ||
| :func:`textwrap.dedent`. This allows "python -c" invocations to be indented | ||
| in shell scripts without causing indentation errors. (Patch by Jon Crall and | ||
| Steven Sun) | ||
| Add an internal API :c:func:`_PyUnicode_Dedent`. (Patch by Steven Sun) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -3559,139 +3559,3 @@ _PyBytes_Repeat(char* dest, Py_ssize_t len_dest, | ||
| } | ||
| } | ||
| } | ||
sunmy2019 marked this conversation as resolved. Show resolvedHide resolvedUh oh!There was an error while loading.Please reload this page. | ||
Uh oh!
There was an error while loading.Please reload this page.