@Test
	public void testBadExpr() {
		try {
			DWARFExpression expr =
				evaluator.readExpr(new byte[] { DW_OP_addr, 1, 2, 3, 4, 5, 6, 7, 8, DW_OP_const1u,
					(byte) 0x55, DW_OP_const1u, (byte) 0xfe, DW_OP_addr, 1, 2 /* truncated */ });
			fail(
				"readExpr should have thrown an exception because the expr's final op was truncated: " +
					expr.toString());
		}
		catch (DWARFExpressionException dee) {
			// Should have been able to read 3 of the operations before failing
			Assert.assertEquals(dee.getExpression().getOpCount(), 3);
		}
	}
Test to ensure that endless loops are ended when the thread is interrupted.

@throws IOException
Ghidra/Features/Base/src/test/java/ghidra/app/util/bin/format/dwarf/expression/DWARFExpressionEvaluatorTest.java