Skip to content

Avoid overflow#210

Merged
lemire merged 3 commits intomasterfrom
avoid_overflow
Oct 26, 2025
Merged

Avoid overflow#210
lemire merged 3 commits intomasterfrom
avoid_overflow

Conversation

@lemire
Copy link
Copy Markdown
Member

@lemire lemire commented Oct 26, 2025

fixes #209

@lemire lemire requested a review from Copilot October 26, 2025 15:34
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR addresses an integer overflow issue in the bitset library on 32-bit architectures by reducing a test index value and adding a CI workflow to test on 32-bit systems.

  • Reduced test index from 6346235235 to 63235235 to avoid overflow on 32-bit systems
  • Added GitHub Actions workflow for testing on 386 architecture

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
bitset_test.go Reduces test index value to prevent overflow on 32-bit systems
.github/workflows/legacy86.go Adds CI workflow for testing on 386 architecture

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +8 to +16
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
- name: Test on 386
run: |
GOARCH=386 go test No newline at end of file
Copy link

Copilot AI Oct 26, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow is missing the 'steps:' keyword before the step definitions, and the 'strategy.matrix' configuration for the go-version variable referenced on line 11. The workflow should include 'steps:' at line 7 and a strategy matrix defining go-version values.

Suggested change
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
- name: Test on 386
run: |
GOARCH=386 go test
strategy:
matrix:
go-version: [ '1.20.x', '1.21.x' ]
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v4
- name: Test on 386
run: |
GOARCH=386 go test

Copilot uses AI. Check for mistakes.
@lemire lemire merged commit d02158d into master Oct 26, 2025
54 checks passed
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.

Test failure on i386

2 participants