History log of /seL4-camkes-master/projects/camkes-tool/camkes/ast/objects.py
Revision Date Author Comments
# c33a8459 30-Sep-2020 Damon Lee <Damon.Lee@data61.csiro.au>

camkes: Add uint64_t and int64_t types to language

The CAmkES language was missing support for larger data types. This
commit introduces two new data types to that is intended to fill that
gap.


# 0cc17c0e 30-Sep-2020 Damon Lee <Damon.Lee@data61.csiro.au>

ast: Clarify type mismatch error message

The previous message was a bit hard to understand.


# 21becfa9 16-Jul-2019 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast,runner: Remove template field from connector

This allows us to more easily extend the mechanisms for constructing
components and connectors.


# 9d10b308 25-Nov-2019 Kent McLeod <Kent.Mcleod@data61.csiro.au>

trivial: Style unstyled files


# 8d65bd65 27-May-2019 Japheth Lim <Japheth.Lim@data61.csiro.au>

templates: arch-definitions: omit exported interfaces from model

The parser already resolves exports in `stage7`, but the export
declarations are left untouched in the `Component`s. This commit
detects and removes them to avoid dangling interfaces in the
Isabelle model.


# e0055d56 15-Jul-2019 Alison Felizzi <Alison.Felizzi@data61.csiro.au>

Style: Style of dtbmatchquery.py and objects.py

Updated style of testdtbmatchquery.py and objects.py


# f6a611eb 14-Jul-2019 Alison Felizzi <Alison.Felizzi@data61.csiro.au>

AST: Updated ast_property checks on QueryObject

Updated the QueryObject ast property checks to account for the
interface now taking a list of dictionaries. Also updated the
property names to match the object field names
(these weren't being checked prior).


# 232d7dfb 25-Mar-2019 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: Allow names of objects to be None

This is similar to previous behavior as some ASTObject subtypes such as
Composition or Assembly can be defined without a name. We require that
the name attribute still exists in this situation and so not defining it
if name was None was incorrect.


# 8e01684a 07-Mar-2019 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: DictLookup.lookup is a list

Previously this was incorrectly typed as a string type, but a lookup
could be a chain of key types.


# 3e3b6f2b 13-May-2018 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: Use ast_property decorator to reduce code dup


# dffb2d6c 13-May-2018 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: add ast_property decorator

Creates getter and setters for an AST property. Should lead to less code
duplication


# 129c113f 18-Oct-2018 Adam Felizzi <Adam.Felizzi@data61.csiro.au>

camkes/ast: Emit warning for extra struct fields

Updated the case when there are extra attributes in the struct
field. This now emits a warning rather than an error.


# 122d3872 17-Oct-2018 Anna Lyons <Anna.Lyons@data61.csiro.au>

camkes/ast: emit warning not error on extra struct fields


# 0200e258 13-Aug-2018 Anna Lyons <Anna.Lyons@data61.csiro.au>

camkes/parser: add query to camkes ADL

This commit adds a new feature called a query. A query appears in the
ADL on the RHS of a setting in the configuration section of the ADL, eg:

configuration {
component.blah = query()
}

queries takes comma separated parameters that can be any literal (numeric_expr |
multi_string | list | dict).

Queries are parsed in a new parsing stage between stage7 and stage8.


# eaf89ecd 26-Sep-2018 Anna Lyons <Anna.Lyons@data61.csiro.au>

parser: allow for dict lookups in attribute references

This commit adds the ability to look up values in attribute references
that are dictionaries.

The syntax is the same as python dict lookups and is as follows:

s.bah <- y.attribute['key']['anotherkey']


# a32bcb49 18-Jul-2018 Adam Felizzi <Adam.Felizzi@data61.csiro.au>

ast: ASTError formatting fix

Updated the formatting of an ASTError in the Connector class.
This assumed each class had a name attribute to print for the
error message. Now checks if the attribute exits.


# e43ddfeb 12-Jul-2018 Adam Felizzi <Adam.Felizzi@data61.csiro.au>

ast: Fixed ASTError formatting in Connector class

Updated the formatting of an ASTError in the Connector class.
Prior to the change a python error/exception would occur as it
tried to format a list of type objects into the error string. Now
accesses the string name of each type object.


# fb2ebb4f 12-Jul-2018 Adam Felizzi <Adam.Felizzi@data61.csiro.au>

ast: Flexible type checking on connectors

Updated the Camkes connector to check on the optional attribute
'disable_interface_type_checking'.
Adding 'disable_interface_type_checking' to your
connector definition relaxes the type checking of the connector,
allowing multiple interface types over the one connection. Updated
the camkes ast representation of a connector to enable the
the checking of the attribute.


# 30e8855b 12-Jul-2018 Adam Felizzi <Adam.Felizzi@data61.csiro.au>

ast & parser: Connectors now have attributes

Extended the defintion of a connector with optional
attributes. The AST object implementation and parser
implementation were modified to allow the passing of connector
attributes.


# 3ce1f977 13-Jul-2017 Anna Lyons <Anna.Lyons@data61.csiro.au>

Fix whitespace

- remove trailing whitespace
- remove duplicate blank lines
- remote blank lines at end of file


# 0c25d459 27-Jun-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

parser: Allow struct elements to have defaults

If a CAmkES struct is declared with some default attribute values,
the struct elements with default values do not need to be included
upon asignment.


# e26e2f32 28-Jun-2017 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Change `generator.next()` to `next(generator)`

The `next` method of generators has been renamed to `__next__` in
python3. The recommended way to get the next element of an iterator is
to use the `next` builtin function.


# 864fe563 20-Jun-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: fix freezing hierarchical connections

When an instance name is omitted from a connection end, but the
composition is contained in a component, then the type for the instance
is the component that contains the composition


# a7bdcd24 19-Jun-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

parser: Reimplement stage 8 parser

Stage 8 parser is supposed to handle dereferencing of attributes,
but this was actually getting incorrectly done as a side effect of
stage 7 parser


# 8b2ec3e6 20-Jun-2017 Anna Lyons <Anna.Lyons@data61.csiro.au>

Fix licenses


# 4797973e 30-Mar-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

CAMKES-584: Add Struct type to camkes

Struct type represents a collection of attributes. Attributes are set by
providing a dictionary of fields and values


# 9866dd57 30-Mar-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

CAMKES-584: Add array support for Attributes

This makes it possible to define an attribute as a list of a type.
Assigning values to an attribute can be achieved by using the
`[3,4,5,6]` syntax.


# cc5a5238 29-Mar-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: types_compatible return error messages

Better error messages when attribute types don't check


# 95b27563 24-Mar-2017 Kent McLeod <Kent.Mcleod@data61.csiro.au>

ast: move types_compatible function into objects

This is needed to avoid circular dependency when extending
types_compatible to do more rigorous type checking


# 9d94374f 06-Mar-2017 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Added instance getter method to Instance

This method just returns self. It exists so instances and connection
ends can both be queried for their associated instance. This simplifies
the logic of specifying kept symbols, as they are stored against the
name of the instance associated with the currently running template.


# 5f025fda 13-Feb-2017 Kofi Doku Atuah <kofidoku.atuah@data61.csiro.au>

CAMKES-560: Add support for new-rt APIs to next

Replace instances of seL4_Recv, seL4_SignalRecv, seL4_Send, with
RT-compliant versions that operate on reply object caps.


# 89a1f069 24-Jan-2017 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Settings dict for Configuration AST objects

This adds a lookup table of Setting AST objects in Configuration AST
objects. The use case this addresses is allowing templates to report
Settings objects as the source of errors.

JIRA: CAMKES-551


# 87e0548a 09-Nov-2016 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Added binary_semaphore primitive


# 5e4a462e 15-Aug-2016 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Implemented __str__ for some AST objcets


# d210afd4 15-Aug-2016 Stephen Sherratt <Stephen.Sherratt@data61.csiro.au>

Include connector type in invalid n-1 conn error


# 6f04aa5d 30-May-2016 Matthew Fernandez <matthew.fernandez@nicta.com.au>

Catch attributes with C keyword names.

This commit cherry-picks c2dde22c6dd3da239fe06818755fb5844c8c3caa from
ssh://github.inside.nicta.com.au/mfernandez/project.


# cfadf0ee 29-May-2016 Matthew Fernandez <matthew.fernandez@nicta.com.au>

Account for attribute default values during freezing.

We should be good to go now.

This commit cherry-picks 72fc9ccb8094fd1dc7b124af27d0305338e44520 from
ssh://github.inside.nicta.com.au/mfernandez/project.

JIRA CAMKES-409


# 4f14054c 29-May-2016 Matthew Fernandez <matthew.fernandez@nicta.com.au>

Add a 'default' field to Attributes. Unused yet.

This commit cherry-picks 2b4907aa9a38772de265c0412dcd6f4b86f0b6d0 from
ssh://github.inside.nicta.com.au/mfernandez/project.

JIRA CAMKES-409.


# bacfebce 27-Oct-2015 Matthew Fernandez <matthew.fernandez@nicta.com.au>

Refactored parser init commit.