Found during the 2026-07-18 Windows audit follow-up (PR #6632 verification).
The method form stack.addChild(child) compiles and runs on native targets but silently does nothing: the mapping "addChild" -> perry_ui_widget_add_child exists only in the js and wasm backends (perry-codegen-js/src/emit/calls.rs:178, perry-codegen-wasm/src/emit/ui_method_map.rs:38). The native pipeline (perry-hir / perry-codegen) has no such method row, and no runtime error surfaces — the call just evaporates.
The supported native surface is the free function widgetAddChild(parent, child) (perry-dispatch/src/ui_table/part_a.rs, method widgetAddChild), which works correctly (verified end-to-end on Windows in PR #6632).
Suggested fix: either wire the method form natively to match js/wasm, or remove it from the js/wasm backends (and any docs/examples) so all backends agree. Silent cross-backend drift is the worst of the three states. The sibling methods in web_runtime.js's wrapWidget (removeAllChildren, setBackground, setFontSize, ...) deserve the same audit — each is a potential native no-op with a working web twin.
Found during the 2026-07-18 Windows audit follow-up (PR #6632 verification).
The method form
stack.addChild(child)compiles and runs on native targets but silently does nothing: the mapping"addChild" -> perry_ui_widget_add_childexists only in the js and wasm backends (perry-codegen-js/src/emit/calls.rs:178,perry-codegen-wasm/src/emit/ui_method_map.rs:38). The native pipeline (perry-hir / perry-codegen) has no such method row, and no runtime error surfaces — the call just evaporates.The supported native surface is the free function
widgetAddChild(parent, child)(perry-dispatch/src/ui_table/part_a.rs, methodwidgetAddChild), which works correctly (verified end-to-end on Windows in PR #6632).Suggested fix: either wire the method form natively to match js/wasm, or remove it from the js/wasm backends (and any docs/examples) so all backends agree. Silent cross-backend drift is the worst of the three states. The sibling methods in
web_runtime.js'swrapWidget(removeAllChildren, setBackground, setFontSize, ...) deserve the same audit — each is a potential native no-op with a working web twin.