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

Replace '__gmp_const' with 'const' #4

Merged
merged 1 commit into from
Apr 18, 2013

Conversation

caltry
Copy link
Contributor

@caltry caltry commented Apr 17, 2013

The __gmp_const macro was added to GMP as a workaround for C compilers
which didn't support the const keyword. GMP 5.1 removed support for
pre-ANSI C compilers, so the __gmp_const workaround was removed at the
same time.

This change replaces all uses of '__gmp_const' with uses of the 'const'
keyword directly, since MLton already expects C99 support from the system
C compiler.

This should fix the build errors for systems using GMP >= 5.1, as reported in #3.

Tested on amd64-freebsd (with GMP 5.1.1) and x86-linux (with GMP 5.0.2).

The __gmp_const macro was added to GMP as a workaround for C compilers
which didn't support the const keyword.  GMP 5.1 removed support for
pre-ANSI C compilers, so the __gmp_const workaround was removed at the
same time.

This change replaces all uses of '__gmp_const' with uses of the 'const'
keword directly, since MLton already expects C99 support from the system
C compiler.

This should fix the build errors for systems using GMP >= 5.1.
MatthewFluet added a commit that referenced this pull request Apr 18, 2013
Replace '__gmp_const' with 'const'.

Fixes #3.
@MatthewFluet MatthewFluet merged commit 7c9c9d3 into MLton:master Apr 18, 2013
@caltry caltry deleted the remove-__gmp_const branch April 19, 2013 04:41
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

Successfully merging this pull request may close these issues.

2 participants