top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How can we rename a function in c?

+1 vote
586 views
How can we rename a function in c?
posted Nov 3, 2014 by Akriti

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

2 Answers

0 votes

Its simple, as per what I understand.

1. Open your .c file 
2. goto the function which you want to rename,
3. rename it with the new name,
4. replace the new name, where ever this fucntion previously called.
answer Nov 4, 2014 by Arshad Khan
0 votes

Agree with Arshad, not sure what is the meaning of change the name of function but if you are looking a function to be identified with two names then try typedef.

answer Nov 4, 2014 by Salil Agrawal
Similar Questions
0 votes

Used the sizeof of function, which gives 1; why?
I want to know the size of the entire function. How to achive it?

#include <stdio.h>
void (*p)(int); 
void test_func(int data)
{
  printf("%d\n",data);
}

main(void)
{
    p = test_func;
    (*p)(4);
    printf("%d",sizeof(test_func));
}
+1 vote

Can someone help me with the example when to use normal function calling and when pointer function calling. What was the reason for introducing pointer function calling in C?

...