Until I added .gitattributes, GitHub thought my BCPL project https://github.com/rptb1/clavicom was written in Brainfuck. If it were, I wouldn't've passed my ‘A’-level exams, but I would perhaps have become a timelord.
I will try to find time to submit a pull, but it's unlikely any time soon.
Shouldn't .b be B? ;-)
I do enjoy classical languages very much, so I'm sad to say there may not be enough BCPL files at GitHub to warrant addition of that language. See the contribution guidelines.
@rptb1 What file extensions does BCPL, other than .b? I notice there's a file in your repo with the .sub extension that's written in (what I'm guessing) is BCPL.
Martin Richard's BCPL distribution (_the_ compiler) uses .b as does the Arnor BCPL manual. My use of .sub isn't canonical — more to do with me working in isolation, pre-Internet. I would guess that there might be some BCPL out there in files with .bcpl but I haven't seen any.
By the way, if it has $( and $) then it's BCPL. BCPL was the first language with "section brackets" that later turned up as { and } — the "squiggle" and "squoggle"!
Now I've seen one! https://github.com/eli-davis/BCPL/blob/master/data_structures/linked_list.bcpl
However, this big pile of BCPL programs uses .b.
Hrm, I see.
BCPL needs a language grammar before it can be parsed by Linguist. From cursory searches, there doesn't appear to be one.
I'd write one, but I'd need a comprehensive language reference first.
That's very enterprising of you. Full BNF grammar in the manual https://www.bell-labs.com/usr/dmr/www/bcpl.pdf thought some details changed later. There's more info here https://www.bell-labs.com/usr/dmr/www/bcpl.html and of course and I may be able to help out a bit later.
Now we're talking. ;)
Will look into doing so once I've finished working on this. A language pack already exists, but its support is limited to man-page macros only...
Slp
Le 29 mars 2016 18:28, "Richard Brooksby" [email protected] a
écrit :
That's very enterprising of you. Full BNF grammar in the manual
https://www.bell-labs.com/usr/dmr/www/bcpl.pdf thought some details
changed later. There's more info here
https://www.bell-labs.com/usr/dmr/www/bcpl.html and of course and I may
be able to help out a bit later.—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
https://github.com/github/linguist/issues/2874#issuecomment-203011877
BCPL needs a language grammar before it can be parsed by Linguist.
But as far as I know, there's no requirement for a language to have a grammar to be added to Linguist.
No? I was under the impression Linguist used TextMate-compatible grammars to identify different parts of a language's anatomy (comments, keywords, standard library functions, etc) which influenced the results of its analysis...
@Alhadis No, that's not how it works. The grammars are used for syntax highlighting when viewing files.
Language classification analysis is done with filenames, shebangs, heuristics, editor modelines, etc.

Wheeelp, you learn something new everyday, haha. Thanks!
Flagging as stale.
Most helpful comment
Wheeelp, you learn something new everyday, haha. Thanks!