Add Str.kind field to typed_ast stubs (#2699)

We recently cut a new-ish release of typed-ast that [adds a new field][0]
named `kind` to the `ast27.Str` and `ast3.Str` classes. This field
stores whatever string modifiers (like `b` or `u`) were present on the
original string.

As a note, I've confirmed that this field is indeed a str (and not
bytes) for ast27's Str class.

  [0]: https://github.com/python/typed_ast/pull/49
This commit is contained in:
Michael Lee
2018-12-18 10:37:19 -08:00
committed by GitHub
parent f7c9677703
commit 44e6b6e0d4
2 changed files with 2 additions and 0 deletions

View File

@@ -246,6 +246,7 @@ class Num(expr):
class Str(expr):
s = ... # type: bytes
kind = ... # type: str
class Attribute(expr):
value = ... # type: expr

View File

@@ -264,6 +264,7 @@ class Num(expr):
class Str(expr):
s = ... # type: str
kind = ... # type: str
class FormattedValue(expr):
value = ... # type: expr