-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Additional language: Forth #20
Comments
I added support for Forth with many (4th, e4, f83, fb, forth, fpm, fr, frt, ft, fth, rx) of the listed extensions with git commit 121cc5e. These extensions conflict with Fortran: f, for cloc can work with extensions to map to multiple languages but then more work is needed to write a special function that can deduce which of the two or more languages a given file is. I might revisit that in the future. Or you could supply the function (see for inspiration cloc's existing subroutines matlab_or_objective_C(), pascal_or_puppet(), Perl_or_Prolog(), et cetera). |
Thank you! |
|
better handling of --explain when language shares file extension with other languages
The integration of your two routines is complete with git commit 88f71e7. |
Looks good! |
hi Lars, if you have a moment could you respond to the remarks at #103 regarding the use of (* .. *) to denote Forth comments? |
Yep. |
File extensions: 4th, f, for, forth, fr, frt, fth, fs. These are supported by GitHub's Linguist.
Comments:
\
to end of line.(
to)
on same line.(*
starts a multi-line comment ending with*)
.Note that the token starting the comment must be surrounded by whitespace.
Links to sample code:
http://github.com/larsbrinkhoff/lbForth/blob/master/kernel.fth
http://github.com/search?q=language%3Aforth+dup+swap&type=Code
The text was updated successfully, but these errors were encountered: