Skip to content

Commit

Permalink
support Mercury lang
Browse files Browse the repository at this point in the history
  • Loading branch information
Hideo Hattori committed Oct 23, 2016
1 parent 0ed5304 commit eb492df
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions language.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,9 @@ var Exts map[string]string = map[string]string{
"kt": "Kotlin",
"lds": "LD Script",
"less": "LESS",
"Objective-C": "Objective-C", // deplicated Obj-C/Matlab
"Objective-C": "Objective-C", // deplicated Obj-C/Matlab/Mercury
"Matlab": "MATLAB", // both use ext '.m'
"Mercury": "Mercury", // use ext '.m'
"md": "Markdown",
"markdown": "Markdown",
"nsi": "NSIS",
Expand Down Expand Up @@ -335,7 +336,7 @@ func lang2exts(lang string) (exts string) {
for ext, l := range Exts {
if lang == l {
switch lang {
case "Objective-C", "MATLAB":
case "Objective-C", "MATLAB", "Mercury":
ext = "m"
case "F#":
ext = "fs"
Expand Down Expand Up @@ -435,6 +436,7 @@ func GetDefinitionLanguages() map[string]*Language {
"Objective-C++": NewLanguage("Objective-C++", "//", "/*", "*/"),
"Makefile": NewLanguage("Makefile", "#", "", ""),
"MATLAB": NewLanguage("MATLAB", "%", "%{", "}%"),
"Mercury": NewLanguage("Mercury", "%", "/*", "*/"),
"Maven": NewLanguage("Maven", "<!--", "<!--", "-->"),
"Mustache": NewLanguage("Mustache", "", "{{!", "}}"),
"M4": NewLanguage("M4", "#", "", ""),
Expand Down

0 comments on commit eb492df

Please sign in to comment.