Skip to content

[Scala3] Move OpaqueTypeSpec and DirectionSpec#5399

Open
adkian-sifive wants to merge 2 commits into
mainfrom
adkian-sifive/scala3-opaquetypespec
Open

[Scala3] Move OpaqueTypeSpec and DirectionSpec#5399
adkian-sifive wants to merge 2 commits into
mainfrom
adkian-sifive/scala3-opaquetypespec

Conversation

@adkian-sifive

@adkian-sifive adkian-sifive commented May 29, 2026

Copy link
Copy Markdown
Member

Summary

OpaqueTypeSpec was hitting two errors in Scala 3:

class MaybeBoxed needs to be abstract, since:
it has 3 unimplemented members.
  // Members declared in chiselTests.experimental.OpaqueTypeSpec$.MaybeBoxed
  def boxed: Boolean = ???
  def underlying: T = ???
  
  // Members declared in chisel3.Record
  def elements: scala.collection.immutable.SeqMap[String, chisel3.Data] = ???

and

def underlying = elements.head._2
                 ^^^^^^^^^^^^^^^^
          Found:    chisel3.Data
          Required: T
          where:    T is a type in class Boxed with bounds <: chisel3.Data

Release Notes

OpaqueTypeSpec now supported in Scala 3

@adkian-sifive adkian-sifive added the Scala 3 Changes related to upgrading to Scala 3 label May 29, 2026
@adkian-sifive adkian-sifive enabled auto-merge (squash) June 1, 2026 05:59
Comment thread src/test/scala/chiselTests/experimental/OpaqueTypeSpec.scala
Comment thread src/test/scala/chiselTests/experimental/OpaqueTypeSpec.scala Outdated
@adkian-sifive adkian-sifive changed the title [Scala3] Move OpaqueTypeSpec and DirectionSpec [Scala3] Move OpaqueTypeSpec Jun 3, 2026
@adkian-sifive adkian-sifive changed the title [Scala3] Move OpaqueTypeSpec [Scala3] Move OpaqueTypeSpec and DirectionSpec Jun 3, 2026
@adkian-sifive adkian-sifive force-pushed the adkian-sifive/scala3-opaquetypespec branch from efcec25 to d5b0135 Compare July 2, 2026 05:30
@adkian-sifive

Copy link
Copy Markdown
Member Author

I think this should be ready to merge if it passes CI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scala 3 Changes related to upgrading to Scala 3

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants