c.js 581 B

12345678910111213141516171819202122232425
  1. /*
  2. Language: C
  3. Category: common, system
  4. Website: https://en.wikipedia.org/wiki/C_(programming_language)
  5. Requires: c-like.js
  6. */
  7. /** @type LanguageFn */
  8. function c(hljs) {
  9. var lang = hljs.getLanguage('c-like').rawDefinition();
  10. // Until C is actually different than C++ there is no reason to auto-detect C
  11. // as it's own language since it would just fail auto-detect testing or
  12. // simply match with C++.
  13. //
  14. // See further comments in c-like.js.
  15. // lang.disableAutodetect = false;
  16. lang.name = 'C';
  17. lang.aliases = ['c', 'h'];
  18. return lang;
  19. }
  20. module.exports = c;