Skip to content

feat: word operators#22

Merged
mosteo merged 5 commits intomasterfrom
feat/word-operators
Jan 16, 2026
Merged

feat: word operators#22
mosteo merged 5 commits intomasterfrom
feat/word-operators

Conversation

@mosteo
Copy link
Member

@mosteo mosteo commented Jan 16, 2026

Fixes #16

@mosteo mosteo marked this pull request as ready for review January 16, 2026 17:27
Copilot AI review requested due to automatic review settings January 16, 2026 17:27
Copy link
Contributor

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 adds support for word operators (and, or, not) as more readable alternatives to the existing symbolic operators (&, |, !) in semantic version expressions. The implementation includes case-insensitive keyword recognition, proper word boundary detection, and comprehensive test coverage.

Changes:

  • Added keyword detection for and, or, and not operators with case-insensitive matching and word boundary validation
  • Updated error messages to reference word operators for better user experience
  • Added comprehensive test coverage for word operators, precedence rules, and mixed operator usage
  • Updated grammar documentation to reflect the new operator alternatives

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/semantic_versioning-extended.adb Implements Is_Keyword function for keyword detection and Match_Token procedure to handle both word and symbol operators
tests/src/semver_tests-word_operators.adb New test file covering basic word operator functionality, case insensitivity, and error cases
tests/src/semver_tests-precedences.adb New test file verifying operator precedence and mixing word/symbol operators
tests/src/semver_tests-extended_expressions.adb Adds integration tests for word operators in complex expressions
grammar.txt Updates grammar documentation to show word operators as alternatives to symbols
.github/workflows/test.yml Updates CI runners to newer versions (unrelated infrastructure improvement)

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

Copy link
Contributor

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

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.


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

@mosteo mosteo merged commit 651513c into master Jan 16, 2026
11 checks passed
@mosteo mosteo deleted the feat/word-operators branch January 16, 2026 18:07
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.

Accept or/and/not as fully written operators

1 participant