Skip to content

Can't call io.circe.yaml.parser.parse on an input stream reader in 0.15.1 #410

@Thrillpool

Description

@Thrillpool

If you try to do

io.circe.yaml.parser.parse(new InputStreamReader(null))

Then you get a compilation error

type mismatch;
 found   : java.io.InputStreamReader
 required: String

I would imagine this change to be responsible d3d0907#diff-f063ea063fa1652fe54e2ad024f6209661708310bfbaf78c7b303fbc7095db2aR12

Though I don't see all the details.

If you replace io.circe.yaml.parser.parse with Parser.default.parse i.e. its definition, it compiles fine.

Edit - I think issue is basically this

object X extends App {
  B.f(0)
}

trait A {
  def f(x: String): String
}

package object B extends A {
  def f(x: Int): String = ???
  def f(x: String): String = ???
}

Edit - I suppose it's pertinent to say I am using scala 2.12

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions