Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

difference between macro and function?

Answer Posted / utpal kumar kashyap

Hi to Everyone,
See, inline function is a function whose code get inserted instead of jump to the function where it was called.
We can make any function as inline but there are few conditions in which compiler will not treat it as inline function....
If
1. Function contains any static variable.
2. It recursive.
3. Function code is large.

However, if function body is large and in this case if we try to make it as inline, then compiler wont give an error, but compiler would treat it as normal function. So idea is this, function code should be small for making it inline.

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which one is better- macro or function?

1273


Specify some guidelines that should be followed while overloading operators?

1257


If dog is a friend of boy, and terrier derives from dog, is terrier a friend of boy?

1086


Is c++ pass by reference or value?

1119


Is swift faster than c++?

1070


What is set in c++?

1180


Which is the best c++ compiler for beginners?

1155


Describe private, protected and public – the differences and give examples.

1254


Which is most difficult programming language?

1168


Define 'std'.

1222


How do you clear a map in c++?

1182


What is an undefined reference/unresolved external symbol error and how do I fix it?

1164


Is c++ still in demand?

1200


What is the exit function in c++?

1024


Can we declare a base-class destructor as virtual?

1064