On 03/05/2013 07:40 PM, Murphy McCauley wrote:
> So here's my feedback on this patch.  If you want to continue iterating, 
> please do.  If not, I'll address it. :)

I sent you a pull request on github, instead. I think it addresses all
of feedback, except:

>> +
>> +    p = struct.pack('!HHHH4s4s', self.subtype, self.nbits, self.src_ofs,
>> +            self.dst_ofs, src, dst)
>> +    return p
>> +
>> +  def _unpack_body (self, raw, offset, avail):
>> +    offset,(self.subtype, self.nbits, self.src_ofs, self.dst_ofs, src, dst) 
>> = \
>> +        of._unpack('!HHHH4s4s', raw, offset)
>> +
>> +    _,dst = nxm_entry.unpack_new(dst, 0)
>> +    self.dst = dst.__class__
>> +
>> +    _,src = nxm_entry.unpack_new(src, 0)
>> +    self.src = src.__class__
> 
> I suspect these unpacks are broken; again this is my fault.  Have you tested 
> them?  Attached is an untested patch which I think fixes them for reg load 
> (or at least gets closer).

Nope, I didn't test them at all! I was suspicious too, but this
functionality isn't useful to me, so I just made superficial
modifications to the implementation copied from nx_reg_load.

Reply via email to