# C++ function

• C/++/#

## Main Question or Discussion Point

I got the following error when I tried to compile some code:

Code:
error: angle_between' cannot be used as a function`
I changed the function name to "function1" and it compiled. Since when did C++ not like underscores in function names?

Related Programming and Computer Science News on Phys.org
mgb_phys
Homework Helper
The underscore isn't a problem ( although leading and trailing ones can cause issues)
Are you sure you haven't got a angle_between() typo somewhere ?

Can you post the line the compiler complains about?

Yeah, it "looks" fine. Maybe you should post the code and where the compiler cries.

Borek
Mentor
Grep your sources looking for angle_between, could be it was defined earlier as something else.