Hi Every Body
I am new born in C++ I am facing and error for last 3 days I tried my best with all what I knew but FAILED.....
Error is -
" Linker Error: Undefined Symbol Library::code in module PRGDONE.CPP"
I am using Turbo C++ 3.0 of Borland
Welcome to Daniweb and Also to C++, Firstly Please Use CODE TAGS the next time you post in your question,
Firstly I see that you are Using a outdated compiler. Though it is not il-legal to use it . It is considered better if you use a modern compiler like CODE::BLOCKs etc.
Next Would you also specify at which line do you get that error, so it will be much easier to figure it out.
Thank you for your reply its exactly not compilation error. Error is coming while running the program after compilation
" Linker Error: Undefined Symbol Library::code in module PRGDONE.CPP"
Line Number is not mentioned in error, but when I comment the line - library::work(); in main function then I get Success message
Dear Dragon
Thank you very very much for helping mebut now I am 3 compilation warings are coming on line no 14, 40, 63 errors are -
Functions containing while are not expanded inline
Functions containing switch are not expanded inline
Functions containing while are not expanded inline
respectively .
I will be thankfull to you for your kind cooperation
In above example f1 is inline while f2 is not.
In general, a inline function cannot contain loops or switch statements. Hence your compiler is making that warning.
Note that the style of your coding is 15 year old and is deprecated( I call such code as "rusted"). Sky Diploma is right in giving you advice to use a modern compiler ( I bet you would be using something as crappy as Turbo C++).
Please read this and migrate to standard.
Inlining is optional for compilers -- they may choose to honor it or not. Most compilers will honor one or two line inline functions, but the ones you posted are probably just too large to make inlining practical. IMO its better to put the implementation code for large functions in the *.cpp file instead of attempting to inline them.
Firstly I see that you are Using a outdated compiler. Though it is not il-legal to use it . It is considered better if you use a modern compiler like CODE::BLOCKs etc.
I normally wont go into small errors in other peoples posting,
but it should be noted that code::blocks is an ide.
The compiler is most likely(depending on the setup) the mingw compiler. The mingw is a subset of the gnu toolchain.
I dont like being a correction nazi,
but the difference between compiler and ide/editor is quite important.
cheers!
To the original poster.
Is it nescesarry to use static variables for you program?
Last edited by monkey_king; Jun 17th, 2009 at 11:05 pm.
No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.