Ben Fritz wrote:
> On Friday, February 26, 2016 at 11:04:56 AM UTC-6, Bram Moolenaar wrote:
> > Ozaki Kiichi wrote:
> >
> > > Some vim codes use C99 features;
> >
> > We aim at ANSI C, but some things may be optional.
> >
> > > * json.c: isinf(), NAN, INFINITY
> >
> > AFAIK isinf() is ANSI C.
> >
> > It appears INFINITY was first officially standardized in C99, but it
> > existed much longer before that. Not sure what else to use when
> > INFINITY is not available.
> >
> > NAN is not even in C99, it appears. Again, not sure what to do if it's
> > not available.
>
> Both of these just bit me, trying to compile with a really old
> compiler I'm stuck with on a Solaris server at work (gcc 2.95.2).
>
> I got around it by removing the Windows checks from the re-definitions
> (see patch). Why do we limit this to Windows anyway?
I'm very surprised you have _isnan() and _finite(). I thought these are
a WIN32 thing. The same check for isnan() is in eval.c.
For INFINITY and NAN we can make it more generic.
isnan(x) can be changed to "x != x".
I don't know an alternative for isinf() though.
What exactly is missing on that system?
Perhaps someone can make a configure check for this stuff.
--
Citizens are not allowed to attend a movie house or theater nor ride in a
public streetcar within at least four hours after eating garlic.
[real standing law in Indiana, United States of America]
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.