Repository navigation
Stop scoring rejected mutants as semantically identical - #44
Merged
seanwevans merged 1 commit intoSep 3, 2026
Merged
Conversation
continuous_semantics_profile caught the ValueError raised by structural_decompress and recorded a distance of zero, so a mutation the front end refuses to compile was indistinguishable from a mutation that changed nothing. The measurement had holes exactly where the interesting boundary cases live. A rejected mutant now scores the rejection distance: every instruction of the base program counted as deleted, floored at 1 so an empty base program cannot collapse the score back to zero. Every profile entry also carries an explicit `compiles` flag, so callers can separate "identical" from "uncompilable" instead of inferring it from the presence of `error`. The preceding commit removed the fence-imbalance ValueErrors, so the remaining rejection path is the grade-fence violation, which the added tests exercise directly. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01K7BqQpyspK2owRy6g6SFxw
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
continuous_semantics_profilecaught theValueErrorfromstructural_decompressand recorded a distance of zero. A mutation the front end refuses to compile was therefore indistinguishable from a mutation that changed nothing — the measurement had holes exactly where the interesting boundary cases live.Before, on
"{ad}":Change
compilesflag, so callers can separate "identical" from "uncompilable" instead of inferring it from the presence oferror.After, on
"(ad)"mutated toward a grade violation:#43 removes the fence-imbalance rejections, so the remaining rejection path is the grade-fence violation, which the new tests exercise directly.
Tests
Four added: rejected mutants are never distance zero, every entry carries
compiles, the floor holds for an empty base program, and brace-unbalancing mutations now produce real distances.The CLI reads only the
distancekeys, so its output is unaffected apart from the corrected numbers.🤖 Generated with Claude Code
https://claude.ai/code/session_01K7BqQpyspK2owRy6g6SFxw
Generated by Claude Code