package yuujinchou
A domain-specific language for manipulating hierarchical names
Install
Dune Dependency
Authors
Maintainers
Sources
4.0.0.tar.gz
md5=35a5e35ed3b3bc9095810eb2a5a73dbd
sha512=3de4e92a74e2cbfc95cbba2ea32e2880be66d81d0e48ca57865e4650de3c912d57b9e1ec9fa8fcc37680cc8dc1c2fb165947323782e86a83567e53cfd31bb727
doc/yuujinchou/Yuujinchou/Modifier/Make/index.html
Module Modifier.Make
Source
The functor to generate an engine.
Parameters
module Param : sig ... end
Signature
Source
type shadow_handler =
Param.context option ->
Trie.bwd_path ->
(Param.data * Param.tag) ->
(Param.data * Param.tag) ->
Param.data * Param.tag
Source
type hook_handler =
Param.context option ->
Trie.bwd_path ->
Param.hook ->
(Param.data, Param.tag) Trie.t ->
(Param.data, Param.tag) Trie.t
Source
val modify :
?context:Param.context ->
?prefix:Trie.bwd_path ->
Param.hook Language.t ->
(Param.data, Param.tag) Trie.t ->
(Param.data, Param.tag) Trie.t
modify modifier trie
runs the modifier
on the trie
and return the transformed trie.
Source
val run :
?not_found:not_found_handler ->
?shadow:shadow_handler ->
?hook:hook_handler ->
(unit -> 'a) ->
'a
run f
initializes the engine and runs the thunk f
.
Source
val try_with :
?not_found:not_found_handler ->
?shadow:shadow_handler ->
?hook:hook_handler ->
(unit -> 'a) ->
'a
try_with f
runs the thunk f
and intercepts modifier effects. See the documentation of run
for the meaning of the optional effect interceptors; the difference is that the default interceptors reperform the intercepted modifier effects instead of silencing them.
try_with
is intended to be used within run
to intercept or reperform effects, while run
is intended to be at the top-level to set up the environment and handle effects by itself. That is, the following is the expected program structure:
run ~not_found ~shadow ~hook @@ fun () ->
(* code *)
try_with ~not_found @@ fun () ->
(* more code *)
try_with ~shadow @@ fun () ->
(* even more code *)
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page