blob: d219fea651167384db691d98862f404fef5b38f6 [file] [log] [blame] [view]
## fi-0167: Cannot constrain twice {:#fi-0167}
Re-assigning the transport bound for a `client_end` or `server_end` that has
already had a transport bound defined through an `alias` declaration is
prohibited:
{% include "docs/reference/fidl/language/error-catalog/label/_bad.md" %}
```fidl
{% includecode gerrit_repo="fuchsia/fuchsia" gerrit_path="tools/fidl/fidlc/tests/fidl/bad/fi-0167.test.fidl" exclude_regexp="\/\/ (Copyright 20|Use of|found in).*" %}
```
Instead, aliasing of `client_end` and `server_end` types should be avoided
entirely:
{% include "docs/reference/fidl/language/error-catalog/label/_good.md" %}
```fidl
{% includecode gerrit_repo="fuchsia/fuchsia" gerrit_path="tools/fidl/fidlc/tests/fidl/good/fi-0167.test.fidl" exclude_regexp="\/\/ (Copyright 20|Use of|found in).*" %}
```
This is disallowed to avoid confusion and compiler implementation complexity.