| 1417 | } |
| 1418 | |
| 1419 | void NotNested() { |
| 1420 | // If you hit this, you're trying to construct a Table/Vector/String |
| 1421 | // during the construction of its parent table (between the MyTableBuilder |
| 1422 | // and table.Finish(). |
| 1423 | // Move the creation of these sub-objects to above the MyTableBuilder to |
| 1424 | // not get this assert. |
| 1425 | // Ignoring this assert may appear to work in simple cases, but the reason |
| 1426 | // it is here is that storing objects in-line may cause vtable offsets |
| 1427 | // to not fit anymore. It also leads to vtable duplication. |
| 1428 | FLATBUFFERS_ASSERT(!nested); |
| 1429 | // If you hit this, fields were added outside the scope of a table. |
| 1430 | FLATBUFFERS_ASSERT(!num_field_loc); |
| 1431 | } |
| 1432 | |
| 1433 | // From generated code (or from the parser), we call StartTable/EndTable |
| 1434 | // with a sequence of AddElement calls in between. |
no outgoing calls
no test coverage detected