On Jun 24 08:39, Parv wrote:
> in message <20100624183407.ga49...@holstein.holy.cow>,
> wrote p...@pair.com thusly...
> >
> > #  Matches a number, either positive (without '+' sign) or
> > #  negative, which is either a whole number; or a real number
> > #  ending with decimal point, or a real number with or without
> > #  leading digits before the decimal point.
> .                 ^
> .                 ^  plural
> > ^
> > -?
> > (
> >   [0-9]  [.]? [0-9]*
> >     |
> >   [0-9]? [.]  [0-9]+
> .        ^
> .        ^  oops
> 
> Please change the immediately above regex portion to ...
> 
>   [0-9]* [.]  [0-9]+
> 
> 
>   - parv

We still need to be able to handle numbers without a decimal.  Try this:

        [0-9]*\.?[0-9]+

The question mark says "0 or 1"
> 
> > )
> > $
> 
> -- 
> 
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"

-- 
Sterling (Chip) Camden
http://camdensoftware.com | http://chipstips.com | http://chipsquips.com
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"

Reply via email to