casey / casey/oi

Support source position annotations

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
7
Forks
1
PR merge metrics
No merged PRs in 30d

Description

@LuoZijun made a create for attaching source position information to an error here: https://github.com/LuoZijun/oioioi

Someone on reddit wanted this, and I think it's a feature that maybe should be incorporated into `oi`.

One way to do this would be to add an `err_at_position(location, position)`, which you would have to call as `err_at_position(location, here!())`. Unfortunately, since the position information is generated via a macro, the user would have to supply the position at the call site.

Contributor guide

Open the contributing guide

Research direction

The issue names no files or tests. Start by reviewing the linked LuoZijun/oioioi implementation and oi's existing error API, then determine how source positions should be represented and exposed. Done should include a settled interface for attaching a location and call-site position, such as err_at_position(location, here!()).

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
devtools
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.