Why do C++ compilers need name mangling?
Answers were Sorted based on User's Feedback
Answer / guest
Name mangling is the rule according to which C++ changes
function's name into function signature before passing that
function to a linker. This is how the linker differentiates
between different functions with the same name.
Is This Answer Correct ? | 7 Yes | 1 No |
Answer / siva
Compilers need name mangling to support/implement function
overloading.
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / achal ubbott
It is by name mangling that a c++ compiler is able to
support function overloading.It is the way of
differentiating functions based on their name,number and
order and type of parameters. Unfortunately ISO has not set
any standard procedure for mangling names. So different c++
compiler vendors implement it in different ways.
Is This Answer Correct ? | 2 Yes | 0 No |
Is c++ pass by reference or value?
What is code reusability in c++?
Describe the setting up of my member functions to avoid overriding by the derived class?
Describe the role of the c++ in the tradeoff of safety vs. Usability?
Which is not an ANSII C++ function a) sin() b) tmpnam() c) kbhit()
When is a template better solution than a base class??
What are vtable and vptr?
Can we use resume in error handling i.e. in the catch block
What is the return value of the insertion operator?
what is the behaviour of C and C++ compiler for the below statements. int *p; p = malloc(100); Is the behaviour same ? or different ?
Why c++ is so important?
What is general form of pure virtual function? Explain?