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

optscript: bug fix, new operators, refactoring #3028

Merged

Conversation

masatake
Copy link
Member

This is a preparation pull request for mering #3027.

The last commit of #3027 includes a critical bug. So the running the test cases fails.
This pull requests includes all commits other than the last one.
All changes are useful even if we don't merge #3027.

masatake added 19 commits May 16, 2021 10:30
The original code updates only the lineNumber member of the tag entry.

Signed-off-by: Masatake YAMATO <[email protected]>
_tagloc takes a corkQueue index and pushes a mloc object locating
the tag object identified by the corkQueue index.

Signed-off-by: Masatake YAMATO <[email protected]>
forall operators has array, dict, and string backends.
Unify the similar code in the backends into one.

Signed-off-by: Masatake YAMATO <[email protected]>
Signed-off-by: Masatake YAMATO <[email protected]>
The original code has code a bug; the inputStart and inputEnd events
propagate only to direct sub parsers. Thes event never propagate to
sub sub parsers. This change fixe this. The events are propagated
recursively in base/sub parser relations.

The ways to run prelude/sequel codes and propagate inputStart/End
events are unified. As the result a optlib parser running as a sub
parser of another optlib parser can run its prelude/sequel codes.

Signed-off-by: Masatake YAMATO <[email protected]>
…efintions

A for loop was used for the iteration.

The original code used XTAG_COUNT as the limit of the loop counter.
However, the contestant doesn't consider dynamically allocated parser-specific
xtags.

The new code uses countXtags() that considers dynamically allocated
parser-specific xtags.

Signed-off-by: Masatake YAMATO <[email protected]>
@masatake
Copy link
Member Author

I fixed the critical bug in #3027. So I withdraw this and I continue to improve #3027 for merging.

@masatake masatake closed this May 17, 2021
@masatake masatake reopened this May 20, 2021
@codecov
Copy link

codecov bot commented May 20, 2021

Codecov Report

Merging #3028 (abeaa4e) into master (3af94f7) will increase coverage by 0.00%.
The diff coverage is 88.33%.

❗ Current head abeaa4e differs from pull request most recent head b6124a6. Consider uploading reports for the commit b6124a6 to get more accurate results
Impacted file tree graph

@@           Coverage Diff            @@
##           master    #3028    +/-   ##
========================================
  Coverage   87.32%   87.32%            
========================================
  Files         199      199            
  Lines       47450    47595   +145     
========================================
+ Hits        41434    41564   +130     
- Misses       6016     6031    +15     
Impacted Files Coverage Δ
main/trace.c 80.39% <ø> (ø)
parsers/yaml.c 92.06% <33.33%> (-6.25%) ⬇️
main/field.c 92.61% <84.37%> (+0.87%) ⬆️
main/lregex.c 83.60% <88.15%> (-0.17%) ⬇️
dsl/optscript.c 87.39% <90.90%> (+0.22%) ⬆️
main/dependency.c 96.40% <100.00%> (+0.04%) ⬆️
main/entry.c 88.51% <100.00%> (+0.02%) ⬆️
main/parse.c 95.85% <100.00%> (ø)
optlib/markdown.c 100.00% <100.00%> (ø)
optlib/pod.c 100.00% <100.00%> (ø)
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3af94f7...b6124a6. Read the comment docs.

@masatake
Copy link
Member Author

In #3027, there are still areas that I have to improve before merging.
So I reopen this request for merging the acceptable subset of #3027.

@masatake masatake merged commit 2b88b80 into universal-ctags:master May 20, 2021
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.

1 participant