Skip to content

Instantly share code, notes, and snippets.

View joehendrix's full-sized avatar

Joe Hendrix joehendrix

View GitHub Profile
class Friend {
constructor() {
console.log('Hello friend')
}
}
function f() {
new Object()
}
@joehendrix
joehendrix / DFA.hs
Created November 4, 2020 16:57
DFA-based cover
{-# LANGUAGE OverloadedStrings #-}
import Control.Monad
import Data.Foldable
import Data.IntMap (IntMap)
import qualified Data.IntMap as IMap
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Maybe
import Data.Set (Set)
import qualified Data.Set as Set
{-# LANGUAGE OverloadedStrings #-}
import Control.Monad
import Data.Foldable
import Data.IntMap (IntMap)
import qualified Data.IntMap as IMap
import Data.Map (Map)
import qualified Data.Map as Map
import Data.Maybe
import Data.Set (Set)
import qualified Data.Set as Set
namespace nat.tactic
open nat
open tactic
meta def match_le (e : expr) : tactic (expr × expr) :=
match expr.is_le e with
| (some r) := return r
| none := tactic.fail "expression is not a leq"
end