comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@merv.cs.nyu.edu (Robert Dewar)
Subject: Re: REQ: Expression parser
Date: 1998/01/22
Date: 1998-01-22T00:00:00+00:00	[thread overview]
Message-ID: <dewar.885449293@merv> (raw)
In-Reply-To: 34C6BC92.62F1@friko2.onet.pl


dagoon asks

<<Hello, I just started coding in ada, so I have problems, esp. with string
handling since it's much different from C or pascal style... I'd love to
see an example of expression parser (like getting "2+2" string and giving
integer=4). I also know that string in ada is saved as (first,last,*text)
but I don't know if there's any simply method of changing first and last.
thanks for any help, regards
>>

Have a look at Ada.Strings.Unbounded, and no a string in Ada is not
"saved as first,last,*text", it is a more abstract object as you
will see from this specification.

If you want to see some extensive examples of the use of this abstraction,
have a look at the coding of GNAT.Spitbol.Patterns in the GNAT library.





      parent reply	other threads:[~1998-01-22  0:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-01-21  0:00 REQ: Expression parser dagoon
1998-01-21  0:00 ` Dale Stanbrough
1998-01-22  0:00 ` Robert Dewar [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox