Probably because here you've fixed the type of the list to Long,
whereas before it was List[Int] since you didn't specify L, e.g.
instead of
val venues = Venue.findAll(ByList(Venue.id, List(1, 2, 3))) // -- List
[Int] by default
try
val venues = Venue.findAll(ByList(Venue.id, List(1L, 2L, 3L))) // --
now a List[Long], may do what you want
or
val venues = Venue.findAll(ByList(Venue.id, List[Long](1, 2, 3)))
It (scalac) should probably be able to infer that vals (the second
argument to ByList) must a List[Long] based on field (the first
argument) being MappedField[Long, Venue], but I guess it is not.
Scala's type inferencer seems to in general be best attempt,
especially in the face of implicits :-/
-Ross
On Sep 15, 2009, at 2:18 PM, harryh wrote:
Though strangely enough, this compiles fine:
val ids: List[Long] = List(1,2,3)
val venues = Venue.findAll(ByList(Venue.id, ids)
Weird!
-harryh
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Lift group.
To post to this group, send email to liftweb@googlegroups.com
To unsubscribe from this group, send email to
liftweb+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/liftweb?hl=en
-~--~~~~--~~--~--~---