From c36e38e0a26f9bdef2892621b99390dedd35686d Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Fri, 6 Nov 2026 22:49:11 -0300 Subject: kinds #48, the export rule finished: every Zig kind declares `pub const pardes_addon = addon.ops(T)` and calls `addon.exportLib(&pardes_addon)` in a comptime block, which exports it only when the output is a library (Zig 0.17 analyses no `pub const` of a library's root and no comptime block of a type made in a generic function, so the export cannot live in `ops` alone: one comptime line in the kind is the spelling that works), and a pardes with kinds compiled in reads the declarations; image.zig's `pub export`, snake's and life's `export` go, no rename anywhere, and fake.c stays the loader's test, never compiled in Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- addons/pdf/pdf.zig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'addons/pdf') diff --git a/addons/pdf/pdf.zig b/addons/pdf/pdf.zig index 4704e7c7..45f1e22a 100644 --- a/addons/pdf/pdf.zig +++ b/addons/pdf/pdf.zig @@ -29,9 +29,8 @@ const m = @import("pdf_bridge"); const c = addon.c; pub const pardes_addon = addon.ops(Pdf); -// A library's one export; a static pardes reads the declaration (Addon.zig). comptime { - if (@import("builtin").output_mode == .Lib) @export(&pardes_addon, .{ .name = "pardes_addon" }); + addon.exportLib(&pardes_addon); } const gap_px = 8; // between two pages of the strip -- cgit v1.3