Woody88 / purescript-wai

Purescript Web Application Interface. Port of the Haskell WAI library.
MIT License
20 stars 2 forks source link

Laziness vs Strict issues? #2

Closed JordanMartinez closed 4 years ago

JordanMartinez commented 4 years ago

Since Haskell is lazy by default, they can have a lot of fields in their Record type for Request. If we port their model 1-to-1, will there be performance issues for doing that?

Woody88 commented 4 years ago

Hmm... I don't think that it's a big issue aside from probably always evaluating a large body when not needed. The rest of the fields are just information that you would find when parsing headers which should be pretty cheap. Am I missing something?

JordanMartinez commented 4 years ago

No, that was just a general question I thought would be worth raising. I'll close this.