Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed, Backport Pending
    • Affects Version/s: Scala 2.9.1
    • Fix Version/s: Scala 2.10.0-M2
    • Component/s: Collections
    • Labels:

      Description

      In 2.9.1 REPL, repeating the exact same "find" query twice gives different results. It only does this when using both ".par" and ".view".

      See also http://stackoverflow.com/questions/8470490/can-views-be-used-with-parallel-collections/9458613#9458613

      scala> val f : Int => Int = _ + 10
      f: Int => Int = <function1>

      scala> List(1,2,3).par.view.map(f).find(_ > 11)
      res11: Option[Int] = Some(12)

      scala> List(1,2,3).par.view.map(f).find(_ > 11)
      res12: Option[Int] = None

        Activity

        Hide
        Simon Ochsenreither added a comment -

        Can't reproduce with Scala version 2.10.0-M2-0044-g0c2f493804-2012-02-25 (OpenJDK 64-Bit Server VM, Java 1.7.0_03-icedtea).

        Show
        Simon Ochsenreither added a comment - Can't reproduce with Scala version 2.10.0-M2-0044-g0c2f493804-2012-02-25 (OpenJDK 64-Bit Server VM, Java 1.7.0_03-icedtea).
        Hide
        Eugene Burmako added a comment -

        Is indeed reproducible in 2.9.1 - both in repl and outside repl.

        Show
        Eugene Burmako added a comment - Is indeed reproducible in 2.9.1 - both in repl and outside repl.
        Hide
        Aleksandar Prokopec added a comment -

        Yes, I can reproduce in 2.9.1, but I can't reproduce it in 2.10 nightly.

        Show
        Aleksandar Prokopec added a comment - Yes, I can reproduce in 2.9.1, but I can't reproduce it in 2.10 nightly.
        Hide
        Aleksandar Prokopec added a comment -

        We accept backports through pull requests.

        Show
        Aleksandar Prokopec added a comment - We accept backports through pull requests.

          People

          • Assignee:
            Aleksandar Prokopec
            Reporter:
            Luigi Plinge
          • Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development