Skip to content

Define language for validations as derived model #176

@enikao

Description

@enikao

Checking a model for consistency and other errors is one of the most common operations on models.
It might also be expensive: if we wanted to assure globally unique names, we had to check all named things in our model on every name change.
The basic structure of validation is very similar in most systems: any issue has a severity level, refers to a node, might relate to a feature, and provides an error message.

As an example, we might define concepts for Error, Warning, and Info.

My specific validator implementation would create instances of Error and Info, but also include a custom compiler-based validation language that defines GeneratorWarning and CompilerWarning as specializations of Warning.
A client that only knows about this validation base language can process both of the specialized warnings in a generic fashion.
Another, compiler-aware client might display GeneratorWarnings differently than CompilerWarnings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions