I the example you link, it looks like the top half is all comments, starting with """ on a line, and ending with """ on a line. What's confusing is that code examples in the comments are surrounded by ```, and they are long enough to look like actual code.
Also, in this markup, the top comments are blue only.
Then, the actual code begins, and it is syntax-colored. In code, comments seem to be preceded by pound.
After a big chunk of code, there is another set of comments in """, and then some more code, ending with `end`.
The ``` code samples in the comments might be part of some automated comment documentation extraction standard or some markup convention. The comments near them seem very formal, defining or explaining the code.
That's the best I can do not knowing the language.
You're looking at a markdown-formatted docstring. Note that it's enclosed in """, similar to Python except that it precedes the method definition. Within the markdown formatting, you can use ``` fences to format code examples.
GitHub's coloring here doesn't quite make it as obvious as it can be. Here's how it renders at the REPL with the help system: http://imgur.com/rlAnpSK
Also, in this markup, the top comments are blue only.
Then, the actual code begins, and it is syntax-colored. In code, comments seem to be preceded by pound.
After a big chunk of code, there is another set of comments in """, and then some more code, ending with `end`.
The ``` code samples in the comments might be part of some automated comment documentation extraction standard or some markup convention. The comments near them seem very formal, defining or explaining the code.
That's the best I can do not knowing the language.