Open johnyf opened 6 years ago
The issue appears to arise due to the assertion Len(x) \in Nat
about the Len
operator of the module Sequences
being builtin to TLAPS. Renaming the module Sequences
to Sequences_copy
makes TLAPS not prove AllLenInNat
(as expected), and also not prove:
---- MODULE LenInNat_copy ----
EXTENDS
Integers,
Sequences_copy,
TLAPS
THEOREM AllLenInNat ==
ASSUME NEW x
PROVE Len(x) \in Nat
BY DEF Len, Seq
=========================
TLAPS v1.4.3 proves that any set
x
hasLen(x) \in Nat
. This is expected to be unprovable, and likely invalid, becauseLen
is defined usingCHOOSE
(in the moduleSequences
). Pages below refer to the TLA+ book.The SMT encoding of the theorem
AllLenInNat
is (tlapm --debug tempfiles -v -C --cleanfp LenInNat.tla
):