1 /*! `excel` grammar compiled for Highlight.js 11.11.1 */
2 var hljsGrammar
= (function () {
6 Language: Excel formulae
7 Author: Victor Zhou <OiCMudkips@users.noreply.github.com>
8 Description: Excel formulae
9 Website: https://products.office.com/en-us/excel/
13 /** @type LanguageFn */
14 function excel(hljs
) {
15 // built-in functions imported from https://web.archive.org/web/20241205190205/https://support.microsoft.com/en-us/office/excel-functions-alphabetical-b3944572-255d-4efb-bb96-c6d90033e188
121 "CUBEMEMBERPROPERTY",
199 "FORECAST.ETS.CONFINT",
200 "FORECAST.ETS.SEASONALITY",
532 name: 'Excel formulae',
537 case_insensitive: true,
539 $pattern: /[a-zA-Z][\w\.]*/,
544 /* matches a beginning equal sign found in Excel formula examples */
548 illegal: /=/, /* only allow single equal sign at front
of line */
551 /* technically, there can be more than 2 letters in column names, but this prevents conflict with some keywords */
553 /* matches a reference to a single cell */
555 begin: /\b[A-Z]{1,2}\d+\b/,
561 /* matches a reference to a range of cells */
563 begin: /[A-Z]{0,2}\d*:[A-Z]{0,2}\d*/,
566 hljs
.BACKSLASH_ESCAPE
,
567 hljs
.QUOTE_STRING_MODE
,
570 begin: hljs
.NUMBER_RE
+ '(%)?',
573 /* Excel formula comments are done by putting the comment in a function call to N() */
574 hljs
.COMMENT(/\bN\(/, /\)/,
588 export default hljsGrammar
;