Skip to content

feat: allow zero slice using func#3

Open
lizard-boy wants to merge 1 commit intomainfrom
pr-293
Open

feat: allow zero slice using func#3
lizard-boy wants to merge 1 commit intomainfrom
pr-293

Conversation

@lizard-boy
Copy link
Collaborator

No description provided.

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR extends slice assertions in root_assertion_node.go by allowing function call expressions as valid endpoints, updating the low/high index checks in slice expressions.

  • Modified /assertion/function/assertiontree/root_assertion_node.go to detect CallExpr endpoints in slice bounds.
  • Added flags for low and high indices so that functions like len(x) can be used safely in slice expressions.
  • Ensured that the new logic aligns with nilability assertions without evaluating the function call values.
  • Verify usage of the custom logging module for error conditions during assertion processing.

💡 (3/5) Reply to the bot's comments like "Can you suggest a fix for this @greptileai?" or ask follow-up questions!

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

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