Skip to content
Snippets Groups Projects
Commit eb94f057 authored by Pascal Perez's avatar Pascal Perez Committed by CQ bot account: commit-bot@chromium.org
Browse files

[fidlgen][go] Do not export request/response structs

To bridge between function arguments/returns and encoding/decoding, the
Go bindings generate request/response structs holdings the various
argument/return values. However, developers should not interact which
these, instead using method calls and receiving returns.

With the introduction of the error syntax, the fidlc compiler creates a
name for the struct holding the value, i.e. the first variant of the
result union where the second is the error. The name for this struct is
suffixed by "Response" which used to clash with the response struct
mentioned above.

By keeping the request/response struct private (unexported), we avoid
this clash.

(This does not solve the more general problem of name clashing -- nor
does it try to.)

FIDL-519 #comment

Change-Id: I50767de8d4b3e2d2cfd1b4f7fd4585ead9a455fd
parent 6e9b1b9e
No related branches found
No related tags found
Loading
Showing
with 3054 additions and 261 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment