enumeratum icon indicating copy to clipboard operation
enumeratum copied to clipboard

Mix scala 2 and 3 macros

Open gregghz opened this issue 9 months ago • 5 comments

This follows the pattern shown here: https://docs.scala-lang.org/scala3/guides/migration/tutorial-macro-mixing.html#:~:text=Introduction,during%20the%20macro%20expansion%20phase

This would allow a mixed scala version project to depend on the scala 3 version of enumeratum and build correctly for both scala 2 modules and scala 3 modules. This is particularly helpful when building with bazel since you can't conditionally include a dependency based on the current scala version the same way you would in sbt.

This was brought up previously by @coreywoodfield here: https://github.com/lloydmeta/enumeratum/issues/300#issuecomment-1363451865 (and he is the author of this PR -- I just rebased the branch).

gregghz avatar May 21 '24 21:05 gregghz