Jump to content
  • Advertisement
Sign in to follow this  
Nirav_Shah

Visual C++ 2005

This topic is 3738 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi all, I am facing strange problem in VC++ 2005.When I try to compile .cpp file which contains inline function declarations than linker is giving "Unresolved External symbol error" when i remove the inline keyword it works just fine. In fact i have tried it by taking small example in which it works just fine with even inline keyword in source file. But when i try to do same thing with my engine code than linker is complaining.Please help me to figure out the problem. Thanks.

Share this post


Link to post
Share on other sites
Advertisement
Thanks Portmanteau for quick response :). I know that inline function definition can be placed in header file But i want to maintain the function declaration and definition in seperate files hence i would like to place the definition in .inl file.so i am using the inline keyword in .inl file but linker complaining with this.

Share this post


Link to post
Share on other sites
If you want the function to be inline then the declaration / definition need to be in the same place. I dont think there is any way around this.

Share this post


Link to post
Share on other sites
You can place the definition in your .ini file if you want, just #include the .ini file at the bottom of the header file.

Basically take the exact code that would be in the header and place it in your .ini, and #include it right after the declarations.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!