You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Crash: "Sorts Int and Bool are incompatible" when a JDK method's result is passed to a parameter refined in an external spec #451
Impact: passing an int returned by an unspecified JDK method to a parameter refined in an external spec crashes the verifier with an internal sort error. The expected outcome is a refinement error, or an accept. This is the everyday way to connect a socket in tests and tools: new Socket(host, server.getLocalPort()).
Minimal reproducer (an external spec and a client, in one directory)
Expected: a refinement error, because server.getLocalPort() can't be proved in range. The same shape in-source gives one: port³ == port¹ is not a subtype of port³ >= 0 && port³ <= 65535.
Real-world scenario. I found this while scoring java.net.Socket specs on JVM-checked probes. Every probe that connects to a local test server (new ServerSocket(0), then new Socket(loopback, server.getLocalPort())) crashes the verifier. That happens both with co-specification's generated spec and with the specs-v2 Socket spec, which refines ports the same way (Port(int x) { x >= 0 && x <= 65535 }).
Activity