Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Contributions to C::B => Topic started by: X1pit on September 14, 2011, 05:35:40 pm

Title: Help with redefinitions
Post by: X1pit on September 14, 2011, 05:35:40 pm
Hey Guys!
I'm really embarressed about my prob but i need help :D
You might imagie my program:
main.cpp is like "#include "file.c" [..mainloop stuff..]"
file.c is like "#include <somelibs> void f(void){}"
When file.c is added to the project it doesn't work because "redefinition of f". But when i don't add it to project it works. But it's simply p*ssing me off to open it all the time by hand.
Idea?
Title: Re: Help with redefinitions
Post by: oBFusCATed on September 14, 2011, 06:15:51 pm
Have you tried to learn what #include "some file" really does?
I guess you haven't.
Go read it in a book and then fix your problem yourself.

p.s. most of the time we don't help beginners learn how to program, this is not a generic c/c++ programming forum
p.p.s. you've known that if you've read the rules...
p.p.p.s. if you've read the rules you've know about one magic link (to our FAQ), which solves most of the problems :)
Title: Re: Help with redefinitions
Post by: Jenna on September 15, 2011, 12:53:27 pm
Unrelated to C::B and therfore violating our forum rules.

Topic locked !