Highlighted KEYWORDs question

Hi guys, I'm writing a small continuous-rotation-servo control sketch, and it seems that every name that I come up with for my variables and functions is already in use, because they are highlighted as soon as I type them. This even happens with no included libraries.

e.g. move, direction, speed

If I use these names for my functions, or for variable names, is there likely to be a problem?
I could rename my funcs and vars to smove, sdirection, sspeed etc, but was just wondering.

I tried searching for where "move" might be defined, but had no luck, except I saw references to it in mouse control. ie mouse.move()

Does Arduino possibly search all installed libraries for keywords, whether or not they're currently included?

The IDE checks for keywords from all installed libraries regardless of whether they are included in the current sketch or not. It can be a bit annoying especially when you're used to something like eclipse that highlights only inclded functions and highlights them all without any extra list or file.

You have all of the source code for everything. You can open up the files and see what is defined where.

I have a "direction" variable in a sketch I'm working on right now. It lights up in the IDE. I ignore it. I think it only matters if you need to use the functions that the IDE recognizes, in the specific scope.

Out of curiosity, what is the "direction" that the IDE recognizes?

Delta_G:
The IDE checks for keywords from all installed libraries regardless of whether they are included in the current sketch or not. It can be a bit annoying especially when you're used to something like eclipse that highlights only inclded functions and highlights them all without any extra list or file.

You have all of the source code for everything. You can open up the files and see what is defined where.

I suspected that was the case. So I should still be able to use these names without conflicts, then, as long as I don't use the ones from the libraries I've actually included.

I knew that they were defined in some libs that I'm not including, but thought they might possibly be defined elsewhere and just not listed in the Arduino "Reference".

jboyton:
I have a “direction” variable in a sketch I’m working on right now. It lights up in the IDE. I ignore it. I think it only matters if you need to use the functions that the IDE recognizes, in the specific scope.

Out of curiosity, what is the “direction” that the IDE recognizes?

Well it’s definitely not in ‘Servo.h’. I have it open in front of me. First place I looked for ‘move’.

there are files named keywords.txt that defines the words to highlight for the libraries.

Thanks, Rob.

The stepper library is where "direction" is defined as a keyword. If you rename that keywords.txt or nuke it then direction won't be lit up anymore.

The keyword "altitude" was another one in my sketch. That one was defined in TinyGPS. It doesn't seem to matter that neither the stepper nor the TinyGPS libraries are included; just the fact that they are in the IDE or library folder is enough.

A minor annoyance... and a feature too. You could light up your own keywords if that made you happy.

robtillaart:
there are files named keywords.txt that defines the words to highlight for the libraries.

Yes, I know. I've written a couple of libraries myself.

jboyton:
Thanks, Rob.

The stepper library is where "direction" is defined as a keyword. If you rename that keywords.txt or nuke it then direction won't be lit up anymore.

The keyword "altitude" was another one in my sketch. That one was defined in TinyGPS. It doesn't seem to matter that neither the stepper nor the TinyGPS libraries are included; just the fact that they are in the IDE or library folder is enough.

A minor annoyance... and a feature too. You could light up your own keywords if that made you happy.

I'm not really worried whether or not they're highlighted. I was just concerned that there might be conflicts if I used them.
Since posting my original question I've finished writing this sketch and it works fine, so no problems.

Thanks everyone for the answers. Much appreciated

The compiler would let you know if there were a conflict.

jboyton:
The compiler would let you know if there were a conflict.

Thanks. I wasn't sure if it would pick that sort of conflict up, but on reflection I guess I'd get an 'already defined' type of error.