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

conditional compilation of gcd(SomeInteger,SomeInteger) in std/math #23773

Merged
merged 7 commits into from
Jul 9, 2024

Conversation

quimt
Copy link
Contributor

@quimt quimt commented Jun 29, 2024

The most specific version of gcd(int,int) in std/math uses bitwise comparisons from C compilers, which can't be borrowed on the js platform in the web browser. Conditional compilation here should fix the issue for this and downstream libraries such as std/rationals when compiling to browser js as the backend.

most specific version of gcd(int,int) uses bitwise comparisons that are not available in non-node js. Conditional compliation should fix the issue here and in other downstream libraries like std/rationals
conditional compilation of gcd(SomeInteger, SomeInteger) in std/math
lib/pure/math.nim Outdated Show resolved Hide resolved
@Araq Araq added the merge_when_passes_CI mergeable once green label Jul 8, 2024
@narimiran narimiran merged commit 96c1653 into nim-lang:devel Jul 9, 2024
18 checks passed
Copy link
Contributor

github-actions bot commented Jul 9, 2024

Thanks for your hard work on this PR!
The lines below are statistics of the Nim compiler built from 96c1653

Hint: mm: orc; opt: speed; options: -d:release
173182 lines; 8.016s; 664.113MiB peakmem

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

Successfully merging this pull request may close these issues.

None yet

3 participants