typelevel / typelevel/cats

Eval documentation

Open
#1,474 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Scala
Stars
5.5k
Forks
1.2k
Avg merge
2d 10h
Merged PRs (30d)
5

Description

The normal rule for Eval is never call .value until the "end-of-world". This should be sufficient, but may not be necessary for safety.

Consider in the eval code itself:
https://github.com/typelevel/cats/blob/master/core/src/main/scala/cats/Eval.scala#L228
https://github.com/typelevel/cats/blob/master/core/src/main/scala/cats/Eval.scala#L285

Can we document why these two internal calls are safe? It was not obvious to me on quick inspection why the right sequence of Call and Later would not blow the stack.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the two referenced sections of core/src/main/scala/cats/Eval.scala, around lines 228 and 285, and trace how the internal Call and Later sequence behaves. Document why those calls are safe from stack overflow, with the explanation placed where Eval users or maintainers can find it; done means the safety rationale is clear without requiring quick-inspection investigation.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.