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

user interface - How to replace the Python logo in a Tkinter-based Python GUI app? -

objective c - Greedy NSProgressIndicator Allocation -

how to set an OCR language in Google Drive -