Main.cc: In function 'int sum(int, int)':
Main.cc:7:12: warning: pointer to a function used in arithmetic [-Wpointer-arith]
sum+=i;
^
Main.cc:7:12: error: assignment of function 'int sum(int, int)'
Main.cc:7:12: error: cannot convert 'int (*)(int, int)' to 'int(int, int)' in assignment
Main.cc:9:1: warning: no return statement in function returning non-void [-Wreturn-type]
}
^