-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
gh-119127: functools.partial placeholders #119827
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
78 commits
Select commit
Hold shift + click to select a range
ee7333c
Initial Implementation
dg-pb 8bcc462
serialization fix
dg-pb c67c9b4
bug fix
dg-pb 680d900
Bug 2 fix
dg-pb 9591ff5
Py_TPFLAGS_IMMUTABLETYPE added
dg-pb 067e938
placeholder added to state as opposed to being used as global constant
dg-pb 8af20b3
static removed
dg-pb 607a0b1
creating sentinel via PyType_Spec
dg-pb f55801e
more accurate variable name
dg-pb 5894145
trailing trim bug and tests
dg-pb 3722e07
Updated docs
dg-pb a79c2af
blurb
dg-pb 12aaa72
Merge branch 'main' into implement-119127
92c767b
minor edit
dg-pb 496a9d2
doc fix
dg-pb 38d9c11
better variable names and mini corrections
dg-pb 707b957
Merge branch 'implement-119127' into implement-119127-again
dg-pb 14b38ca
review comments mostly
dg-pb 32bca19
singleton sentinel and reduce
dg-pb 8576493
python module sentinel better mimics the one of the extension
dg-pb a3fd2d6
Emulated None behaviour, but using PyType_FromModuleAndSpec
dg-pb 0852993
review feedback
dg-pb 6fea348
included constant into tsv
dg-pb caec6e8
documentation update
dg-pb 115b8c5
review edits
dg-pb 3f5f00b
trailing placeholder prohibition and small changes
dg-pb 202c929
change constant name in ignores
dg-pb 2c16d38
PlaceholderType Hidden
dg-pb 400ff55
support 4-arg pre-placeholder state
dg-pb 8ccc38f
better variable names
dg-pb e7c82c7
partialmethod impl
dg-pb c9b7ef3
fix tests
dg-pb e59d711
adjust inspect to partial Placeholders
dg-pb 7bfc591
arg alignment
dg-pb 7957a97
small fixes
dg-pb 8aaee6a
pickle compatibility ensured
dg-pb fe8e0ad
trailing placeholder test for __setstate__
dg-pb 00dd80e
rough implementation rolled back and example of successive applicatio…
dg-pb d352cfa
small doc edits
dg-pb 9038ed5
example changes
dg-pb 49b8c71
serialization issues addressed
dg-pb bc1fdbd
delete redundant references
dg-pb 3067221
simplify PyPlaceholder implementation
dg-pb 1185510
more optimal python functools.partial
dg-pb 266b4fa
placeholder arg and pre-placeholder instance conversions to positional
dg-pb dd58a12
unittest.mock.ANY test for Placeholder
dg-pb 5971fbb
functools.partial.__get__
dg-pb 9033650
Revert "functools.partial.__get__"
dg-pb d31e5d1
Merge branch 'main' into implement-119127-again
dg-pb a3d39b0
review changes
dg-pb 9e4c5df
factor out repr. same to be used for partial and partialmethod
dg-pb 16f12f8
microopt & args.count(Placeholder) can not be used as it uses __eq__
dg-pb 82dd600
simplify preparation
dg-pb f9cb653
whatsnew + minor doc edit
dg-pb d255524
typo fixes
dg-pb 404044e
whatsnew edit
dg-pb 800217b
revert stylistic changes
dg-pb 38ee450
factor out full __new__
dg-pb 11f47db
Merge branch 'main' into implement-119127-again
serhiy-storchaka 3c872bd
Merge branch 'main' into implement-119127-again
serhiy-storchaka fd16189
CR part 1
dg-pb a6c6ef2
CR Part 2
dg-pb 1c8d73e
remove ignored global var
dg-pb a8bd3ae
CR changes
dg-pb 70e47ed
small CR changes and doc updates
dg-pb 2eacf5e
push placeholder check to earlier place
dg-pb f78d8d3
more appropriate test functions and better doc example
dg-pb 0a8640e
minor fixes; message, doc polish
dg-pb 6e3d282
better doc example and small test changes
dg-pb 66c305d
assertRaisesRegex exact match
dg-pb 14bf68c
doc nits
dg-pb ee642d5
Add Placeholder to __all__
rhettinger 8d6c28e
Update copyright span
rhettinger 8744bcb
Minor doc edits and add doctests
rhettinger b896470
Merge branch 'main' into implement-119127-again
rhettinger 4881ae6
Merge branch 'main' into implement-119127-again
rhettinger c3ad7d9
Having the separate dict was necessary to eliminate duplicate keywords
rhettinger 5e5d484
Merge branch 'main' into implement-119127-again
rhettinger File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
push placeholder check to earlier place
- Loading branch information
commit 2eacf5e40d24a8cf988993db3aaa7725b0c15ac6
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.