You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The move to Scala3 requires a very serious rewrite, as Scala 3 has dropped projection types.
I started a conversation on the lampepfl github discussion space to see how others are coping with this. That has a number of important links too. But I should perhaps move the conversation to a more visible forum.
Anyway, I think when I last tried to compile banana-rdf in Scala3 I ended up with way over 500 problems.
The obvious answer is to use projection types, but it is not that easy. I tried 10 months ago, but at the time my understanding of Scala3 was very small.
The text was updated successfully, but these errors were encountered:
Projection types are not the panacea either I think. Using bananas-rdf in a Scala3 project, I have noticed that there are two problems:
Inheritance of types does not work. So inference from Rdf#Bnode to Rdf#Node do not work automatically.
There is leakage from the underlying projection types if one does not parameterize one's code with Rdf in class SomeClass[Rdf <: RDF](...). I noticed this because I wanted to add a find method to GraphW that returns an Iterator. But if I have Rdf hard code to Jena I get
acRulesGraph.find(node,wac.default,ANY).exists{ (cnode: Rdf#Node) =>
[error] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[error] |value exists is not a member of org.apache.jena.util.iterator.ExtendedIterator[org.apache.jena.graph.Triple], but could be made available as an extension method.
So Scala3's opaque types may help avoid this type of problem.
The move to Scala3 requires a very serious rewrite, as Scala 3 has dropped projection types.
I started a conversation on the lampepfl github discussion space to see how others are coping with this. That has a number of important links too. But I should perhaps move the conversation to a more visible forum.
Anyway, I think when I last tried to compile banana-rdf in Scala3 I ended up with way over 500 problems.
The obvious answer is to use projection types, but it is not that easy. I tried 10 months ago, but at the time my understanding of Scala3 was very small.
The text was updated successfully, but these errors were encountered: