bodil / purescript-signal

Elm style FRP library for PureScript
Apache License 2.0
258 stars 44 forks source link

removed zipP and defined zip as synonyme for map2 #28

Closed brunjlar closed 9 years ago

brunjlar commented 9 years ago

I noticed that zip is doing exactly the same as map2 and that map2 is defined in terms of the Functor/Applicative instance of Signal, whereas zip is defined explicitly by zipP.

So I suggest to remove zipP and define zip as a synonyme of map2.

bodil commented 9 years ago

The reason for this was performance: you get a handwritten piece of Javascript which does exactly what it says on the tin without any indirection. I'm not sure I believe in that reason anymore, though, so I'm OK with this patch. It certainly makes things more elegant. :)