Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compiler error #36

Open
hy05190134 opened this issue Jan 29, 2015 · 4 comments
Open

compiler error #36

hy05190134 opened this issue Jan 29, 2015 · 4 comments

Comments

@hy05190134
Copy link

In macos system, the file in system's default path also define stack_t structure.

In file included from ../cstl/cstack.h:35:
../cstl/cstl_stack_private.h:45:2: error: typedef redefinition with different types ('struct _tagstack'
vs 'struct __darwin_sigaltstack')
}stack_t;
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/sys/_types/_sigaltstack.h:42:29: note:
previous definition is here
typedef _STRUCT_SIGALTSTACK stack_t;

@activesys
Copy link
Owner

在苹果系统上确实有重定义的现象。

@hy05190134
Copy link
Author

这个倒好解决,我每次修改下系统头文件即可,不过我还有个棘手的问题,就是typedef uint64_t 这样的类型,好像直接用uint64_t 是有问题的,也就是关于typedef的类型该怎么处理的问题?

@activesys
Copy link
Owner

type_register(uint64_t);

@activesys
Copy link
Owner

uint64_t这样的类型将在libcstl-2.4版本中默认支持。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants