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

Languages patterns update #130

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

bogdancondorachi
Copy link
Contributor

@bogdancondorachi bogdancondorachi commented May 28, 2024

This is a series of language updates based on #123 where new tokens have been introduced which lets us add new patterns for numeric and logical values.

Currently as a draft where I'll update it with all the changes as they are added

JSON

  • Added comment pattern (not valid but helpful in terms of code documentation)
  • Added literal pattern (true|false|null)
  • Added operator pattern (:)
  • Added numeric pattern ("age": 30)

YAML

  • Added date/time pattern (date: 2024-05-31)
  • Added literal pattern (true|false|yes|no|null)
  • Added numeric pattern (age: 28)

@coveralls
Copy link

coveralls commented May 28, 2024

Pull Request Test Coverage Report for Build 9279665034

Details

  • 18 of 21 (85.71%) changed or added relevant lines in 9 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.1%) to 95.203%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/Languages/Json/Patterns/JsonCommentPattern.php 1 2 50.0%
src/Languages/Json/Patterns/JsonLiteralPattern.php 1 2 50.0%
src/Languages/Json/Patterns/JsonNumberPattern.php 1 2 50.0%
Totals Coverage Status
Change from base Build 9266627087: -0.1%
Covered Lines: 1568
Relevant Lines: 1647

💛 - Coveralls

@bogdancondorachi bogdancondorachi changed the title Languages improvements based on #123 Languages numeric/logical patterns May 28, 2024
bogdancondorachi added a commit to bogdancondorachi/highlight that referenced this pull request May 29, 2024
@bogdancondorachi bogdancondorachi changed the title Languages numeric/logical patterns Languages patterns update May 29, 2024
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