c - using extern with same parameter name inside function -


i have c code have global variable

main_prog.c

pld po; int main(){} 

i have function in definition

functiondef.c

void function(pld po) {   extern po; } 

what problem how compiler know using extern po or parameter po??

you can access extern variable if declare in different scope.

void function(pld po) {      {         extern pld po;    //this po declared in main     } } 

Comments

Popular posts from this blog

css - I want to align grid in center -

Contact Form PHP Email Script -

python - SWIG function not printing output -