8000 [3.10] gh-93217: fix some issues in man page and --help (GH-93219) (#… · python/cpython@c649526 · GitHub
[go: up one dir, main page]

Skip to content

Commit c649526

Browse files
authored
[3.10] gh-93217: fix some issues in man page and --help (GH-93219) (#93261)
1 parent 561c709 commit c649526

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

Misc/python.man

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,10 @@ python \- an interpreted, interactive, object-oriented programming language
6666
.B \-x
6767
]
6868
[
69-
[
7069
.B \-X
7170
.I option
7271
]
72+
[
7373
.B \-?
7474
]
7575
.br
@@ -302,7 +302,8 @@ Set implementation specific option. The following options are available:
302302
more verbose than the default if the code is correct: new warnings are
303303
only emitted when an issue is detected. Effect of the developer mode:
304304
* Add default warning filter, as -W default
305-
* Install debug hooks on memory allocators: see the PyMem_SetupDebugHooks() C function
305+
* Install debug hooks on memory allocators: see the PyMem_SetupDebugHooks()
306+
C function
306307
* Enable the faulthandler module to dump the Python traceback on a crash
307308
* Enable asyncio debug mode
308309
* Set the dev_mode attribute of sys.flags to True
@@ -313,7 +314,10 @@ Set implementation specific option. The following options are available:
313314
otherwise activate automatically). See PYTHONUTF8 for more details
314315

315316
-X pycache_prefix=PATH: enable writing .pyc files to a parallel tree rooted at the
316-
given directory instead of to the code tree.
317+
given directory instead of to the code tree.
318+
319+
-X warn_default_encoding: enable opt-in EncodingWarning for 'encoding=None'
320+
317321
.TP
318322
.B \-x
319323
Skip the first line of the source. This is intended for a DOS

Python/initconfig.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Options and arguments (and corresponding environment variables):\n\
4141
-d : turn on parser debugging output (for experts only, only works on\n\
4242
debug builds); also PYTHONDEBUG=x\n\
4343
-E : ignore PYTHON* environment variables (such as PYTHONPATH)\n\
44-
-h : print this help message and exit (also --help)\n\
44+
-h : print this help message and exit (also -? or --help)\n\
4545
";
4646
static const char usage_2[] = "\
4747
-i : inspect interactively after running script; forces a prompt even\n\
@@ -67,7 +67,6 @@ static const char usage_3[] = "\
6767
also PYTHONWARNINGS=arg\n\
6868
-x : skip first line of source, allowing use of non-Unix forms of #!cmd\n\
6969
-X opt : set implementation-specific option. The following options are available:\n\
70-
\n\
7170
-X faulthandler: enable faulthandler\n\
7271
-X showrefcount: output the total reference count and number of used\n\
7372
memory blocks when the program finishes or after each statement in the\n\
@@ -84,7 +83,8 @@ static const char usage_3[] = "\
8483
checks which are too expensive to be enabled by default. Effect of the\n\
8584
developer mode:\n\
8685
* Add default warning filter, as -W default\n\
87-
* Install debug hooks on memory allocators: see the PyMem_SetupDebugHooks() C function\n\
86+
* Install debug hooks on memory allocators: see the PyMem_SetupDebugHooks()\n\
87+
C function\n\
8888
* Enable the faulthandler module to dump the Python traceback on a crash\n\
8989
* Enable asyncio debug mode\n\
9090
* Set the dev_mode attribute of sys.flags to True\n\
@@ -95,7 +95,6 @@ static const char usage_3[] = "\
9595
-X pycache_prefix=PATH: enable writing .pyc files to a parallel tree rooted at the\n\
9696
given directory instead of to the code tree\n\
9797
-X warn_default_encoding: enable opt-in EncodingWarning for 'encoding=None'\n\
98-
\n\
9998
--check-hash-based-pycs always|default|never:\n\
10099
control how Python invalidates hash-based .pyc files\n\
101100
";

0 commit comments

Comments
 (0)
0