Skip to content

Commit 4355759

Browse files
committed
regen per r6844
1 parent 6aab706 commit 4355759

File tree

121 files changed

+121
-4477
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

121 files changed

+121
-4477
lines changed

src/org/python/antlr/ast/AssertDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/AssignDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/AttributeDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/AugAssignDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/BinOpDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/BoolOpDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/BreakDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

src/org/python/antlr/ast/CallDerived.java

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -981,43 +981,7 @@ public PyObject __call__(PyObject args[],String keywords[]) {
981981
}
982982

983983
public PyObject __findattr_ex__(String name) {
984-
PyType self_type=getType();
985-
// TODO: We should speed this up. As the __getattribute__ slot almost never
986-
// changes, it is a good candidate for caching, as PyClass does with
987-
// __getattr__. See #1102.
988-
PyObject getattribute=self_type.lookup("__getattribute__");
989-
PyString py_name=null;
990-
PyException firstAttributeError=null;
991-
try {
992-
if (getattribute!=null) {
993-
py_name=PyString.fromInterned(name);
994-
return getattribute.__get__(this,self_type).__call__(py_name);
995-
} else {
996-
Py.Warning(String.format("__getattribute__ not found on type %s",self_type.getName()));
997-
PyObject ret=super.__findattr_ex__(name);
998-
if (ret!=null) {
999-
return ret;
1000-
} // else: pass through to __getitem__ invocation
1001-
}
1002-
} catch (PyException e) {
1003-
if (!e.match(Py.AttributeError)) {
1004-
throw e;
1005-
} else {
1006-
firstAttributeError=e; // saved to avoid swallowing custom AttributeErrors
1007-
// and pass through to __getattr__ invocation.
1008-
}
1009-
}
1010-
PyObject getattr=self_type.lookup("__getattr__");
1011-
if (getattr!=null) {
1012-
if (py_name==null) {
1013-
py_name=PyString.fromInterned(name);
1014-
}
1015-
return getattr.__get__(this,self_type).__call__(py_name);
1016-
}
1017-
if (firstAttributeError!=null) {
1018-
throw firstAttributeError;
1019-
}
1020-
return null;
984+
return Deriveds.__findattr_ex__(this,name);
1021985
}
1022986

1023987
public void __setattr__(String name,PyObject value) {

0 commit comments

Comments
 (0)