示例#1
0
 def __deepcopy__(self, memo):
     newone = type(self)(self.length, self.pointer)
     newone.__dict__.update(self.__dict__)
     if self.pointer != None:
         newone.pointer = _wildcard_copy(self.pointer, self.length)
     return newone
示例#2
0
 def __deepcopy__(self,memo):
   newone = type(self)(self.length,self.pointer)
   newone.__dict__.update(self.__dict__)
   if self.pointer != None:
     newone.pointer = _wildcard_copy(self.pointer,self.length) 
   return newone
示例#3
0
def wildcard_copy(w):
    if w.pointer != None:
        return wildcard(w.length, _wildcard_copy(w.pointer, w.length))
    else:
        return wildcard(w.length, None)
示例#4
0
def wildcard_copy(w):
  if w.pointer != None:
    return wildcard(w.length,_wildcard_copy(w.pointer,w.length))
  else:
    return wildcard(w.length,None)