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

C INT_MAX not handled #204

Closed
russel opened this issue Sep 2, 2018 · 3 comments
Closed

C INT_MAX not handled #204

russel opened this issue Sep 2, 2018 · 3 comments

Comments

@russel
Copy link
Contributor

russel commented Sep 2, 2018

Using DStep v0.2.3-16-g1308991 compiled on Debian Sid with LDC 1.11.0 and LLVM 6.0, I generated a module for fontconfig.h (version 2.13.0). Sadly:

generated/fontconfig.d(257): Error: undefined identifier INT_MAX
generated/fontconfig.d(576): Error: undefined identifier stat_

I am not sure where the stat_ is creeping in. The generated D is:

FcCache* FcDirCacheLoadFile (const(FcChar8)* cache_file, stat_* file_stat);
@russel
Copy link
Contributor Author

russel commented Sep 2, 2018

I believe s/INT_MAX/int.max/ does the job for the first error.

ciechowoj added a commit to ciechowoj/dstep that referenced this issue Sep 29, 2018
@ciechowoj
Copy link
Contributor

There was a bug preventing dstep from including core.stdc.limits. Regarding stat_ the dstep was confused by the fact that stat library has two symbols with the same name struct stat and function stat, after translation struct is removed so there is ambiguity...

@jacob-carlborg
Copy link
Owner

The bindnings in druntime solves this by naming the type stat_t.

ciechowoj added a commit to ciechowoj/dstep that referenced this issue Sep 30, 2018
ciechowoj added a commit to ciechowoj/dstep that referenced this issue Oct 2, 2018
ciechowoj added a commit to ciechowoj/dstep that referenced this issue Oct 2, 2018
ciechowoj added a commit to ciechowoj/dstep that referenced this issue Oct 5, 2018
ciechowoj added a commit to ciechowoj/dstep that referenced this issue Dec 31, 2018
jacob-carlborg added a commit that referenced this issue Dec 31, 2018
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

3 participants