7c05ca01e80ee0f73d703c986f99bc72c0270719,spacy/tokens/underscore.py,Underscore,__getattr__,#Underscore#Any#,26
Before Change
elif method is not None:
return functools.partial(method, self._obj)
else:
return self._doc.user_data.get(self._get_key(name), default)
def __setattr__(self, name, value):
if name not in self._extensions:
raise AttributeError(Errors.E047.format(name=name))
After Change
return functools.partial(method, self._obj)
else:
key = self._get_key(name)
if key in self._doc.user_data:
return self._doc.user_data[key]
elif isinstance(default, self.mutable_types):
// Handle mutable default arguments (see /)
new_default = copy.copy(default)
self.__setattr__(name, new_default)
return new_default
return default
def __setattr__(self, name, value):
if name not in self._extensions:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: explosion/spaCy
Commit Name: 7c05ca01e80ee0f73d703c986f99bc72c0270719
Time: 2019-03-11
Author: ines@ines.io
File Name: spacy/tokens/underscore.py
Class Name: Underscore
Method Name: __getattr__
Project Name: GPflow/GPflowOpt
Commit Name: 0301ffaa163f037bf999ea93522ba9d054e0f0c9
Time: 2017-08-13
Author: joachim.vanderherten@ugent.be
File Name: GPflowOpt/models.py
Class Name: ModelWrapper
Method Name: __setattr__
Project Name: pyinstaller/pyinstaller
Commit Name: 7a7eb11a7bed7024831694f973c3f2cf30fd359e
Time: 2020-07-01
Author: 50370070+Legorooj@users.noreply.github.com
File Name: PyInstaller/depend/imphook.py
Class Name: ModuleHook
Method Name: _load_hook_module