# \#base

**URL:** https://discuss.ocaml.org/tag/base/69.md

[Latest](https://discuss.ocaml.org/latest.md) · [Categories](https://discuss.ocaml.org/categories.md) · [Tags](https://discuss.ocaml.org/tags.md)

---

## [Jane Street Libraries (base/core/async/etc) with 5.5](https://discuss.ocaml.org/t/jane-street-libraries-base-core-async-etc-with-5-5/18469)

<div class="topic-metadata">

**Author:** [@smuenzel](https://discuss.ocaml.org/u/smuenzel)\
**Replies:** 1\
**Last updated:** [August 25, 2026, 12:06pm UTC](https://discuss.ocaml.org/t/jane-street-libraries-base-core-async-etc-with-5-5/18469 "2026-08-25T12:06:01Z")

</div>

(Note: much of the linked repos are modified with the the help of LLMs, so please do check the diff to the upstream version before installing. Most diffs are very small. Also, this release is not affiliated with Jane Str…

---

## [Odoc and shadowing](https://discuss.ocaml.org/t/odoc-and-shadowing/17052)

<div class="topic-metadata">

**Author:** [@ElijahVlasov](https://discuss.ocaml.org/u/ElijahVlasov)\
**Replies:** 2\
**Last updated:** [August 4, 2025, 1:54pm UTC](https://discuss.ocaml.org/t/odoc-and-shadowing/17052 "2025-08-04T13:54:27Z")

</div>

Hi, I’m struggling with odoc a bit. If I have the following interface: val bla : unit -\> char then it renders as it is with odoc. But if I do: open Base val bla : unit -\> char it gets rendered (annoyingly) as: va…

---

## [Stdlib vs Base in 2025 (beginner)](https://discuss.ocaml.org/t/stdlib-vs-base-in-2025-beginner/16626)

<div class="topic-metadata">

**Author:** [@emiel](https://discuss.ocaml.org/u/emiel)\
**Replies:** 4\
**Last updated:** [May 9, 2025, 8:45am UTC](https://discuss.ocaml.org/t/stdlib-vs-base-in-2025-beginner/16626 "2025-05-09T08:45:46Z")

</div>

Hello. I’ve restarted my OCaml learning journey and am working on some exercises. One source I’m using is Exercism, which defaults to using Base for exercises. I’m reading OCaml From the Very Beginning and OCaml Programm…

---

## [Ocaml IO - Printing Contents of a buffer](https://discuss.ocaml.org/t/ocaml-io-printing-contents-of-a-buffer/15316)

<div class="topic-metadata">

**Author:** [@dibri](https://discuss.ocaml.org/u/dibri)\
**Replies:** 4\
**Last updated:** [September 21, 2024, 9:35am UTC](https://discuss.ocaml.org/t/ocaml-io-printing-contents-of-a-buffer/15316 "2024-09-21T09:35:28Z")

</div>

I am still learning ocaml and have run into an issue printing the contents of a buffer to stdout (or anything to be honest). I have tried using the buffered channels and string conversions but nothing seems to work. Even…

---

## [Why does ppx\_base 0.17 not support windows installation while 0.16 does?](https://discuss.ocaml.org/t/why-does-ppx-base-0-17-not-support-windows-installation-while-0-16-does/14897)

<div class="topic-metadata">

**Author:** [@MaxHaydenChiz](https://discuss.ocaml.org/u/MaxHaydenChiz)\
**Replies:** 4\
**Last updated:** [July 4, 2024, 8:30pm UTC](https://discuss.ocaml.org/t/why-does-ppx-base-0-17-not-support-windows-installation-while-0-16-does/14897 "2024-07-04T20:30:02Z")

</div>

I was toying around with the new opam’s windows support and tried to use to it to install core. Core depends on ppx\_base. But opam kept wanting to install 0.16.x and would then fail at compiling it. (I think it fails bec…

---

## [How to print sexp with non-ASCII characters?](https://discuss.ocaml.org/t/how-to-print-sexp-with-non-ascii-characters/14528)

<div class="topic-metadata">

**Author:** [@mudrz](https://discuss.ocaml.org/u/mudrz)\
**Replies:** 3\
**Last updated:** [April 23, 2024, 2:35pm UTC](https://discuss.ocaml.org/t/how-to-print-sexp-with-non-ascii-characters/14528 "2024-04-23T14:35:29Z")

</div>

I’m using \[@@deriving sexp\_of\] and I’m not sure how to handle the logging of non-ASCII characters. How can you print a s-expression with non-ASCII characters? running this in utop: #require "Base" ;; let e = "é";; let…

---

## [Seeking feedback on repackaged libraries for Base](https://discuss.ocaml.org/t/seeking-feedback-on-repackaged-libraries-for-base/14241)

<div class="topic-metadata">

**Author:** [@mbarbin](https://discuss.ocaml.org/u/mbarbin)\
**Replies:** 2\
**Last updated:** [March 21, 2024, 5:51pm UTC](https://discuss.ocaml.org/t/seeking-feedback-on-repackaged-libraries-for-base/14241 "2024-03-21T17:51:23Z")

</div>

Dear OCaml community, Lately I’ve been working on reducing dependency footprints in some of my projects, which led me to repackage some of Jane Street’s libraries that I frequently use. The goal was to make these librar…

---

## [Utop sends "Alert deprecated: module Base.Format"](https://discuss.ocaml.org/t/utop-sends-alert-deprecated-module-base-format/13365)

<div class="topic-metadata">

**Author:** [@carotte\_sauvage](https://discuss.ocaml.org/u/carotte_sauvage)\
**Replies:** 2\
**Last updated:** [November 3, 2023, 4:04pm UTC](https://discuss.ocaml.org/t/utop-sends-alert-deprecated-module-base-format/13365 "2023-11-03T16:04:06Z")

</div>

Hi, On this page Real World OCaml, I tried to follow the instructions to : Install and set up opam Install librairies and tools Set up my editor (I use Emacs) The step 2) asks me to execute this command : opam inst…

---

## [Too much code when using Map](https://discuss.ocaml.org/t/too-much-code-when-using-map/12503)

<div class="topic-metadata">

**Author:** [@vivanov](https://discuss.ocaml.org/u/vivanov)\
**Replies:** 3\
**Last updated:** [June 29, 2023, 6:42am UTC](https://discuss.ocaml.org/t/too-much-code-when-using-map/12503 "2023-06-29T06:42:02Z")

</div>

Hey, I am using maps and it turns out that it takes a lot of code to write something simple. For example, even though I want to use find function, I need to specify exact module. For example, if I have a module StringMa…

---

## [Error: Unbound value compare\_list](https://discuss.ocaml.org/t/error-unbound-value-compare-list/11454)

<div class="topic-metadata">

**Author:** [@olleharstedt](https://discuss.ocaml.org/u/olleharstedt)\
**Replies:** 1\
**Last updated:** [February 19, 2023, 5:30pm UTC](https://discuss.ocaml.org/t/error-unbound-value-compare-list/11454 "2023-02-19T17:30:22Z")

</div>

I’m trying to get rid of open Base, since it’s an absolute minefield of a lib, but getting some weird error messages for ppx extensions. Does ppx\_compare depend on open Base? I’m getting 8 | includes list \* …

---

## [Reference to undefined global 'Base' error](https://discuss.ocaml.org/t/reference-to-undefined-global-base-error/10526)

<div class="topic-metadata">

**Author:** [@Yash\_Vaibhav](https://discuss.ocaml.org/u/Yash_Vaibhav)\
**Replies:** 5\
**Last updated:** [September 27, 2022, 2:52am UTC](https://discuss.ocaml.org/t/reference-to-undefined-global-base-error/10526 "2022-09-27T02:52:28Z")

</div>

I tried running the following piece of code from Real World OCaml, # require "base" open Base let distance (x1,y1) (x2,y2) = Float.sqrt ((x1 -. x2) \*\*. 2. +. (y1 -. y2) \*\*. 2.);; If I have Base installed then why am …

---

## [Ocaml base compiler failing to build](https://discuss.ocaml.org/t/ocaml-base-compiler-failing-to-build/9676)

<div class="topic-metadata">

**Author:** [@felipe-godoi](https://discuss.ocaml.org/u/felipe-godoi)\
**Replies:** 4\
**Last updated:** [April 16, 2022, 12:18pm UTC](https://discuss.ocaml.org/t/ocaml-base-compiler-failing-to-build/9676 "2022-04-16T12:18:37Z")

</div>

I’m following the Real World Ocaml tutorial but when I try to create an env using opam switch create 4.13.1 it says that “the compilation of ocaml-base-compiler.4.13.1 failed” I searched similar issues but none of them …

---

## [Jane Street packages: dropping support for 32-bit](https://discuss.ocaml.org/t/jane-street-packages-dropping-support-for-32-bit/8621)

<div class="topic-metadata">

**Author:** [@Arseniy\_Alekseyev](https://discuss.ocaml.org/u/Arseniy_Alekseyev)\
**Replies:** 23\
**Last updated:** [November 5, 2021, 8:12pm UTC](https://discuss.ocaml.org/t/jane-street-packages-dropping-support-for-32-bit/8621 "2021-11-05T20:12:53Z")

</div>

In Jane Street we plan to stop maintaining the compatibility of our open source packages with 32-bit architectures. This includes everything published on Jane Street · GitHub. We are not going to deliberately break thi…

---

## [Goodbye Core\_kernel](https://discuss.ocaml.org/t/goodbye-core-kernel/8393)

<div class="topic-metadata">

**Author:** [@jeremiedimino](https://discuss.ocaml.org/u/jeremiedimino)\
**Replies:** 7\
**Last updated:** [August 31, 2021, 4:11pm UTC](https://discuss.ocaml.org/t/goodbye-core-kernel/8393 "2021-08-31T16:11:26Z")

</div>

Hi, just a heads up that the Core\_kernel library from Jane Street will eventually disappear, leaving place to only Base and Core. More details in this blog post on our website: This change is good but is not backward …

---

## [Advantage of Int63 compared to Int64?](https://discuss.ocaml.org/t/advantage-of-int63-compared-to-int64/7465)

<div class="topic-metadata">

**Author:** [@mudrz](https://discuss.ocaml.org/u/mudrz)\
**Replies:** 13\
**Last updated:** [March 16, 2021, 4:51pm UTC](https://discuss.ocaml.org/t/advantage-of-int63-compared-to-int64/7465 "2021-03-16T16:51:20Z")

</div>

this is probably a stupid question, but - why does Base have Int63? the docs have a description: https://ocaml.janestreet.com/ocaml-core/latest/doc/base/Base/Int63/index.html The size of Int63 is always 63 bits. On a…

---

## [How to compile Let\_syntax of Base?](https://discuss.ocaml.org/t/how-to-compile-let-syntax-of-base/1890)

<div class="topic-metadata">

**Author:** [@Taki](https://discuss.ocaml.org/u/Taki)\
**Replies:** 7\
**Last updated:** [October 12, 2020, 3:47pm UTC](https://discuss.ocaml.org/t/how-to-compile-let-syntax-of-base/1890 "2020-10-12T15:47:12Z")

</div>

I’m reading RWO v2 and try to write my own demo as: open Base open Stdio let f1 n = if n \< 10 then None else Some n let f2 n = if n \> 15 then None else Some n let combines n = let open Option.Let\_syntax in le…

---

## [Using ocamlformat in a base-0.14 switch](https://discuss.ocaml.org/t/using-ocamlformat-in-a-base-0-14-switch/5963)

<div class="topic-metadata">

**Author:** [@MattWindsor91](https://discuss.ocaml.org/u/MattWindsor91)\
**Replies:** 2\
**Last updated:** [June 12, 2020, 8:33pm UTC](https://discuss.ocaml.org/t/using-ocamlformat-in-a-base-0-14-switch/5963 "2020-06-12T20:33:43Z")

</div>

(This is probably a specific instance of a more general question) As we know, the 0.14 release of Jane Street’s base ecosystem recently landed, and I’d like to try it out to see if it’s easy enough to upgrade my OCaml p…

---

## [When did Core remove polymorphic comparison operators in recent OCaml?](https://discuss.ocaml.org/t/when-did-core-remove-polymorphic-comparison-operators-in-recent-ocaml/5633)

<div class="topic-metadata">

**Author:** [@trungta](https://discuss.ocaml.org/u/trungta)\
**Replies:** 6\
**Last updated:** [April 27, 2020, 5:49pm UTC](https://discuss.ocaml.org/t/when-did-core-remove-polymorphic-comparison-operators-in-recent-ocaml/5633 "2020-04-27T17:49:36Z")

</div>

Hi, I’m using the Core library in a project, and recently when I upgraded my OCaml from 4.08.1 to 4.10.0, plenty of compilation errors suddenly appear for comparison expressions like: if (xs = \[\]) then ... or if (x …

---

## [Functorial vs "comparator" container interfaces?](https://discuss.ocaml.org/t/functorial-vs-comparator-container-interfaces/5384)

<div class="topic-metadata">

**Author:** [@jjb](https://discuss.ocaml.org/u/jjb)\
**Replies:** 12\
**Last updated:** [April 16, 2020, 11:05am UTC](https://discuss.ocaml.org/t/functorial-vs-comparator-container-interfaces/5384 "2020-04-16T11:05:36Z")

</div>

I wonder if there has been any performance evaluation, of e.g. Set and Map, that compares the functorial (Stdlib Make functor style) versus “comparator” (Base-style) interfaces? To be concrete, suppose we define a Make f…

---

## [Making a StringSet with Base](https://discuss.ocaml.org/t/making-a-stringset-with-base/5469)

<div class="topic-metadata">

**Author:** [@martindemello](https://discuss.ocaml.org/u/martindemello)\
**Replies:** 7\
**Last updated:** [April 11, 2020, 4:25am UTC](https://discuss.ocaml.org/t/making-a-stringset-with-base/5469 "2020-04-11T04:25:08Z")

</div>

I have the following code to create a StringSet module in base: open Base type t = Set.M(String).t let empty = Set.empty (module String) let of\_list = Set.of\_list (module String) let diff = Set.diff let inter = Set.in…

---

## [Why is the Command module part of Core/Core\_Kernel and not Base](https://discuss.ocaml.org/t/why-is-the-command-module-part-of-core-core-kernel-and-not-base/5111)

<div class="topic-metadata">

**Author:** [@gainhad](https://discuss.ocaml.org/u/gainhad)\
**Replies:** 2\
**Last updated:** [February 3, 2020, 1:22am UTC](https://discuss.ocaml.org/t/why-is-the-command-module-part-of-core-core-kernel-and-not-base/5111 "2020-02-03T01:22:59Z")

</div>

Out of curiosity, does anyone know why the Command module is part of Core\_Kernel and not Base? It seems like something really nice to have in Base, and is often the only reason I have to pull in Core or Core\_Kernel inste…

---

## [Upcoming breaking change in Base/Core v0.14](https://discuss.ocaml.org/t/upcoming-breaking-change-in-base-core-v0-14/4806)

<div class="topic-metadata">

**Author:** [@bcc32](https://discuss.ocaml.org/u/bcc32)\
**Replies:** 2\
**Last updated:** [December 3, 2019, 2:04pm UTC](https://discuss.ocaml.org/t/upcoming-breaking-change-in-base-core-v0-14/4806 "2019-12-03T14:04:36Z")

</div>

We’re changing functions in Base that used to use the polymorphic variant type \[ \`Fst of 'a | \`Snd of 'b \] to use ('a, 'b) Either.t instead. As well as enabling the use of all of the functions in the Either module, t…

---

## [Newbie: how to sort a list using Base?](https://discuss.ocaml.org/t/newbie-how-to-sort-a-list-using-base/4586)

<div class="topic-metadata">

**Author:** [@dimitarvp](https://discuss.ocaml.org/u/dimitarvp)\
**Replies:** 3\
**Last updated:** [October 28, 2019, 9:47am UTC](https://discuss.ocaml.org/t/newbie-how-to-sort-a-list-using-base/4586 "2019-10-28T09:47:15Z")

</div>

Without using base, I was able to just do this: List.sort compare my\_list But after putting open Base on top of my file, the compiler is slapping me on the wrist. I found this answer (here in this forum) but I’d like t…

---

## [Beginner question on code style in Base](https://discuss.ocaml.org/t/beginner-question-on-code-style-in-base/4237)

<div class="topic-metadata">

**Author:** [@cmxa](https://discuss.ocaml.org/u/cmxa)\
**Replies:** 2\
**Last updated:** [August 12, 2019, 6:29am UTC](https://discuss.ocaml.org/t/beginner-question-on-code-style-in-base/4237 "2019-08-12T06:29:35Z")

</div>

I am reading the code in Base. https://github.com/janestreet/base/blob/master/src/array.ml has module Insertion\_sort : Sort = struct let sort arr ~compare ~left ~right = (\* loop invariant: \[arr\] is …

---

## [Containers interface & Passing constraints through functors](https://discuss.ocaml.org/t/containers-interface-passing-constraints-through-functors/4011)

<div class="topic-metadata">

**Author:** [@s.t.s](https://discuss.ocaml.org/u/s.t.s)\
**Replies:** 9\
**Last updated:** [July 3, 2019, 2:54pm UTC](https://discuss.ocaml.org/t/containers-interface-passing-constraints-through-functors/4011 "2019-07-03T14:54:04Z")

</div>

I am working on an exercise, whence I am trying to define some basic algorithms on arrays. Since arrays naturally includes string interfaces, I would like to also make sure that the infrastructure includes the possibili…

---

## [Should I prefer Core\_kernel or Base's APIs where they differ?](https://discuss.ocaml.org/t/should-i-prefer-core-kernel-or-bases-apis-where-they-differ/3804)

<div class="topic-metadata">

**Author:** [@MattWindsor91](https://discuss.ocaml.org/u/MattWindsor91)\
**Replies:** 2\
**Last updated:** [May 15, 2019, 6:13pm UTC](https://discuss.ocaml.org/t/should-i-prefer-core-kernel-or-bases-apis-where-they-differ/3804 "2019-05-15T18:13:00Z")

</div>

Though usually Core\_kernel is a superset of Base (and its related libraries)'s functionality, I’ve noticed there are some places where the exposed API surface is a little different: for instance, Base\_quickcheck (which e…

---

## [Configuring a project directory and setting up the related toolchain (opam, dune, etc.)](https://discuss.ocaml.org/t/configuring-a-project-directory-and-setting-up-the-related-toolchain-opam-dune-etc/2635)

<div class="topic-metadata">

**Author:** [@RogerT](https://discuss.ocaml.org/u/RogerT)\
**Replies:** 13\
**Last updated:** [October 1, 2018, 2:33pm UTC](https://discuss.ocaml.org/t/configuring-a-project-directory-and-setting-up-the-related-toolchain-opam-dune-etc/2635 "2018-10-01T14:33:28Z")

</div>

My focus is on using Ocaml tools for coding programs. I’m far away from my first “Hello World!” in OCaml. And I think I’m also quite far away from being able to create an OCaml program for Real World. Learning OCaml la…

---

## [How to initialize a Base.Hashtbl on an abstract type?](https://discuss.ocaml.org/t/how-to-initialize-a-base-hashtbl-on-an-abstract-type/2056)

<div class="topic-metadata">

**Author:** [@loxs](https://discuss.ocaml.org/u/loxs)\
**Replies:** 7\
**Last updated:** [May 29, 2018, 1:14pm UTC](https://discuss.ocaml.org/t/how-to-initialize-a-base-hashtbl-on-an-abstract-type/2056 "2018-05-29T13:14:29Z")

</div>

Could someone show me how to initialize a Base.Hashtbl and how to satisfy it with a key that is an abstracted list of ints? I tried lots of things but still fail to make it work and I don’t kow where to read (yes, did re…

---

## [No \`t\_of\_sexp\` generated by \` \[@@deriving sexp\]\`](https://discuss.ocaml.org/t/no-t-of-sexp-generated-by-deriving-sexp/1999)

<div class="topic-metadata">

**Author:** [@Taki](https://discuss.ocaml.org/u/Taki)\
**Replies:** 8\
**Last updated:** [May 16, 2018, 12:20pm UTC](https://discuss.ocaml.org/t/no-t-of-sexp-generated-by-deriving-sexp/1999 "2018-05-16T12:20:54Z")

</div>

According to RWO: type t = { foo: int; bar: float } \[@@deriving sexp\] ;; type t = { foo : int; bar : float; } val t\_of\_sexp : Ppx\_sexp\_conv\_lib.Sexp.t -\> t = \<fun\> val sexp\_of\_t : t -\> Ppx\_sexp\_conv\_lib.Sexp.t = \<fun\> t…

---

## [OCaml Tutorial in Sydney, Australia](https://discuss.ocaml.org/t/ocaml-tutorial-in-sydney-australia/1967)

<div class="topic-metadata">

**Author:** [@Yaron\_Minsky](https://discuss.ocaml.org/u/Yaron_Minsky)\
**Replies:** 0\
**Last updated:** [May 8, 2018, 10:42am UTC](https://discuss.ocaml.org/t/ocaml-tutorial-in-sydney-australia/1967 "2018-05-08T10:42:53Z")

</div>

Hey, I’m going to be running an OCaml Tutorial in Sydney as part of Yow LambdaJam, on May 21st. If you’re interested in learning OCaml and a lot of the supporting tools (including Merlin, Dune, expect tests, Async, Js\_of…

[Next page](https://discuss.ocaml.org/tag/base/69.md?match_all_tags=true&page=1&tags%5B%5D=base)
