orbit-lang/Bootstrap

TypeChecker - Propagate SourcePosition

开放

#4 创建于 2021年5月16日

 (0 条评论) (0 个反应) (0 位负责人)Kotlin (0 个派生)auto 404
TypeCheckergood first issue

仓库指标

星标
 (0 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

Currently, information about source positions & tokens is effectively thrown away after the frontend phase is complete, because Types do not currently capture source positions from their source nodes. It should be fairly simple to extend the TypeProtocol interface to capture a meaningful SourcePosition in most cases.

This metadata is useful for propagating good error messages. Currently, errors & warnings from the TypeChecker phase are reported as occurring at SourcePosition (line: 0, offset: 0), which is obviously bad.

贡献者指南