Skip to content

Instantly share code, notes, and snippets.

@mloskot
Created May 16, 2012 14:32
Show Gist options
  • Select an option

  • Save mloskot/2710802 to your computer and use it in GitHub Desktop.

Select an option

Save mloskot/2710802 to your computer and use it in GitHub Desktop.
/* For NAN */
#ifdef __GNUC__
#define _GNU_SOURCE
#endif
#include <math.h>
@mloskot

mloskot commented May 16, 2012

Copy link
Copy Markdown
Author

Here is the IEEE-compatible way: https://gist.github.com/2711003

In fact, if you look at GCC code of NAN you can see similar NAN trick, but with slightly different pattern.

@springmeyer

Copy link
Copy Markdown

awesome, thanks!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment