Skip to content

Integration with Argus.jl - #83

Merged
bergel merged 61 commits into
mainfrom
iulia/argus
Jun 9, 2026
Merged

Integration with Argus.jl#83
bergel merged 61 commits into
mainfrom
iulia/argus

Conversation

@iuliadmtru

Copy link
Copy Markdown
Collaborator

This is a major change that removes the CSTParser.jl dependency in favour of Argus.jl.

The new approach uses Argus for writing and matching rules in a more expressive way than before. It is now possible to:

  • write rules that were impossible to express before (e.g. containers with abstract types);
  • separate internal rules from the main codebase;
  • group rules together in RuleGroups;
  • use custom rule disabling methods;
  • use custom pattern-matching utils;
  • and more (see the Argus documentation for all features).

Apart from new features and improvements, this PR also brings a major reorganisation and cleaning up. Still, there is still some work that can be done for even further improvement (e.g. more instructive logs, remove/replace some unnecessary functions such as run_lint_on_text).

I believe this PR is good to merge as-is.

@iuliadmtru

iuliadmtru commented May 30, 2026

Copy link
Copy Markdown
Collaborator Author

@bergel @comnik Argus is not compatible (and will not be) with Julia v1.9, but it is with >=v1.10. Do you think we could remove the 1.9 tests?

@bergel

bergel commented Jun 1, 2026

Copy link
Copy Markdown
Collaborator

I just pushed into your branch.

@bergel

bergel commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator

another push. I suspect that the getting coverage does not work, maybe because of the extensive macro expansions. The following code successfuly executes the tests:

import Pkg; Pkg.test(;julia_args=["--check-bounds=yes", "--compiled-modules=yes", "--depwarn=yes"], allow_reresolve=true, coverage=false, force_latest_compatible_version=false)

However, the one actually used by the workflow (before my last commit) was doing:

import Pkg; Pkg.test(;julia_args=["--check-bounds=yes", "--compiled-modules=yes", "--depwarn=yes"], allow_reresolve=true, coverage=true, force_latest_compatible_version=false)

Which breaks.

@bergel

bergel commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator

Also, I had to exclude x84, again, no idea why.

@iuliadmtru

iuliadmtru commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator Author

Let's wait for the latest Argus release to be merged. I'll add back coverage and x84 tests afterwards. I think they will pass this time.

@iuliadmtru

Copy link
Copy Markdown
Collaborator Author

@bergel All good now :).

@bergel bergel left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Good to be merged!

@bergel
bergel merged commit 754397d into main Jun 9, 2026
9 checks passed
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