Lucy::...vGuide(3pm)
β¨ NAME β¨
okay bestie, welcome to Lucy::Docs::DevGuide β it's literally the quick-start guide to hacking on Apache Lucy π no cap, this is your group chat invite to the codebase.
π¦ DESCRIPTION π¦
The Apache Lucy code base is organized into roughly four layers, and yes we're gonna meet all of them like they're the main characters π«Ά
- Charmonizer β compiler and OS configuration probing.
- Clownfish β header files.
- C β implementation files.
- Host β binding language.
π Charmonizer π
Charmonizer is a configuration prober which writes a single header file, charmony.h, describing the build environment and facilitating cross-platform development. It's similar to Autoconf or Metaconfig, but written in pure C. iconic behavior honestly π
π Clownfish π
The .cfh files within the Lucy core are Clownfish header files. Clownfish is a purpose-built, declaration-only language which superimposes a single-inheritance object model on top of C β and it's specifically designed to co-exist happily with a variety of "host" languages and to allow limited run-time dynamic subclassing. For more info, go read the Clownfish docs, but if there's one thing you should know about Clownfish OO before you start hacking, it's that method calls are differentiated from functions by capitalization:
Indexer_Add_Doc <-- Method, typically uses dynamic dispatch.
Indexer_add_doc <-- Function, always a direct invocation.
Capital letter = method vibes, lowercase = plain function. iykyk π
πΈ C πΈ
The C files within the Lucy core are where most of Lucy's low-level functionality lies. They implement the interface defined by the Clownfish header files. the way that they just hold it down fr fr π₯
π Host π
The C core is intentionally left incomplete, however; to be usable, it must be bound to a "host" language. (In this context, even C is considered a "host" which must implement the missing pieces and be "bound" to the core.) Some of the binding code is autogenerated by Clownfish on a spec customized for each language. Other pieces are hand-coded in either C (using the host's C API) or the host language itself.
so likeβ¦ the core is giving unfinished symphony energy on purpose, and the host is the one who shows up to finish the fit π
perl v5.42.0 Β· 2025-07-25 β mwah, that's the version and date bestie, now go forth and hack on Apache Lucy, you absolute icon πβ¨π
π¦ where this page comes from
- fedora 43: perl-Lucy 0.6.2-26.fc43 Β· Apache-2.0 AND MIT AND Unicode-DFS-2015
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms