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

input-validate: add CATEGORIES make variable #3793

Merged
merged 2 commits into from
Aug 12, 2023

Conversation

hirooih
Copy link
Contributor

@hirooih hirooih commented Aug 12, 2023

This PR lets validate-input make target support the CATEGORIES variable as units make target does.

Some minor fixes of input validation are also included.

Signed-off-by: Hiroo HAYASHI <24754036+hirooih@users.noreply.github.com>
- use the real name of the category of simple-json.d.

- add description about NONE in a validator file.

Signed-off-by: Hiroo HAYASHI <24754036+hirooih@users.noreply.github.com>
@hirooih hirooih requested a review from masatake August 12, 2023 08:28
@codecov
Copy link

codecov bot commented Aug 12, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (a423dce) 83.04% compared to head (f2f0703) 83.04%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3793   +/-   ##
=======================================
  Coverage   83.04%   83.04%           
=======================================
  Files         227      227           
  Lines       55203    55203           
=======================================
  Hits        45843    45843           
  Misses       9360     9360           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hirooih hirooih merged commit ce46d93 into universal-ctags:master Aug 12, 2023
39 checks passed
@hirooih hirooih deleted the validate-input-category branch August 12, 2023 11:52
@hirooih
Copy link
Contributor Author

hirooih commented Aug 12, 2023

@masatake san,

Thank you for your approval.

BTW I have a question after reading the section, Input validation for Units.

With VALIDATORS variable passed via command-line, you can specify validators to run. Multiple validators can be specified using a comma-separated list. If you don’t give VALIDATORS, the make target tries to use all available validators.

What is a use-case of the VALIDATORS variable?
make validate-input works fine. On what situation this variable is needed?

@masatake
Copy link
Member

@hirooih As you implemented, CATEGORIES may cover most of all use cases.
VALIDATORS is mainly designed for C++.
Some languages like C++ have generations of standards like C++-11 and C++-23.
Even if an input is valid as C++11, the input can be invalid as C++-23.
For validating only C++-23 input but not C++-11 ([or vice versa]), the VALIDATORS may help you.

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