package js_of_ocaml-compiler

  1. Overview
  2. Docs
Compiler from OCaml bytecode to JavaScript

Install

dune-project
 Dependency

Authors

Maintainers

Sources

js_of_ocaml-6.3.0.tbz
sha256=cbca9aceade642734252e939a6476914604888d0a2552ca6dfc30b6047e612c0
sha512=01bd6ce2d20e5a8541d87602dce6987d3739b42d93a8290ff0c5f6a131034c0f4c569d94ecd8d2f259f3ff804066cbcd55271dd5c7f122aae3f6feb5d8f6ac55

doc/js_of_ocaml-compiler.runtime/Jsoo_runtime/Effect/index.html

Module Jsoo_runtime.EffectSource

Sourceval assume_no_perform : (unit -> 'a) -> 'a

Passing a function f as argument of `assume_no_perform` guarantees that, when compiling with `--effects=double-translation`, the direct-style version of f is called, which is faster than the CPS version. As a consequence, performing an effect in a transitive callee of f will raise `Effect.Unhandled`, regardless of any effect handlers installed before the call to `assume_no_perform`, unless a new effect handler was installed in the meantime.

This behaviour is the same when double translation is disabled.