Skip to content

Add beluga (.bel) language with tests#962

Merged
AlDanial merged 3 commits intoAlDanial:masterfrom
aubertc:master
Feb 23, 2026
Merged

Add beluga (.bel) language with tests#962
AlDanial merged 3 commits intoAlDanial:masterfrom
aubertc:master

Conversation

@aubertc
Copy link
Contributor

@aubertc aubertc commented Feb 23, 2026

This PR adds support for recognizing the Beluga language, which is a proof assistant similar to e.g. Rocq (formely Coq) or Lean.

Summary:

  • add .bel extension mapping and Beluga language definition (cf. documentation)
  • strip full-line and inline Beluga comments
  • added example file and corresponding test

@AlDanial AlDanial merged commit 00ff5f1 into AlDanial:master Feb 23, 2026
1 check passed
@AlDanial
Copy link
Owner

thanks!

@aubertc
Copy link
Contributor Author

aubertc commented Feb 23, 2026

No, thank you for developing such a nice tool, integrating this language was a breeze ;-)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note (to self / anyone trying to add a language to cloc): this file was obtained by doing something like

cloc --yaml tests/inputs/beluga.bel > test/outputs/beluga.bel.yaml

and then manually editing the .yaml file to add the report_file : ../outputs/beluga.bel.yaml line.

@AlDanial please let me know if there is a better way to do it, and I'll probably create a pull request documenting how to add a language to cloc.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Also if there is a linter or style that is enforced, please let me know ;-)

@AlDanial
Copy link
Owner

I welcome a PR to add instructions to the README on how to add a new language. btw, I use

cloc --yaml tests/inputs/beluga.bel --out test/outputs/beluga.bel.yaml

There's no linter or style guide for cloc. Free form, but hopefully you'll apply common sense :)

@aubertc
Copy link
Contributor Author

aubertc commented Feb 24, 2026

Thanks @AlDanial , this is done with #963

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