Erlend E. Aasland
2ad699002e
Docs: Argument Clinic: Restructure "Basic concepts and usage" ( #106981 )
...
Split "Basic concepts and usage" into:
- Reference
- Terminology
- CLI reference
- Background
- Basic concepts
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2023-07-26 22:08:43 +00:00
Alex Waygood
5aa6964a5c
gh-104050: Argument clinic: Annotate str_converter_key() ( #107294 )
2023-07-26 21:12:18 +01:00
Alex Waygood
f9bcdf2368
gh-104050: Argument clinic: Complete get_destination_buffer annotations ( #107293 )
2023-07-26 21:11:15 +01:00
Alex Waygood
14d074e1fb
gh-104683: Argument Clinic: Make most arguments to Class and Function required ( #107289 )
2023-07-26 11:54:03 +01:00
Alex Waygood
c362678dd2
gh-104050: Argument clinic: improve typing around parse_arg() methods ( #107288 )
2023-07-26 11:51:24 +01:00
Alex Waygood
33838fedf7
gh-104050: Argument clinic: annotate post_parsing() and cleanup() ( #107225 )
2023-07-25 23:33:03 +01:00
Alex Waygood
ee9010784c
gh-104050: Argument clinic: more misc typing improvements ( #107264 )
2023-07-25 22:08:52 +01:00
Alex Waygood
d9e34db993
gh-104050: Argument clinic: more misc typing coverage improvements ( #107210 )
2023-07-25 08:49:07 +00:00
Alex Waygood
dbfe73837d
gh-104050: Argument clinic: improve typing around adding C converters ( #107209 )
2023-07-25 09:18:19 +01:00
Alex Waygood
4bbf071635
gh-104050: Argument Clinic: Annotate CRenderData.__init__ ( #107207 )
...
Argument Clinic: Annotate `CRenderData.__init__`
2023-07-24 21:38:50 +00:00
Alex Waygood
d93fe5afe2
gh-104050: Argument clinic: misc improvements to type annotation coverage ( #107206 )
2023-07-24 21:23:58 +00:00
Alex Waygood
ac2d85a174
gh-104050: Argument clinic: annotate format_docstring() ( #107200 )
2023-07-24 20:29:50 +00:00
Alex Waygood
db17529f80
gh-104050: Argument Clinic: annotate main() ( #107192 )
2023-07-24 19:32:38 +00:00
Erlend E. Aasland
3aeffc0d8f
gh-104050: Argument Clinic: Increase typing coverage ( #107074 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-22 22:30:42 +00:00
Erlend E. Aasland
c5adf26b18
gh-104050: Argument Clinic: Annotate the BufferSeries class ( #106935 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-22 12:46:42 +02:00
Erlend E. Aasland
3372bcba98
gh-106970: Fix Argument Clinic 'destination <name> clear' command ( #106972 )
...
Add test for the 'destination <name> clear' command,
and the 'destination' directive in general.
Fix two bugs in 'destination <name> clear' command:
1. The text attribute of the allocator is called 'text', not '_text'
2. Return after processing the 'clear' command,
instead of proceeding directly to the fail().
2023-07-22 09:43:13 +02:00
Erlend E. Aasland
d81b4f8ff8
gh-104050: Argument Clinic: Annotate the IndentStack class ( #106934 )
2023-07-20 23:19:11 +00:00
Erlend E. Aasland
1d5a625eb0
gh-104050: Argument Clinic: Increase CConverter typing coverage ( #106932 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-20 22:45:02 +00:00
Erlend E. Aasland
42c6300d4f
gh-104050: Argument Clinic: Annotate CLanguage.render_option_group_parsing() ( #106929 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-20 21:33:33 +00:00
Erlend E. Aasland
00e52acebd
gh-104683: Argument Clinic: Modernise parse_special_symbol() ( #106837 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-17 22:37:11 +00:00
Erlend E. Aasland
036bb73656
gh-104050: Improve Argument Clinic type annotation coverage ( #106810 )
...
Add various missing annotations in the following classes:
- BlockPrinter
- CConverter
- CLanguage
- FormatCounterFormatter
- Language
- _TextAccumulator
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-17 13:47:08 +02:00
Erlend E. Aasland
383dcbebcd
gh-104050: Argument Clinic: Annotate Clinic.parse() ( #106760 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-17 00:04:10 +00:00
Erlend E. Aasland
bbf6297985
gh-104050: Argument Clinic: Annotate BlockParser ( #106750 )
2023-07-15 10:11:32 +00:00
Erlend E. Aasland
7c95345e4f
gh-104050: Argument Clinic: Annotate output_templates() ( #106732 )
...
Co-authored-by: AlexWaygood <alex.waygood@gmail.com>
2023-07-14 12:20:58 +00:00
Alex Waygood
128a6c1d88
gh-104683: Argument clinic: use an enum to describe the different kinds of functions ( #106721 )
...
Argument clinic: use an enum to describe the different kinds of functions
2023-07-13 22:54:05 +00:00
Erlend E. Aasland
2d43beec22
gh-104050: Argument Clinic: Annotate nested function parser_body() in the CLanguage class ( #106699 )
2023-07-12 22:49:30 +00:00
Alex Waygood
8aa4beaad0
gh-104683: Argument clinic: modernise cpp.Monitor ( #106698 )
2023-07-12 22:48:36 +00:00
Alex Waygood
a180e7a0df
gh-104050: Argument clinic: Annotate the Destination class ( #106655 )
...
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-07-12 22:33:47 +01:00
Alex Waygood
7ce3ea4906
gh-104683: Argument clinic: Minor readability improvements for Destination.__init__ ( #106652 )
2023-07-11 23:08:28 +00:00
Alex Waygood
d0972c77aa
gh-104050: Argument Clinic: Annotate the Block class ( #106519 )
2023-07-11 21:21:14 +00:00
Alex Waygood
363f4f99c5
gh-104683: clinic.py: refactor Parameter and Function as dataclasses ( #106477 )
2023-07-07 13:10:07 +00:00
Alex Waygood
5548097925
gh-104683: clinic.py: refactor four simple classes as dataclasses ( #106476 )
2023-07-06 22:17:12 +01:00
Alex Waygood
d0c6ba956f
gh-104683: clinic.py: Don't needlessly reimplement contextlib.redirect_stdout ( #106478 )
...
clinic.py: Don't needlessly reimplement `contextlib.redirect_stdout`
2023-07-06 14:23:02 +01:00
Erlend E. Aasland
9d1d4f9c73
gh-64595: Fix regression in file write logic in Argument Clinic ( #106449 )
...
Revert the two commits that introduced the regressions:
- gh-104152
- gh-104507
2023-07-05 13:23:22 +02:00
Erlend E. Aasland
7bb9fa5ae4
gh-104050: Partially annotate Argument Clinic CLanguage class ( #106437 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-04 23:07:57 +00:00
Erlend E. Aasland
22087516bc
gh-104050: Annotate Argument Clinic parameter permutation helpers ( #106431 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-04 22:15:10 +00:00
Erlend E. Aasland
110b97c94c
gh-104050: Annotate toplevel functions in clinic.py ( #106435 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-04 22:13:30 +00:00
Erlend E. Aasland
8f6df5e9cb
gh-106368: Add tests for permutation helpers in Argument Clinic ( #106407 )
...
Added new test class PermutationTests()
2023-07-04 11:36:40 +00:00
Erlend E. Aasland
b24479dcba
gh-104050: Annotate more Argument Clinic DSLParser state methods ( #106376 )
...
Annotate the following methods:
- state_parameter()
- state_parameter_docstring_start()
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-03 22:10:46 +00:00
Erlend E. Aasland
71b40443fe
gh-104683: Modernise Argument Clinic parameter state machine ( #106362 )
...
Use enums and pattern matching to make the code more readable.
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-03 21:16:21 +00:00
Erlend E. Aasland
2e2daac2f1
gh-104050: Add more type hints to Argument Clinic DSLParser() ( #106354 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-03 14:03:31 +00:00
Erlend E. Aasland
0da4c883cf
gh-106359: Fix corner case bugs in Argument Clinic converter parser ( #106361 )
...
DSLParser.parse_converter() could return unusable kwdicts in some rare cases
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-07-03 13:14:59 +00:00
Erlend E. Aasland
60e41a0cbb
gh-104146: Remove unused attr 'parameter_indent' from clinic.DLParser ( #106358 )
2023-07-03 11:00:35 +00:00
Erlend E. Aasland
18fedd04a7
gh-104050: Annotate Argument Clinic DSLParser attributes ( #106357 )
2023-07-03 10:06:54 +00:00
Erlend E. Aasland
569887aa9d
gh-104050: Add more type hints to Argument Clinic DSLParser() ( #106343 )
...
Annotate the following method signatures:
- state_dsl_start()
- state_parameter_docstring_start()
- state_parameters_start()
Inverting ignore_line() logic, add type hints (including type guard) to
it, and rename to valid_line().
2023-07-02 23:42:38 +00:00
dependabot[bot]
c336b4c14f
build(deps-dev): bump mypy from 1.3.0 to 1.4.1 in /Tools/clinic ( #106305 )
...
Bumps [mypy](https://github.com/python/mypy ) from 1.3.0 to 1.4.1.
- [Commits](https://github.com/python/mypy/compare/v1.3.0...v1.4.1 )
---
updated-dependencies:
- dependency-name: mypy
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-01 09:54:32 +00:00
Victor Stinner
cbb9ba844f
gh-92536: Argument Clinic no longer emits PyUnicode_READY() ( #105208 )
...
Since Python 3.12, PyUnicode_READY() does nothing and always
returns 0.
Argument Clinic now also checks for .cpp files (PC/_wmimodule.cpp).
2023-06-02 01:31:58 +02:00
Victor Stinner
dd29ae26f8
gh-105156: Argument Clinic avoids Py_UNICODE type ( #105161 )
...
Argument Clinic now uses "const wchar_t*" type instead of
"const Py_UNICODE*" type for the "Py_UNICODE" format.
2023-05-31 17:52:33 +00:00
Alex Waygood
4b107d86f3
gh-104683: clinic.py: Modernise parse_converter() using pattern-matching ( #104696 )
2023-05-21 23:29:43 +00:00
Erlend E. Aasland
6ba8406cb6
gh-104050: Add more type annotations to Argument Clinic ( #104631 )
...
Annotate methods of the following classes:
- class Function
- class Parameter
- class LandMine
2023-05-21 21:24:26 +00:00