enso/docs/parser/construct-resolution.md

42 lines
1.2 KiB
Markdown
Raw Normal View History

2020-06-25 15:06:08 +03:00
---
layout: developer-doc
title: Construct Resolution
category: parser
tags: [parser, construct, resolution]
order: 6
2020-06-25 15:06:08 +03:00
---
# Construct Resolution
2020-07-21 15:59:40 +03:00
2020-06-26 16:54:20 +03:00
Construct resolution is the process of turning the low-level AST format into the
full high-level AST format that represents both all of Enso's language
constructs and contains rich error nodes.
2020-06-25 15:06:08 +03:00
<!-- MarkdownTOC levels="2,3" autolink="true" -->
2020-06-26 16:54:20 +03:00
- [Syntax Errors](#syntax-errors)
2020-06-25 15:06:08 +03:00
<!-- /MarkdownTOC -->
2020-06-26 16:54:20 +03:00
> The actionables for this section are:
>
> - Produce a detailed design for this resolution functionality, accounting for
> all known current use cases.
## Syntax Errors
2020-07-21 15:59:40 +03:00
2020-06-26 16:54:20 +03:00
It is very important that Enso is able to provide descriptive and useful syntax
errors to its users. Doing so requires that it has a full understanding of the
language's syntax, but also that it is designed in such a fashion that it will
always succeed, regardless of any errors. Errors must be:
- Highly descriptive, so that it is easy for the runtime to explain to the user
what went wrong.
- Highly localised, so that the scope of the error has as minimal an impact on
parsing as possible.
> The actionables for this section are:
>
> - Determine how to design this parsing phase to obtain very accurate syntax
> errors.