Pages: [1]   Go Down
Author Topic: The math function FLOOR is a reserve word without documentation.  (Read 1488 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I looked for the math function "floor" in the Language Reference and found none. when I started to write my own floor function, I found the word floor was already reserved. I.E. lights up amber colored. Does anyone know if a floor function exists in an undocumented state? If so where can I find info on it? Should I just write my own using another name?
Logged

Ontario
Offline Offline
God Member
*****
Karma: 20
Posts: 835
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It should be there as soon as you #include <math.h>

http://www.nongnu.org/avr-libc/user-manual/group__avr__math.html#ga0f0bf9ac2651b80846a9d9d89bd4cb85

The syntax colouring in the IDE is based on a rule-set that is not connected to the actual compiler and libc, so do not assume that the colour coding necessarily means that something is genuinely "reserved" or defined or otherwise has a specific meaning.  It's a guideline and convenience more than anything.
« Last Edit: March 15, 2011, 12:09:37 pm by gardner » Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks that clears it up. I should have checked the libraries.
Logged

Pages: [1]   Go Up
Jump to: