A common frustration is seeing a term `Ptr x :: foo ptr` and not being
able to inspect the inferred type `foo` (this is especially true when
`Ptr` occurs within another expression).
Copying the style of `UCAST`, this adds syntax rules for displaying `Ptr
x :: foo ptr` as `PTR(foo) x` and `ptr_coerce (bar :: a ptr) :: b ptr`
as `PTR_COERCE(a -> b) bar`.
Just because we *can* extend the core SML `List` signature, that doesn't
mean we *should*. It's a neat trick, but it makes it harder to find uses
of the new modules, and obfuscates definitions for very little gain.
The C parser tracks what short names a given long name corresponds to.
Change AutoCorres to use that information, instead of trying to demangle
the names 'manually'.
Previously, the C parser would define locals differently depending on
the order they appear in the source (the first instance got a short
name, the second etc. got a longer one). This would sometimes make
things break when source was reordered.
Now, the C parser emits the long name for _every_ local, and emits an
abbreviation for backwards-compatibility and convenience for common
variables (like loop indexes `int i`).
Adjusts the Simpl syntax modifiers to work with abbreviations.
Modifies the VCG tactic to try and convert long-name bound variables in
the goal to their abbreviated names.
Note that we have removed the LIB_FILES manifest and no longer intend
to maintain it manually. Instead, we just extract the entire Lib and
CLib sessions from the L4.verified repository. This means that the
next AutoCorres release will have some unneeded theories and a couple
of files with GPL licenses.
Some attributes attached to global variables weren't kept in
the AST if they appeared at the front of the declaration rather
than the back.
For instance, the aligned attribute was lost in this declaration:
int __attribute__((aligned(16))) x;
but kept if it appeared last:
int y __attribute__((aligned(16)));
Now fixed.