sous_masque.miaou
← Le code · src/outil/miaou/sous_masque.miaou · 26 lignes
(node sous_masque
(params (a Nat) (b Nat))
(returns Bool)
(intent "chaque effet de a est-il dans b ?")
(origin "phase 8f6 : le vérificateur en miaou, d'après m_controler de l'outil inter (un masque d'effets : bit 0 entree.lire, 1 sortie.ecrire, 2 arguments.lire, 3 fichier.lire, 4 fichier.ecrire, 5 fichier.installer, 6 programme.lancer, 7 temps.attendre)")
(effects)
(uses a_effet)
(requires
true)
(ensures
true)
(examples
(ex (5 7) true)
(ex (5 3) false)
(ex (0 0) true)
(ex (128 127) false)
(ex (256 255) false)
(ex (256 384) true))
(equivalence exact)
(body.high
(and (and (and (or (not (a_effet a 0)) (a_effet b 0)) (or (not (a_effet a 1)) (a_effet b 1))) (and (or (not (a_effet a 2)) (a_effet b 2)) (or (not (a_effet a 3)) (a_effet b 3))))
(and (or (not (a_effet a 4)) (a_effet b 4))
(and (or (not (a_effet a 5)) (a_effet b 5))
(and (or (not (a_effet a 6)) (a_effet b 6))
(and (or (not (a_effet a 7)) (a_effet b 7)) (or (not (a_effet a 8)) (a_effet b 8))))))))
(end node sous_masque))