jashkenas / jashkenas/coffee-script-tmbundle

Issue with CoffeeScript block comment syntax on Github viewer

Open
#156 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
826
Forks
232
PR merge metrics
No merged PRs in 30d

Description

I noticed an issue when viewing a CoffeeScript file on Github. Here:
https://github.com/perroned/bigbluebutton/blob/99e0b75997f58796b74e3e9df3b7f2de0aa2ee5c/bigbluebutton-html5/app/client/globals.coffee#L158-L162

In CoffeeScript triple pound signs '###' are used to show the beginning and ending of a block comment. This is how my code looks in Atom editor:

![](https://ci6.googleusercontent.com/proxy/MPDUK7jiR6_-NJgQ9OnPHZ44Vh7JIXevg1UEjOqh86VY_uGSRcZEq4yBd9MIUFDfon3fppFn5rqZ0iR9UhZIubuKoj0ZwOme0be6kUXVD552A4mRrFttCC5PLUzabprnyLHHWE9BkjArHr6rHALXxpDDjyGfhgYN0IQ=s0-d-e1-ft#https://cloud.githubusercontent.com/assets/6475374/11254521/2f9b17d0-8e0f-11e5-8ccd-1a0d679ad96d.png)
(Correct)

The code between the tags is recognized as a comment, and everything surrounding is displayed correctly. However here on the Github viewer everything after the code comment tag is not displayed properly https://github.com/perroned/bigbluebutton/blob/99e0b75997f58796b74e3e9df3b7f2de0aa2ee5c/bigbluebutton-html5/app/client/globals.coffee#L164-L165

![image](https://cloud.githubusercontent.com/assets/6475374/11324833/93416704-910b-11e5-8a03-873a6d7d2d9e.png)

It is displayed as a comment. Some lines still show some form of syntax highlighting like here on line number 196 https://github.com/perroned/bigbluebutton/blob/99e0b75997f58796b74e3e9df3b7f2de0aa2ee5c/bigbluebutton-html5/app/client/globals.coffee#L196

![image](https://cloud.githubusercontent.com/assets/6475374/11324845/b3b9b464-910b-11e5-84c4-5cb0f2c21f12.png)

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the rendering using the linked globals.coffee example, focusing on lines 158-165 and 196. Inspect the CoffeeScript syntax-highlighting grammar used by this TextMate bundle and compare how triple-pound block comments are parsed; done means code after the closing marker is displayed and highlighted correctly on GitHub.

Written by the indexing model from the issue text.

Assessment

Tech stack
coffeescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.