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

parser: Sort keywords #48851

Merged
merged 4 commits into from
Dec 2, 2023
Merged

parser: Sort keywords #48851

merged 4 commits into from
Dec 2, 2023

Conversation

dveeden
Copy link
Contributor

@dveeden dveeden commented Nov 23, 2023

What problem does this PR solve?

Issue Number: close #48850

Problem Summary:

What changed and how does it work?

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. do-not-merge/needs-tests-checked size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Nov 23, 2023
Copy link

tiprow bot commented Nov 23, 2023

Hi @dveeden. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link

codecov bot commented Nov 23, 2023

Codecov Report

Merging #48851 (8d197f5) into master (f39e9bf) will increase coverage by 1.5516%.
Report is 30 commits behind head on master.
The diff coverage is n/a.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #48851        +/-   ##
================================================
+ Coverage   70.9922%   72.5439%   +1.5516%     
================================================
  Files          1368       1391        +23     
  Lines        403975     416545     +12570     
================================================
+ Hits         286791     302178     +15387     
+ Misses        97214      95378      -1836     
+ Partials      19970      18989       -981     
Flag Coverage Δ
integration 43.7022% <ø> (?)
unit 71.0054% <ø> (+0.0131%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 53.9663% <ø> (ø)
parser ∅ <ø> (∅)
br 48.2364% <ø> (-4.7358%) ⬇️

@dveeden
Copy link
Contributor Author

dveeden commented Nov 23, 2023

Tested withTestKeywordsSorting in #48801

func TestKeywordsSorting(t *testing.T) {
	for i, kw := range parser.Keywords {
		if i > 1 && parser.Keywords[i-1].Word > kw.Word && parser.Keywords[i-1].Reserved == kw.Reserved {
			t.Errorf("%s should come after %s, please update parser.y and re-generate keywords.go\n",
				parser.Keywords[i-1].Word, kw.Word)
		}
	}
}

@ti-chi-bot ti-chi-bot bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Nov 23, 2023
@dveeden
Copy link
Contributor Author

dveeden commented Nov 23, 2023

/retest

Copy link

tiprow bot commented Nov 23, 2023

@dveeden: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@dveeden
Copy link
Contributor Author

dveeden commented Nov 23, 2023

/ok-to-test

@ti-chi-bot ti-chi-bot bot added the ok-to-test Indicates a PR is ready to be tested. label Nov 23, 2023
@dveeden dveeden mentioned this pull request Nov 23, 2023
16 tasks
@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Nov 23, 2023
Copy link
Contributor

@mjonss mjonss left a comment

Choose a reason for hiding this comment

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

LGTM, just one question about consistency with all upper case keywords.

pkg/parser/parser.y Show resolved Hide resolved
@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Nov 27, 2023
Copy link

ti-chi-bot bot commented Nov 27, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-11-23 17:01:13.427007266 +0000 UTC m=+510102.092233464: ☑️ agreed by tangenta.
  • 2023-11-27 14:25:17.970682581 +0000 UTC m=+846346.635908777: ☑️ agreed by mjonss.

@hawkingrei
Copy link
Member

@dveeden It needs @eason or @yudongusa‘s approve

Copy link
Member

@bb7133 bb7133 left a comment

Choose a reason for hiding this comment

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

LGTM

@easonn7
Copy link

easonn7 commented Dec 2, 2023

/approve

Copy link

ti-chi-bot bot commented Dec 2, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bb7133, easonn7, mjonss, tangenta

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added the approved label Dec 2, 2023
@ti-chi-bot ti-chi-bot bot merged commit a409acb into pingcap:master Dec 2, 2023
16 checks passed
@ti-chi-bot ti-chi-bot added the needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. label Jun 26, 2024
ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Jun 26, 2024
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.5: #54220.

@ti-chi-bot ti-chi-bot mentioned this pull request Jun 26, 2024
13 tasks
ti-chi-bot bot pushed a commit that referenced this pull request Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. ok-to-test Indicates a PR is ready to be tested. release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The keywords in parser.y are not sorted properly
8 participants