| Index: src/trusted/validator_arm/dgen_test_output.py
|
| ===================================================================
|
| --- src/trusted/validator_arm/dgen_test_output.py (revision 9758)
|
| +++ src/trusted/validator_arm/dgen_test_output.py (working copy)
|
| @@ -183,13 +183,6 @@
|
| BASE_BASE_TESTER='%(decoder_base)sTester%(qualifier)s'
|
| DECODER_TESTER='%(baseline)sTester_%(test_case)s'
|
|
|
| -def _negated_constraint(constraint):
|
| - """Returns the negated pattern for the pattern text passed in."""
|
| - if constraint[0] == '~':
|
| - return constraint[1:]
|
| - else:
|
| - return '~' + constraint
|
| -
|
| def _safety_to_check(safety):
|
| return [s for s in safety if not isinstance(s, str)]
|
|
|
| @@ -921,10 +914,7 @@
|
| out.write(PATTERN_CONSTRAINT_RESTRICTIONS_HEADER)
|
| for c in action.constraints().restrictions:
|
| out.write(CONSTRAINT_CHECK %
|
| - dgen_core.BitPattern.parse(
|
| - _negated_constraint(c),
|
| - dgen_core.BitField('constraint', 31, 0))
|
| - .to_commented_bool())
|
| + c.negate().to_commented_bool())
|
| out.write(CONSTRAINT_TESTER_CLASS_FOOTER % values)
|
| if safety_to_check:
|
| out.write(SAFETY_TESTER_HEADER % values)
|
|
|