The primary reason for not using a parser generator is the grammar for a
JSP page is context sensitive, and highly ambiguous, so its parsing does
not fit the model used in parsing of conventional languages.  Also, the
grammar is relative simple, once you get past the attributes, so using a
custom parser is actually easier and more flexible.

As you'll see when I put back the sources, I tried to write down the
grammar for a JSP page, just to put the parser on a more vigorous basis,
but there are still cases where the context sensitivity interfere with
normal parsing (e.g. the recognition of custom tags).  It is much easier
for a custom parser to just handle them as special cases.


> Date: Tue, 26 Mar 2002 08:17:12 -0600
> From: Bob Lee <[EMAIL PROTECTED]>
> Subject: Re: [PLAN] New Jasper
> To: Tomcat Developers List <[EMAIL PROTECTED]>, 'Kin-Man Chung' 
<[EMAIL PROTECTED]>
> MIME-version: 1.0
> X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
> Content-transfer-encoding: 7bit
> X-Priority: 3
> X-MSMail-priority: Normal
> Delivered-to: mailing list [EMAIL PROTECTED]
> Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm
> X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N
> List-Post: <mailto:[EMAIL PROTECTED]>
> List-Subscribe: <mailto:[EMAIL PROTECTED]>
> List-Unsubscribe: <mailto:[EMAIL PROTECTED]>
> List-Help: <mailto:[EMAIL PROTECTED]>
> List-Id: "Tomcat Developers List" <tomcat-dev.jakarta.apache.org>
> 
> Possibly very stupid question...
> 
> Is there any reason not to use JavaCC on the JSP compiler? I know the
> grammar is pretty nasty, but that doesn't make a custom solution any easier
> either.
> 
> Bob
> 
> 
> ----- Original Message -----
> From: "Ignacio J. Ortega" <[EMAIL PROTECTED]>
> To: "'Tomcat Developers List'" <[EMAIL PROTECTED]>; "'Kin-Man
> Chung'" <[EMAIL PROTECTED]>
> Sent: Tuesday, March 26, 2002 8:04 AM
> Subject: RE: [PLAN] New Jasper
> 
> 
> > > De: Kin-Man Chung [mailto:[EMAIL PROTECTED]]
> > > Enviado el: martes 26 de marzo de 2002 1:13
> >
> > > Thanks for the pointer.  I'll look at both places to see if there are
> > > codes/ideas I can borrow.
> >
> > My comment was more geared toward the use of this repository, than to
> > reuse the code there, i think is cleanest to build Jasper2 in his own
> > repo.., Well and if you can borrow some of the code there, much better.
> > :))
> >
> >
> > Saludos ,
> > Ignacio J. Ortega
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> >
> >
> 
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
> 


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to