• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Greg Guerin <email@hidden>
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Greg Guerin <email@hidden>


  • Subject: Re: Greg Guerin <email@hidden>
  • From: Bill Monk <email@hidden>
  • Date: Sun, 18 Jun 2006 09:59:33 -0500


On Jun 17, 2006, at 9:32 AM, email@hidden wrote:

If <fp.h> is being included, I suggest a simple test:
  if ( pi != M_PI )
    printf( "Well, isn't that interesting." );
  if ( pi/2.0 != M_PI_2 )
    printf( "Approximately half as interesting." );

Nothing printed, so pi == M_PI and pi/2.0 == M_PI_2. (<fp.h> and <math.h> both included via <Carbon/Carbon.h>; using -llibm compiler flag)


More ideas for simple tests.  Print the values of:

  M_PI - pi
  M_PI_2 - pi/2.0
  M_PI_2 - acos( 0.0 )
  M_PI_2 - asin( 1.0 )
  cos( acos( 0 ) )

0.00000000000000000000 0.00000000000000000000 0.00000000000000000000 0.00000000000000000000 0.00000000000000006123

Interesting. :)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: How to make a dictionary for Dictionary.app
  • Next by Date: Re: Is there a warning for "Called function with no prototype"?
  • Previous by thread: How to make a dictionary for Dictionary.app
  • Next by thread: define GCC_PREFIX_FILE setting at project level?
  • Index(es):
    • Date
    • Thread