Using the Scala library, available only for an older version of Scala

I am new to Scala. However, I created a medium-sized program with Scala 2.9.0 . Now I want to use the open source library, available only for Scala 2.7.7 .

Is it possible to use this library 2.7.7 in my Scala 2.9.0 program? How can I do it? I already looked at sbt, but actually it didn’t work. Does anyone have a hello world example for this ?

+7
source share
3 answers

In principle, it should be possible to use a custom class loader for 2.7.7 banners and custom wrappers. But in practice, since the library is open source, it is very likely that it would be less work to recompile it from 2.9 and make the necessary changes. (There are usually not many.)

+8
source

In the "Types" section there is an early preview of the migration manager (http://typesafe.com/technology/migration-manager), which promises reports and resolves binary incompatibilities. An early preview seems to report incompatibilities, but it might be worth it.

+3
source

The best approach is to either use a supported library or update the code.

If you take the second option, compile the code with the -deprecation and -Xmigration .

This tells you what you need to change between versions.

+1
source

All Articles