C语言高级指针话题—高级声明

  • int    f()                                返回值为int的函数;
  • int   f[3]                               int型数组;
  • int   **f()                              返回值为“int型指针的指针”的函数;
  • int   (*f)()                             返回值为int的函数指针;
  • int   (*f)[6]                           指向“int型数组”的指针;
  • int   *f()                               返回值为“int型指针”的函数;
  • int   **(*f[])()                        指向“返回值为int型指针的指针的函数”的指针的数组;
  • int   **f[6]                            int型指针的指针数组;
  • int   *(*f)[6]                          指向“int型指针数组”的指针;
  • int  *(*f())()                          返回值为“返回值为int的指针的函数指针”的函数;
  • int  (**(*f)())()                      返回值为“返回值为int的函数指针的指针”的函数指针;
  • int  (*(*f)())[6]                 返回值为“指向int型数组的指针”的函数指针;
  • int  *(*(*(*f)())[6])()              返回值为“指向'返回值为int型指针的函数指针'的数组的指针”的函数指针。

猜你喜欢

转载自blog.csdn.net/sinat_34653971/article/details/79969844