Replace the stub implementation of invalidation with the proper
implementation. A ReadPathCache is added to each global so that it can
keep tracks of what target are associated to which read paths.
This commit switches `model::Type::ID` from being a GUID to be a
progressive number, in order to make things easier for humans.
On top of this, this commit introduces the following changes:
* TypeCopier: import all the necessary PrimitiveTypes and improve
handling of CustomName.
* Move Kind as the last field of the key of each TupleTree type used in
an `UpcastablePointer`.
* Update the ground truth of tests to ignore the `CustomName` in favor
of focusing on `OriginalName`.
* Increase adoption of `model::Binary::makeType`, equivalent to
`Binary.recordNewType(makeType<model::*Type>())`.
Not every case can benefit from extra liniency, so they were manually
reviewed on a case by case basis.
Additionally, this drops a couple of "this should be a non-strict
specialization" commits, because of a bug with clang
(see the GenericGraph concepts rework commit for more details) as
to avoid confusion (we wouldn't want anyone trying to solve these
"todo"s) until the clang struct type deduction is fixed. Especially
considering that there are currently no cases where these softer
versions would be beneficial (we never inherit from templates in
question).
`DocumentError`s are the inteded way of propagating errors from the
pipeline to the frontend when a location is required to inform the user
of the error whereabouts.
`TupleTreeReference`s use the Root type as a pointer only so they can
operate with forward declarations. Before this commit there were static
asserts that prevented this use case, and thus required the headers
defining the root type to be included before this one to work correctly.
We drop those `static_assert`s to make sure that all headers are parsable
on their own.
This commit reduces build times by introducing a type-erasure layer when
performing a visit on TupleTrees. Basically instead of propagating the
type of the visitor along all of the template castle, we wrap the
visitor into a virtual class with one method for each possible type in
the TupleTree.
This enables a single instatiation of visit algorithm.
We used to assign an uninitialized field to `false`. However, what we
really wanted to is to construct the optional by invoking the default
constructor of the `value_type` of the optional.
The copy of a TupleTree is potentially very expensive, so it was
disabled until now and only allowed via the explict method clone().
We have now decided to make TupleTree copiable.
This commit adds a copy-constructor and a copy-assignment, killing the
clone() method that was already unused and is now effectively useless.