android - 指向 stdio FILE 的指针出现编译器错误

标签 android c android-ndk

android NDK 正在提示这一点:

#include <stdio.h>
int fileno (FILE *stream); //line 27 io.h

它说:

jni/application/io.h:27:5: error: expected ')' before '*' token
jni/application/io.h:27:5: error: expected ')' before '->' token

我会理解 FILE 是否是某个宏,但事实并非如此,它只是来自 stdio 的宏。

如果我取出*stream我得到:

int fileno (FILE);
jni/application/io.h:27:5: error: expected ')' before '->' token

我无法理解它从哪里获取 -> token 。

最佳答案

等等,我明白了,filenostdio.h 中的宏

因此扩展到:

int ((FILE* stream)->_file);

关于android - 指向 stdio FILE 的指针出现编译器错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12329441/

相关文章:

python - 是否有用于 Unicode 空白的 Python 常量?

android - 如何在 Windows 操作系统上安装 Android NDK?没有任何 Unix Linux 的简单方法?

java - 通过 Intent 将 cookie 传递给浏览器

android - 如何在代码中将小部件添加到主屏幕

android - 建立phonegap 1.7。应用程序

C:避免频繁类型转换的高性能临时变量

Android:将 ImageView 设置到我的相对布局的底部

c - GCC 的 __builtin_expect 在 if else 语句中的优势是什么?

android - 如何在android项目中安装openssl.so和libssl.so?

java - Android NDK 是否为通过套接字发送大 int[] 提供加速?