What is the difference between inline functions and macros?

Answer Posted / glibwaresoftsolutions

1. Macros: Text substitution; no type checking.
2. Inline functions: Replaced at runtime; provide type checking and debugging benefits.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do pointers work?

919


Is c++ faster than c?

779


Where are setjmp and longjmp used in c++?

831


What do you mean by const correctness?

824


What is enum class in c++?

931


What is called array?

803


Explain what is class definition in c++ ?

798


Describe new operator and delete operator?

832


What are the important differences between c++ and java?

828


What is a down cast?

827


What is binary object model?

765


How do you master coding?

801


What is c++ namespace?

935


Evaluate as true or false: !(1 &&0 || !1) a) True b) False c) Invalid statement

839


Why do we use using namespace std in c++?

801