Closed nilehmann closed 2 months ago
We should have a string sort encoded as a string in z3/fixpoint and refine str by it. The following is a minimal test case we should support
str
#[flux::spec( fn require_eq(x: &str[@a], &{str[@b] | a == b}))] fn require_eq(x: &str, y: &str) {} fn test_good() { require_eq("a", "a"); } fn test_bad() { require_eq("a", "b"); }
Right now both test_good and test_bad are accepted by Flux, because strings are refined by unit.
test_good
test_bad
We should have a string sort encoded as a string in z3/fixpoint and refine
str
by it. The following is a minimal test case we should supportRight now both
test_good
andtest_bad
are accepted by Flux, because strings are refined by unit.