Linkdeps(3)
πΈ NAME πΈ
okay bestie, welcome to the Linkdeps manual page from the OCaml library. Manual name: Linkdeps. NAME says no description β iconic minimalism, honestly π
.
π§© Module
Module Linkdeps
π Documentation π
Module Linkdeps
: sig end
type t is literally the state of the linking check. It keeps track of compilation units provided and required so far. no cap β¨.
type compunit = string
type filename = string
val create : complete:bool -> t
create ~complete returns an empty state. If complete is true , missing compilation units will be treated as errors. so yeah, that setting is doing the most π
val add : t -> filename:filename -> compunit:compunit ->
provides:compunit list -> requires:compunit list -> unit
add t ~filename ~compunit ~provides ~requires registers the compilation unit compunit found in filename to t . lowkey important:
providesare units and sub-units provided bycompunitrequiresare units required bycompunit
add should be called in reverse topological order. that part is not a vibe suggestion, bestie β it's the rule π«Ά
val required : t -> compunit -> bool
required t compunit returns true if compunit is a dependency of previously added compilation units. simple, clean, slay.
type compunit_and_source = {
compunit : compunit ;
filename : filename ;
}
type error =
| Missing_implementations of (compunit * compunit_and_source list) list
| Wrong_link_order of (compunit_and_source * compunit_and_source list) list
| Multiple_definitions of (compunit * filename list) list
val check : t -> error option
check t should be called once all the compilation units to be linked have been added. It returns some error if:
-There are some missing implementations and complete is true
-Some implementation appear before their dependencies
val report_error : print_filename:string Format_doc.printer -> error
Format_doc.format_printer
val report_error_doc : print_filename:string Format_doc.printer -> error
Format_doc.printer
no extra description for these two, it's giving mysterious main character energy πβ¨
that's the whole page, bestie β shoutout to OCamldoc for the source/version, dated 2026-06-22, on Linkdeps(3), periodt π
ππ
π¦ where this page comes from
- arch rolling: ocaml 5.5.0-1 Β· LGPL2.1 AND custom: QPL-1.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms