diff options
author | Jack Jansen <jack.jansen@cwi.nl> | 2001-06-28 22:07:30 (GMT) |
---|---|---|
committer | Jack Jansen <jack.jansen@cwi.nl> | 2001-06-28 22:07:30 (GMT) |
commit | 1319abf745f3e3de7e087d856f957173a765fb86 (patch) | |
tree | 2bb612a060f2f0c507eb69742e62293bccef04ba | |
parent | 08a898f85d69c060241dc7f07f003e6e6c4acd50 (diff) | |
download | cpython-1319abf745f3e3de7e087d856f957173a765fb86.zip cpython-1319abf745f3e3de7e087d856f957173a765fb86.tar.gz cpython-1319abf745f3e3de7e087d856f957173a765fb86.tar.bz2 |
Make basechain a class variable in stead of initializing it in __init__. That way it's more easily overridden.
-rw-r--r-- | Tools/bgen/bgen/bgenObjectDefinition.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Tools/bgen/bgen/bgenObjectDefinition.py b/Tools/bgen/bgen/bgenObjectDefinition.py index b6f33fe..e6db9cd 100644 --- a/Tools/bgen/bgen/bgenObjectDefinition.py +++ b/Tools/bgen/bgen/bgenObjectDefinition.py @@ -3,6 +3,7 @@ from bgenGeneratorGroup import GeneratorGroup class ObjectDefinition(GeneratorGroup): "Spit out code that together defines a new Python object type" + basechain = "NULL" def __init__(self, name, prefix, itselftype): """ObjectDefinition constructor. May be extended, but do not override. @@ -21,7 +22,6 @@ class ObjectDefinition(GeneratorGroup): self.typename = name + '_Type' self.argref = "" # set to "*" if arg to <type>_New should be pointer self.static = "static " # set to "" to make <type>_New and <type>_Convert public - self.basechain = "NULL" # set to &<basetype>_chain to chain methods def add(self, g, dupcheck=0): g.setselftype(self.objecttype, self.itselftype) |