|
-
December 30th, 2010, 05:21 AM
#3
Re: Order of multiplication matters?
an invalid type argument for unary * exception
The star is used for two purposes in C:
- a multliplication of two numbers (a binary *)
- a reference to the content pointed by an address (a unary *)
Here, it seems the compiler is considering that the star is used for the second purpose, for some reasons I dont know until I can see the code (my guess is that there is a ";" at the end of #define PI ..., and this is not important if PI is used at the end of the formula, but it matters if PI is used before the end).
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|