this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

odoc-interactive-extension: consolidate dual-compiler builds, per-package findlib, cross-jsoo compat

- Consolidate js_top_worker and odoc dual-compiler stanzas into single
library stanzas with cppo rules generating impl.ml from impl.cppo.ml
- Per-package findlib_index.json with relative universe paths (../dep)
and implicit stdlib dependency injection
- Add find_stdlib_dcs to Impl.S interface for stdlib CMI lookup via
findlib metadata instead of hardcoded URLs
- Replace jsoo Json.output/Json.unsafe_input with plain JSON.stringify/
JSON.parse for cross-jsoo-version compatibility (6.0.1+ox vs 6.2.0)
- Cross-origin worker support: set __global_rel_url in blob worker,
skip URL rewriting for absolute http(s) URLs
- Fix odoc doc comments and ocamlformat-ignore for cppo files
- Add demo docs, helper scripts, and x-ocaml package-lock.json

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

+129 -34
+3 -3
dune-project
··· 35 35 (package 36 36 (name odoc) 37 37 (sites (lib extensions)) 38 - (documentation (depends odoc-driver odoc-parser odoc-md sherlodoc cmdliner))) 38 + ) 39 39 40 - (package (name odoc-parser) (documentation (depends odoc))) 40 + (package (name odoc-parser)) 41 41 (package (name odoc-md)) 42 - (package (name odoc-driver) (documentation (depends sherlodoc odoc))) 42 + (package (name odoc-driver)) 43 43 (package (name odoc-bench) (allow_empty)) 44 44 (package (name sherlodoc)) 45 45
+4
src/.ocamlformat-ignore
··· 1 1 document/*.cppo.ml 2 2 loader/*.cppo.ml 3 + loader/*.cppo.mli 3 4 loader/cmi.ml 4 5 loader/cmi.mli 5 6 loader/cmt.ml 6 7 loader/cmti.ml 7 8 loader/doc_attr.ml 9 + loader/ident_env.ml 8 10 loader/implementation.ml 11 + loader/odoc_loader.ml 9 12 loader/typedtree_traverse.ml 10 13 loader/lookup_def.ml 11 14 loader/lookup_def.mli 15 + syntax_highlighter/*.cppo.ml 12 16 syntax_highlighter/syntax_highlighter.ml 13 17 model/*.cppo.ml 14 18 odoc/*.cppo.ml
src/loader/cmi.ml src/loader/cmi.cppo.ml
src/loader/cmi.mli src/loader/cmi.cppo.mli
src/loader/cmt.ml src/loader/cmt.cppo.ml
src/loader/cmti.ml src/loader/cmti.cppo.ml
src/loader/doc_attr.ml src/loader/doc_attr.cppo.ml
+107 -19
src/loader/dune
··· 1 - (library 2 - (name odoc_loader) 3 - (public_name odoc.loader) 4 - (enabled_if 5 - (not %{ocaml-config:ox})) 6 - (preprocess 7 - (action 8 - (run %{bin:cppo} -V OCAML:%{ocaml_version} %{input-file}))) 9 - (libraries 10 - odoc_model 11 - odoc-parser 12 - syntax_highlighter 13 - odoc_document 14 - odoc_utils 15 - compiler-libs.optcomp)) 1 + (rule 2 + (targets cmi.ml) 3 + (deps (:x cmi.cppo.ml)) 4 + (enabled_if (not %{ocaml-config:ox})) 5 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 6 + 7 + (rule 8 + (targets cmi.ml) 9 + (deps (:x cmi.cppo.ml)) 10 + (enabled_if %{ocaml-config:ox}) 11 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 12 + 13 + (rule 14 + (targets cmi.mli) 15 + (deps (:x cmi.cppo.mli)) 16 + (enabled_if (not %{ocaml-config:ox})) 17 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 18 + 19 + (rule 20 + (targets cmi.mli) 21 + (deps (:x cmi.cppo.mli)) 22 + (enabled_if %{ocaml-config:ox}) 23 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 24 + 25 + (rule 26 + (targets cmti.ml) 27 + (deps (:x cmti.cppo.ml)) 28 + (enabled_if (not %{ocaml-config:ox})) 29 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 30 + 31 + (rule 32 + (targets cmti.ml) 33 + (deps (:x cmti.cppo.ml)) 34 + (enabled_if %{ocaml-config:ox}) 35 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 36 + 37 + (rule 38 + (targets cmt.ml) 39 + (deps (:x cmt.cppo.ml)) 40 + (enabled_if (not %{ocaml-config:ox})) 41 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 42 + 43 + (rule 44 + (targets cmt.ml) 45 + (deps (:x cmt.cppo.ml)) 46 + (enabled_if %{ocaml-config:ox}) 47 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 48 + 49 + (rule 50 + (targets doc_attr.ml) 51 + (deps (:x doc_attr.cppo.ml)) 52 + (enabled_if (not %{ocaml-config:ox})) 53 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 54 + 55 + (rule 56 + (targets doc_attr.ml) 57 + (deps (:x doc_attr.cppo.ml)) 58 + (enabled_if %{ocaml-config:ox}) 59 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 60 + 61 + (rule 62 + (targets ident_env.ml) 63 + (deps (:x ident_env.cppo.ml)) 64 + (enabled_if (not %{ocaml-config:ox})) 65 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 66 + 67 + (rule 68 + (targets ident_env.ml) 69 + (deps (:x ident_env.cppo.ml)) 70 + (enabled_if %{ocaml-config:ox}) 71 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 72 + 73 + (rule 74 + (targets implementation.ml) 75 + (deps (:x implementation.cppo.ml)) 76 + (enabled_if (not %{ocaml-config:ox})) 77 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 78 + 79 + (rule 80 + (targets implementation.ml) 81 + (deps (:x implementation.cppo.ml)) 82 + (enabled_if %{ocaml-config:ox}) 83 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 84 + 85 + (rule 86 + (targets odoc_loader.ml) 87 + (deps (:x odoc_loader.cppo.ml)) 88 + (enabled_if (not %{ocaml-config:ox})) 89 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 90 + 91 + (rule 92 + (targets odoc_loader.ml) 93 + (deps (:x odoc_loader.cppo.ml)) 94 + (enabled_if %{ocaml-config:ox}) 95 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 96 + 97 + (rule 98 + (targets typedtree_traverse.ml) 99 + (deps (:x typedtree_traverse.cppo.ml)) 100 + (enabled_if (not %{ocaml-config:ox})) 101 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 102 + 103 + (rule 104 + (targets typedtree_traverse.ml) 105 + (deps (:x typedtree_traverse.cppo.ml)) 106 + (enabled_if %{ocaml-config:ox}) 107 + (action (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 16 108 17 109 (library 18 110 (name odoc_loader) 19 111 (public_name odoc.loader) 20 - (enabled_if %{ocaml-config:ox}) 21 - (preprocess 22 - (action 23 - (run %{bin:cppo} -V OCAML:%{ocaml_version} -D "OXCAML" %{input-file}))) 24 112 (libraries 25 113 odoc_model 26 114 odoc-parser
src/loader/ident_env.ml src/loader/ident_env.cppo.ml
src/loader/implementation.ml src/loader/implementation.cppo.ml
src/loader/odoc_loader.ml src/loader/odoc_loader.cppo.ml
src/loader/typedtree_traverse.ml src/loader/typedtree_traverse.cppo.ml
+1 -1
src/parser/lexer.mll
··· 549 549 { warning input Parse_error.truncated_see; 550 550 emit input (`Word "@see") } 551 551 552 - | '@' (['a'-'z' 'A'-'Z'] ['a'-'z' 'A'-'Z' '0'-'9' '_' '.']* as tag) 552 + | '@' (['a'-'z' 'A'-'Z'] ['a'-'z' 'A'-'Z' '0'-'9' '_' '.' '-']* as tag) 553 553 { emit input (`Tag (`Custom tag)) } 554 554 555 555 | '@'
+14 -11
src/syntax_highlighter/dune
··· 1 - (library 2 - (name syntax_highlighter) 3 - (public_name odoc.syntax_highlighter) 1 + (rule 2 + (targets syntax_highlighter.ml) 3 + (deps 4 + (:x syntax_highlighter.cppo.ml)) 4 5 (enabled_if 5 6 (not %{ocaml-config:ox})) 6 - (preprocess 7 - (action 8 - (run %{bin:cppo} -V OCAML:%{ocaml_version} %{input-file}))) 9 - (libraries compiler-libs.common)) 7 + (action 8 + (run %{bin:cppo} -V OCAML:%{ocaml_version} %{x} -o %{targets}))) 9 + 10 + (rule 11 + (targets syntax_highlighter.ml) 12 + (deps 13 + (:x syntax_highlighter.cppo.ml)) 14 + (enabled_if %{ocaml-config:ox}) 15 + (action 16 + (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{x} -o %{targets}))) 10 17 11 18 (library 12 19 (name syntax_highlighter) 13 20 (public_name odoc.syntax_highlighter) 14 - (enabled_if %{ocaml-config:ox}) 15 - (preprocess 16 - (action 17 - (run %{bin:cppo} -V OCAML:%{ocaml_version} -D OXCAML %{input-file}))) 18 21 (libraries compiler-libs.common))
src/syntax_highlighter/syntax_highlighter.ml src/syntax_highlighter/syntax_highlighter.cppo.ml