Scan out-param / nullable Doxygen from the source, not the parsed headers#54
Merged
estebanzimanyi merged 1 commit intoJul 15, 2026
Conversation
The `may be NULL` and `@param[out]` Doxygen tags are a property of the MEOS C source (meos/src/**/*.c), but merge_nullable / merge_outparams scanned HEADERS_DIR.parent. On the provision-meos build-libmeos path HEADERS_DIR is the INSTALLED headers (the generated meos_export.h, with no sibling src/), so the scan finds 0 out-params — the codegens then cannot fold single out-param wrappers (ttext_value_at_timestamptz, textset_value_n, set_as_hexwkb, ...), and every binding whose hand-written surface calls the folded form fails to compile. Scan the tags from the source checkout (MDB_SRC_ROOT/meos), the same root the @sqlfn / @InGroup maps already use, falling back to the header tree's parent when the headers are themselves a source checkout.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
may be NULLand@param[out]Doxygen tags are a property of the MEOS C source (meos/src/**/*.c), butrun.pyscanned them fromHEADERS_DIR.parent.On the
provision-meosbuild-libmeos: truepath,HEADERS_DIRis the installed headers (the generatedmeos_export.h, deliberately parsed there so base-type I/O likeinterval_inis visible) — whose parent has nosrc/. So the scan finds 0 out-params and 0 nullable, even though the source has 459 / 95.With no
shape.outParams, the codegens cannot fold single out-param wrappers, so functions likettext_value_at_timestamptz(temp, t, strict, text **value)emit unfolded (the out-param stays a visible argument). Every binding whose hand-written surface calls the folded form then fails to compile — e.g. JMEOS:This breaks the catalog for every
build-libmeos: trueconsumer (JMEOS, MEOS.NET, Spark, …); the catalog-only path (javadoc) was unaffected because it parses the source header tree.Fix
Scan the Doxygen tags from the source checkout (
MDB_SRC_ROOT/meos) — the same root the@sqlfn/@ingroupmaps already use — falling back to the header tree's parent when the headers are themselves a source checkout (noMDB_SRC_ROOT). Signature parsing still uses the installed headers unchanged.Verified: simulating the build path (installed-headers dir with no sibling
src/,MDB_SRC_ROOT=source) now reportsnullable: 95,out params: 459, andttext_value_at_timestamptz/textset_value_n/set_as_hexwkbregain theirshape.outParams. The normal full-source path is unchanged.