Skip to content

fix: fix incorrect format argument in CudaError::IndexOutOfBounds#1173

Open
letmehateu wants to merge 1 commit intolambdaclass:mainfrom
letmehateu:incorrect-argument
Open

fix: fix incorrect format argument in CudaError::IndexOutOfBounds#1173
letmehateu wants to merge 1 commit intolambdaclass:mainfrom
letmehateu:incorrect-argument

Conversation

@letmehateu
Copy link
Copy Markdown

Description

Fix IndexOutOfBounds error message using {0} (index) twice instead of {0} and {1}, so buffer length was never shown

Type of change

  • Bug fix

@letmehateu letmehateu requested a review from a team as a code owner February 12, 2026 23:23
@greptile-apps
Copy link
Copy Markdown

greptile-apps bot commented Feb 12, 2026

Greptile Overview

Greptile Summary

Fixed a format string bug in the IndexOutOfBounds error variant where both placeholders were set to {0}, causing the buffer length to never be displayed in the error message.

  • Corrected the format string from "Index out of bounds: {0}. Length of buffer is {0}" to "Index out of bounds: {0}. Length of buffer is {1}"
  • The error variant correctly takes two usize parameters (index and buffer length), and now both values will be properly displayed

Confidence Score: 5/5

  • This PR is safe to merge with no risk
  • This is a trivial one-character fix that corrects an obvious bug in a format string. The change is straightforward, has no side effects, and fixes a clear error where the buffer length parameter was not being displayed in error messages
  • No files require special attention

Important Files Changed

Filename Overview
crates/gpu/src/cuda/abstractions/errors.rs Fixed format string bug in IndexOutOfBounds error message - changed {0} to {1} for buffer length parameter

Last reviewed commit: 037df52

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.

1 participant