History log of /fuchsia/zircon/system/utest/fidl/fidl_coded_types.cpp
Revision Date Author Comments
# f479a0e8 26-Mar-2018 Jeff Brown <jeffbrown@google.com>

[fidl] Include declared names in FIDL tables.

This enables the name of a FIDL type to be formatted at runtime
using fidl_format_type_name(). Handy for debugging.

The strings are always generated today but they could be omitted
in the future, if desired.

Change-Id: I0cb0d2ab6e3c00a2a4b8f609d563c4bde2d6f98c


# 51da239b 14-Mar-2018 James Robinson <jamesr@google.com>

[fidl] Move public fidl headers to match naming convention

The fidl library provides headers intended for general use, so the
include path should be spelled <lib/fidl/foo.h> as per
https://fuchsia.googlesource.com/docs/+/master/development/languages/c-cpp/naming.md.
This moves the headers into the proper location and updates includes to
match.

Change-Id: I9db162c3fd40170d63730bc9b7079c7e7e950982


# 379a42fe 06-Mar-2018 George Kulakowski <kulakowski@google.com>

[fidl] Fix coding of vectors with boring payloads

Boring types don't make it into the coding tables. A uint32 struct
member is elided. So is an array of them. Things that aren't boring
(maybe transitively) have pointers or handles to check.

Vectors of boring things are semi-boring. We need the payload bounds,
but can skip looking at the contents.

Change-Id: I7f4d256d770406040baf17919bb5ab48d595fb5e


# 82e1aba3 21-Feb-2018 Gary Miguel <garymm@google.com>

[fidl] Fix "recursion too deep" test cases and union field offsets.

1. Before this change, the recursion_message_type was not a valid FIDL message.
In particular the pointers in the maybe_recurse union were not being followed
because they weren't properly encoded as Pointer types.
Furthermore, pointers to Unions doesn't actually trigger the recursion code path
in the encoder, so I had to change them to pointers to Structs.

Previously the test was passing by accident because it was only asserting that
ZX_ERR_INVALID_ARGS was returned. Now we assert that we get the expected
error message, and we also check that things work as expected at
FIDL_RECURSION_DEPTH - 1 and then break at FIDL_RECURSION_DEPTH - 1.

2. Fix the incorrect assumption that union data will immediately follow
the tag. This bug was revealed in the process of doing 1.

3. Improve some error messages.

Change-Id: If027f11744aea10b52974c1ca5976b14da721fd8


# 0a778d1e 06-Nov-2017 George Kulakowski <kulakowski@google.com>

[fidl] Introduce fidl::Nullability for encoding tables

In the course of writing tests etc. I've found this makes the
generated output much more readable at a glance.

Change-Id: Ifb6d066caf2099173ffc65822c597ea426d8f16e


# d46dd4d8 01-Nov-2017 George Kulakowski <kulakowski@google.com>

[fidl] Rewrite encoding tests to separate out to-be-generated data

Also format all fidl-related code with a 100 column limit.

Change-Id: I1b7b66ab3ac1a1b88dc1217d50904249a9539000