fact: Fixpoint pos_of_bitseq s : positive := match s with | [::] => xH | true :: t => xI (pos_of_bitseq t) | false :: t => xO (pos_of_bitseq t) end.
imports: mathcomp(ssreflect ssrfun ssrbool eqtype ssrnat seq choice) mathcomp(fintype tuple) BinPos BinNat PArith ssr_ext