Fix a flake8 lint.

Also don't infer writes_cpu_flags if it is specified explicitly.
This commit is contained in:
Jakob Stoklund Olesen
2017-10-19 16:16:27 -07:00
parent 7c9b9e3d27
commit ea68a69f8b

View File

@@ -147,7 +147,9 @@ class Instruction(object):
setattr(self, attr, not not kwargs.get(attr, False)) setattr(self, attr, not not kwargs.get(attr, False))
# Infer the 'writes_cpu_flags' field value. # Infer the 'writes_cpu_flags' field value.
setattr(self, 'writes_cpu_flags', any(out.is_cpu_flags() for out in self.outs)) if 'writes_cpu_flags' not in kwargs:
self.writes_cpu_flags = any(
out.is_cpu_flags() for out in self.outs)
InstructionGroup.append(self) InstructionGroup.append(self)