Permalink
Browse files

direct embedding: backported matching on tuples by symbols for Scala …

…2.10.x compatibility
  • Loading branch information...
cvogt committed May 1, 2013
1 parent 17cb162 commit 942d33ea1ceb2055597df4286235107ce802a9fc
Showing with 6 additions and 2 deletions.
  1. +6 −2 src/main/scala/scala/slick/direct/SlickBackend.scala
@@ -223,10 +223,14 @@ class SlickBackend( driver:BasicDriver, mapper:Mapper ) extends QueryableBackend
// Tuples
case Apply(
Select(Select(Ident(package_), class_), method_),
op,
components
)
if package_.decoded == "scala" && class_.decoded.startsWith("Tuple") && method_.decoded == "apply" // FIXME: match smarter than matching strings
if definitions
.TupleClass
.filter(_ != NoSymbol)
.map( _.companionSymbol.typeSignature.member( newTermName("apply") ) )
.contains( op.symbol )
=>
sq.ProductNode( components.map(s2sq(_).node) )

0 comments on commit 942d33e

Please sign in to comment.