We’re here to help you

Menu

Dezyne Errors

At various places in the development of a Dezyne component errors can occur. This page provides an overview of the error categories, and some advice on their resolution.

Errors are either syntax or semantics oriented. A slightly different separation is made here however: Some errors can be found statically, by analyzing the text, other errors are found only during verification or simulation.

Static errors

The static analysis of a component is done in a couple of phases. Each of these can report errors.

Parsing

As a first step a Dezyne file is parsed and processed by a syntax checker. Modern parsers are generated from a high level specification and as a result all error messages are generated too. These error messages can be somewhat cryptic.

Name resolution

The next step involves name resolution: all declarations have to introduce a unique name and all identifiers that are used in a model have to be declared. Name resolution can be elaborate at some points, especially due to the use of 'dotted names', as in 'bool b = Intf.Result.Ok' where 'Ok' is an enum value introduced in the declaration of enum 'Result', which is introduced in the context of interface 'Intf'.

A typical error message would be:

identifier declared before: 'b'

or

undefined Enum value reference: 'OOK' in 'I.Result.OOK'

Type checking

Once all names have been resolved, each expression is checked for type safety. An example:

In 'bool b = C && D' it is checked that 'C && D' is a 'bool' expression, and consequently that both 'C' and 'D' are 'bool' expressions. A typical error message would be:

'&&' requires a boolean second argument

Well-formedness checking

On top of the above, a collection of well-formedness checks is defined. Some of these checks are 'common sense', other ones are needed to define appropriate semantics.

See Well-formedness for an overview of all checks.

Verification and simulation errors

Models that are parsed correctly can be verified and simulated.

See Verifying models for an overview on verification.

See Simulation and verification error messages for an overview of error messages issued during simulation or verification.

If you have questions that weren’t answered by this Guide,
let our support team help you out.

Enjoy this article? Don't forget to share.