Is there a way to give default values to parameters of a function in gcc (in djgpp)?
void fnc(int a, int b=0); <<--??
fnc(10); = fnc(10, 0);
fnc(20, 15);
default value for parameters in gcc
Re:default value for parameters in gcc
Code: Select all
void func(int a,int b=0)
{
//functions definition (functions code)
}
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:default value for parameters in gcc
this is a c++ only feature, isn't it ?