You're right about that. You probably wouldn't get very far without
understanding that. I'm still concerned that I have to type
unnecessary stuff to express myself without getting any gains in (new
Link("a" :: "b" :: nil) vs Link("a", "b")) :D

- Vesa

On 2 marras, 22:27, Jim Barrows <jim.barr...@gmail.com> wrote:
> On Mon, Nov 2, 2009 at 1:15 PM, Vesa <brut...@gmail.com> wrote:
>
> > Hi,
>
> > I was wondering few thing while reading lift examples. Could the Link
> > class be turned into a case class so reading would improve? new Link
> > ("a" :: "b" :: nil, false) could be RecursiveLink("a", "b") and new
> > Link("a" :: "b" :: Nil) could be something like AbsoluteLink("a",
> > "b"). This would at least eliminate the need to explain scala's list
>
> Shouldn't the reader already be aware of Scala's list construction, since
> that is in fact the language we're using?
> If you think Scala's list construction is difficult to for a new reader, I
> think explaining a case class would be even more confusing.
>
> You might want to look at how case classes differ from a normal
> class<http://www.scala-lang.org/node/258>as well.
>
>  construction syntax to the reader. I found out extremely unintuitive
>
> > the syntax to create Links with dsl like ("help" :: "" :: Nil) ->
> > true. This syntax is usually associated with generation of key-value
> > pairs even in lift APIs and creates confusion (at least on my case). I
> > guess varargs might be out of question if scala backward compatibility
> > is considered, but I don't see a reason not to use case classes here.
>
> > - Vesa
>
> --
> James A Barrows
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to