package lrgrep
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
Analyse the stack of a Menhir-generated LR parser using regular expressions
Install
dune-project
Dependency
Authors
Maintainers
Sources
lrgrep-0.3.tbz
sha256=84a1874d0c063da371e19c84243aac7c40bfcb9aaf204251e0eb0d1f077f2cde
sha512=5a16ff42a196fd741bc64a1bdd45b4dca0098633e73aa665829a44625ec15382891c3643fa210dbe3704336eab095d4024e093e37ae5313810f6754de6119d55
doc/src/utils/usage.ml.html
Source file usage.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42type mark = { mutable used: bool; } let new_mark () = { used = false } let is_used t = t.used let is_unused t = not (is_used t) let cmon_mark _ = Cmon.constant "<Usage.mark>" type set = | Empty | Leaf of mark | Join of {s1: set; s2: set; mutable used: bool} let empty = Empty let is_empty = function | Empty -> true | _ -> false let singleton mark = Leaf mark let join s1 s2 = if s1 == s2 then s1 else match s1, s2 with | Empty, s | s, Empty -> s | _ -> Join {s1; s2; used=false} let rec mark_used = function | Empty -> () | Leaf m -> m.used <- true | Join j when j.used -> () | Join j -> j.used <- true; mark_used j.s1; mark_used j.s2 let cmon_set _ = Cmon.constant "<Usage.set>"
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>