linebender / linebender/interpoli
Use functions instead of trait methods as the API for `src/spline.rs`
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 18
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
I don't really think that this module has much advantage for understandability in this form. I'd rather see two functions, which can internally use a shared trait.
Originally posted by @DJMcNab in https://github.com/linebender/interpoli/pull/2#discussion_r1720044392
That module currently has a trait which is implemented for two types, including a (slice, slice, t) tuple, and a method which iterates through that type. I'd much rather see this be a function instead, so that the parameter names have meaning.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review src/spline.rs, starting with the trait, its two implementations, and the method that iterates over the tuple-based input. Refactor the public API into two functions with meaningful parameter names while retaining a shared internal trait where useful; done means callers no longer need the trait-method form.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend-api-design
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100