News for hackers. Stuff that matters.
Re:Strymonas – A library for OCaml and Scala for fast, bulk,... by zokier on Saturday November 26, 2016 @05:08PM (#13046173)
I'm not sure I get what's the difference between for example:

    def filterFilterTest (xs : Rep[Array[Int]]) : Rep[Int] =
        Stream[Int](xs)
          .filter(d => d % 2 == 0)
          .filter(d => d % 3 == 0)
          .fold(unit(0), ((a : Rep[Int]) => (b : Rep[Int]) => a + b))
and

    xs.filter(d => d % 2 == 0).filter(d => d % 3 == 0).fold(0)(_+_)
(grabbed from unit tests here: https://github.com/strymonas/staged-streams.scala/blob/maste... )

They both look pretty much the same and superficially do the same thing too, so what makes this new thing better/novel?

Re:Strymonas – A library for OCaml and Scala for fast, bulk,... by otini on Saturday November 26, 2016 @06:29PM (#13046648)
I would say that the latter is non-optimal, i.e. generates some unnecessary intermediary values whereas the former is optimal as shown in the paper.