예제 #1
0
 def write_bytecode(self, f):
     """Dump the bytecode into the file or file like object passed."""
     if self.code is None:
         raise TypeError('can\'t write empty bucket')
     f.write(bc_magic)
     pickle.dump(self.checksum, f, 2)
     marshal_dump(self.code, f)
예제 #2
0
파일: bccache.py 프로젝트: 3liz/Quantum-GIS
 def write_bytecode(self, f):
     """Dump the bytecode into the file or file like object passed."""
     if self.code is None:
         raise TypeError('can\'t write empty bucket')
     f.write(bc_magic)
     pickle.dump(self.checksum, f, 2)
     marshal_dump(self.code, f)