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.

貢獻者指南