Cleanup WASM bindings generators so they all have a similar interface
PiperOrigin-RevId: 827965451 Change-Id: I657fc4d3a480fbc62124c84fe9ddc0900a91183f
This commit is contained in:
committed by
Copybara-Service
parent
776fc32eb4
commit
29c1a3a0a5
@@ -635,9 +635,9 @@ def build_struct_source(
|
||||
with builder.function(f"std::unique_ptr<{w}> {w}::copy()"):
|
||||
builder.line(f"return std::make_unique<{w}>(*this);")
|
||||
|
||||
# C struct getter/setter
|
||||
with builder.function(f"{s}* {w}::get() const"):
|
||||
builder.line("return ptr_;")
|
||||
|
||||
with builder.function(f"void {w}::set({s}* ptr)"):
|
||||
builder.line("ptr_ = ptr;")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user