python: be consistent with what value marks have in keywords

Marks are added to keywords in three places:

- `Node.add_marker`: name -> `Mark`
- `Function.__init__(callspec)`: name -> `Mark`
- `Function.__init__ iter_markers`: name -> True

I think it should be consistent, which will also help with some upcoming
code cleaning. The `Mark` seems more useful than just a `True`, so
switch to that.
This commit is contained in:
Ran Benita 2021-10-07 00:42:43 +03:00
parent 4e5fb520b6
commit e9bb1aa233
1 changed files with 1 additions and 1 deletions

View File

@ -1675,7 +1675,7 @@ class Function(PyobjMixin, nodes.Item):
self.keywords.update(
{
mark.name: True
mark.name: mark
for mark in self.iter_markers()
if mark.name not in self.keywords
}