mirror of
https://github.com/python/cpython.git
synced 2025-07-29 06:05:00 +00:00
change threading.getIdent to a property
This is new in 2.6 so now need to worry about backwards compatibility :)
This commit is contained in:
parent
e5bdccc77b
commit
d8a8972ca9
4 changed files with 9 additions and 8 deletions
|
@ -663,7 +663,8 @@ class Thread(_Verbose):
|
|||
|
||||
setName = _old_api(set_name, "setName")
|
||||
|
||||
def get_ident(self):
|
||||
@property
|
||||
def ident(self):
|
||||
assert self.__initialized, "Thread.__init__() not called"
|
||||
return self.__ident
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue