@@ -30,7 +30,7 @@ Argument Clinic's primary goal
3030is to take over responsibility for all argument parsing code
3131inside CPython. This means that, when you convert a function
3232to work with Argument Clinic, that function should no longer
33- do any of its own argument parsing-- the code generated by
33+ do any of its own argument parsing— the code generated by
3434Argument Clinic should be a "black box" to you, where CPython
3535calls in at the top, and your code gets called at the bottom,
3636with ``PyObject *args `` (and maybe ``PyObject *kwargs ``)
@@ -43,12 +43,12 @@ redundant information in a surprising number of places.
4343When you use Argument Clinic, you don't have to repeat yourself.
4444
4545Obviously, no one would want to use Argument Clinic unless
46- it's solving their problem-- and without creating new problems of
46+ it's solving their problem— and without creating new problems of
4747its own.
4848So it's paramount that Argument Clinic generate correct code.
4949It'd be nice if the code was faster, too, but at the very least
5050it should not introduce a major speed regression. (Eventually Argument
51- Clinic *should * make a major speedup possible-- we could
51+ Clinic *should * make a major speedup possible— we could
5252rewrite its code generator to produce tailor-made argument
5353parsing code, rather than calling the general-purpose CPython
5454argument parsing library. That would make for the fastest
@@ -113,7 +113,7 @@ line. However, if the input hasn't changed, the output won't change either.
113113
114114You should never modify the output portion of an Argument Clinic block. Instead,
115115change the input until it produces the output you want. (That's the purpose of the
116- checksum-- to detect if someone changed the output, as these edits would be lost
116+ checksum— to detect if someone changed the output, as these edits would be lost
117117the next time Argument Clinic writes out fresh output.)
118118
119119For the sake of clarity, here's the terminology we'll use with Argument Clinic:
@@ -166,7 +166,7 @@ Let's dive in!
166166 or if it has multiple calls to :c:func: `PyArg_ParseTuple `,
167167 you should choose a different function. Argument Clinic *does *
168168 support all of these scenarios. But these are advanced
169- topics-- let's do something simpler for your first function.
169+ topics— let's do something simpler for your first function.
170170
171171 Also, if the function has multiple calls to :c:func: `PyArg_ParseTuple `
172172 or :c:func: `PyArg_ParseTupleAndKeywords ` where it supports different
@@ -188,7 +188,7 @@ Let's dive in!
188188
189189 If the old docstring had a first line that looked like a function
190190 signature, throw that line away. (The docstring doesn't need it
191- anymore-- when you use ``help() `` on your builtin in the future,
191+ anymore— when you use ``help() `` on your builtin in the future,
192192 the first line will be built automatically based on the function's
193193 signature.)
194194
@@ -209,7 +209,7 @@ Let's dive in!
2092096. Above the docstring, enter the name of the function, followed
210210 by a blank line. This should be the Python name of the function,
211211 and should be the full dotted path
212- to the function-- it should start with the name of the module,
212+ to the function— it should start with the name of the module,
213213 include any sub-modules, and if the function is a method on
214214 a class it should include the class name too.
215215
@@ -275,7 +275,7 @@ Let's dive in!
275275 What's a "converter"? It establishes both the type
276276 of the variable used in C, and the method to convert the Python
277277 value into a C value at runtime.
278- For now you're going to use what's called a "legacy converter"-- a
278+ For now you're going to use what's called a "legacy converter"— a
279279 convenience syntax intended to make porting old code into Argument
280280 Clinic easier.
281281
@@ -425,7 +425,7 @@ Let's dive in!
425425 (Argument Clinic always generates its format strings
426426 with a ``: `` followed by the name of the function. If the
427427 existing code's format string ends with ``; ``, to provide
428- usage help, this change is harmless-- don't worry about it.)
428+ usage help, this change is harmless— don't worry about it.)
429429
430430 Third, for parameters whose format units require two arguments
431431 (like a length variable, or an encoding string, or a pointer
@@ -638,7 +638,7 @@ an optional argument on the *left* side of its required argument!
638638Another example is ``curses.window.addch() ``, which has a group of two
639639arguments that must always be specified together. (The arguments are
640640called ``x `` and ``y ``; if you call the function passing in ``x ``,
641- you must also pass in ``y ``-- and if you don't pass in ``x `` you may not
641+ you must also pass in ``y ``— and if you don't pass in ``x `` you may not
642642pass in ``y `` either.)
643643
644644In any case, the goal of Argument Clinic is to support argument parsing
@@ -889,7 +889,7 @@ Advanced converters
889889Remember those format units you skipped for your first
890890time because they were advanced? Here's how to handle those too.
891891
892- The trick is, all those format units take arguments-- either
892+ The trick is, all those format units take arguments— either
893893conversion functions, or types, or strings specifying an encoding.
894894(But "legacy converters" don't support arguments. That's why we
895895skipped them for your first function.) The argument you specified
@@ -1003,7 +1003,7 @@ Using a return converter
10031003By default the impl function Argument Clinic generates for you returns ``PyObject * ``.
10041004But your C function often computes some C type, then converts it into the ``PyObject * ``
10051005at the last moment. Argument Clinic handles converting your inputs from Python types
1006- into native C types-- why not have it convert your return value from a native C type
1006+ into native C types— why not have it convert your return value from a native C type
10071007into a Python type too?
10081008
10091009That's what a "return converter" does. It changes your impl function to return
@@ -1185,7 +1185,7 @@ Writing a custom converter
11851185As we hinted at in the previous section... you can write your own converters!
11861186A converter is simply a Python class that inherits from ``CConverter ``.
11871187The main purpose of a custom converter is if you have a parameter using
1188- the ``O& `` format unit-- parsing this parameter means calling
1188+ the ``O& `` format unit— parsing this parameter means calling
11891189a :c:func: `PyArg_ParseTuple ` "converter function".
11901190
11911191Your converter class should be named ``*something*_converter ``.
@@ -1227,7 +1227,7 @@ to specify in your subclass. Here's the current list:
12271227 The default value used to initialize the C variable when
12281228 there is no default, but not specifying a default may
12291229 result in an "uninitialized variable" warning. This can
1230- easily happen when using option groups-- although
1230+ easily happen when using option groups— although
12311231 properly-written code will never actually use this value,
12321232 the variable does get passed in to the impl, and the
12331233 C compiler will complain about the "use" of the
@@ -1403,7 +1403,7 @@ Let's start with defining some terminology:
14031403 all of processing, even from Clinic blocks *after * the
14041404
14051405 ``suppress ``
1406- The text is suppressed-- thrown away.
1406+ The text is suppressed— thrown away.
14071407
14081408
14091409Clinic defines five new directives that let you reconfigure its output.
0 commit comments