> One potential problem is that if the value is large/small enough to make
> float8out use 'E' notation, conversion to numeric will still fail ---
> this is the same problem you hacked around in float8_numeric() earlier.
Yup. But in the long run, that is a problem for numeric(), not float8.
If nothing else, numeric() should be willing to flag cases where it
has trouble, and it doesn't seem to do that. That should probably be
considered a "must fix" for v6.5.
> I still like the idea of hanging on to the original string form of the
> constant long enough so that parser_typecast can feed that directly to
> the target type's xxx_in() routine, and not have to worry about
> conversion errors.
I agree. I'm just worried about losing the typing hints provided by
scan.l if we went to a "string only" solution. Also, there might be a
performance hit if we ended up having to do the string conversion too
many times.
At this late date, I'm (so far) happy doing the kinds of fixes we've
done, but we should revisit the issue for v6.5.x...
- Thomas
--
Thomas Lockhart lockhart@alumni.caltech.edu
South Pasadena, California