Skip to content

Omit return_value in gdextension_interface.json for void functions#114684

Merged
Repiteo merged 1 commit into
godotengine:masterfrom
dsnopek:gdextension-interface-json-omit-return-value
Jan 8, 2026
Merged

Omit return_value in gdextension_interface.json for void functions#114684
Repiteo merged 1 commit into
godotengine:masterfrom
dsnopek:gdextension-interface-json-omit-return-value

Conversation

@dsnopek
Copy link
Copy Markdown
Contributor

@dsnopek dsnopek commented Jan 7, 2026

Currently, the gdextension_interface.json requires specifying return_value for all functions, using the "type": "void" for ones without return values.

However, this is different than extension_api.json which omits the return_value in this case.

Per @Bromeon's suggestion on godotengine/godot-docs#11551 (comment), this updates the gdextension_interface.json to match extension_api.json

To ensure consistency, this also disallows using void without the pointer modifier as a type, so "type": "void" would now generate an error

@dsnopek dsnopek added this to the 4.6 milestone Jan 7, 2026
@dsnopek dsnopek requested a review from a team as a code owner January 7, 2026 14:45
@dsnopek dsnopek requested a review from a team as a code owner January 7, 2026 14:45
@dsnopek dsnopek requested a review from Bromeon January 7, 2026 15:19
Copy link
Copy Markdown
Member

@akien-mga akien-mga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems good to me.

@Repiteo Repiteo merged commit 2d37d38 into godotengine:master Jan 8, 2026
20 checks passed
@Repiteo
Copy link
Copy Markdown
Contributor

Repiteo commented Jan 8, 2026

Thanks!

rivie13 pushed a commit to rivie13/Phoenix-Agentic-Engine that referenced this pull request Feb 16, 2026
…ace-json-omit-return-value

Omit `return_value` in `gdextension_interface.json` for `void` functions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants