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

Magnolia interface unification for Scala 2 and Scala 3 versions #458

Open
YaroslavSagach opened this issue Feb 15, 2023 · 1 comment
Open

Comments

@YaroslavSagach
Copy link
Contributor

In a process of migrating the project to Scala 3, I created a cross build. In which, I separated code with magnolia, that differs. So the Scala 2. code uses 1.1.3 version, and Scala 3 uses 1.2.6. Also, there is common code, which I want to keep for both versions. But, I've stumbled upon a problem, that those 2 versions of magnolia have different interfaces. In particular, I have a problem with CaseClass 'params'. In 1.1.3 it's "parameters", but in 1.2.6 it's "params" :

val params: IArray[CaseClass.Param[Typeclass, Type]],

override def parameters: Seq[Param[Typeclass, Type]] = parametersArray

So, is there any way to unify these interfaces, for such use cases like mine?

@adamw
Copy link
Member

adamw commented Feb 22, 2023

Yes, and I expect this might diverge further. For example, we'll be releasing magnolia 2 for scala 3 using a different package name (see #457), and there might be more changes needed to support scala3-specific types. So I don't think having a unified interface will be possible in the long run.

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

2 participants