Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation failure: value foreach is not a member of java.util.stream.Stream[String] #2

Closed
danielkasza opened this issue Sep 17, 2020 · 3 comments

Comments

@danielkasza
Copy link

I cannot compile ae3a437.

Commands I used:

  • git clone git@github.com:tdb-alcorn/chisel-formal.git
  • cd chisel-formal/
  • sbt compile

Result:

[error] /home/dkasza/projects/chisel-formal/src/main/scala/chisel3/formal/FormalSpec.scala:47:34: value foreach is not a member of java.util.stream.Stream[String]
[error]       for (line <- result.output.lines) {
[error]                                  ^
[error] /home/dkasza/projects/chisel-formal/src/main/scala/chisel3/formal/FormalSpec.scala:48:27: type mismatch;
[error]  found   : Array[Object]
[error]  required: Array[String]
[error] Note: Object >: String, but class Array is invariant in type T.
[error] You may wish to investigate a wildcard type such as `_ >: String`. (SLS 3.2.10)
[error]         checkLine(result, rtlLines, line)
[error]                           ^
[error] two errors found
[error] (Compile / compileIncremental) Compilation failed
[error] Total time: 3 s, completed Sep 16, 2020, 11:25:46 PM

I tried to build earlier revisions, but got similar errors.

Am I doing something wrong?

@danielkasza
Copy link
Author

I think this is caused by scala/bug#11125 and can be fixed by using linesIterator.

@danielkasza
Copy link
Author

With linesIterator, the example in the readme works.

@Martoni
Copy link
Contributor

Martoni commented Oct 2, 2020

Have you got a patch for compile it with linesIterator ?

[edit]

Ok, found it. #6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants