Skip to content
This repository has been archived by the owner on Nov 29, 2020. It is now read-only.

Lazy val optimization for pure code #24

Open
sir-wabbit opened this issue Jun 28, 2018 · 0 comments
Open

Lazy val optimization for pure code #24

sir-wabbit opened this issue Jun 28, 2018 · 0 comments
Labels
good first issue Good for newcomers optimization Code optimization opportunity.

Comments

@sir-wabbit
Copy link
Contributor

sir-wabbit commented Jun 28, 2018

We could replace all lazy vals with the cheapest version of https://github.com/runarorama/latr (@Lazify) by default. If the code is pure, re-evaluating a thunk twice is not a problem and the probability of that happening is minuscule anyway.

See https://docs.scala-lang.org/sips/improved-lazy-val-initialization.html for more background

@sir-wabbit sir-wabbit added the optimization Code optimization opportunity. label Jun 29, 2018
@sir-wabbit sir-wabbit changed the title Investigate if we could include SIP-20 by default on all lazy vals Lazy val optimization for pure code Jun 29, 2018
@sir-wabbit sir-wabbit added the good first issue Good for newcomers label Jul 15, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers optimization Code optimization opportunity.
Projects
None yet
Development

No branches or pull requests

1 participant