Skip to content

15. Findings

Contents of ATD 0.1

15.1 Codes

A finding has a code ATD<nnnn>, by range:

Code Finding
ATD0001 The description declares a version of ATD the reader does not know; the message names both.
ATD0002 The file does not start with atd <major>.<minor>.
ATD1001 A syntax error: what was found, and what was expected.
ATD1002 Text no token matches.
ATD2001 No such attribute.
ATD2002 No such element or relation type.
ATD2003 Imports that form a cycle (once).
ATD2004 No such binding rule.
ATD2005 No such function.
ATD2006 A name declared twice in one namespace.
ATD2007 A part of another tool type's origin.
ATD2008 A part two roots import.
ATD2009 An imported file that is not there or outside the description's folder.
ATD2010 A capability not in the catalogue, or used without requires capability.
ATD2011 No such name of another namespace (a reason, an operation, a style, …).
ATD3001 A construct of the model the description's kind does not admit.
ATD3002 A surface construct of another kind.
ATD3003 A designer or editor without its one surface, or with two.
ATD4001 An expression whose type does not fit its position.
ATD4003 A CEL reserved word as an identifier.
ATD4004 An unknown variable in an expression.
ATD5001 A setting the construct's schema does not have.
ATD5002 A setting's value the schema does not admit.
ATD5003 A literal where the schema wants an expression.
ATD6001 A binding that reads or writes an attribute the model does not declare.
ATD6002 A hierarchy surface that does not fit its types (section 14.7).
ATD6003 A counter id rule whose mark is not a string attribute of the document.
ATD6004 A setting of persistence that no binding's registration keeps as a block, or that one binding does not.
ATD7001 A call of a function outside CEL's library and the description (a clock, randomness, a file, …).
ATD7002 An impure function called from a position that only reads.
ATD7003 A path of a function that neither returns nor fails.
ATD7004 A recursion bound above 64.
ATD7101 At run time: a loop reached its limit.
ATD7102 At run time: the step budget is exceeded.
ATD7103 At run time: the recursion bound is exceeded.
ATD8001 A grammar in a binding that is not LALR(1), naming the conflict (FBL 0.9).
ATD9001 Validation: a difference from a conformance fixture.
ATD9010 A capability the running host does not provide.

15.2 Severities

error (the description is not accepted), warning and information. Every finding of section 15.1 is an error unless its construct says otherwise.

15.3 Positions and messages

A finding names its file, the 1-based line and column (in code points) of its start, and of its end; related places it concerns; and its message, a sentence in English in ADP's words (docs/terminology.md), naming the construct as the tool engineer wrote it. A syntax error names what was found and what was expected. Localized text a description carries is never in a finding's message.

15.4 Machine-readable findings

atd check --json writes $defs/Findings, the findings in a stable order: by file, then line and column, then code (FR-091). A finding carries its fixes, each a title and text edits in byte offsets, and its suggestions. The language servers' diagnostics carry the same code, and the fixes as code actions.

15.5 Closest names

The closest names a finding offers for a name that resolves to nothing are the names of the same namespace in scope within an edit distance of 2 or sharing a prefix of 3, at most five, nearest first.

Referenced from