notebook/notes/.obsidian/plugins/obsidian-to-anki-plugin/main.js

68507 lines
1.9 MiB
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

'use strict';
var obsidian = require('obsidian');
var path$1 = require('path');
const ANKI_PORT = 8765;
function invoke(action, params = {}) {
return new Promise((resolve, reject) => {
const xhr = new XMLHttpRequest();
xhr.addEventListener('error', () => reject('failed to issue request'));
xhr.addEventListener('load', () => {
try {
const response = JSON.parse(xhr.responseText);
if (Object.getOwnPropertyNames(response).length != 2) {
throw 'response has an unexpected number of fields';
}
if (!response.hasOwnProperty('error')) {
throw 'response is missing required error field';
}
if (!response.hasOwnProperty('result')) {
throw 'response is missing required result field';
}
if (response.error) {
throw response.error;
}
resolve(response.result);
}
catch (e) {
reject(e);
}
});
xhr.open('POST', 'http://127.0.0.1:' + ANKI_PORT.toString());
xhr.send(JSON.stringify({ action, version: 6, params }));
});
}
function parse(response) {
//Helper function for parsing the result of a multi
if (Object.getOwnPropertyNames(response).length != 2) {
throw 'response has an unexpected number of fields';
}
if (!(response.hasOwnProperty('error'))) {
throw 'response is missing required error field';
}
if (!(response.hasOwnProperty('result'))) {
throw 'response is missing required result field';
}
if (response.error) {
throw response.error;
}
return response.result;
}
// All the rest of these functions only return request objects as opposed to actually carrying out the action. For efficiency!
function request(action, params = {}) {
return { action, version: 6, params };
}
function multi(actions) {
return request('multi', { actions: actions });
}
function addNote(note) {
return request('addNote', { note: note });
}
function createDeck(deck) {
return request('createDeck', { deck: deck });
}
function deleteNotes(note_ids) {
return request('deleteNotes', { notes: note_ids });
}
function updateNoteFields(id, fields) {
return request('updateNoteFields', {
note: {
id: id,
fields: fields
}
});
}
function notesInfo(note_ids) {
return request('notesInfo', {
notes: note_ids
});
}
function changeDeck(card_ids, deck) {
return request('changeDeck', {
cards: card_ids,
deck: deck
});
}
function removeTags(note_ids, tags) {
return request('removeTags', {
notes: note_ids,
tags: tags
});
}
function addTags(note_ids, tags) {
return request('addTags', {
notes: note_ids,
tags: tags
});
}
function getTags() {
return request('getTags');
}
function storeMediaFileByPath(filename, path) {
return request('storeMediaFile', {
filename: filename,
path: path
});
}
const defaultDescs = {
"Scan Directory": "The directory to scan. Leave empty to scan the entire vault",
"Tag": "The tag that the plugin automatically adds to any generated cards.",
"Deck": "The deck the plugin adds cards to if TARGET DECK is not specified in the file.",
"Scheduling Interval": "The time, in minutes, between automatic scans of the vault. Set this to 0 to disable automatic scanning.",
"Add File Link": "Append a link to the file that generated the flashcard on the field specified in the table.",
"Add Context": "Append 'context' for the card, in the form of path > heading > heading etc, to the field specified in the table.",
"CurlyCloze": "Convert {cloze deletions} -> {{c1::cloze deletions}} on note types that have a 'Cloze' in their name.",
"CurlyCloze - Highlights to Clozes": "Convert ==highlights== -> {highlights} to be processed by CurlyCloze.",
"ID Comments": "Wrap note IDs in a HTML comment.",
"Add Obsidian Tags": "Interpret #tags in the fields of a note as Anki tags, removing them from the note text in Anki."
};
const DEFAULT_IGNORED_FILE_GLOBS = [
'**/*.excalidraw.md'
];
class SettingsTab extends obsidian.PluginSettingTab {
setup_custom_regexp(note_type, row_cells) {
const plugin = this.plugin;
let regexp_section = plugin.settings["CUSTOM_REGEXPS"];
let custom_regexp = new obsidian.Setting(row_cells[1])
.addText(text => text.setValue(regexp_section.hasOwnProperty(note_type) ? regexp_section[note_type] : "")
.onChange((value) => {
plugin.settings["CUSTOM_REGEXPS"][note_type] = value;
plugin.saveAllData();
}));
custom_regexp.settingEl = row_cells[1];
custom_regexp.infoEl.remove();
custom_regexp.controlEl.className += " anki-center";
}
setup_link_field(note_type, row_cells) {
const plugin = this.plugin;
let link_fields_section = plugin.settings.FILE_LINK_FIELDS;
let link_field = new obsidian.Setting(row_cells[2])
.addDropdown(async (dropdown) => {
if (!(plugin.fields_dict[note_type])) {
plugin.fields_dict = await plugin.loadFieldsDict();
if (Object.keys(plugin.fields_dict).length != plugin.note_types.length) {
new obsidian.Notice('Need to connect to Anki to generate fields dictionary...');
try {
plugin.fields_dict = await plugin.generateFieldsDict();
new obsidian.Notice("Fields dictionary successfully generated!");
}
catch (e) {
new obsidian.Notice("Couldn't connect to Anki! Check console for error message.");
return;
}
}
}
const field_names = plugin.fields_dict[note_type];
for (let field of field_names) {
dropdown.addOption(field, field);
}
dropdown.setValue(link_fields_section.hasOwnProperty(note_type) ? link_fields_section[note_type] : field_names[0]);
dropdown.onChange((value) => {
plugin.settings.FILE_LINK_FIELDS[note_type] = value;
plugin.saveAllData();
});
});
link_field.settingEl = row_cells[2];
link_field.infoEl.remove();
link_field.controlEl.className += " anki-center";
}
setup_context_field(note_type, row_cells) {
const plugin = this.plugin;
let context_fields_section = plugin.settings.CONTEXT_FIELDS;
let context_field = new obsidian.Setting(row_cells[3])
.addDropdown(async (dropdown) => {
const field_names = plugin.fields_dict[note_type];
for (let field of field_names) {
dropdown.addOption(field, field);
}
dropdown.setValue(context_fields_section.hasOwnProperty(note_type) ? context_fields_section[note_type] : field_names[0]);
dropdown.onChange((value) => {
plugin.settings.CONTEXT_FIELDS[note_type] = value;
plugin.saveAllData();
});
});
context_field.settingEl = row_cells[3];
context_field.infoEl.remove();
context_field.controlEl.className += " anki-center";
}
create_collapsible(name) {
let { containerEl } = this;
let div = containerEl.createEl('div', { cls: "collapsible-item" });
div.innerHTML = `
<div class="collapsible-item-self"><div class="collapsible-item-collapse collapse-icon anki-rotated"><svg viewBox="0 0 100 100" width="8" height="8" class="right-triangle"><path fill="currentColor" stroke="currentColor" d="M94.9,20.8c-1.4-2.5-4.1-4.1-7.1-4.1H12.2c-3,0-5.7,1.6-7.1,4.1c-1.3,2.4-1.2,5.2,0.2,7.6L43.1,88c1.5,2.3,4,3.7,6.9,3.7 s5.4-1.4,6.9-3.7l37.8-59.6C96.1,26,96.2,23.2,94.9,20.8L94.9,20.8z"></path></svg></div><div class="collapsible-item-inner"></div><header>${name}</header></div>
`;
div.addEventListener('click', function () {
this.classList.toggle("active");
let icon = this.firstElementChild.firstElementChild;
icon.classList.toggle("anki-rotated");
let content = this.nextElementSibling;
if (content.style.display === "block") {
content.style.display = "none";
}
else {
content.style.display = "block";
}
});
}
setup_note_table() {
let { containerEl } = this;
const plugin = this.plugin;
containerEl.createEl('h3', { text: 'Note type settings' });
this.create_collapsible("Note Type Table");
let note_type_table = containerEl.createEl('table', { cls: "anki-settings-table" });
let head = note_type_table.createTHead();
let header_row = head.insertRow();
for (let header of ["Note Type", "Custom Regexp", "File Link Field", "Context Field"]) {
let th = document.createElement("th");
th.appendChild(document.createTextNode(header));
header_row.appendChild(th);
}
let main_body = note_type_table.createTBody();
if (!(plugin.settings.hasOwnProperty("CONTEXT_FIELDS"))) {
plugin.settings.CONTEXT_FIELDS = {};
}
for (let note_type of plugin.note_types) {
let row = main_body.insertRow();
row.insertCell();
row.insertCell();
row.insertCell();
row.insertCell();
let row_cells = row.children;
row_cells[0].innerHTML = note_type;
this.setup_custom_regexp(note_type, row_cells);
this.setup_link_field(note_type, row_cells);
this.setup_context_field(note_type, row_cells);
}
}
setup_syntax() {
let { containerEl } = this;
const plugin = this.plugin;
let syntax_settings = containerEl.createEl('h3', { text: 'Syntax Settings' });
for (let key of Object.keys(plugin.settings["Syntax"])) {
new obsidian.Setting(syntax_settings)
.setName(key)
.addText(text => text.setValue(plugin.settings["Syntax"][key])
.onChange((value) => {
plugin.settings["Syntax"][key] = value;
plugin.saveAllData();
}));
}
}
setup_defaults() {
let { containerEl } = this;
const plugin = this.plugin;
let defaults_settings = containerEl.createEl('h3', { text: 'Defaults' });
// To account for new scan directory
if (!(plugin.settings["Defaults"].hasOwnProperty("Scan Directory"))) {
plugin.settings["Defaults"]["Scan Directory"] = "";
}
// To account for new add context
if (!(plugin.settings["Defaults"].hasOwnProperty("Add Context"))) {
plugin.settings["Defaults"]["Add Context"] = false;
}
// To account for new scheduling interval
if (!(plugin.settings["Defaults"].hasOwnProperty("Scheduling Interval"))) {
plugin.settings["Defaults"]["Scheduling Interval"] = 0;
}
// To account for new highlights to clozes
if (!(plugin.settings["Defaults"].hasOwnProperty("CurlyCloze - Highlights to Clozes"))) {
plugin.settings["Defaults"]["CurlyCloze - Highlights to Clozes"] = false;
}
// To account for new add obsidian tags
if (!(plugin.settings["Defaults"].hasOwnProperty("Add Obsidian Tags"))) {
plugin.settings["Defaults"]["Add Obsidian Tags"] = false;
}
for (let key of Object.keys(plugin.settings["Defaults"])) {
// To account for removal of regex setting
if (key === "Regex") {
continue;
}
if (typeof plugin.settings["Defaults"][key] === "string") {
new obsidian.Setting(defaults_settings)
.setName(key)
.setDesc(defaultDescs[key])
.addText(text => text.setValue(plugin.settings["Defaults"][key])
.onChange((value) => {
plugin.settings["Defaults"][key] = value;
plugin.saveAllData();
}));
}
else if (typeof plugin.settings["Defaults"][key] === "boolean") {
new obsidian.Setting(defaults_settings)
.setName(key)
.setDesc(defaultDescs[key])
.addToggle(toggle => toggle.setValue(plugin.settings["Defaults"][key])
.onChange((value) => {
plugin.settings["Defaults"][key] = value;
plugin.saveAllData();
}));
}
else {
new obsidian.Setting(defaults_settings)
.setName(key)
.setDesc(defaultDescs[key])
.addSlider(slider => {
slider.setValue(plugin.settings["Defaults"][key])
.setLimits(0, 360, 5)
.setDynamicTooltip()
.onChange(async (value) => {
plugin.settings["Defaults"][key] = value;
await plugin.saveAllData();
if (plugin.hasOwnProperty("schedule_id")) {
window.clearInterval(plugin.schedule_id);
}
if (value != 0) {
plugin.schedule_id = window.setInterval(async () => await plugin.scanVault(), value * 1000 * 60);
plugin.registerInterval(plugin.schedule_id);
}
});
});
}
}
}
get_folders() {
const app = this.plugin.app;
let folder_list = [app.vault.getRoot()];
for (let folder of folder_list) {
let filtered_list = folder.children.filter((element) => element.hasOwnProperty("children"));
folder_list.push(...filtered_list);
}
return folder_list.slice(1); //Removes initial vault folder
}
setup_folder_deck(folder, row_cells) {
const plugin = this.plugin;
let folder_decks = plugin.settings.FOLDER_DECKS;
if (!(folder_decks.hasOwnProperty(folder.path))) {
folder_decks[folder.path] = "";
}
let folder_deck = new obsidian.Setting(row_cells[1])
.addText(text => text.setValue(folder_decks[folder.path])
.onChange((value) => {
plugin.settings.FOLDER_DECKS[folder.path] = value;
plugin.saveAllData();
}));
folder_deck.settingEl = row_cells[1];
folder_deck.infoEl.remove();
folder_deck.controlEl.className += " anki-center";
}
setup_folder_tag(folder, row_cells) {
const plugin = this.plugin;
let folder_tags = plugin.settings.FOLDER_TAGS;
if (!(folder_tags.hasOwnProperty(folder.path))) {
folder_tags[folder.path] = "";
}
let folder_tag = new obsidian.Setting(row_cells[2])
.addText(text => text.setValue(folder_tags[folder.path])
.onChange((value) => {
plugin.settings.FOLDER_TAGS[folder.path] = value;
plugin.saveAllData();
}));
folder_tag.settingEl = row_cells[2];
folder_tag.infoEl.remove();
folder_tag.controlEl.className += " anki-center";
}
setup_folder_table() {
let { containerEl } = this;
const plugin = this.plugin;
const folder_list = this.get_folders();
containerEl.createEl('h3', { text: 'Folder settings' });
this.create_collapsible("Folder Table");
let folder_table = containerEl.createEl('table', { cls: "anki-settings-table" });
let head = folder_table.createTHead();
let header_row = head.insertRow();
for (let header of ["Folder", "Folder Deck", "Folder Tags"]) {
let th = document.createElement("th");
th.appendChild(document.createTextNode(header));
header_row.appendChild(th);
}
let main_body = folder_table.createTBody();
if (!(plugin.settings.hasOwnProperty("FOLDER_DECKS"))) {
plugin.settings.FOLDER_DECKS = {};
}
if (!(plugin.settings.hasOwnProperty("FOLDER_TAGS"))) {
plugin.settings.FOLDER_TAGS = {};
}
for (let folder of folder_list) {
let row = main_body.insertRow();
row.insertCell();
row.insertCell();
row.insertCell();
let row_cells = row.children;
row_cells[0].innerHTML = folder.path;
this.setup_folder_deck(folder, row_cells);
this.setup_folder_tag(folder, row_cells);
}
}
setup_buttons() {
let { containerEl } = this;
const plugin = this.plugin;
let action_buttons = containerEl.createEl('h3', { text: 'Actions' });
new obsidian.Setting(action_buttons)
.setName("Regenerate Note Type Table")
.setDesc("Connect to Anki to regenerate the table with new note types, or get rid of deleted note types.")
.addButton(button => {
button.setButtonText("Regenerate").setClass("mod-cta")
.onClick(async () => {
new obsidian.Notice("Need to connect to Anki to update note types...");
try {
plugin.note_types = await invoke('modelNames');
plugin.regenerateSettingsRegexps();
plugin.fields_dict = await plugin.loadFieldsDict();
if (Object.keys(plugin.fields_dict).length != plugin.note_types.length) {
new obsidian.Notice('Need to connect to Anki to generate fields dictionary...');
try {
plugin.fields_dict = await plugin.generateFieldsDict();
new obsidian.Notice("Fields dictionary successfully generated!");
}
catch (e) {
new obsidian.Notice("Couldn't connect to Anki! Check console for error message.");
return;
}
}
await plugin.saveAllData();
this.setup_display();
new obsidian.Notice("Note types updated!");
}
catch (e) {
new obsidian.Notice("Couldn't connect to Anki! Check console for details.");
}
});
});
new obsidian.Setting(action_buttons)
.setName("Clear Media Cache")
.setDesc(`Clear the cached list of media filenames that have been added to Anki.
The plugin will skip over adding a media file if it's added a file with the same name before, so clear this if e.g. you've updated the media file with the same name.`)
.addButton(button => {
button.setButtonText("Clear").setClass("mod-cta")
.onClick(async () => {
plugin.added_media = [];
await plugin.saveAllData();
new obsidian.Notice("Media Cache cleared successfully!");
});
});
new obsidian.Setting(action_buttons)
.setName("Clear File Hash Cache")
.setDesc(`Clear the cached dictionary of file hashes that the plugin has scanned before.
The plugin will skip over a file if the file path and the hash is unaltered.`)
.addButton(button => {
button.setButtonText("Clear").setClass("mod-cta")
.onClick(async () => {
plugin.file_hashes = {};
await plugin.saveAllData();
new obsidian.Notice("File Hash Cache cleared successfully!");
});
});
}
setup_ignore_files() {
let { containerEl } = this;
const plugin = this.plugin;
let ignored_files_settings = containerEl.createEl('h3', { text: 'Ignored File Settings' });
plugin.settings["IGNORED_FILE_GLOBS"] = plugin.settings.hasOwnProperty("IGNORED_FILE_GLOBS") ? plugin.settings["IGNORED_FILE_GLOBS"] : DEFAULT_IGNORED_FILE_GLOBS;
const descriptionFragment = document.createDocumentFragment();
descriptionFragment.createEl("span", { text: "Glob patterns for files to ignore. You can add multiple patterns. One per line. Have a look at the " });
descriptionFragment.createEl("a", { text: "README.md", href: "https://github.com/Pseudonium/Obsidian_to_Anki?tab=readme-ov-file#features" });
descriptionFragment.createEl("span", { text: " for more information, examples and further resources." });
new obsidian.Setting(ignored_files_settings)
.setName("Patterns to ignore")
.setDesc(descriptionFragment)
.addTextArea(text => {
text.setValue(plugin.settings.IGNORED_FILE_GLOBS.join("\n"))
.setPlaceholder("Examples: '**/*.excalidraw.md', 'Templates/**'")
.onChange((value) => {
let ignoreLines = value.split("\n");
ignoreLines = ignoreLines.filter(e => e.trim() != ""); //filter out empty lines and blank lines
plugin.settings.IGNORED_FILE_GLOBS = ignoreLines;
plugin.saveAllData();
});
text.inputEl.rows = 10;
text.inputEl.cols = 30;
});
}
setup_display() {
let { containerEl } = this;
containerEl.empty();
containerEl.createEl('h2', { text: 'Obsidian_to_Anki settings' });
containerEl.createEl('a', { text: 'For more information check the wiki', href: "https://github.com/Pseudonium/Obsidian_to_Anki/wiki" });
this.setup_note_table();
this.setup_folder_table();
this.setup_syntax();
this.setup_defaults();
this.setup_buttons();
this.setup_ignore_files();
}
async display() {
this.setup_display();
}
}
const ANKI_ICON = `<path fill="currentColor" stroke="currentColor" d="M 27.00,3.53 C 18.43,6.28 16.05,10.38 16.00,19.00 16.00,19.00 16.00,80.00 16.00,80.00 16.00,82.44 15.87,85.73 16.74,88.00 20.66,98.22 32.23,97.00 41.00,97.00 41.00,97.00 69.00,97.00 69.00,97.00 76.63,96.99 82.81,95.84 86.35,88.00 88.64,82.94 88.00,72.79 88.00,67.00 88.00,67.00 88.00,24.00 88.00,24.00 87.99,16.51 87.72,10.42 80.98,5.65 76.04,2.15 69.73,3.00 64.00,3.00 64.00,3.00 27.00,3.53 27.00,3.53 Z M 68.89,15.71 C 74.04,15.96 71.96,19.20 74.01,22.68 74.01,22.68 76.72,25.74 76.72,25.74 80.91,30.85 74.53,31.03 71.92,34.29 70.70,35.81 70.05,38.73 67.81,39.09 65.64,39.43 63.83,37.03 61.83,36.00 59.14,34.63 56.30,35.24 55.08,33.40 53.56,31.11 56.11,28.55 56.20,25.00 56.24,23.28 55.32,20.97 56.20,19.35 57.67,16.66 60.89,18.51 64.00,17.71 64.00,17.71 68.89,15.71 68.89,15.71 Z M 43.06,43.86 C 49.81,45.71 48.65,51.49 53.21,53.94 56.13,55.51 59.53,53.51 62.94,54.44 64.83,54.96 66.30,56.05 66.54,58.11 67.10,62.74 60.87,66.31 60.69,71.00 60.57,74.03 64.97,81.26 61.40,83.96 57.63,86.82 51.36,80.81 47.00,82.22 43.96,83.20 40.23,88.11 36.11,87.55 29.79,86.71 33.95,77.99 32.40,74.18 30.78,70.20 24.67,68.95 23.17,64.97 22.34,62.79 23.39,61.30 25.15,60.09 28.29,57.92 32.74,58.49 35.44,55.57 39.11,51.60 36.60,45.74 43.06,43.86 Z" />`;
const OBS_INLINE_MATH_REGEXP = /(?<!\$)\$((?=[\S])(?=[^$])[\s\S]*?\S)\$/g;
const OBS_DISPLAY_MATH_REGEXP = /\$\$([\s\S]*?)\$\$/g;
const OBS_CODE_REGEXP = /(?<!`)`(?=[^`])[\s\S]*?`/g;
const OBS_DISPLAY_CODE_REGEXP = /```[\s\S]*?```/g;
const CODE_CSS_URL = `https://cdn.jsdelivr.net/npm/highlightjs-themes@1.0.0/arta.css`;
function escapeRegex(str) {
// Got from stackoverflow - https://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript
return str.replace(/[-\/\\^$*+?.()|[\]{}]/g, '\\$&');
}
/*Manages parsing notes into a dictionary formatted for AnkiConnect.
Input must be the note text.
Does NOT deal with finding the note in the file.*/
const TAG_PREFIX = "Tags: ";
const TAG_SEP = " ";
const ID_REGEXP_STR = String.raw `\n?(?:<!--)?(?:ID: (\d+).*)`;
const TAG_REGEXP_STR = String.raw `(Tags: .*)`;
const OBS_TAG_REGEXP = /#(\w+)/g;
const ANKI_CLOZE_REGEXP = /{{c\d+::[\s\S]+?}}/;
const CLOZE_ERROR = 42;
const NOTE_TYPE_ERROR = 69;
function has_clozes(text) {
/*Checks whether text actually has cloze deletions.*/
return ANKI_CLOZE_REGEXP.test(text);
}
function note_has_clozes(note) {
/*Checks whether a note has cloze deletions in any of its fields.*/
for (let i in note.fields) {
if (has_clozes(note.fields[i])) {
return true;
}
}
return false;
}
class AbstractNote {
text;
split_text;
current_field_num;
delete;
identifier;
tags;
note_type;
field_names;
current_field;
ID_REGEXP = /(?:<!--)?ID: (\d+)/;
formatter;
curly_cloze;
highlights_to_cloze;
no_note_type;
constructor(note_text, fields_dict, curly_cloze, highlights_to_cloze, formatter) {
this.text = note_text.trim();
this.current_field_num = 0;
this.delete = false;
this.no_note_type = false;
this.split_text = this.getSplitText();
this.identifier = this.getIdentifier();
this.tags = this.getTags();
this.note_type = this.getNoteType();
if (!(fields_dict.hasOwnProperty(this.note_type))) {
this.no_note_type = true;
return;
}
this.field_names = fields_dict[this.note_type];
this.current_field = this.field_names[0];
this.formatter = formatter;
this.curly_cloze = curly_cloze;
this.highlights_to_cloze = highlights_to_cloze;
}
parse(deck, url, frozen_fields_dict, data, context) {
let template = JSON.parse(JSON.stringify(data.template));
template["modelName"] = this.note_type;
if (this.no_note_type) {
return { note: template, identifier: NOTE_TYPE_ERROR };
}
template["fields"] = this.getFields();
const file_link_fields = data.file_link_fields;
if (url) {
this.formatter.format_note_with_url(template, url, file_link_fields[this.note_type]);
}
if (Object.keys(frozen_fields_dict).length) {
this.formatter.format_note_with_frozen_fields(template, frozen_fields_dict);
}
if (context) {
const context_field = data.context_fields[this.note_type];
template["fields"][context_field] += context;
}
if (data.add_obs_tags) {
for (let key in template["fields"]) {
for (let match of template["fields"][key].matchAll(OBS_TAG_REGEXP)) {
this.tags.push(match[1]);
}
template["fields"][key] = template["fields"][key].replace(OBS_TAG_REGEXP, "");
}
}
template["tags"].push(...this.tags);
template["deckName"] = deck;
return { note: template, identifier: this.identifier };
}
}
class Note extends AbstractNote {
getSplitText() {
return this.text.split("\n");
}
getIdentifier() {
if (this.ID_REGEXP.test(this.split_text[this.split_text.length - 1])) {
return parseInt(this.ID_REGEXP.exec(this.split_text.pop())[1]);
}
else {
return null;
}
}
getTags() {
if (this.split_text[this.split_text.length - 1].startsWith(TAG_PREFIX)) {
return this.split_text.pop().slice(TAG_PREFIX.length).split(TAG_SEP);
}
else {
return [];
}
}
getNoteType() {
return this.split_text[0];
}
fieldFromLine(line) {
/*From a given line, determine the next field to add text into.
Then, return the stripped line, and the field.*/
for (let field of this.field_names) {
if (line.startsWith(field + ":")) {
return [line.slice((field + ":").length), field];
}
}
return [line, this.current_field];
}
getFields() {
let fields = {};
for (let field of this.field_names) {
fields[field] = "";
}
for (let line of this.split_text.slice(1)) {
[line, this.current_field] = this.fieldFromLine(line);
fields[this.current_field] += line + "\n";
}
for (let key in fields) {
fields[key] = this.formatter.format(fields[key].trim(), this.note_type.includes("Cloze") && this.curly_cloze, this.highlights_to_cloze).trim();
}
return fields;
}
}
class InlineNote extends AbstractNote {
static TAG_REGEXP = /Tags: (.*)/;
static ID_REGEXP = /(?:<!--)?ID: (\d+)/;
static TYPE_REGEXP = /\[(.*?)\]/;
getSplitText() {
return this.text.split(" ");
}
getIdentifier() {
const result = this.text.match(InlineNote.ID_REGEXP);
if (result) {
this.text = this.text.slice(0, result.index).trim();
return parseInt(result[1]);
}
else {
return null;
}
}
getTags() {
const result = this.text.match(InlineNote.TAG_REGEXP);
if (result) {
this.text = this.text.slice(0, result.index).trim();
return result[1].split(TAG_SEP);
}
else {
return [];
}
}
getNoteType() {
const result = this.text.match(InlineNote.TYPE_REGEXP);
this.text = this.text.slice(result.index + result[0].length);
return result[1];
}
getFields() {
let fields = {};
for (let field of this.field_names) {
fields[field] = "";
}
for (let word of this.text.split(" ")) {
for (let field of this.field_names) {
if (word === field + ":") {
this.current_field = field;
word = "";
}
}
fields[this.current_field] += word + " ";
}
for (let key in fields) {
fields[key] = this.formatter.format(fields[key].trim(), this.note_type.includes("Cloze") && this.curly_cloze, this.highlights_to_cloze).trim();
}
return fields;
}
}
class RegexNote {
match;
note_type;
groups;
identifier;
tags;
field_names;
curly_cloze;
highlights_to_cloze;
formatter;
constructor(match, note_type, fields_dict, tags, id, curly_cloze, highlights_to_cloze, formatter) {
this.match = match;
this.note_type = note_type;
this.identifier = id ? parseInt(this.match.pop()) : null;
this.tags = tags ? this.match.pop().slice(TAG_PREFIX.length).split(TAG_SEP) : [];
this.field_names = fields_dict[note_type];
this.curly_cloze = curly_cloze;
this.formatter = formatter;
this.highlights_to_cloze = highlights_to_cloze;
}
getFields() {
let fields = {};
for (let field of this.field_names) {
fields[field] = "";
}
for (let index in this.match.slice(1)) {
fields[this.field_names[index]] = this.match.slice(1)[index] ? this.match.slice(1)[index] : "";
}
for (let key in fields) {
fields[key] = this.formatter.format(fields[key].trim(), this.note_type.includes("Cloze") && this.curly_cloze, this.highlights_to_cloze).trim();
}
return fields;
}
parse(deck, url = "", frozen_fields_dict, data, context) {
let template = JSON.parse(JSON.stringify(data.template));
template["modelName"] = this.note_type;
template["fields"] = this.getFields();
const file_link_fields = data.file_link_fields;
if (url) {
this.formatter.format_note_with_url(template, url, file_link_fields[this.note_type]);
}
if (Object.keys(frozen_fields_dict).length) {
this.formatter.format_note_with_frozen_fields(template, frozen_fields_dict);
}
if (context) {
const context_field = data.context_fields[this.note_type];
template["fields"][context_field] += context;
}
if (this.note_type.includes("Cloze") && !(note_has_clozes(template))) {
this.identifier = CLOZE_ERROR; //An error code that says "don't add this note!"
}
if (data.add_obs_tags) {
for (let key in template["fields"]) {
for (let match of template["fields"][key].matchAll(OBS_TAG_REGEXP)) {
this.tags.push(match[1]);
}
template["fields"][key] = template["fields"][key].replace(OBS_TAG_REGEXP, "");
}
}
template["tags"].push(...this.tags);
template["deckName"] = deck;
return { note: template, identifier: this.identifier };
}
}
async function settingToData(app, settings, fields_dict) {
let result = {};
//Some processing required
result.vault_name = app.vault.getName();
result.fields_dict = fields_dict;
result.custom_regexps = settings.CUSTOM_REGEXPS;
result.file_link_fields = settings.FILE_LINK_FIELDS;
result.context_fields = settings.CONTEXT_FIELDS;
result.folder_decks = settings.FOLDER_DECKS;
result.folder_tags = settings.FOLDER_TAGS;
result.template = {
deckName: settings.Defaults.Deck,
modelName: "",
fields: {},
options: {
allowDuplicate: false,
duplicateScope: "deck"
},
tags: [settings.Defaults.Tag]
};
result.EXISTING_IDS = await invoke('findNotes', { query: "" });
//RegExp section
result.FROZEN_REGEXP = new RegExp(escapeRegex(settings.Syntax["Frozen Fields Line"]) + String.raw ` - (.*?):\n((?:[^\n][\n]?)+)`, "g");
result.DECK_REGEXP = new RegExp(String.raw `^` + escapeRegex(settings.Syntax["Target Deck Line"]) + String.raw `(?:\n|: )(.*)`, "m");
result.TAG_REGEXP = new RegExp(String.raw `^` + escapeRegex(settings.Syntax["File Tags Line"]) + String.raw `(?:\n|: )(.*)`, "m");
result.NOTE_REGEXP = new RegExp(String.raw `^` + escapeRegex(settings.Syntax["Begin Note"]) + String.raw `\n([\s\S]*?\n)` + escapeRegex(settings.Syntax["End Note"]), "gm");
result.INLINE_REGEXP = new RegExp(escapeRegex(settings.Syntax["Begin Inline Note"]) + String.raw `(.*?)` + escapeRegex(settings.Syntax["End Inline Note"]), "g");
result.EMPTY_REGEXP = new RegExp(escapeRegex(settings.Syntax["Delete Note Line"]) + ID_REGEXP_STR, "g");
//Just a simple transfer
result.curly_cloze = settings.Defaults.CurlyCloze;
result.highlights_to_cloze = settings.Defaults["CurlyCloze - Highlights to Clozes"];
result.add_file_link = settings.Defaults["Add File Link"];
result.comment = settings.Defaults["ID Comments"];
result.add_context = settings.Defaults["Add Context"];
result.add_obs_tags = settings.Defaults["Add Obsidian Tags"];
result.ignored_file_globs = settings.IGNORED_FILE_GLOBS ?? [];
return result;
}
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
function createCommonjsModule(fn, basedir, module) {
return module = {
path: basedir,
exports: {},
require: function (path, base) {
return commonjsRequire(path, (base === undefined || base === null) ? module.path : base);
}
}, fn(module, module.exports), module.exports;
}
function commonjsRequire () {
throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
}
var md5 = createCommonjsModule(function (module, exports) {
/*
TypeScript Md5
==============
Based on work by
* Joseph Myers: http://www.myersdaily.org/joseph/javascript/md5-text.html
* André Cruz: https://github.com/satazor/SparkMD5
* Raymond Hill: https://github.com/gorhill/yamd5.js
Effectively a TypeScrypt re-write of Raymond Hill JS Library
The MIT License (MIT)
Copyright (C) 2014 Raymond Hill
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
DO WHAT YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2015 André Cruz <amdfcruz@gmail.com>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT YOU WANT TO.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.Md5 = void 0;
var Md5 = /** @class */ (function () {
function Md5() {
this._dataLength = 0;
this._bufferLength = 0;
this._state = new Int32Array(4);
this._buffer = new ArrayBuffer(68);
this._buffer8 = new Uint8Array(this._buffer, 0, 68);
this._buffer32 = new Uint32Array(this._buffer, 0, 17);
this.start();
}
Md5.hashStr = function (str, raw) {
if (raw === void 0) { raw = false; }
return this.onePassHasher
.start()
.appendStr(str)
.end(raw);
};
Md5.hashAsciiStr = function (str, raw) {
if (raw === void 0) { raw = false; }
return this.onePassHasher
.start()
.appendAsciiStr(str)
.end(raw);
};
Md5._hex = function (x) {
var hc = Md5.hexChars;
var ho = Md5.hexOut;
var n;
var offset;
var j;
var i;
for (i = 0; i < 4; i += 1) {
offset = i * 8;
n = x[i];
for (j = 0; j < 8; j += 2) {
ho[offset + 1 + j] = hc.charAt(n & 0x0F);
n >>>= 4;
ho[offset + 0 + j] = hc.charAt(n & 0x0F);
n >>>= 4;
}
}
return ho.join('');
};
Md5._md5cycle = function (x, k) {
var a = x[0];
var b = x[1];
var c = x[2];
var d = x[3];
// ff()
a += (b & c | ~b & d) + k[0] - 680876936 | 0;
a = (a << 7 | a >>> 25) + b | 0;
d += (a & b | ~a & c) + k[1] - 389564586 | 0;
d = (d << 12 | d >>> 20) + a | 0;
c += (d & a | ~d & b) + k[2] + 606105819 | 0;
c = (c << 17 | c >>> 15) + d | 0;
b += (c & d | ~c & a) + k[3] - 1044525330 | 0;
b = (b << 22 | b >>> 10) + c | 0;
a += (b & c | ~b & d) + k[4] - 176418897 | 0;
a = (a << 7 | a >>> 25) + b | 0;
d += (a & b | ~a & c) + k[5] + 1200080426 | 0;
d = (d << 12 | d >>> 20) + a | 0;
c += (d & a | ~d & b) + k[6] - 1473231341 | 0;
c = (c << 17 | c >>> 15) + d | 0;
b += (c & d | ~c & a) + k[7] - 45705983 | 0;
b = (b << 22 | b >>> 10) + c | 0;
a += (b & c | ~b & d) + k[8] + 1770035416 | 0;
a = (a << 7 | a >>> 25) + b | 0;
d += (a & b | ~a & c) + k[9] - 1958414417 | 0;
d = (d << 12 | d >>> 20) + a | 0;
c += (d & a | ~d & b) + k[10] - 42063 | 0;
c = (c << 17 | c >>> 15) + d | 0;
b += (c & d | ~c & a) + k[11] - 1990404162 | 0;
b = (b << 22 | b >>> 10) + c | 0;
a += (b & c | ~b & d) + k[12] + 1804603682 | 0;
a = (a << 7 | a >>> 25) + b | 0;
d += (a & b | ~a & c) + k[13] - 40341101 | 0;
d = (d << 12 | d >>> 20) + a | 0;
c += (d & a | ~d & b) + k[14] - 1502002290 | 0;
c = (c << 17 | c >>> 15) + d | 0;
b += (c & d | ~c & a) + k[15] + 1236535329 | 0;
b = (b << 22 | b >>> 10) + c | 0;
// gg()
a += (b & d | c & ~d) + k[1] - 165796510 | 0;
a = (a << 5 | a >>> 27) + b | 0;
d += (a & c | b & ~c) + k[6] - 1069501632 | 0;
d = (d << 9 | d >>> 23) + a | 0;
c += (d & b | a & ~b) + k[11] + 643717713 | 0;
c = (c << 14 | c >>> 18) + d | 0;
b += (c & a | d & ~a) + k[0] - 373897302 | 0;
b = (b << 20 | b >>> 12) + c | 0;
a += (b & d | c & ~d) + k[5] - 701558691 | 0;
a = (a << 5 | a >>> 27) + b | 0;
d += (a & c | b & ~c) + k[10] + 38016083 | 0;
d = (d << 9 | d >>> 23) + a | 0;
c += (d & b | a & ~b) + k[15] - 660478335 | 0;
c = (c << 14 | c >>> 18) + d | 0;
b += (c & a | d & ~a) + k[4] - 405537848 | 0;
b = (b << 20 | b >>> 12) + c | 0;
a += (b & d | c & ~d) + k[9] + 568446438 | 0;
a = (a << 5 | a >>> 27) + b | 0;
d += (a & c | b & ~c) + k[14] - 1019803690 | 0;
d = (d << 9 | d >>> 23) + a | 0;
c += (d & b | a & ~b) + k[3] - 187363961 | 0;
c = (c << 14 | c >>> 18) + d | 0;
b += (c & a | d & ~a) + k[8] + 1163531501 | 0;
b = (b << 20 | b >>> 12) + c | 0;
a += (b & d | c & ~d) + k[13] - 1444681467 | 0;
a = (a << 5 | a >>> 27) + b | 0;
d += (a & c | b & ~c) + k[2] - 51403784 | 0;
d = (d << 9 | d >>> 23) + a | 0;
c += (d & b | a & ~b) + k[7] + 1735328473 | 0;
c = (c << 14 | c >>> 18) + d | 0;
b += (c & a | d & ~a) + k[12] - 1926607734 | 0;
b = (b << 20 | b >>> 12) + c | 0;
// hh()
a += (b ^ c ^ d) + k[5] - 378558 | 0;
a = (a << 4 | a >>> 28) + b | 0;
d += (a ^ b ^ c) + k[8] - 2022574463 | 0;
d = (d << 11 | d >>> 21) + a | 0;
c += (d ^ a ^ b) + k[11] + 1839030562 | 0;
c = (c << 16 | c >>> 16) + d | 0;
b += (c ^ d ^ a) + k[14] - 35309556 | 0;
b = (b << 23 | b >>> 9) + c | 0;
a += (b ^ c ^ d) + k[1] - 1530992060 | 0;
a = (a << 4 | a >>> 28) + b | 0;
d += (a ^ b ^ c) + k[4] + 1272893353 | 0;
d = (d << 11 | d >>> 21) + a | 0;
c += (d ^ a ^ b) + k[7] - 155497632 | 0;
c = (c << 16 | c >>> 16) + d | 0;
b += (c ^ d ^ a) + k[10] - 1094730640 | 0;
b = (b << 23 | b >>> 9) + c | 0;
a += (b ^ c ^ d) + k[13] + 681279174 | 0;
a = (a << 4 | a >>> 28) + b | 0;
d += (a ^ b ^ c) + k[0] - 358537222 | 0;
d = (d << 11 | d >>> 21) + a | 0;
c += (d ^ a ^ b) + k[3] - 722521979 | 0;
c = (c << 16 | c >>> 16) + d | 0;
b += (c ^ d ^ a) + k[6] + 76029189 | 0;
b = (b << 23 | b >>> 9) + c | 0;
a += (b ^ c ^ d) + k[9] - 640364487 | 0;
a = (a << 4 | a >>> 28) + b | 0;
d += (a ^ b ^ c) + k[12] - 421815835 | 0;
d = (d << 11 | d >>> 21) + a | 0;
c += (d ^ a ^ b) + k[15] + 530742520 | 0;
c = (c << 16 | c >>> 16) + d | 0;
b += (c ^ d ^ a) + k[2] - 995338651 | 0;
b = (b << 23 | b >>> 9) + c | 0;
// ii()
a += (c ^ (b | ~d)) + k[0] - 198630844 | 0;
a = (a << 6 | a >>> 26) + b | 0;
d += (b ^ (a | ~c)) + k[7] + 1126891415 | 0;
d = (d << 10 | d >>> 22) + a | 0;
c += (a ^ (d | ~b)) + k[14] - 1416354905 | 0;
c = (c << 15 | c >>> 17) + d | 0;
b += (d ^ (c | ~a)) + k[5] - 57434055 | 0;
b = (b << 21 | b >>> 11) + c | 0;
a += (c ^ (b | ~d)) + k[12] + 1700485571 | 0;
a = (a << 6 | a >>> 26) + b | 0;
d += (b ^ (a | ~c)) + k[3] - 1894986606 | 0;
d = (d << 10 | d >>> 22) + a | 0;
c += (a ^ (d | ~b)) + k[10] - 1051523 | 0;
c = (c << 15 | c >>> 17) + d | 0;
b += (d ^ (c | ~a)) + k[1] - 2054922799 | 0;
b = (b << 21 | b >>> 11) + c | 0;
a += (c ^ (b | ~d)) + k[8] + 1873313359 | 0;
a = (a << 6 | a >>> 26) + b | 0;
d += (b ^ (a | ~c)) + k[15] - 30611744 | 0;
d = (d << 10 | d >>> 22) + a | 0;
c += (a ^ (d | ~b)) + k[6] - 1560198380 | 0;
c = (c << 15 | c >>> 17) + d | 0;
b += (d ^ (c | ~a)) + k[13] + 1309151649 | 0;
b = (b << 21 | b >>> 11) + c | 0;
a += (c ^ (b | ~d)) + k[4] - 145523070 | 0;
a = (a << 6 | a >>> 26) + b | 0;
d += (b ^ (a | ~c)) + k[11] - 1120210379 | 0;
d = (d << 10 | d >>> 22) + a | 0;
c += (a ^ (d | ~b)) + k[2] + 718787259 | 0;
c = (c << 15 | c >>> 17) + d | 0;
b += (d ^ (c | ~a)) + k[9] - 343485551 | 0;
b = (b << 21 | b >>> 11) + c | 0;
x[0] = a + x[0] | 0;
x[1] = b + x[1] | 0;
x[2] = c + x[2] | 0;
x[3] = d + x[3] | 0;
};
/**
* Initialise buffer to be hashed
*/
Md5.prototype.start = function () {
this._dataLength = 0;
this._bufferLength = 0;
this._state.set(Md5.stateIdentity);
return this;
};
// Char to code point to to array conversion:
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/charCodeAt
// #Example.3A_Fixing_charCodeAt_to_handle_non-Basic-Multilingual-Plane_characters_if_their_presence_earlier_in_the_string_is_unknown
/**
* Append a UTF-8 string to the hash buffer
* @param str String to append
*/
Md5.prototype.appendStr = function (str) {
var buf8 = this._buffer8;
var buf32 = this._buffer32;
var bufLen = this._bufferLength;
var code;
var i;
for (i = 0; i < str.length; i += 1) {
code = str.charCodeAt(i);
if (code < 128) {
buf8[bufLen++] = code;
}
else if (code < 0x800) {
buf8[bufLen++] = (code >>> 6) + 0xC0;
buf8[bufLen++] = code & 0x3F | 0x80;
}
else if (code < 0xD800 || code > 0xDBFF) {
buf8[bufLen++] = (code >>> 12) + 0xE0;
buf8[bufLen++] = (code >>> 6 & 0x3F) | 0x80;
buf8[bufLen++] = (code & 0x3F) | 0x80;
}
else {
code = ((code - 0xD800) * 0x400) + (str.charCodeAt(++i) - 0xDC00) + 0x10000;
if (code > 0x10FFFF) {
throw new Error('Unicode standard supports code points up to U+10FFFF');
}
buf8[bufLen++] = (code >>> 18) + 0xF0;
buf8[bufLen++] = (code >>> 12 & 0x3F) | 0x80;
buf8[bufLen++] = (code >>> 6 & 0x3F) | 0x80;
buf8[bufLen++] = (code & 0x3F) | 0x80;
}
if (bufLen >= 64) {
this._dataLength += 64;
Md5._md5cycle(this._state, buf32);
bufLen -= 64;
buf32[0] = buf32[16];
}
}
this._bufferLength = bufLen;
return this;
};
/**
* Append an ASCII string to the hash buffer
* @param str String to append
*/
Md5.prototype.appendAsciiStr = function (str) {
var buf8 = this._buffer8;
var buf32 = this._buffer32;
var bufLen = this._bufferLength;
var i;
var j = 0;
for (;;) {
i = Math.min(str.length - j, 64 - bufLen);
while (i--) {
buf8[bufLen++] = str.charCodeAt(j++);
}
if (bufLen < 64) {
break;
}
this._dataLength += 64;
Md5._md5cycle(this._state, buf32);
bufLen = 0;
}
this._bufferLength = bufLen;
return this;
};
/**
* Append a byte array to the hash buffer
* @param input array to append
*/
Md5.prototype.appendByteArray = function (input) {
var buf8 = this._buffer8;
var buf32 = this._buffer32;
var bufLen = this._bufferLength;
var i;
var j = 0;
for (;;) {
i = Math.min(input.length - j, 64 - bufLen);
while (i--) {
buf8[bufLen++] = input[j++];
}
if (bufLen < 64) {
break;
}
this._dataLength += 64;
Md5._md5cycle(this._state, buf32);
bufLen = 0;
}
this._bufferLength = bufLen;
return this;
};
/**
* Get the state of the hash buffer
*/
Md5.prototype.getState = function () {
var s = this._state;
return {
buffer: String.fromCharCode.apply(null, Array.from(this._buffer8)),
buflen: this._bufferLength,
length: this._dataLength,
state: [s[0], s[1], s[2], s[3]]
};
};
/**
* Override the current state of the hash buffer
* @param state New hash buffer state
*/
Md5.prototype.setState = function (state) {
var buf = state.buffer;
var x = state.state;
var s = this._state;
var i;
this._dataLength = state.length;
this._bufferLength = state.buflen;
s[0] = x[0];
s[1] = x[1];
s[2] = x[2];
s[3] = x[3];
for (i = 0; i < buf.length; i += 1) {
this._buffer8[i] = buf.charCodeAt(i);
}
};
/**
* Hash the current state of the hash buffer and return the result
* @param raw Whether to return the value as an `Int32Array`
*/
Md5.prototype.end = function (raw) {
if (raw === void 0) { raw = false; }
var bufLen = this._bufferLength;
var buf8 = this._buffer8;
var buf32 = this._buffer32;
var i = (bufLen >> 2) + 1;
this._dataLength += bufLen;
var dataBitsLen = this._dataLength * 8;
buf8[bufLen] = 0x80;
buf8[bufLen + 1] = buf8[bufLen + 2] = buf8[bufLen + 3] = 0;
buf32.set(Md5.buffer32Identity.subarray(i), i);
if (bufLen > 55) {
Md5._md5cycle(this._state, buf32);
buf32.set(Md5.buffer32Identity);
}
// Do the final computation based on the tail and length
// Beware that the final length may not fit in 32 bits so we take care of that
if (dataBitsLen <= 0xFFFFFFFF) {
buf32[14] = dataBitsLen;
}
else {
var matches = dataBitsLen.toString(16).match(/(.*?)(.{0,8})$/);
if (matches === null) {
return;
}
var lo = parseInt(matches[2], 16);
var hi = parseInt(matches[1], 16) || 0;
buf32[14] = lo;
buf32[15] = hi;
}
Md5._md5cycle(this._state, buf32);
return raw ? this._state : Md5._hex(this._state);
};
// Private Static Variables
Md5.stateIdentity = new Int32Array([1732584193, -271733879, -1732584194, 271733878]);
Md5.buffer32Identity = new Int32Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
Md5.hexChars = '0123456789abcdef';
Md5.hexOut = [];
// Permanent instance is to use for one-call hashing
Md5.onePassHasher = new Md5();
return Md5;
}());
exports.Md5 = Md5;
if (Md5.hashStr('hello') !== '5d41402abc4b2a76b9719d911017c592') {
throw new Error('Md5 self test failed.');
}
});
var showdown = createCommonjsModule(function (module) {
(function(){
/**
* Created by Tivie on 13-07-2015.
*/
function getDefaultOpts (simple) {
var defaultOptions = {
omitExtraWLInCodeBlocks: {
defaultValue: false,
describe: 'Omit the default extra whiteline added to code blocks',
type: 'boolean'
},
noHeaderId: {
defaultValue: false,
describe: 'Turn on/off generated header id',
type: 'boolean'
},
prefixHeaderId: {
defaultValue: false,
describe: 'Add a prefix to the generated header ids. Passing a string will prefix that string to the header id. Setting to true will add a generic \'section-\' prefix',
type: 'string'
},
rawPrefixHeaderId: {
defaultValue: false,
describe: 'Setting this option to true will prevent showdown from modifying the prefix. This might result in malformed IDs (if, for instance, the " char is used in the prefix)',
type: 'boolean'
},
ghCompatibleHeaderId: {
defaultValue: false,
describe: 'Generate header ids compatible with github style (spaces are replaced with dashes, a bunch of non alphanumeric chars are removed)',
type: 'boolean'
},
rawHeaderId: {
defaultValue: false,
describe: 'Remove only spaces, \' and " from generated header ids (including prefixes), replacing them with dashes (-). WARNING: This might result in malformed ids',
type: 'boolean'
},
headerLevelStart: {
defaultValue: false,
describe: 'The header blocks level start',
type: 'integer'
},
parseImgDimensions: {
defaultValue: false,
describe: 'Turn on/off image dimension parsing',
type: 'boolean'
},
simplifiedAutoLink: {
defaultValue: false,
describe: 'Turn on/off GFM autolink style',
type: 'boolean'
},
excludeTrailingPunctuationFromURLs: {
defaultValue: false,
describe: 'Excludes trailing punctuation from links generated with autoLinking',
type: 'boolean'
},
literalMidWordUnderscores: {
defaultValue: false,
describe: 'Parse midword underscores as literal underscores',
type: 'boolean'
},
literalMidWordAsterisks: {
defaultValue: false,
describe: 'Parse midword asterisks as literal asterisks',
type: 'boolean'
},
strikethrough: {
defaultValue: false,
describe: 'Turn on/off strikethrough support',
type: 'boolean'
},
tables: {
defaultValue: false,
describe: 'Turn on/off tables support',
type: 'boolean'
},
tablesHeaderId: {
defaultValue: false,
describe: 'Add an id to table headers',
type: 'boolean'
},
ghCodeBlocks: {
defaultValue: true,
describe: 'Turn on/off GFM fenced code blocks support',
type: 'boolean'
},
tasklists: {
defaultValue: false,
describe: 'Turn on/off GFM tasklist support',
type: 'boolean'
},
smoothLivePreview: {
defaultValue: false,
describe: 'Prevents weird effects in live previews due to incomplete input',
type: 'boolean'
},
smartIndentationFix: {
defaultValue: false,
describe: 'Tries to smartly fix indentation in es6 strings',
type: 'boolean'
},
disableForced4SpacesIndentedSublists: {
defaultValue: false,
describe: 'Disables the requirement of indenting nested sublists by 4 spaces',
type: 'boolean'
},
simpleLineBreaks: {
defaultValue: false,
describe: 'Parses simple line breaks as <br> (GFM Style)',
type: 'boolean'
},
requireSpaceBeforeHeadingText: {
defaultValue: false,
describe: 'Makes adding a space between `#` and the header text mandatory (GFM Style)',
type: 'boolean'
},
ghMentions: {
defaultValue: false,
describe: 'Enables github @mentions',
type: 'boolean'
},
ghMentionsLink: {
defaultValue: 'https://github.com/{u}',
describe: 'Changes the link generated by @mentions. Only applies if ghMentions option is enabled.',
type: 'string'
},
encodeEmails: {
defaultValue: true,
describe: 'Encode e-mail addresses through the use of Character Entities, transforming ASCII e-mail addresses into its equivalent decimal entities',
type: 'boolean'
},
openLinksInNewWindow: {
defaultValue: false,
describe: 'Open all links in new windows',
type: 'boolean'
},
backslashEscapesHTMLTags: {
defaultValue: false,
describe: 'Support for HTML Tag escaping. ex: \<div>foo\</div>',
type: 'boolean'
},
emoji: {
defaultValue: false,
describe: 'Enable emoji support. Ex: `this is a :smile: emoji`',
type: 'boolean'
},
underline: {
defaultValue: false,
describe: 'Enable support for underline. Syntax is double or triple underscores: `__underline word__`. With this option enabled, underscores no longer parses into `<em>` and `<strong>`',
type: 'boolean'
},
ellipsis: {
defaultValue: true,
describe: 'Replaces three dots with the ellipsis unicode character',
type: 'boolean'
},
completeHTMLDocument: {
defaultValue: false,
describe: 'Outputs a complete html document, including `<html>`, `<head>` and `<body>` tags',
type: 'boolean'
},
metadata: {
defaultValue: false,
describe: 'Enable support for document metadata (defined at the top of the document between `«««` and `»»»` or between `---` and `---`).',
type: 'boolean'
},
splitAdjacentBlockquotes: {
defaultValue: false,
describe: 'Split adjacent blockquote blocks',
type: 'boolean'
}
};
if (simple === false) {
return JSON.parse(JSON.stringify(defaultOptions));
}
var ret = {};
for (var opt in defaultOptions) {
if (defaultOptions.hasOwnProperty(opt)) {
ret[opt] = defaultOptions[opt].defaultValue;
}
}
return ret;
}
function allOptionsOn () {
var options = getDefaultOpts(true),
ret = {};
for (var opt in options) {
if (options.hasOwnProperty(opt)) {
ret[opt] = true;
}
}
return ret;
}
/**
* Created by Tivie on 06-01-2015.
*/
// Private properties
var showdown = {},
parsers = {},
extensions = {},
globalOptions = getDefaultOpts(true),
setFlavor = 'vanilla',
flavor = {
github: {
omitExtraWLInCodeBlocks: true,
simplifiedAutoLink: true,
excludeTrailingPunctuationFromURLs: true,
literalMidWordUnderscores: true,
strikethrough: true,
tables: true,
tablesHeaderId: true,
ghCodeBlocks: true,
tasklists: true,
disableForced4SpacesIndentedSublists: true,
simpleLineBreaks: true,
requireSpaceBeforeHeadingText: true,
ghCompatibleHeaderId: true,
ghMentions: true,
backslashEscapesHTMLTags: true,
emoji: true,
splitAdjacentBlockquotes: true
},
original: {
noHeaderId: true,
ghCodeBlocks: false
},
ghost: {
omitExtraWLInCodeBlocks: true,
parseImgDimensions: true,
simplifiedAutoLink: true,
excludeTrailingPunctuationFromURLs: true,
literalMidWordUnderscores: true,
strikethrough: true,
tables: true,
tablesHeaderId: true,
ghCodeBlocks: true,
tasklists: true,
smoothLivePreview: true,
simpleLineBreaks: true,
requireSpaceBeforeHeadingText: true,
ghMentions: false,
encodeEmails: true
},
vanilla: getDefaultOpts(true),
allOn: allOptionsOn()
};
/**
* helper namespace
* @type {{}}
*/
showdown.helper = {};
/**
* TODO LEGACY SUPPORT CODE
* @type {{}}
*/
showdown.extensions = {};
/**
* Set a global option
* @static
* @param {string} key
* @param {*} value
* @returns {showdown}
*/
showdown.setOption = function (key, value) {
globalOptions[key] = value;
return this;
};
/**
* Get a global option
* @static
* @param {string} key
* @returns {*}
*/
showdown.getOption = function (key) {
return globalOptions[key];
};
/**
* Get the global options
* @static
* @returns {{}}
*/
showdown.getOptions = function () {
return globalOptions;
};
/**
* Reset global options to the default values
* @static
*/
showdown.resetOptions = function () {
globalOptions = getDefaultOpts(true);
};
/**
* Set the flavor showdown should use as default
* @param {string} name
*/
showdown.setFlavor = function (name) {
if (!flavor.hasOwnProperty(name)) {
throw Error(name + ' flavor was not found');
}
showdown.resetOptions();
var preset = flavor[name];
setFlavor = name;
for (var option in preset) {
if (preset.hasOwnProperty(option)) {
globalOptions[option] = preset[option];
}
}
};
/**
* Get the currently set flavor
* @returns {string}
*/
showdown.getFlavor = function () {
return setFlavor;
};
/**
* Get the options of a specified flavor. Returns undefined if the flavor was not found
* @param {string} name Name of the flavor
* @returns {{}|undefined}
*/
showdown.getFlavorOptions = function (name) {
if (flavor.hasOwnProperty(name)) {
return flavor[name];
}
};
/**
* Get the default options
* @static
* @param {boolean} [simple=true]
* @returns {{}}
*/
showdown.getDefaultOptions = function (simple) {
return getDefaultOpts(simple);
};
/**
* Get or set a subParser
*
* subParser(name) - Get a registered subParser
* subParser(name, func) - Register a subParser
* @static
* @param {string} name
* @param {function} [func]
* @returns {*}
*/
showdown.subParser = function (name, func) {
if (showdown.helper.isString(name)) {
if (typeof func !== 'undefined') {
parsers[name] = func;
} else {
if (parsers.hasOwnProperty(name)) {
return parsers[name];
} else {
throw Error('SubParser named ' + name + ' not registered!');
}
}
}
};
/**
* Gets or registers an extension
* @static
* @param {string} name
* @param {object|object[]|function=} ext
* @returns {*}
*/
showdown.extension = function (name, ext) {
if (!showdown.helper.isString(name)) {
throw Error('Extension \'name\' must be a string');
}
name = showdown.helper.stdExtName(name);
// Getter
if (showdown.helper.isUndefined(ext)) {
if (!extensions.hasOwnProperty(name)) {
throw Error('Extension named ' + name + ' is not registered!');
}
return extensions[name];
// Setter
} else {
// Expand extension if it's wrapped in a function
if (typeof ext === 'function') {
ext = ext();
}
// Ensure extension is an array
if (!showdown.helper.isArray(ext)) {
ext = [ext];
}
var validExtension = validate(ext, name);
if (validExtension.valid) {
extensions[name] = ext;
} else {
throw Error(validExtension.error);
}
}
};
/**
* Gets all extensions registered
* @returns {{}}
*/
showdown.getAllExtensions = function () {
return extensions;
};
/**
* Remove an extension
* @param {string} name
*/
showdown.removeExtension = function (name) {
delete extensions[name];
};
/**
* Removes all extensions
*/
showdown.resetExtensions = function () {
extensions = {};
};
/**
* Validate extension
* @param {array} extension
* @param {string} name
* @returns {{valid: boolean, error: string}}
*/
function validate (extension, name) {
var errMsg = (name) ? 'Error in ' + name + ' extension->' : 'Error in unnamed extension',
ret = {
valid: true,
error: ''
};
if (!showdown.helper.isArray(extension)) {
extension = [extension];
}
for (var i = 0; i < extension.length; ++i) {
var baseMsg = errMsg + ' sub-extension ' + i + ': ',
ext = extension[i];
if (typeof ext !== 'object') {
ret.valid = false;
ret.error = baseMsg + 'must be an object, but ' + typeof ext + ' given';
return ret;
}
if (!showdown.helper.isString(ext.type)) {
ret.valid = false;
ret.error = baseMsg + 'property "type" must be a string, but ' + typeof ext.type + ' given';
return ret;
}
var type = ext.type = ext.type.toLowerCase();
// normalize extension type
if (type === 'language') {
type = ext.type = 'lang';
}
if (type === 'html') {
type = ext.type = 'output';
}
if (type !== 'lang' && type !== 'output' && type !== 'listener') {
ret.valid = false;
ret.error = baseMsg + 'type ' + type + ' is not recognized. Valid values: "lang/language", "output/html" or "listener"';
return ret;
}
if (type === 'listener') {
if (showdown.helper.isUndefined(ext.listeners)) {
ret.valid = false;
ret.error = baseMsg + '. Extensions of type "listener" must have a property called "listeners"';
return ret;
}
} else {
if (showdown.helper.isUndefined(ext.filter) && showdown.helper.isUndefined(ext.regex)) {
ret.valid = false;
ret.error = baseMsg + type + ' extensions must define either a "regex" property or a "filter" method';
return ret;
}
}
if (ext.listeners) {
if (typeof ext.listeners !== 'object') {
ret.valid = false;
ret.error = baseMsg + '"listeners" property must be an object but ' + typeof ext.listeners + ' given';
return ret;
}
for (var ln in ext.listeners) {
if (ext.listeners.hasOwnProperty(ln)) {
if (typeof ext.listeners[ln] !== 'function') {
ret.valid = false;
ret.error = baseMsg + '"listeners" property must be an hash of [event name]: [callback]. listeners.' + ln +
' must be a function but ' + typeof ext.listeners[ln] + ' given';
return ret;
}
}
}
}
if (ext.filter) {
if (typeof ext.filter !== 'function') {
ret.valid = false;
ret.error = baseMsg + '"filter" must be a function, but ' + typeof ext.filter + ' given';
return ret;
}
} else if (ext.regex) {
if (showdown.helper.isString(ext.regex)) {
ext.regex = new RegExp(ext.regex, 'g');
}
if (!(ext.regex instanceof RegExp)) {
ret.valid = false;
ret.error = baseMsg + '"regex" property must either be a string or a RegExp object, but ' + typeof ext.regex + ' given';
return ret;
}
if (showdown.helper.isUndefined(ext.replace)) {
ret.valid = false;
ret.error = baseMsg + '"regex" extensions must implement a replace string or function';
return ret;
}
}
}
return ret;
}
/**
* Validate extension
* @param {object} ext
* @returns {boolean}
*/
showdown.validateExtension = function (ext) {
var validateExtension = validate(ext, null);
if (!validateExtension.valid) {
console.warn(validateExtension.error);
return false;
}
return true;
};
/**
* showdownjs helper functions
*/
if (!showdown.hasOwnProperty('helper')) {
showdown.helper = {};
}
/**
* Check if var is string
* @static
* @param {string} a
* @returns {boolean}
*/
showdown.helper.isString = function (a) {
return (typeof a === 'string' || a instanceof String);
};
/**
* Check if var is a function
* @static
* @param {*} a
* @returns {boolean}
*/
showdown.helper.isFunction = function (a) {
var getType = {};
return a && getType.toString.call(a) === '[object Function]';
};
/**
* isArray helper function
* @static
* @param {*} a
* @returns {boolean}
*/
showdown.helper.isArray = function (a) {
return Array.isArray(a);
};
/**
* Check if value is undefined
* @static
* @param {*} value The value to check.
* @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.
*/
showdown.helper.isUndefined = function (value) {
return typeof value === 'undefined';
};
/**
* ForEach helper function
* Iterates over Arrays and Objects (own properties only)
* @static
* @param {*} obj
* @param {function} callback Accepts 3 params: 1. value, 2. key, 3. the original array/object
*/
showdown.helper.forEach = function (obj, callback) {
// check if obj is defined
if (showdown.helper.isUndefined(obj)) {
throw new Error('obj param is required');
}
if (showdown.helper.isUndefined(callback)) {
throw new Error('callback param is required');
}
if (!showdown.helper.isFunction(callback)) {
throw new Error('callback param must be a function/closure');
}
if (typeof obj.forEach === 'function') {
obj.forEach(callback);
} else if (showdown.helper.isArray(obj)) {
for (var i = 0; i < obj.length; i++) {
callback(obj[i], i, obj);
}
} else if (typeof (obj) === 'object') {
for (var prop in obj) {
if (obj.hasOwnProperty(prop)) {
callback(obj[prop], prop, obj);
}
}
} else {
throw new Error('obj does not seem to be an array or an iterable object');
}
};
/**
* Standardidize extension name
* @static
* @param {string} s extension name
* @returns {string}
*/
showdown.helper.stdExtName = function (s) {
return s.replace(/[_?*+\/\\.^-]/g, '').replace(/\s/g, '').toLowerCase();
};
function escapeCharactersCallback (wholeMatch, m1) {
var charCodeToEscape = m1.charCodeAt(0);
return '¨E' + charCodeToEscape + 'E';
}
/**
* Callback used to escape characters when passing through String.replace
* @static
* @param {string} wholeMatch
* @param {string} m1
* @returns {string}
*/
showdown.helper.escapeCharactersCallback = escapeCharactersCallback;
/**
* Escape characters in a string
* @static
* @param {string} text
* @param {string} charsToEscape
* @param {boolean} afterBackslash
* @returns {XML|string|void|*}
*/
showdown.helper.escapeCharacters = function (text, charsToEscape, afterBackslash) {
// First we have to escape the escape characters so that
// we can build a character class out of them
var regexString = '([' + charsToEscape.replace(/([\[\]\\])/g, '\\$1') + '])';
if (afterBackslash) {
regexString = '\\\\' + regexString;
}
var regex = new RegExp(regexString, 'g');
text = text.replace(regex, escapeCharactersCallback);
return text;
};
/**
* Unescape HTML entities
* @param txt
* @returns {string}
*/
showdown.helper.unescapeHTMLEntities = function (txt) {
return txt
.replace(/&quot;/g, '"')
.replace(/&lt;/g, '<')
.replace(/&gt;/g, '>')
.replace(/&amp;/g, '&');
};
var rgxFindMatchPos = function (str, left, right, flags) {
var f = flags || '',
g = f.indexOf('g') > -1,
x = new RegExp(left + '|' + right, 'g' + f.replace(/g/g, '')),
l = new RegExp(left, f.replace(/g/g, '')),
pos = [],
t, s, m, start, end;
do {
t = 0;
while ((m = x.exec(str))) {
if (l.test(m[0])) {
if (!(t++)) {
s = x.lastIndex;
start = s - m[0].length;
}
} else if (t) {
if (!--t) {
end = m.index + m[0].length;
var obj = {
left: {start: start, end: s},
match: {start: s, end: m.index},
right: {start: m.index, end: end},
wholeMatch: {start: start, end: end}
};
pos.push(obj);
if (!g) {
return pos;
}
}
}
}
} while (t && (x.lastIndex = s));
return pos;
};
/**
* matchRecursiveRegExp
*
* (c) 2007 Steven Levithan <stevenlevithan.com>
* MIT License
*
* Accepts a string to search, a left and right format delimiter
* as regex patterns, and optional regex flags. Returns an array
* of matches, allowing nested instances of left/right delimiters.
* Use the "g" flag to return all matches, otherwise only the
* first is returned. Be careful to ensure that the left and
* right format delimiters produce mutually exclusive matches.
* Backreferences are not supported within the right delimiter
* due to how it is internally combined with the left delimiter.
* When matching strings whose format delimiters are unbalanced
* to the left or right, the output is intentionally as a
* conventional regex library with recursion support would
* produce, e.g. "<<x>" and "<x>>" both produce ["x"] when using
* "<" and ">" as the delimiters (both strings contain a single,
* balanced instance of "<x>").
*
* examples:
* matchRecursiveRegExp("test", "\\(", "\\)")
* returns: []
* matchRecursiveRegExp("<t<<e>><s>>t<>", "<", ">", "g")
* returns: ["t<<e>><s>", ""]
* matchRecursiveRegExp("<div id=\"x\">test</div>", "<div\\b[^>]*>", "</div>", "gi")
* returns: ["test"]
*/
showdown.helper.matchRecursiveRegExp = function (str, left, right, flags) {
var matchPos = rgxFindMatchPos (str, left, right, flags),
results = [];
for (var i = 0; i < matchPos.length; ++i) {
results.push([
str.slice(matchPos[i].wholeMatch.start, matchPos[i].wholeMatch.end),
str.slice(matchPos[i].match.start, matchPos[i].match.end),
str.slice(matchPos[i].left.start, matchPos[i].left.end),
str.slice(matchPos[i].right.start, matchPos[i].right.end)
]);
}
return results;
};
/**
*
* @param {string} str
* @param {string|function} replacement
* @param {string} left
* @param {string} right
* @param {string} flags
* @returns {string}
*/
showdown.helper.replaceRecursiveRegExp = function (str, replacement, left, right, flags) {
if (!showdown.helper.isFunction(replacement)) {
var repStr = replacement;
replacement = function () {
return repStr;
};
}
var matchPos = rgxFindMatchPos(str, left, right, flags),
finalStr = str,
lng = matchPos.length;
if (lng > 0) {
var bits = [];
if (matchPos[0].wholeMatch.start !== 0) {
bits.push(str.slice(0, matchPos[0].wholeMatch.start));
}
for (var i = 0; i < lng; ++i) {
bits.push(
replacement(
str.slice(matchPos[i].wholeMatch.start, matchPos[i].wholeMatch.end),
str.slice(matchPos[i].match.start, matchPos[i].match.end),
str.slice(matchPos[i].left.start, matchPos[i].left.end),
str.slice(matchPos[i].right.start, matchPos[i].right.end)
)
);
if (i < lng - 1) {
bits.push(str.slice(matchPos[i].wholeMatch.end, matchPos[i + 1].wholeMatch.start));
}
}
if (matchPos[lng - 1].wholeMatch.end < str.length) {
bits.push(str.slice(matchPos[lng - 1].wholeMatch.end));
}
finalStr = bits.join('');
}
return finalStr;
};
/**
* Returns the index within the passed String object of the first occurrence of the specified regex,
* starting the search at fromIndex. Returns -1 if the value is not found.
*
* @param {string} str string to search
* @param {RegExp} regex Regular expression to search
* @param {int} [fromIndex = 0] Index to start the search
* @returns {Number}
* @throws InvalidArgumentError
*/
showdown.helper.regexIndexOf = function (str, regex, fromIndex) {
if (!showdown.helper.isString(str)) {
throw 'InvalidArgumentError: first parameter of showdown.helper.regexIndexOf function must be a string';
}
if (regex instanceof RegExp === false) {
throw 'InvalidArgumentError: second parameter of showdown.helper.regexIndexOf function must be an instance of RegExp';
}
var indexOf = str.substring(fromIndex || 0).search(regex);
return (indexOf >= 0) ? (indexOf + (fromIndex || 0)) : indexOf;
};
/**
* Splits the passed string object at the defined index, and returns an array composed of the two substrings
* @param {string} str string to split
* @param {int} index index to split string at
* @returns {[string,string]}
* @throws InvalidArgumentError
*/
showdown.helper.splitAtIndex = function (str, index) {
if (!showdown.helper.isString(str)) {
throw 'InvalidArgumentError: first parameter of showdown.helper.regexIndexOf function must be a string';
}
return [str.substring(0, index), str.substring(index)];
};
/**
* Obfuscate an e-mail address through the use of Character Entities,
* transforming ASCII characters into their equivalent decimal or hex entities.
*
* Since it has a random component, subsequent calls to this function produce different results
*
* @param {string} mail
* @returns {string}
*/
showdown.helper.encodeEmailAddress = function (mail) {
var encode = [
function (ch) {
return '&#' + ch.charCodeAt(0) + ';';
},
function (ch) {
return '&#x' + ch.charCodeAt(0).toString(16) + ';';
},
function (ch) {
return ch;
}
];
mail = mail.replace(/./g, function (ch) {
if (ch === '@') {
// this *must* be encoded. I insist.
ch = encode[Math.floor(Math.random() * 2)](ch);
} else {
var r = Math.random();
// roughly 10% raw, 45% hex, 45% dec
ch = (
r > 0.9 ? encode[2](ch) : r > 0.45 ? encode[1](ch) : encode[0](ch)
);
}
return ch;
});
return mail;
};
/**
*
* @param str
* @param targetLength
* @param padString
* @returns {string}
*/
showdown.helper.padEnd = function padEnd (str, targetLength, padString) {
/*jshint bitwise: false*/
// eslint-disable-next-line space-infix-ops
targetLength = targetLength>>0; //floor if number or convert non-number to 0;
/*jshint bitwise: true*/
padString = String(padString || ' ');
if (str.length > targetLength) {
return String(str);
} else {
targetLength = targetLength - str.length;
if (targetLength > padString.length) {
padString += padString.repeat(targetLength / padString.length); //append to original to ensure we are longer than needed
}
return String(str) + padString.slice(0,targetLength);
}
};
/**
* POLYFILLS
*/
// use this instead of builtin is undefined for IE8 compatibility
if (typeof (console) === 'undefined') {
console = {
warn: function (msg) {
alert(msg);
},
log: function (msg) {
alert(msg);
},
error: function (msg) {
throw msg;
}
};
}
/**
* Common regexes.
* We declare some common regexes to improve performance
*/
showdown.helper.regexes = {
asteriskDashAndColon: /([*_:~])/g
};
/**
* EMOJIS LIST
*/
showdown.helper.emojis = {
'+1':'\ud83d\udc4d',
'-1':'\ud83d\udc4e',
'100':'\ud83d\udcaf',
'1234':'\ud83d\udd22',
'1st_place_medal':'\ud83e\udd47',
'2nd_place_medal':'\ud83e\udd48',
'3rd_place_medal':'\ud83e\udd49',
'8ball':'\ud83c\udfb1',
'a':'\ud83c\udd70\ufe0f',
'ab':'\ud83c\udd8e',
'abc':'\ud83d\udd24',
'abcd':'\ud83d\udd21',
'accept':'\ud83c\ude51',
'aerial_tramway':'\ud83d\udea1',
'airplane':'\u2708\ufe0f',
'alarm_clock':'\u23f0',
'alembic':'\u2697\ufe0f',
'alien':'\ud83d\udc7d',
'ambulance':'\ud83d\ude91',
'amphora':'\ud83c\udffa',
'anchor':'\u2693\ufe0f',
'angel':'\ud83d\udc7c',
'anger':'\ud83d\udca2',
'angry':'\ud83d\ude20',
'anguished':'\ud83d\ude27',
'ant':'\ud83d\udc1c',
'apple':'\ud83c\udf4e',
'aquarius':'\u2652\ufe0f',
'aries':'\u2648\ufe0f',
'arrow_backward':'\u25c0\ufe0f',
'arrow_double_down':'\u23ec',
'arrow_double_up':'\u23eb',
'arrow_down':'\u2b07\ufe0f',
'arrow_down_small':'\ud83d\udd3d',
'arrow_forward':'\u25b6\ufe0f',
'arrow_heading_down':'\u2935\ufe0f',
'arrow_heading_up':'\u2934\ufe0f',
'arrow_left':'\u2b05\ufe0f',
'arrow_lower_left':'\u2199\ufe0f',
'arrow_lower_right':'\u2198\ufe0f',
'arrow_right':'\u27a1\ufe0f',
'arrow_right_hook':'\u21aa\ufe0f',
'arrow_up':'\u2b06\ufe0f',
'arrow_up_down':'\u2195\ufe0f',
'arrow_up_small':'\ud83d\udd3c',
'arrow_upper_left':'\u2196\ufe0f',
'arrow_upper_right':'\u2197\ufe0f',
'arrows_clockwise':'\ud83d\udd03',
'arrows_counterclockwise':'\ud83d\udd04',
'art':'\ud83c\udfa8',
'articulated_lorry':'\ud83d\ude9b',
'artificial_satellite':'\ud83d\udef0',
'astonished':'\ud83d\ude32',
'athletic_shoe':'\ud83d\udc5f',
'atm':'\ud83c\udfe7',
'atom_symbol':'\u269b\ufe0f',
'avocado':'\ud83e\udd51',
'b':'\ud83c\udd71\ufe0f',
'baby':'\ud83d\udc76',
'baby_bottle':'\ud83c\udf7c',
'baby_chick':'\ud83d\udc24',
'baby_symbol':'\ud83d\udebc',
'back':'\ud83d\udd19',
'bacon':'\ud83e\udd53',
'badminton':'\ud83c\udff8',
'baggage_claim':'\ud83d\udec4',
'baguette_bread':'\ud83e\udd56',
'balance_scale':'\u2696\ufe0f',
'balloon':'\ud83c\udf88',
'ballot_box':'\ud83d\uddf3',
'ballot_box_with_check':'\u2611\ufe0f',
'bamboo':'\ud83c\udf8d',
'banana':'\ud83c\udf4c',
'bangbang':'\u203c\ufe0f',
'bank':'\ud83c\udfe6',
'bar_chart':'\ud83d\udcca',
'barber':'\ud83d\udc88',
'baseball':'\u26be\ufe0f',
'basketball':'\ud83c\udfc0',
'basketball_man':'\u26f9\ufe0f',
'basketball_woman':'\u26f9\ufe0f&zwj;\u2640\ufe0f',
'bat':'\ud83e\udd87',
'bath':'\ud83d\udec0',
'bathtub':'\ud83d\udec1',
'battery':'\ud83d\udd0b',
'beach_umbrella':'\ud83c\udfd6',
'bear':'\ud83d\udc3b',
'bed':'\ud83d\udecf',
'bee':'\ud83d\udc1d',
'beer':'\ud83c\udf7a',
'beers':'\ud83c\udf7b',
'beetle':'\ud83d\udc1e',
'beginner':'\ud83d\udd30',
'bell':'\ud83d\udd14',
'bellhop_bell':'\ud83d\udece',
'bento':'\ud83c\udf71',
'biking_man':'\ud83d\udeb4',
'bike':'\ud83d\udeb2',
'biking_woman':'\ud83d\udeb4&zwj;\u2640\ufe0f',
'bikini':'\ud83d\udc59',
'biohazard':'\u2623\ufe0f',
'bird':'\ud83d\udc26',
'birthday':'\ud83c\udf82',
'black_circle':'\u26ab\ufe0f',
'black_flag':'\ud83c\udff4',
'black_heart':'\ud83d\udda4',
'black_joker':'\ud83c\udccf',
'black_large_square':'\u2b1b\ufe0f',
'black_medium_small_square':'\u25fe\ufe0f',
'black_medium_square':'\u25fc\ufe0f',
'black_nib':'\u2712\ufe0f',
'black_small_square':'\u25aa\ufe0f',
'black_square_button':'\ud83d\udd32',
'blonde_man':'\ud83d\udc71',
'blonde_woman':'\ud83d\udc71&zwj;\u2640\ufe0f',
'blossom':'\ud83c\udf3c',
'blowfish':'\ud83d\udc21',
'blue_book':'\ud83d\udcd8',
'blue_car':'\ud83d\ude99',
'blue_heart':'\ud83d\udc99',
'blush':'\ud83d\ude0a',
'boar':'\ud83d\udc17',
'boat':'\u26f5\ufe0f',
'bomb':'\ud83d\udca3',
'book':'\ud83d\udcd6',
'bookmark':'\ud83d\udd16',
'bookmark_tabs':'\ud83d\udcd1',
'books':'\ud83d\udcda',
'boom':'\ud83d\udca5',
'boot':'\ud83d\udc62',
'bouquet':'\ud83d\udc90',
'bowing_man':'\ud83d\ude47',
'bow_and_arrow':'\ud83c\udff9',
'bowing_woman':'\ud83d\ude47&zwj;\u2640\ufe0f',
'bowling':'\ud83c\udfb3',
'boxing_glove':'\ud83e\udd4a',
'boy':'\ud83d\udc66',
'bread':'\ud83c\udf5e',
'bride_with_veil':'\ud83d\udc70',
'bridge_at_night':'\ud83c\udf09',
'briefcase':'\ud83d\udcbc',
'broken_heart':'\ud83d\udc94',
'bug':'\ud83d\udc1b',
'building_construction':'\ud83c\udfd7',
'bulb':'\ud83d\udca1',
'bullettrain_front':'\ud83d\ude85',
'bullettrain_side':'\ud83d\ude84',
'burrito':'\ud83c\udf2f',
'bus':'\ud83d\ude8c',
'business_suit_levitating':'\ud83d\udd74',
'busstop':'\ud83d\ude8f',
'bust_in_silhouette':'\ud83d\udc64',
'busts_in_silhouette':'\ud83d\udc65',
'butterfly':'\ud83e\udd8b',
'cactus':'\ud83c\udf35',
'cake':'\ud83c\udf70',
'calendar':'\ud83d\udcc6',
'call_me_hand':'\ud83e\udd19',
'calling':'\ud83d\udcf2',
'camel':'\ud83d\udc2b',
'camera':'\ud83d\udcf7',
'camera_flash':'\ud83d\udcf8',
'camping':'\ud83c\udfd5',
'cancer':'\u264b\ufe0f',
'candle':'\ud83d\udd6f',
'candy':'\ud83c\udf6c',
'canoe':'\ud83d\udef6',
'capital_abcd':'\ud83d\udd20',
'capricorn':'\u2651\ufe0f',
'car':'\ud83d\ude97',
'card_file_box':'\ud83d\uddc3',
'card_index':'\ud83d\udcc7',
'card_index_dividers':'\ud83d\uddc2',
'carousel_horse':'\ud83c\udfa0',
'carrot':'\ud83e\udd55',
'cat':'\ud83d\udc31',
'cat2':'\ud83d\udc08',
'cd':'\ud83d\udcbf',
'chains':'\u26d3',
'champagne':'\ud83c\udf7e',
'chart':'\ud83d\udcb9',
'chart_with_downwards_trend':'\ud83d\udcc9',
'chart_with_upwards_trend':'\ud83d\udcc8',
'checkered_flag':'\ud83c\udfc1',
'cheese':'\ud83e\uddc0',
'cherries':'\ud83c\udf52',
'cherry_blossom':'\ud83c\udf38',
'chestnut':'\ud83c\udf30',
'chicken':'\ud83d\udc14',
'children_crossing':'\ud83d\udeb8',
'chipmunk':'\ud83d\udc3f',
'chocolate_bar':'\ud83c\udf6b',
'christmas_tree':'\ud83c\udf84',
'church':'\u26ea\ufe0f',
'cinema':'\ud83c\udfa6',
'circus_tent':'\ud83c\udfaa',
'city_sunrise':'\ud83c\udf07',
'city_sunset':'\ud83c\udf06',
'cityscape':'\ud83c\udfd9',
'cl':'\ud83c\udd91',
'clamp':'\ud83d\udddc',
'clap':'\ud83d\udc4f',
'clapper':'\ud83c\udfac',
'classical_building':'\ud83c\udfdb',
'clinking_glasses':'\ud83e\udd42',
'clipboard':'\ud83d\udccb',
'clock1':'\ud83d\udd50',
'clock10':'\ud83d\udd59',
'clock1030':'\ud83d\udd65',
'clock11':'\ud83d\udd5a',
'clock1130':'\ud83d\udd66',
'clock12':'\ud83d\udd5b',
'clock1230':'\ud83d\udd67',
'clock130':'\ud83d\udd5c',
'clock2':'\ud83d\udd51',
'clock230':'\ud83d\udd5d',
'clock3':'\ud83d\udd52',
'clock330':'\ud83d\udd5e',
'clock4':'\ud83d\udd53',
'clock430':'\ud83d\udd5f',
'clock5':'\ud83d\udd54',
'clock530':'\ud83d\udd60',
'clock6':'\ud83d\udd55',
'clock630':'\ud83d\udd61',
'clock7':'\ud83d\udd56',
'clock730':'\ud83d\udd62',
'clock8':'\ud83d\udd57',
'clock830':'\ud83d\udd63',
'clock9':'\ud83d\udd58',
'clock930':'\ud83d\udd64',
'closed_book':'\ud83d\udcd5',
'closed_lock_with_key':'\ud83d\udd10',
'closed_umbrella':'\ud83c\udf02',
'cloud':'\u2601\ufe0f',
'cloud_with_lightning':'\ud83c\udf29',
'cloud_with_lightning_and_rain':'\u26c8',
'cloud_with_rain':'\ud83c\udf27',
'cloud_with_snow':'\ud83c\udf28',
'clown_face':'\ud83e\udd21',
'clubs':'\u2663\ufe0f',
'cocktail':'\ud83c\udf78',
'coffee':'\u2615\ufe0f',
'coffin':'\u26b0\ufe0f',
'cold_sweat':'\ud83d\ude30',
'comet':'\u2604\ufe0f',
'computer':'\ud83d\udcbb',
'computer_mouse':'\ud83d\uddb1',
'confetti_ball':'\ud83c\udf8a',
'confounded':'\ud83d\ude16',
'confused':'\ud83d\ude15',
'congratulations':'\u3297\ufe0f',
'construction':'\ud83d\udea7',
'construction_worker_man':'\ud83d\udc77',
'construction_worker_woman':'\ud83d\udc77&zwj;\u2640\ufe0f',
'control_knobs':'\ud83c\udf9b',
'convenience_store':'\ud83c\udfea',
'cookie':'\ud83c\udf6a',
'cool':'\ud83c\udd92',
'policeman':'\ud83d\udc6e',
'copyright':'\u00a9\ufe0f',
'corn':'\ud83c\udf3d',
'couch_and_lamp':'\ud83d\udecb',
'couple':'\ud83d\udc6b',
'couple_with_heart_woman_man':'\ud83d\udc91',
'couple_with_heart_man_man':'\ud83d\udc68&zwj;\u2764\ufe0f&zwj;\ud83d\udc68',
'couple_with_heart_woman_woman':'\ud83d\udc69&zwj;\u2764\ufe0f&zwj;\ud83d\udc69',
'couplekiss_man_man':'\ud83d\udc68&zwj;\u2764\ufe0f&zwj;\ud83d\udc8b&zwj;\ud83d\udc68',
'couplekiss_man_woman':'\ud83d\udc8f',
'couplekiss_woman_woman':'\ud83d\udc69&zwj;\u2764\ufe0f&zwj;\ud83d\udc8b&zwj;\ud83d\udc69',
'cow':'\ud83d\udc2e',
'cow2':'\ud83d\udc04',
'cowboy_hat_face':'\ud83e\udd20',
'crab':'\ud83e\udd80',
'crayon':'\ud83d\udd8d',
'credit_card':'\ud83d\udcb3',
'crescent_moon':'\ud83c\udf19',
'cricket':'\ud83c\udfcf',
'crocodile':'\ud83d\udc0a',
'croissant':'\ud83e\udd50',
'crossed_fingers':'\ud83e\udd1e',
'crossed_flags':'\ud83c\udf8c',
'crossed_swords':'\u2694\ufe0f',
'crown':'\ud83d\udc51',
'cry':'\ud83d\ude22',
'crying_cat_face':'\ud83d\ude3f',
'crystal_ball':'\ud83d\udd2e',
'cucumber':'\ud83e\udd52',
'cupid':'\ud83d\udc98',
'curly_loop':'\u27b0',
'currency_exchange':'\ud83d\udcb1',
'curry':'\ud83c\udf5b',
'custard':'\ud83c\udf6e',
'customs':'\ud83d\udec3',
'cyclone':'\ud83c\udf00',
'dagger':'\ud83d\udde1',
'dancer':'\ud83d\udc83',
'dancing_women':'\ud83d\udc6f',
'dancing_men':'\ud83d\udc6f&zwj;\u2642\ufe0f',
'dango':'\ud83c\udf61',
'dark_sunglasses':'\ud83d\udd76',
'dart':'\ud83c\udfaf',
'dash':'\ud83d\udca8',
'date':'\ud83d\udcc5',
'deciduous_tree':'\ud83c\udf33',
'deer':'\ud83e\udd8c',
'department_store':'\ud83c\udfec',
'derelict_house':'\ud83c\udfda',
'desert':'\ud83c\udfdc',
'desert_island':'\ud83c\udfdd',
'desktop_computer':'\ud83d\udda5',
'male_detective':'\ud83d\udd75\ufe0f',
'diamond_shape_with_a_dot_inside':'\ud83d\udca0',
'diamonds':'\u2666\ufe0f',
'disappointed':'\ud83d\ude1e',
'disappointed_relieved':'\ud83d\ude25',
'dizzy':'\ud83d\udcab',
'dizzy_face':'\ud83d\ude35',
'do_not_litter':'\ud83d\udeaf',
'dog':'\ud83d\udc36',
'dog2':'\ud83d\udc15',
'dollar':'\ud83d\udcb5',
'dolls':'\ud83c\udf8e',
'dolphin':'\ud83d\udc2c',
'door':'\ud83d\udeaa',
'doughnut':'\ud83c\udf69',
'dove':'\ud83d\udd4a',
'dragon':'\ud83d\udc09',
'dragon_face':'\ud83d\udc32',
'dress':'\ud83d\udc57',
'dromedary_camel':'\ud83d\udc2a',
'drooling_face':'\ud83e\udd24',
'droplet':'\ud83d\udca7',
'drum':'\ud83e\udd41',
'duck':'\ud83e\udd86',
'dvd':'\ud83d\udcc0',
'e-mail':'\ud83d\udce7',
'eagle':'\ud83e\udd85',
'ear':'\ud83d\udc42',
'ear_of_rice':'\ud83c\udf3e',
'earth_africa':'\ud83c\udf0d',
'earth_americas':'\ud83c\udf0e',
'earth_asia':'\ud83c\udf0f',
'egg':'\ud83e\udd5a',
'eggplant':'\ud83c\udf46',
'eight_pointed_black_star':'\u2734\ufe0f',
'eight_spoked_asterisk':'\u2733\ufe0f',
'electric_plug':'\ud83d\udd0c',
'elephant':'\ud83d\udc18',
'email':'\u2709\ufe0f',
'end':'\ud83d\udd1a',
'envelope_with_arrow':'\ud83d\udce9',
'euro':'\ud83d\udcb6',
'european_castle':'\ud83c\udff0',
'european_post_office':'\ud83c\udfe4',
'evergreen_tree':'\ud83c\udf32',
'exclamation':'\u2757\ufe0f',
'expressionless':'\ud83d\ude11',
'eye':'\ud83d\udc41',
'eye_speech_bubble':'\ud83d\udc41&zwj;\ud83d\udde8',
'eyeglasses':'\ud83d\udc53',
'eyes':'\ud83d\udc40',
'face_with_head_bandage':'\ud83e\udd15',
'face_with_thermometer':'\ud83e\udd12',
'fist_oncoming':'\ud83d\udc4a',
'factory':'\ud83c\udfed',
'fallen_leaf':'\ud83c\udf42',
'family_man_woman_boy':'\ud83d\udc6a',
'family_man_boy':'\ud83d\udc68&zwj;\ud83d\udc66',
'family_man_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
'family_man_girl':'\ud83d\udc68&zwj;\ud83d\udc67',
'family_man_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
'family_man_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
'family_man_man_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc66',
'family_man_man_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
'family_man_man_girl':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67',
'family_man_man_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
'family_man_man_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
'family_man_woman_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
'family_man_woman_girl':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67',
'family_man_woman_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
'family_man_woman_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
'family_woman_boy':'\ud83d\udc69&zwj;\ud83d\udc66',
'family_woman_boy_boy':'\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
'family_woman_girl':'\ud83d\udc69&zwj;\ud83d\udc67',
'family_woman_girl_boy':'\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
'family_woman_girl_girl':'\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
'family_woman_woman_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc66',
'family_woman_woman_boy_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
'family_woman_woman_girl':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67',
'family_woman_woman_girl_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
'family_woman_woman_girl_girl':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
'fast_forward':'\u23e9',
'fax':'\ud83d\udce0',
'fearful':'\ud83d\ude28',
'feet':'\ud83d\udc3e',
'female_detective':'\ud83d\udd75\ufe0f&zwj;\u2640\ufe0f',
'ferris_wheel':'\ud83c\udfa1',
'ferry':'\u26f4',
'field_hockey':'\ud83c\udfd1',
'file_cabinet':'\ud83d\uddc4',
'file_folder':'\ud83d\udcc1',
'film_projector':'\ud83d\udcfd',
'film_strip':'\ud83c\udf9e',
'fire':'\ud83d\udd25',
'fire_engine':'\ud83d\ude92',
'fireworks':'\ud83c\udf86',
'first_quarter_moon':'\ud83c\udf13',
'first_quarter_moon_with_face':'\ud83c\udf1b',
'fish':'\ud83d\udc1f',
'fish_cake':'\ud83c\udf65',
'fishing_pole_and_fish':'\ud83c\udfa3',
'fist_raised':'\u270a',
'fist_left':'\ud83e\udd1b',
'fist_right':'\ud83e\udd1c',
'flags':'\ud83c\udf8f',
'flashlight':'\ud83d\udd26',
'fleur_de_lis':'\u269c\ufe0f',
'flight_arrival':'\ud83d\udeec',
'flight_departure':'\ud83d\udeeb',
'floppy_disk':'\ud83d\udcbe',
'flower_playing_cards':'\ud83c\udfb4',
'flushed':'\ud83d\ude33',
'fog':'\ud83c\udf2b',
'foggy':'\ud83c\udf01',
'football':'\ud83c\udfc8',
'footprints':'\ud83d\udc63',
'fork_and_knife':'\ud83c\udf74',
'fountain':'\u26f2\ufe0f',
'fountain_pen':'\ud83d\udd8b',
'four_leaf_clover':'\ud83c\udf40',
'fox_face':'\ud83e\udd8a',
'framed_picture':'\ud83d\uddbc',
'free':'\ud83c\udd93',
'fried_egg':'\ud83c\udf73',
'fried_shrimp':'\ud83c\udf64',
'fries':'\ud83c\udf5f',
'frog':'\ud83d\udc38',
'frowning':'\ud83d\ude26',
'frowning_face':'\u2639\ufe0f',
'frowning_man':'\ud83d\ude4d&zwj;\u2642\ufe0f',
'frowning_woman':'\ud83d\ude4d',
'middle_finger':'\ud83d\udd95',
'fuelpump':'\u26fd\ufe0f',
'full_moon':'\ud83c\udf15',
'full_moon_with_face':'\ud83c\udf1d',
'funeral_urn':'\u26b1\ufe0f',
'game_die':'\ud83c\udfb2',
'gear':'\u2699\ufe0f',
'gem':'\ud83d\udc8e',
'gemini':'\u264a\ufe0f',
'ghost':'\ud83d\udc7b',
'gift':'\ud83c\udf81',
'gift_heart':'\ud83d\udc9d',
'girl':'\ud83d\udc67',
'globe_with_meridians':'\ud83c\udf10',
'goal_net':'\ud83e\udd45',
'goat':'\ud83d\udc10',
'golf':'\u26f3\ufe0f',
'golfing_man':'\ud83c\udfcc\ufe0f',
'golfing_woman':'\ud83c\udfcc\ufe0f&zwj;\u2640\ufe0f',
'gorilla':'\ud83e\udd8d',
'grapes':'\ud83c\udf47',
'green_apple':'\ud83c\udf4f',
'green_book':'\ud83d\udcd7',
'green_heart':'\ud83d\udc9a',
'green_salad':'\ud83e\udd57',
'grey_exclamation':'\u2755',
'grey_question':'\u2754',
'grimacing':'\ud83d\ude2c',
'grin':'\ud83d\ude01',
'grinning':'\ud83d\ude00',
'guardsman':'\ud83d\udc82',
'guardswoman':'\ud83d\udc82&zwj;\u2640\ufe0f',
'guitar':'\ud83c\udfb8',
'gun':'\ud83d\udd2b',
'haircut_woman':'\ud83d\udc87',
'haircut_man':'\ud83d\udc87&zwj;\u2642\ufe0f',
'hamburger':'\ud83c\udf54',
'hammer':'\ud83d\udd28',
'hammer_and_pick':'\u2692',
'hammer_and_wrench':'\ud83d\udee0',
'hamster':'\ud83d\udc39',
'hand':'\u270b',
'handbag':'\ud83d\udc5c',
'handshake':'\ud83e\udd1d',
'hankey':'\ud83d\udca9',
'hatched_chick':'\ud83d\udc25',
'hatching_chick':'\ud83d\udc23',
'headphones':'\ud83c\udfa7',
'hear_no_evil':'\ud83d\ude49',
'heart':'\u2764\ufe0f',
'heart_decoration':'\ud83d\udc9f',
'heart_eyes':'\ud83d\ude0d',
'heart_eyes_cat':'\ud83d\ude3b',
'heartbeat':'\ud83d\udc93',
'heartpulse':'\ud83d\udc97',
'hearts':'\u2665\ufe0f',
'heavy_check_mark':'\u2714\ufe0f',
'heavy_division_sign':'\u2797',
'heavy_dollar_sign':'\ud83d\udcb2',
'heavy_heart_exclamation':'\u2763\ufe0f',
'heavy_minus_sign':'\u2796',
'heavy_multiplication_x':'\u2716\ufe0f',
'heavy_plus_sign':'\u2795',
'helicopter':'\ud83d\ude81',
'herb':'\ud83c\udf3f',
'hibiscus':'\ud83c\udf3a',
'high_brightness':'\ud83d\udd06',
'high_heel':'\ud83d\udc60',
'hocho':'\ud83d\udd2a',
'hole':'\ud83d\udd73',
'honey_pot':'\ud83c\udf6f',
'horse':'\ud83d\udc34',
'horse_racing':'\ud83c\udfc7',
'hospital':'\ud83c\udfe5',
'hot_pepper':'\ud83c\udf36',
'hotdog':'\ud83c\udf2d',
'hotel':'\ud83c\udfe8',
'hotsprings':'\u2668\ufe0f',
'hourglass':'\u231b\ufe0f',
'hourglass_flowing_sand':'\u23f3',
'house':'\ud83c\udfe0',
'house_with_garden':'\ud83c\udfe1',
'houses':'\ud83c\udfd8',
'hugs':'\ud83e\udd17',
'hushed':'\ud83d\ude2f',
'ice_cream':'\ud83c\udf68',
'ice_hockey':'\ud83c\udfd2',
'ice_skate':'\u26f8',
'icecream':'\ud83c\udf66',
'id':'\ud83c\udd94',
'ideograph_advantage':'\ud83c\ude50',
'imp':'\ud83d\udc7f',
'inbox_tray':'\ud83d\udce5',
'incoming_envelope':'\ud83d\udce8',
'tipping_hand_woman':'\ud83d\udc81',
'information_source':'\u2139\ufe0f',
'innocent':'\ud83d\ude07',
'interrobang':'\u2049\ufe0f',
'iphone':'\ud83d\udcf1',
'izakaya_lantern':'\ud83c\udfee',
'jack_o_lantern':'\ud83c\udf83',
'japan':'\ud83d\uddfe',
'japanese_castle':'\ud83c\udfef',
'japanese_goblin':'\ud83d\udc7a',
'japanese_ogre':'\ud83d\udc79',
'jeans':'\ud83d\udc56',
'joy':'\ud83d\ude02',
'joy_cat':'\ud83d\ude39',
'joystick':'\ud83d\udd79',
'kaaba':'\ud83d\udd4b',
'key':'\ud83d\udd11',
'keyboard':'\u2328\ufe0f',
'keycap_ten':'\ud83d\udd1f',
'kick_scooter':'\ud83d\udef4',
'kimono':'\ud83d\udc58',
'kiss':'\ud83d\udc8b',
'kissing':'\ud83d\ude17',
'kissing_cat':'\ud83d\ude3d',
'kissing_closed_eyes':'\ud83d\ude1a',
'kissing_heart':'\ud83d\ude18',
'kissing_smiling_eyes':'\ud83d\ude19',
'kiwi_fruit':'\ud83e\udd5d',
'koala':'\ud83d\udc28',
'koko':'\ud83c\ude01',
'label':'\ud83c\udff7',
'large_blue_circle':'\ud83d\udd35',
'large_blue_diamond':'\ud83d\udd37',
'large_orange_diamond':'\ud83d\udd36',
'last_quarter_moon':'\ud83c\udf17',
'last_quarter_moon_with_face':'\ud83c\udf1c',
'latin_cross':'\u271d\ufe0f',
'laughing':'\ud83d\ude06',
'leaves':'\ud83c\udf43',
'ledger':'\ud83d\udcd2',
'left_luggage':'\ud83d\udec5',
'left_right_arrow':'\u2194\ufe0f',
'leftwards_arrow_with_hook':'\u21a9\ufe0f',
'lemon':'\ud83c\udf4b',
'leo':'\u264c\ufe0f',
'leopard':'\ud83d\udc06',
'level_slider':'\ud83c\udf9a',
'libra':'\u264e\ufe0f',
'light_rail':'\ud83d\ude88',
'link':'\ud83d\udd17',
'lion':'\ud83e\udd81',
'lips':'\ud83d\udc44',
'lipstick':'\ud83d\udc84',
'lizard':'\ud83e\udd8e',
'lock':'\ud83d\udd12',
'lock_with_ink_pen':'\ud83d\udd0f',
'lollipop':'\ud83c\udf6d',
'loop':'\u27bf',
'loud_sound':'\ud83d\udd0a',
'loudspeaker':'\ud83d\udce2',
'love_hotel':'\ud83c\udfe9',
'love_letter':'\ud83d\udc8c',
'low_brightness':'\ud83d\udd05',
'lying_face':'\ud83e\udd25',
'm':'\u24c2\ufe0f',
'mag':'\ud83d\udd0d',
'mag_right':'\ud83d\udd0e',
'mahjong':'\ud83c\udc04\ufe0f',
'mailbox':'\ud83d\udceb',
'mailbox_closed':'\ud83d\udcea',
'mailbox_with_mail':'\ud83d\udcec',
'mailbox_with_no_mail':'\ud83d\udced',
'man':'\ud83d\udc68',
'man_artist':'\ud83d\udc68&zwj;\ud83c\udfa8',
'man_astronaut':'\ud83d\udc68&zwj;\ud83d\ude80',
'man_cartwheeling':'\ud83e\udd38&zwj;\u2642\ufe0f',
'man_cook':'\ud83d\udc68&zwj;\ud83c\udf73',
'man_dancing':'\ud83d\udd7a',
'man_facepalming':'\ud83e\udd26&zwj;\u2642\ufe0f',
'man_factory_worker':'\ud83d\udc68&zwj;\ud83c\udfed',
'man_farmer':'\ud83d\udc68&zwj;\ud83c\udf3e',
'man_firefighter':'\ud83d\udc68&zwj;\ud83d\ude92',
'man_health_worker':'\ud83d\udc68&zwj;\u2695\ufe0f',
'man_in_tuxedo':'\ud83e\udd35',
'man_judge':'\ud83d\udc68&zwj;\u2696\ufe0f',
'man_juggling':'\ud83e\udd39&zwj;\u2642\ufe0f',
'man_mechanic':'\ud83d\udc68&zwj;\ud83d\udd27',
'man_office_worker':'\ud83d\udc68&zwj;\ud83d\udcbc',
'man_pilot':'\ud83d\udc68&zwj;\u2708\ufe0f',
'man_playing_handball':'\ud83e\udd3e&zwj;\u2642\ufe0f',
'man_playing_water_polo':'\ud83e\udd3d&zwj;\u2642\ufe0f',
'man_scientist':'\ud83d\udc68&zwj;\ud83d\udd2c',
'man_shrugging':'\ud83e\udd37&zwj;\u2642\ufe0f',
'man_singer':'\ud83d\udc68&zwj;\ud83c\udfa4',
'man_student':'\ud83d\udc68&zwj;\ud83c\udf93',
'man_teacher':'\ud83d\udc68&zwj;\ud83c\udfeb',
'man_technologist':'\ud83d\udc68&zwj;\ud83d\udcbb',
'man_with_gua_pi_mao':'\ud83d\udc72',
'man_with_turban':'\ud83d\udc73',
'tangerine':'\ud83c\udf4a',
'mans_shoe':'\ud83d\udc5e',
'mantelpiece_clock':'\ud83d\udd70',
'maple_leaf':'\ud83c\udf41',
'martial_arts_uniform':'\ud83e\udd4b',
'mask':'\ud83d\ude37',
'massage_woman':'\ud83d\udc86',
'massage_man':'\ud83d\udc86&zwj;\u2642\ufe0f',
'meat_on_bone':'\ud83c\udf56',
'medal_military':'\ud83c\udf96',
'medal_sports':'\ud83c\udfc5',
'mega':'\ud83d\udce3',
'melon':'\ud83c\udf48',
'memo':'\ud83d\udcdd',
'men_wrestling':'\ud83e\udd3c&zwj;\u2642\ufe0f',
'menorah':'\ud83d\udd4e',
'mens':'\ud83d\udeb9',
'metal':'\ud83e\udd18',
'metro':'\ud83d\ude87',
'microphone':'\ud83c\udfa4',
'microscope':'\ud83d\udd2c',
'milk_glass':'\ud83e\udd5b',
'milky_way':'\ud83c\udf0c',
'minibus':'\ud83d\ude90',
'minidisc':'\ud83d\udcbd',
'mobile_phone_off':'\ud83d\udcf4',
'money_mouth_face':'\ud83e\udd11',
'money_with_wings':'\ud83d\udcb8',
'moneybag':'\ud83d\udcb0',
'monkey':'\ud83d\udc12',
'monkey_face':'\ud83d\udc35',
'monorail':'\ud83d\ude9d',
'moon':'\ud83c\udf14',
'mortar_board':'\ud83c\udf93',
'mosque':'\ud83d\udd4c',
'motor_boat':'\ud83d\udee5',
'motor_scooter':'\ud83d\udef5',
'motorcycle':'\ud83c\udfcd',
'motorway':'\ud83d\udee3',
'mount_fuji':'\ud83d\uddfb',
'mountain':'\u26f0',
'mountain_biking_man':'\ud83d\udeb5',
'mountain_biking_woman':'\ud83d\udeb5&zwj;\u2640\ufe0f',
'mountain_cableway':'\ud83d\udea0',
'mountain_railway':'\ud83d\ude9e',
'mountain_snow':'\ud83c\udfd4',
'mouse':'\ud83d\udc2d',
'mouse2':'\ud83d\udc01',
'movie_camera':'\ud83c\udfa5',
'moyai':'\ud83d\uddff',
'mrs_claus':'\ud83e\udd36',
'muscle':'\ud83d\udcaa',
'mushroom':'\ud83c\udf44',
'musical_keyboard':'\ud83c\udfb9',
'musical_note':'\ud83c\udfb5',
'musical_score':'\ud83c\udfbc',
'mute':'\ud83d\udd07',
'nail_care':'\ud83d\udc85',
'name_badge':'\ud83d\udcdb',
'national_park':'\ud83c\udfde',
'nauseated_face':'\ud83e\udd22',
'necktie':'\ud83d\udc54',
'negative_squared_cross_mark':'\u274e',
'nerd_face':'\ud83e\udd13',
'neutral_face':'\ud83d\ude10',
'new':'\ud83c\udd95',
'new_moon':'\ud83c\udf11',
'new_moon_with_face':'\ud83c\udf1a',
'newspaper':'\ud83d\udcf0',
'newspaper_roll':'\ud83d\uddde',
'next_track_button':'\u23ed',
'ng':'\ud83c\udd96',
'no_good_man':'\ud83d\ude45&zwj;\u2642\ufe0f',
'no_good_woman':'\ud83d\ude45',
'night_with_stars':'\ud83c\udf03',
'no_bell':'\ud83d\udd15',
'no_bicycles':'\ud83d\udeb3',
'no_entry':'\u26d4\ufe0f',
'no_entry_sign':'\ud83d\udeab',
'no_mobile_phones':'\ud83d\udcf5',
'no_mouth':'\ud83d\ude36',
'no_pedestrians':'\ud83d\udeb7',
'no_smoking':'\ud83d\udead',
'non-potable_water':'\ud83d\udeb1',
'nose':'\ud83d\udc43',
'notebook':'\ud83d\udcd3',
'notebook_with_decorative_cover':'\ud83d\udcd4',
'notes':'\ud83c\udfb6',
'nut_and_bolt':'\ud83d\udd29',
'o':'\u2b55\ufe0f',
'o2':'\ud83c\udd7e\ufe0f',
'ocean':'\ud83c\udf0a',
'octopus':'\ud83d\udc19',
'oden':'\ud83c\udf62',
'office':'\ud83c\udfe2',
'oil_drum':'\ud83d\udee2',
'ok':'\ud83c\udd97',
'ok_hand':'\ud83d\udc4c',
'ok_man':'\ud83d\ude46&zwj;\u2642\ufe0f',
'ok_woman':'\ud83d\ude46',
'old_key':'\ud83d\udddd',
'older_man':'\ud83d\udc74',
'older_woman':'\ud83d\udc75',
'om':'\ud83d\udd49',
'on':'\ud83d\udd1b',
'oncoming_automobile':'\ud83d\ude98',
'oncoming_bus':'\ud83d\ude8d',
'oncoming_police_car':'\ud83d\ude94',
'oncoming_taxi':'\ud83d\ude96',
'open_file_folder':'\ud83d\udcc2',
'open_hands':'\ud83d\udc50',
'open_mouth':'\ud83d\ude2e',
'open_umbrella':'\u2602\ufe0f',
'ophiuchus':'\u26ce',
'orange_book':'\ud83d\udcd9',
'orthodox_cross':'\u2626\ufe0f',
'outbox_tray':'\ud83d\udce4',
'owl':'\ud83e\udd89',
'ox':'\ud83d\udc02',
'package':'\ud83d\udce6',
'page_facing_up':'\ud83d\udcc4',
'page_with_curl':'\ud83d\udcc3',
'pager':'\ud83d\udcdf',
'paintbrush':'\ud83d\udd8c',
'palm_tree':'\ud83c\udf34',
'pancakes':'\ud83e\udd5e',
'panda_face':'\ud83d\udc3c',
'paperclip':'\ud83d\udcce',
'paperclips':'\ud83d\udd87',
'parasol_on_ground':'\u26f1',
'parking':'\ud83c\udd7f\ufe0f',
'part_alternation_mark':'\u303d\ufe0f',
'partly_sunny':'\u26c5\ufe0f',
'passenger_ship':'\ud83d\udef3',
'passport_control':'\ud83d\udec2',
'pause_button':'\u23f8',
'peace_symbol':'\u262e\ufe0f',
'peach':'\ud83c\udf51',
'peanuts':'\ud83e\udd5c',
'pear':'\ud83c\udf50',
'pen':'\ud83d\udd8a',
'pencil2':'\u270f\ufe0f',
'penguin':'\ud83d\udc27',
'pensive':'\ud83d\ude14',
'performing_arts':'\ud83c\udfad',
'persevere':'\ud83d\ude23',
'person_fencing':'\ud83e\udd3a',
'pouting_woman':'\ud83d\ude4e',
'phone':'\u260e\ufe0f',
'pick':'\u26cf',
'pig':'\ud83d\udc37',
'pig2':'\ud83d\udc16',
'pig_nose':'\ud83d\udc3d',
'pill':'\ud83d\udc8a',
'pineapple':'\ud83c\udf4d',
'ping_pong':'\ud83c\udfd3',
'pisces':'\u2653\ufe0f',
'pizza':'\ud83c\udf55',
'place_of_worship':'\ud83d\uded0',
'plate_with_cutlery':'\ud83c\udf7d',
'play_or_pause_button':'\u23ef',
'point_down':'\ud83d\udc47',
'point_left':'\ud83d\udc48',
'point_right':'\ud83d\udc49',
'point_up':'\u261d\ufe0f',
'point_up_2':'\ud83d\udc46',
'police_car':'\ud83d\ude93',
'policewoman':'\ud83d\udc6e&zwj;\u2640\ufe0f',
'poodle':'\ud83d\udc29',
'popcorn':'\ud83c\udf7f',
'post_office':'\ud83c\udfe3',
'postal_horn':'\ud83d\udcef',
'postbox':'\ud83d\udcee',
'potable_water':'\ud83d\udeb0',
'potato':'\ud83e\udd54',
'pouch':'\ud83d\udc5d',
'poultry_leg':'\ud83c\udf57',
'pound':'\ud83d\udcb7',
'rage':'\ud83d\ude21',
'pouting_cat':'\ud83d\ude3e',
'pouting_man':'\ud83d\ude4e&zwj;\u2642\ufe0f',
'pray':'\ud83d\ude4f',
'prayer_beads':'\ud83d\udcff',
'pregnant_woman':'\ud83e\udd30',
'previous_track_button':'\u23ee',
'prince':'\ud83e\udd34',
'princess':'\ud83d\udc78',
'printer':'\ud83d\udda8',
'purple_heart':'\ud83d\udc9c',
'purse':'\ud83d\udc5b',
'pushpin':'\ud83d\udccc',
'put_litter_in_its_place':'\ud83d\udeae',
'question':'\u2753',
'rabbit':'\ud83d\udc30',
'rabbit2':'\ud83d\udc07',
'racehorse':'\ud83d\udc0e',
'racing_car':'\ud83c\udfce',
'radio':'\ud83d\udcfb',
'radio_button':'\ud83d\udd18',
'radioactive':'\u2622\ufe0f',
'railway_car':'\ud83d\ude83',
'railway_track':'\ud83d\udee4',
'rainbow':'\ud83c\udf08',
'rainbow_flag':'\ud83c\udff3\ufe0f&zwj;\ud83c\udf08',
'raised_back_of_hand':'\ud83e\udd1a',
'raised_hand_with_fingers_splayed':'\ud83d\udd90',
'raised_hands':'\ud83d\ude4c',
'raising_hand_woman':'\ud83d\ude4b',
'raising_hand_man':'\ud83d\ude4b&zwj;\u2642\ufe0f',
'ram':'\ud83d\udc0f',
'ramen':'\ud83c\udf5c',
'rat':'\ud83d\udc00',
'record_button':'\u23fa',
'recycle':'\u267b\ufe0f',
'red_circle':'\ud83d\udd34',
'registered':'\u00ae\ufe0f',
'relaxed':'\u263a\ufe0f',
'relieved':'\ud83d\ude0c',
'reminder_ribbon':'\ud83c\udf97',
'repeat':'\ud83d\udd01',
'repeat_one':'\ud83d\udd02',
'rescue_worker_helmet':'\u26d1',
'restroom':'\ud83d\udebb',
'revolving_hearts':'\ud83d\udc9e',
'rewind':'\u23ea',
'rhinoceros':'\ud83e\udd8f',
'ribbon':'\ud83c\udf80',
'rice':'\ud83c\udf5a',
'rice_ball':'\ud83c\udf59',
'rice_cracker':'\ud83c\udf58',
'rice_scene':'\ud83c\udf91',
'right_anger_bubble':'\ud83d\uddef',
'ring':'\ud83d\udc8d',
'robot':'\ud83e\udd16',
'rocket':'\ud83d\ude80',
'rofl':'\ud83e\udd23',
'roll_eyes':'\ud83d\ude44',
'roller_coaster':'\ud83c\udfa2',
'rooster':'\ud83d\udc13',
'rose':'\ud83c\udf39',
'rosette':'\ud83c\udff5',
'rotating_light':'\ud83d\udea8',
'round_pushpin':'\ud83d\udccd',
'rowing_man':'\ud83d\udea3',
'rowing_woman':'\ud83d\udea3&zwj;\u2640\ufe0f',
'rugby_football':'\ud83c\udfc9',
'running_man':'\ud83c\udfc3',
'running_shirt_with_sash':'\ud83c\udfbd',
'running_woman':'\ud83c\udfc3&zwj;\u2640\ufe0f',
'sa':'\ud83c\ude02\ufe0f',
'sagittarius':'\u2650\ufe0f',
'sake':'\ud83c\udf76',
'sandal':'\ud83d\udc61',
'santa':'\ud83c\udf85',
'satellite':'\ud83d\udce1',
'saxophone':'\ud83c\udfb7',
'school':'\ud83c\udfeb',
'school_satchel':'\ud83c\udf92',
'scissors':'\u2702\ufe0f',
'scorpion':'\ud83e\udd82',
'scorpius':'\u264f\ufe0f',
'scream':'\ud83d\ude31',
'scream_cat':'\ud83d\ude40',
'scroll':'\ud83d\udcdc',
'seat':'\ud83d\udcba',
'secret':'\u3299\ufe0f',
'see_no_evil':'\ud83d\ude48',
'seedling':'\ud83c\udf31',
'selfie':'\ud83e\udd33',
'shallow_pan_of_food':'\ud83e\udd58',
'shamrock':'\u2618\ufe0f',
'shark':'\ud83e\udd88',
'shaved_ice':'\ud83c\udf67',
'sheep':'\ud83d\udc11',
'shell':'\ud83d\udc1a',
'shield':'\ud83d\udee1',
'shinto_shrine':'\u26e9',
'ship':'\ud83d\udea2',
'shirt':'\ud83d\udc55',
'shopping':'\ud83d\udecd',
'shopping_cart':'\ud83d\uded2',
'shower':'\ud83d\udebf',
'shrimp':'\ud83e\udd90',
'signal_strength':'\ud83d\udcf6',
'six_pointed_star':'\ud83d\udd2f',
'ski':'\ud83c\udfbf',
'skier':'\u26f7',
'skull':'\ud83d\udc80',
'skull_and_crossbones':'\u2620\ufe0f',
'sleeping':'\ud83d\ude34',
'sleeping_bed':'\ud83d\udecc',
'sleepy':'\ud83d\ude2a',
'slightly_frowning_face':'\ud83d\ude41',
'slightly_smiling_face':'\ud83d\ude42',
'slot_machine':'\ud83c\udfb0',
'small_airplane':'\ud83d\udee9',
'small_blue_diamond':'\ud83d\udd39',
'small_orange_diamond':'\ud83d\udd38',
'small_red_triangle':'\ud83d\udd3a',
'small_red_triangle_down':'\ud83d\udd3b',
'smile':'\ud83d\ude04',
'smile_cat':'\ud83d\ude38',
'smiley':'\ud83d\ude03',
'smiley_cat':'\ud83d\ude3a',
'smiling_imp':'\ud83d\ude08',
'smirk':'\ud83d\ude0f',
'smirk_cat':'\ud83d\ude3c',
'smoking':'\ud83d\udeac',
'snail':'\ud83d\udc0c',
'snake':'\ud83d\udc0d',
'sneezing_face':'\ud83e\udd27',
'snowboarder':'\ud83c\udfc2',
'snowflake':'\u2744\ufe0f',
'snowman':'\u26c4\ufe0f',
'snowman_with_snow':'\u2603\ufe0f',
'sob':'\ud83d\ude2d',
'soccer':'\u26bd\ufe0f',
'soon':'\ud83d\udd1c',
'sos':'\ud83c\udd98',
'sound':'\ud83d\udd09',
'space_invader':'\ud83d\udc7e',
'spades':'\u2660\ufe0f',
'spaghetti':'\ud83c\udf5d',
'sparkle':'\u2747\ufe0f',
'sparkler':'\ud83c\udf87',
'sparkles':'\u2728',
'sparkling_heart':'\ud83d\udc96',
'speak_no_evil':'\ud83d\ude4a',
'speaker':'\ud83d\udd08',
'speaking_head':'\ud83d\udde3',
'speech_balloon':'\ud83d\udcac',
'speedboat':'\ud83d\udea4',
'spider':'\ud83d\udd77',
'spider_web':'\ud83d\udd78',
'spiral_calendar':'\ud83d\uddd3',
'spiral_notepad':'\ud83d\uddd2',
'spoon':'\ud83e\udd44',
'squid':'\ud83e\udd91',
'stadium':'\ud83c\udfdf',
'star':'\u2b50\ufe0f',
'star2':'\ud83c\udf1f',
'star_and_crescent':'\u262a\ufe0f',
'star_of_david':'\u2721\ufe0f',
'stars':'\ud83c\udf20',
'station':'\ud83d\ude89',
'statue_of_liberty':'\ud83d\uddfd',
'steam_locomotive':'\ud83d\ude82',
'stew':'\ud83c\udf72',
'stop_button':'\u23f9',
'stop_sign':'\ud83d\uded1',
'stopwatch':'\u23f1',
'straight_ruler':'\ud83d\udccf',
'strawberry':'\ud83c\udf53',
'stuck_out_tongue':'\ud83d\ude1b',
'stuck_out_tongue_closed_eyes':'\ud83d\ude1d',
'stuck_out_tongue_winking_eye':'\ud83d\ude1c',
'studio_microphone':'\ud83c\udf99',
'stuffed_flatbread':'\ud83e\udd59',
'sun_behind_large_cloud':'\ud83c\udf25',
'sun_behind_rain_cloud':'\ud83c\udf26',
'sun_behind_small_cloud':'\ud83c\udf24',
'sun_with_face':'\ud83c\udf1e',
'sunflower':'\ud83c\udf3b',
'sunglasses':'\ud83d\ude0e',
'sunny':'\u2600\ufe0f',
'sunrise':'\ud83c\udf05',
'sunrise_over_mountains':'\ud83c\udf04',
'surfing_man':'\ud83c\udfc4',
'surfing_woman':'\ud83c\udfc4&zwj;\u2640\ufe0f',
'sushi':'\ud83c\udf63',
'suspension_railway':'\ud83d\ude9f',
'sweat':'\ud83d\ude13',
'sweat_drops':'\ud83d\udca6',
'sweat_smile':'\ud83d\ude05',
'sweet_potato':'\ud83c\udf60',
'swimming_man':'\ud83c\udfca',
'swimming_woman':'\ud83c\udfca&zwj;\u2640\ufe0f',
'symbols':'\ud83d\udd23',
'synagogue':'\ud83d\udd4d',
'syringe':'\ud83d\udc89',
'taco':'\ud83c\udf2e',
'tada':'\ud83c\udf89',
'tanabata_tree':'\ud83c\udf8b',
'taurus':'\u2649\ufe0f',
'taxi':'\ud83d\ude95',
'tea':'\ud83c\udf75',
'telephone_receiver':'\ud83d\udcde',
'telescope':'\ud83d\udd2d',
'tennis':'\ud83c\udfbe',
'tent':'\u26fa\ufe0f',
'thermometer':'\ud83c\udf21',
'thinking':'\ud83e\udd14',
'thought_balloon':'\ud83d\udcad',
'ticket':'\ud83c\udfab',
'tickets':'\ud83c\udf9f',
'tiger':'\ud83d\udc2f',
'tiger2':'\ud83d\udc05',
'timer_clock':'\u23f2',
'tipping_hand_man':'\ud83d\udc81&zwj;\u2642\ufe0f',
'tired_face':'\ud83d\ude2b',
'tm':'\u2122\ufe0f',
'toilet':'\ud83d\udebd',
'tokyo_tower':'\ud83d\uddfc',
'tomato':'\ud83c\udf45',
'tongue':'\ud83d\udc45',
'top':'\ud83d\udd1d',
'tophat':'\ud83c\udfa9',
'tornado':'\ud83c\udf2a',
'trackball':'\ud83d\uddb2',
'tractor':'\ud83d\ude9c',
'traffic_light':'\ud83d\udea5',
'train':'\ud83d\ude8b',
'train2':'\ud83d\ude86',
'tram':'\ud83d\ude8a',
'triangular_flag_on_post':'\ud83d\udea9',
'triangular_ruler':'\ud83d\udcd0',
'trident':'\ud83d\udd31',
'triumph':'\ud83d\ude24',
'trolleybus':'\ud83d\ude8e',
'trophy':'\ud83c\udfc6',
'tropical_drink':'\ud83c\udf79',
'tropical_fish':'\ud83d\udc20',
'truck':'\ud83d\ude9a',
'trumpet':'\ud83c\udfba',
'tulip':'\ud83c\udf37',
'tumbler_glass':'\ud83e\udd43',
'turkey':'\ud83e\udd83',
'turtle':'\ud83d\udc22',
'tv':'\ud83d\udcfa',
'twisted_rightwards_arrows':'\ud83d\udd00',
'two_hearts':'\ud83d\udc95',
'two_men_holding_hands':'\ud83d\udc6c',
'two_women_holding_hands':'\ud83d\udc6d',
'u5272':'\ud83c\ude39',
'u5408':'\ud83c\ude34',
'u55b6':'\ud83c\ude3a',
'u6307':'\ud83c\ude2f\ufe0f',
'u6708':'\ud83c\ude37\ufe0f',
'u6709':'\ud83c\ude36',
'u6e80':'\ud83c\ude35',
'u7121':'\ud83c\ude1a\ufe0f',
'u7533':'\ud83c\ude38',
'u7981':'\ud83c\ude32',
'u7a7a':'\ud83c\ude33',
'umbrella':'\u2614\ufe0f',
'unamused':'\ud83d\ude12',
'underage':'\ud83d\udd1e',
'unicorn':'\ud83e\udd84',
'unlock':'\ud83d\udd13',
'up':'\ud83c\udd99',
'upside_down_face':'\ud83d\ude43',
'v':'\u270c\ufe0f',
'vertical_traffic_light':'\ud83d\udea6',
'vhs':'\ud83d\udcfc',
'vibration_mode':'\ud83d\udcf3',
'video_camera':'\ud83d\udcf9',
'video_game':'\ud83c\udfae',
'violin':'\ud83c\udfbb',
'virgo':'\u264d\ufe0f',
'volcano':'\ud83c\udf0b',
'volleyball':'\ud83c\udfd0',
'vs':'\ud83c\udd9a',
'vulcan_salute':'\ud83d\udd96',
'walking_man':'\ud83d\udeb6',
'walking_woman':'\ud83d\udeb6&zwj;\u2640\ufe0f',
'waning_crescent_moon':'\ud83c\udf18',
'waning_gibbous_moon':'\ud83c\udf16',
'warning':'\u26a0\ufe0f',
'wastebasket':'\ud83d\uddd1',
'watch':'\u231a\ufe0f',
'water_buffalo':'\ud83d\udc03',
'watermelon':'\ud83c\udf49',
'wave':'\ud83d\udc4b',
'wavy_dash':'\u3030\ufe0f',
'waxing_crescent_moon':'\ud83c\udf12',
'wc':'\ud83d\udebe',
'weary':'\ud83d\ude29',
'wedding':'\ud83d\udc92',
'weight_lifting_man':'\ud83c\udfcb\ufe0f',
'weight_lifting_woman':'\ud83c\udfcb\ufe0f&zwj;\u2640\ufe0f',
'whale':'\ud83d\udc33',
'whale2':'\ud83d\udc0b',
'wheel_of_dharma':'\u2638\ufe0f',
'wheelchair':'\u267f\ufe0f',
'white_check_mark':'\u2705',
'white_circle':'\u26aa\ufe0f',
'white_flag':'\ud83c\udff3\ufe0f',
'white_flower':'\ud83d\udcae',
'white_large_square':'\u2b1c\ufe0f',
'white_medium_small_square':'\u25fd\ufe0f',
'white_medium_square':'\u25fb\ufe0f',
'white_small_square':'\u25ab\ufe0f',
'white_square_button':'\ud83d\udd33',
'wilted_flower':'\ud83e\udd40',
'wind_chime':'\ud83c\udf90',
'wind_face':'\ud83c\udf2c',
'wine_glass':'\ud83c\udf77',
'wink':'\ud83d\ude09',
'wolf':'\ud83d\udc3a',
'woman':'\ud83d\udc69',
'woman_artist':'\ud83d\udc69&zwj;\ud83c\udfa8',
'woman_astronaut':'\ud83d\udc69&zwj;\ud83d\ude80',
'woman_cartwheeling':'\ud83e\udd38&zwj;\u2640\ufe0f',
'woman_cook':'\ud83d\udc69&zwj;\ud83c\udf73',
'woman_facepalming':'\ud83e\udd26&zwj;\u2640\ufe0f',
'woman_factory_worker':'\ud83d\udc69&zwj;\ud83c\udfed',
'woman_farmer':'\ud83d\udc69&zwj;\ud83c\udf3e',
'woman_firefighter':'\ud83d\udc69&zwj;\ud83d\ude92',
'woman_health_worker':'\ud83d\udc69&zwj;\u2695\ufe0f',
'woman_judge':'\ud83d\udc69&zwj;\u2696\ufe0f',
'woman_juggling':'\ud83e\udd39&zwj;\u2640\ufe0f',
'woman_mechanic':'\ud83d\udc69&zwj;\ud83d\udd27',
'woman_office_worker':'\ud83d\udc69&zwj;\ud83d\udcbc',
'woman_pilot':'\ud83d\udc69&zwj;\u2708\ufe0f',
'woman_playing_handball':'\ud83e\udd3e&zwj;\u2640\ufe0f',
'woman_playing_water_polo':'\ud83e\udd3d&zwj;\u2640\ufe0f',
'woman_scientist':'\ud83d\udc69&zwj;\ud83d\udd2c',
'woman_shrugging':'\ud83e\udd37&zwj;\u2640\ufe0f',
'woman_singer':'\ud83d\udc69&zwj;\ud83c\udfa4',
'woman_student':'\ud83d\udc69&zwj;\ud83c\udf93',
'woman_teacher':'\ud83d\udc69&zwj;\ud83c\udfeb',
'woman_technologist':'\ud83d\udc69&zwj;\ud83d\udcbb',
'woman_with_turban':'\ud83d\udc73&zwj;\u2640\ufe0f',
'womans_clothes':'\ud83d\udc5a',
'womans_hat':'\ud83d\udc52',
'women_wrestling':'\ud83e\udd3c&zwj;\u2640\ufe0f',
'womens':'\ud83d\udeba',
'world_map':'\ud83d\uddfa',
'worried':'\ud83d\ude1f',
'wrench':'\ud83d\udd27',
'writing_hand':'\u270d\ufe0f',
'x':'\u274c',
'yellow_heart':'\ud83d\udc9b',
'yen':'\ud83d\udcb4',
'yin_yang':'\u262f\ufe0f',
'yum':'\ud83d\ude0b',
'zap':'\u26a1\ufe0f',
'zipper_mouth_face':'\ud83e\udd10',
'zzz':'\ud83d\udca4',
/* special emojis :P */
'octocat': '<img alt=":octocat:" height="20" width="20" align="absmiddle" src="https://assets-cdn.github.com/images/icons/emoji/octocat.png">',
'showdown': '<span style="font-family: \'Anonymous Pro\', monospace; text-decoration: underline; text-decoration-style: dashed; text-decoration-color: #3e8b8a;text-underline-position: under;">S</span>'
};
/**
* Created by Estevao on 31-05-2015.
*/
/**
* Showdown Converter class
* @class
* @param {object} [converterOptions]
* @returns {Converter}
*/
showdown.Converter = function (converterOptions) {
var
/**
* Options used by this converter
* @private
* @type {{}}
*/
options = {},
/**
* Language extensions used by this converter
* @private
* @type {Array}
*/
langExtensions = [],
/**
* Output modifiers extensions used by this converter
* @private
* @type {Array}
*/
outputModifiers = [],
/**
* Event listeners
* @private
* @type {{}}
*/
listeners = {},
/**
* The flavor set in this converter
*/
setConvFlavor = setFlavor,
/**
* Metadata of the document
* @type {{parsed: {}, raw: string, format: string}}
*/
metadata = {
parsed: {},
raw: '',
format: ''
};
_constructor();
/**
* Converter constructor
* @private
*/
function _constructor () {
converterOptions = converterOptions || {};
for (var gOpt in globalOptions) {
if (globalOptions.hasOwnProperty(gOpt)) {
options[gOpt] = globalOptions[gOpt];
}
}
// Merge options
if (typeof converterOptions === 'object') {
for (var opt in converterOptions) {
if (converterOptions.hasOwnProperty(opt)) {
options[opt] = converterOptions[opt];
}
}
} else {
throw Error('Converter expects the passed parameter to be an object, but ' + typeof converterOptions +
' was passed instead.');
}
if (options.extensions) {
showdown.helper.forEach(options.extensions, _parseExtension);
}
}
/**
* Parse extension
* @param {*} ext
* @param {string} [name='']
* @private
*/
function _parseExtension (ext, name) {
name = name || null;
// If it's a string, the extension was previously loaded
if (showdown.helper.isString(ext)) {
ext = showdown.helper.stdExtName(ext);
name = ext;
// LEGACY_SUPPORT CODE
if (showdown.extensions[ext]) {
console.warn('DEPRECATION WARNING: ' + ext + ' is an old extension that uses a deprecated loading method.' +
'Please inform the developer that the extension should be updated!');
legacyExtensionLoading(showdown.extensions[ext], ext);
return;
// END LEGACY SUPPORT CODE
} else if (!showdown.helper.isUndefined(extensions[ext])) {
ext = extensions[ext];
} else {
throw Error('Extension "' + ext + '" could not be loaded. It was either not found or is not a valid extension.');
}
}
if (typeof ext === 'function') {
ext = ext();
}
if (!showdown.helper.isArray(ext)) {
ext = [ext];
}
var validExt = validate(ext, name);
if (!validExt.valid) {
throw Error(validExt.error);
}
for (var i = 0; i < ext.length; ++i) {
switch (ext[i].type) {
case 'lang':
langExtensions.push(ext[i]);
break;
case 'output':
outputModifiers.push(ext[i]);
break;
}
if (ext[i].hasOwnProperty('listeners')) {
for (var ln in ext[i].listeners) {
if (ext[i].listeners.hasOwnProperty(ln)) {
listen(ln, ext[i].listeners[ln]);
}
}
}
}
}
/**
* LEGACY_SUPPORT
* @param {*} ext
* @param {string} name
*/
function legacyExtensionLoading (ext, name) {
if (typeof ext === 'function') {
ext = ext(new showdown.Converter());
}
if (!showdown.helper.isArray(ext)) {
ext = [ext];
}
var valid = validate(ext, name);
if (!valid.valid) {
throw Error(valid.error);
}
for (var i = 0; i < ext.length; ++i) {
switch (ext[i].type) {
case 'lang':
langExtensions.push(ext[i]);
break;
case 'output':
outputModifiers.push(ext[i]);
break;
default:// should never reach here
throw Error('Extension loader error: Type unrecognized!!!');
}
}
}
/**
* Listen to an event
* @param {string} name
* @param {function} callback
*/
function listen (name, callback) {
if (!showdown.helper.isString(name)) {
throw Error('Invalid argument in converter.listen() method: name must be a string, but ' + typeof name + ' given');
}
if (typeof callback !== 'function') {
throw Error('Invalid argument in converter.listen() method: callback must be a function, but ' + typeof callback + ' given');
}
if (!listeners.hasOwnProperty(name)) {
listeners[name] = [];
}
listeners[name].push(callback);
}
function rTrimInputText (text) {
var rsp = text.match(/^\s*/)[0].length,
rgx = new RegExp('^\\s{0,' + rsp + '}', 'gm');
return text.replace(rgx, '');
}
/**
* Dispatch an event
* @private
* @param {string} evtName Event name
* @param {string} text Text
* @param {{}} options Converter Options
* @param {{}} globals
* @returns {string}
*/
this._dispatch = function dispatch (evtName, text, options, globals) {
if (listeners.hasOwnProperty(evtName)) {
for (var ei = 0; ei < listeners[evtName].length; ++ei) {
var nText = listeners[evtName][ei](evtName, text, this, options, globals);
if (nText && typeof nText !== 'undefined') {
text = nText;
}
}
}
return text;
};
/**
* Listen to an event
* @param {string} name
* @param {function} callback
* @returns {showdown.Converter}
*/
this.listen = function (name, callback) {
listen(name, callback);
return this;
};
/**
* Converts a markdown string into HTML
* @param {string} text
* @returns {*}
*/
this.makeHtml = function (text) {
//check if text is not falsy
if (!text) {
return text;
}
var globals = {
gHtmlBlocks: [],
gHtmlMdBlocks: [],
gHtmlSpans: [],
gUrls: {},
gTitles: {},
gDimensions: {},
gListLevel: 0,
hashLinkCounts: {},
langExtensions: langExtensions,
outputModifiers: outputModifiers,
converter: this,
ghCodeBlocks: [],
metadata: {
parsed: {},
raw: '',
format: ''
}
};
// This lets us use ¨ trema as an escape char to avoid md5 hashes
// The choice of character is arbitrary; anything that isn't
// magic in Markdown will work.
text = text.replace(/¨/g, '¨T');
// Replace $ with ¨D
// RegExp interprets $ as a special character
// when it's in a replacement string
text = text.replace(/\$/g, '¨D');
// Standardize line endings
text = text.replace(/\r\n/g, '\n'); // DOS to Unix
text = text.replace(/\r/g, '\n'); // Mac to Unix
// Stardardize line spaces
text = text.replace(/\u00A0/g, '&nbsp;');
if (options.smartIndentationFix) {
text = rTrimInputText(text);
}
// Make sure text begins and ends with a couple of newlines:
text = '\n\n' + text + '\n\n';
// detab
text = showdown.subParser('detab')(text, options, globals);
/**
* Strip any lines consisting only of spaces and tabs.
* This makes subsequent regexs easier to write, because we can
* match consecutive blank lines with /\n+/ instead of something
* contorted like /[ \t]*\n+/
*/
text = text.replace(/^[ \t]+$/mg, '');
//run languageExtensions
showdown.helper.forEach(langExtensions, function (ext) {
text = showdown.subParser('runExtension')(ext, text, options, globals);
});
// run the sub parsers
text = showdown.subParser('metadata')(text, options, globals);
text = showdown.subParser('hashPreCodeTags')(text, options, globals);
text = showdown.subParser('githubCodeBlocks')(text, options, globals);
text = showdown.subParser('hashHTMLBlocks')(text, options, globals);
text = showdown.subParser('hashCodeTags')(text, options, globals);
text = showdown.subParser('stripLinkDefinitions')(text, options, globals);
text = showdown.subParser('blockGamut')(text, options, globals);
text = showdown.subParser('unhashHTMLSpans')(text, options, globals);
text = showdown.subParser('unescapeSpecialChars')(text, options, globals);
// attacklab: Restore dollar signs
text = text.replace(/¨D/g, '$$');
// attacklab: Restore tremas
text = text.replace(/¨T/g, '¨');
// render a complete html document instead of a partial if the option is enabled
text = showdown.subParser('completeHTMLDocument')(text, options, globals);
// Run output modifiers
showdown.helper.forEach(outputModifiers, function (ext) {
text = showdown.subParser('runExtension')(ext, text, options, globals);
});
// update metadata
metadata = globals.metadata;
return text;
};
/**
* Converts an HTML string into a markdown string
* @param src
* @param [HTMLParser] A WHATWG DOM and HTML parser, such as JSDOM. If none is supplied, window.document will be used.
* @returns {string}
*/
this.makeMarkdown = this.makeMd = function (src, HTMLParser) {
// replace \r\n with \n
src = src.replace(/\r\n/g, '\n');
src = src.replace(/\r/g, '\n'); // old macs
// due to an edge case, we need to find this: > <
// to prevent removing of non silent white spaces
// ex: <em>this is</em> <strong>sparta</strong>
src = src.replace(/>[ \t]+</, '>¨NBSP;<');
if (!HTMLParser) {
if (window && window.document) {
HTMLParser = window.document;
} else {
throw new Error('HTMLParser is undefined. If in a webworker or nodejs environment, you need to provide a WHATWG DOM and HTML such as JSDOM');
}
}
var doc = HTMLParser.createElement('div');
doc.innerHTML = src;
var globals = {
preList: substitutePreCodeTags(doc)
};
// remove all newlines and collapse spaces
clean(doc);
// some stuff, like accidental reference links must now be escaped
// TODO
// doc.innerHTML = doc.innerHTML.replace(/\[[\S\t ]]/);
var nodes = doc.childNodes,
mdDoc = '';
for (var i = 0; i < nodes.length; i++) {
mdDoc += showdown.subParser('makeMarkdown.node')(nodes[i], globals);
}
function clean (node) {
for (var n = 0; n < node.childNodes.length; ++n) {
var child = node.childNodes[n];
if (child.nodeType === 3) {
if (!/\S/.test(child.nodeValue) && !/^[ ]+$/.test(child.nodeValue)) {
node.removeChild(child);
--n;
} else {
child.nodeValue = child.nodeValue.split('\n').join(' ');
child.nodeValue = child.nodeValue.replace(/(\s)+/g, '$1');
}
} else if (child.nodeType === 1) {
clean(child);
}
}
}
// find all pre tags and replace contents with placeholder
// we need this so that we can remove all indentation from html
// to ease up parsing
function substitutePreCodeTags (doc) {
var pres = doc.querySelectorAll('pre'),
presPH = [];
for (var i = 0; i < pres.length; ++i) {
if (pres[i].childElementCount === 1 && pres[i].firstChild.tagName.toLowerCase() === 'code') {
var content = pres[i].firstChild.innerHTML.trim(),
language = pres[i].firstChild.getAttribute('data-language') || '';
// if data-language attribute is not defined, then we look for class language-*
if (language === '') {
var classes = pres[i].firstChild.className.split(' ');
for (var c = 0; c < classes.length; ++c) {
var matches = classes[c].match(/^language-(.+)$/);
if (matches !== null) {
language = matches[1];
break;
}
}
}
// unescape html entities in content
content = showdown.helper.unescapeHTMLEntities(content);
presPH.push(content);
pres[i].outerHTML = '<precode language="' + language + '" precodenum="' + i.toString() + '"></precode>';
} else {
presPH.push(pres[i].innerHTML);
pres[i].innerHTML = '';
pres[i].setAttribute('prenum', i.toString());
}
}
return presPH;
}
return mdDoc;
};
/**
* Set an option of this Converter instance
* @param {string} key
* @param {*} value
*/
this.setOption = function (key, value) {
options[key] = value;
};
/**
* Get the option of this Converter instance
* @param {string} key
* @returns {*}
*/
this.getOption = function (key) {
return options[key];
};
/**
* Get the options of this Converter instance
* @returns {{}}
*/
this.getOptions = function () {
return options;
};
/**
* Add extension to THIS converter
* @param {{}} extension
* @param {string} [name=null]
*/
this.addExtension = function (extension, name) {
name = name || null;
_parseExtension(extension, name);
};
/**
* Use a global registered extension with THIS converter
* @param {string} extensionName Name of the previously registered extension
*/
this.useExtension = function (extensionName) {
_parseExtension(extensionName);
};
/**
* Set the flavor THIS converter should use
* @param {string} name
*/
this.setFlavor = function (name) {
if (!flavor.hasOwnProperty(name)) {
throw Error(name + ' flavor was not found');
}
var preset = flavor[name];
setConvFlavor = name;
for (var option in preset) {
if (preset.hasOwnProperty(option)) {
options[option] = preset[option];
}
}
};
/**
* Get the currently set flavor of this converter
* @returns {string}
*/
this.getFlavor = function () {
return setConvFlavor;
};
/**
* Remove an extension from THIS converter.
* Note: This is a costly operation. It's better to initialize a new converter
* and specify the extensions you wish to use
* @param {Array} extension
*/
this.removeExtension = function (extension) {
if (!showdown.helper.isArray(extension)) {
extension = [extension];
}
for (var a = 0; a < extension.length; ++a) {
var ext = extension[a];
for (var i = 0; i < langExtensions.length; ++i) {
if (langExtensions[i] === ext) {
langExtensions.splice(i, 1);
}
}
for (var ii = 0; ii < outputModifiers.length; ++ii) {
if (outputModifiers[ii] === ext) {
outputModifiers.splice(ii, 1);
}
}
}
};
/**
* Get all extension of THIS converter
* @returns {{language: Array, output: Array}}
*/
this.getAllExtensions = function () {
return {
language: langExtensions,
output: outputModifiers
};
};
/**
* Get the metadata of the previously parsed document
* @param raw
* @returns {string|{}}
*/
this.getMetadata = function (raw) {
if (raw) {
return metadata.raw;
} else {
return metadata.parsed;
}
};
/**
* Get the metadata format of the previously parsed document
* @returns {string}
*/
this.getMetadataFormat = function () {
return metadata.format;
};
/**
* Private: set a single key, value metadata pair
* @param {string} key
* @param {string} value
*/
this._setMetadataPair = function (key, value) {
metadata.parsed[key] = value;
};
/**
* Private: set metadata format
* @param {string} format
*/
this._setMetadataFormat = function (format) {
metadata.format = format;
};
/**
* Private: set metadata raw text
* @param {string} raw
*/
this._setMetadataRaw = function (raw) {
metadata.raw = raw;
};
};
/**
* Turn Markdown link shortcuts into XHTML <a> tags.
*/
showdown.subParser('anchors', function (text, options, globals) {
text = globals.converter._dispatch('anchors.before', text, options, globals);
var writeAnchorTag = function (wholeMatch, linkText, linkId, url, m5, m6, title) {
if (showdown.helper.isUndefined(title)) {
title = '';
}
linkId = linkId.toLowerCase();
// Special case for explicit empty url
if (wholeMatch.search(/\(<?\s*>? ?(['"].*['"])?\)$/m) > -1) {
url = '';
} else if (!url) {
if (!linkId) {
// lower-case and turn embedded newlines into spaces
linkId = linkText.toLowerCase().replace(/ ?\n/g, ' ');
}
url = '#' + linkId;
if (!showdown.helper.isUndefined(globals.gUrls[linkId])) {
url = globals.gUrls[linkId];
if (!showdown.helper.isUndefined(globals.gTitles[linkId])) {
title = globals.gTitles[linkId];
}
} else {
return wholeMatch;
}
}
//url = showdown.helper.escapeCharacters(url, '*_', false); // replaced line to improve performance
url = url.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
var result = '<a href="' + url + '"';
if (title !== '' && title !== null) {
title = title.replace(/"/g, '&quot;');
//title = showdown.helper.escapeCharacters(title, '*_', false); // replaced line to improve performance
title = title.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
result += ' title="' + title + '"';
}
// optionLinksInNewWindow only applies
// to external links. Hash links (#) open in same page
if (options.openLinksInNewWindow && !/^#/.test(url)) {
// escaped _
result += ' rel="noopener noreferrer" target="¨E95Eblank"';
}
result += '>' + linkText + '</a>';
return result;
};
// First, handle reference-style links: [link text] [id]
text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)] ?(?:\n *)?\[(.*?)]()()()()/g, writeAnchorTag);
// Next, inline-style links: [link text](url "optional title")
// cases with crazy urls like ./image/cat1).png
text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)]()[ \t]*\([ \t]?<([^>]*)>(?:[ \t]*((["'])([^"]*?)\5))?[ \t]?\)/g,
writeAnchorTag);
// normal cases
text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)]()[ \t]*\([ \t]?<?([\S]+?(?:\([\S]*?\)[\S]*?)?)>?(?:[ \t]*((["'])([^"]*?)\5))?[ \t]?\)/g,
writeAnchorTag);
// handle reference-style shortcuts: [link text]
// These must come last in case you've also got [link test][1]
// or [link test](/foo)
text = text.replace(/\[([^\[\]]+)]()()()()()/g, writeAnchorTag);
// Lastly handle GithubMentions if option is enabled
if (options.ghMentions) {
text = text.replace(/(^|\s)(\\)?(@([a-z\d]+(?:[a-z\d.-]+?[a-z\d]+)*))/gmi, function (wm, st, escape, mentions, username) {
if (escape === '\\') {
return st + mentions;
}
//check if options.ghMentionsLink is a string
if (!showdown.helper.isString(options.ghMentionsLink)) {
throw new Error('ghMentionsLink option must be a string');
}
var lnk = options.ghMentionsLink.replace(/\{u}/g, username),
target = '';
if (options.openLinksInNewWindow) {
target = ' rel="noopener noreferrer" target="¨E95Eblank"';
}
return st + '<a href="' + lnk + '"' + target + '>' + mentions + '</a>';
});
}
text = globals.converter._dispatch('anchors.after', text, options, globals);
return text;
});
// url allowed chars [a-z\d_.~:/?#[]@!$&'()*+,;=-]
var simpleURLRegex = /([*~_]+|\b)(((https?|ftp|dict):\/\/|www\.)[^'">\s]+?\.[^'">\s]+?)()(\1)?(?=\s|$)(?!["<>])/gi,
simpleURLRegex2 = /([*~_]+|\b)(((https?|ftp|dict):\/\/|www\.)[^'">\s]+\.[^'">\s]+?)([.!?,()\[\]])?(\1)?(?=\s|$)(?!["<>])/gi,
delimUrlRegex = /()<(((https?|ftp|dict):\/\/|www\.)[^'">\s]+)()>()/gi,
simpleMailRegex = /(^|\s)(?:mailto:)?([A-Za-z0-9!#$%&'*+-/=?^_`{|}~.]+@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)(?=$|\s)/gmi,
delimMailRegex = /<()(?:mailto:)?([-.\w]+@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)>/gi,
replaceLink = function (options) {
return function (wm, leadingMagicChars, link, m2, m3, trailingPunctuation, trailingMagicChars) {
link = link.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
var lnkTxt = link,
append = '',
target = '',
lmc = leadingMagicChars || '',
tmc = trailingMagicChars || '';
if (/^www\./i.test(link)) {
link = link.replace(/^www\./i, 'http://www.');
}
if (options.excludeTrailingPunctuationFromURLs && trailingPunctuation) {
append = trailingPunctuation;
}
if (options.openLinksInNewWindow) {
target = ' rel="noopener noreferrer" target="¨E95Eblank"';
}
return lmc + '<a href="' + link + '"' + target + '>' + lnkTxt + '</a>' + append + tmc;
};
},
replaceMail = function (options, globals) {
return function (wholeMatch, b, mail) {
var href = 'mailto:';
b = b || '';
mail = showdown.subParser('unescapeSpecialChars')(mail, options, globals);
if (options.encodeEmails) {
href = showdown.helper.encodeEmailAddress(href + mail);
mail = showdown.helper.encodeEmailAddress(mail);
} else {
href = href + mail;
}
return b + '<a href="' + href + '">' + mail + '</a>';
};
};
showdown.subParser('autoLinks', function (text, options, globals) {
text = globals.converter._dispatch('autoLinks.before', text, options, globals);
text = text.replace(delimUrlRegex, replaceLink(options));
text = text.replace(delimMailRegex, replaceMail(options, globals));
text = globals.converter._dispatch('autoLinks.after', text, options, globals);
return text;
});
showdown.subParser('simplifiedAutoLinks', function (text, options, globals) {
if (!options.simplifiedAutoLink) {
return text;
}
text = globals.converter._dispatch('simplifiedAutoLinks.before', text, options, globals);
if (options.excludeTrailingPunctuationFromURLs) {
text = text.replace(simpleURLRegex2, replaceLink(options));
} else {
text = text.replace(simpleURLRegex, replaceLink(options));
}
text = text.replace(simpleMailRegex, replaceMail(options, globals));
text = globals.converter._dispatch('simplifiedAutoLinks.after', text, options, globals);
return text;
});
/**
* These are all the transformations that form block-level
* tags like paragraphs, headers, and list items.
*/
showdown.subParser('blockGamut', function (text, options, globals) {
text = globals.converter._dispatch('blockGamut.before', text, options, globals);
// we parse blockquotes first so that we can have headings and hrs
// inside blockquotes
text = showdown.subParser('blockQuotes')(text, options, globals);
text = showdown.subParser('headers')(text, options, globals);
// Do Horizontal Rules:
text = showdown.subParser('horizontalRule')(text, options, globals);
text = showdown.subParser('lists')(text, options, globals);
text = showdown.subParser('codeBlocks')(text, options, globals);
text = showdown.subParser('tables')(text, options, globals);
// We already ran _HashHTMLBlocks() before, in Markdown(), but that
// was to escape raw HTML in the original Markdown source. This time,
// we're escaping the markup we've just created, so that we don't wrap
// <p> tags around block-level tags.
text = showdown.subParser('hashHTMLBlocks')(text, options, globals);
text = showdown.subParser('paragraphs')(text, options, globals);
text = globals.converter._dispatch('blockGamut.after', text, options, globals);
return text;
});
showdown.subParser('blockQuotes', function (text, options, globals) {
text = globals.converter._dispatch('blockQuotes.before', text, options, globals);
// add a couple extra lines after the text and endtext mark
text = text + '\n\n';
var rgx = /(^ {0,3}>[ \t]?.+\n(.+\n)*\n*)+/gm;
if (options.splitAdjacentBlockquotes) {
rgx = /^ {0,3}>[\s\S]*?(?:\n\n)/gm;
}
text = text.replace(rgx, function (bq) {
// attacklab: hack around Konqueror 3.5.4 bug:
// "----------bug".replace(/^-/g,"") == "bug"
bq = bq.replace(/^[ \t]*>[ \t]?/gm, ''); // trim one level of quoting
// attacklab: clean up hack
bq = bq.replace(/¨0/g, '');
bq = bq.replace(/^[ \t]+$/gm, ''); // trim whitespace-only lines
bq = showdown.subParser('githubCodeBlocks')(bq, options, globals);
bq = showdown.subParser('blockGamut')(bq, options, globals); // recurse
bq = bq.replace(/(^|\n)/g, '$1 ');
// These leading spaces screw with <pre> content, so we need to fix that:
bq = bq.replace(/(\s*<pre>[^\r]+?<\/pre>)/gm, function (wholeMatch, m1) {
var pre = m1;
// attacklab: hack around Konqueror 3.5.4 bug:
pre = pre.replace(/^ /mg, '¨0');
pre = pre.replace(/¨0/g, '');
return pre;
});
return showdown.subParser('hashBlock')('<blockquote>\n' + bq + '\n</blockquote>', options, globals);
});
text = globals.converter._dispatch('blockQuotes.after', text, options, globals);
return text;
});
/**
* Process Markdown `<pre><code>` blocks.
*/
showdown.subParser('codeBlocks', function (text, options, globals) {
text = globals.converter._dispatch('codeBlocks.before', text, options, globals);
// sentinel workarounds for lack of \A and \Z, safari\khtml bug
text += '¨0';
var pattern = /(?:\n\n|^)((?:(?:[ ]{4}|\t).*\n+)+)(\n*[ ]{0,3}[^ \t\n]|(?=¨0))/g;
text = text.replace(pattern, function (wholeMatch, m1, m2) {
var codeblock = m1,
nextChar = m2,
end = '\n';
codeblock = showdown.subParser('outdent')(codeblock, options, globals);
codeblock = showdown.subParser('encodeCode')(codeblock, options, globals);
codeblock = showdown.subParser('detab')(codeblock, options, globals);
codeblock = codeblock.replace(/^\n+/g, ''); // trim leading newlines
codeblock = codeblock.replace(/\n+$/g, ''); // trim trailing newlines
if (options.omitExtraWLInCodeBlocks) {
end = '';
}
codeblock = '<pre><code>' + codeblock + end + '</code></pre>';
return showdown.subParser('hashBlock')(codeblock, options, globals) + nextChar;
});
// strip sentinel
text = text.replace(/¨0/, '');
text = globals.converter._dispatch('codeBlocks.after', text, options, globals);
return text;
});
/**
*
* * Backtick quotes are used for <code></code> spans.
*
* * You can use multiple backticks as the delimiters if you want to
* include literal backticks in the code span. So, this input:
*
* Just type ``foo `bar` baz`` at the prompt.
*
* Will translate to:
*
* <p>Just type <code>foo `bar` baz</code> at the prompt.</p>
*
* There's no arbitrary limit to the number of backticks you
* can use as delimters. If you need three consecutive backticks
* in your code, use four for delimiters, etc.
*
* * You can use spaces to get literal backticks at the edges:
*
* ... type `` `bar` `` ...
*
* Turns to:
*
* ... type <code>`bar`</code> ...
*/
showdown.subParser('codeSpans', function (text, options, globals) {
text = globals.converter._dispatch('codeSpans.before', text, options, globals);
if (typeof (text) === 'undefined') {
text = '';
}
text = text.replace(/(^|[^\\])(`+)([^\r]*?[^`])\2(?!`)/gm,
function (wholeMatch, m1, m2, m3) {
var c = m3;
c = c.replace(/^([ \t]*)/g, ''); // leading whitespace
c = c.replace(/[ \t]*$/g, ''); // trailing whitespace
c = showdown.subParser('encodeCode')(c, options, globals);
c = m1 + '<code>' + c + '</code>';
c = showdown.subParser('hashHTMLSpans')(c, options, globals);
return c;
}
);
text = globals.converter._dispatch('codeSpans.after', text, options, globals);
return text;
});
/**
* Create a full HTML document from the processed markdown
*/
showdown.subParser('completeHTMLDocument', function (text, options, globals) {
if (!options.completeHTMLDocument) {
return text;
}
text = globals.converter._dispatch('completeHTMLDocument.before', text, options, globals);
var doctype = 'html',
doctypeParsed = '<!DOCTYPE HTML>\n',
title = '',
charset = '<meta charset="utf-8">\n',
lang = '',
metadata = '';
if (typeof globals.metadata.parsed.doctype !== 'undefined') {
doctypeParsed = '<!DOCTYPE ' + globals.metadata.parsed.doctype + '>\n';
doctype = globals.metadata.parsed.doctype.toString().toLowerCase();
if (doctype === 'html' || doctype === 'html5') {
charset = '<meta charset="utf-8">';
}
}
for (var meta in globals.metadata.parsed) {
if (globals.metadata.parsed.hasOwnProperty(meta)) {
switch (meta.toLowerCase()) {
case 'doctype':
break;
case 'title':
title = '<title>' + globals.metadata.parsed.title + '</title>\n';
break;
case 'charset':
if (doctype === 'html' || doctype === 'html5') {
charset = '<meta charset="' + globals.metadata.parsed.charset + '">\n';
} else {
charset = '<meta name="charset" content="' + globals.metadata.parsed.charset + '">\n';
}
break;
case 'language':
case 'lang':
lang = ' lang="' + globals.metadata.parsed[meta] + '"';
metadata += '<meta name="' + meta + '" content="' + globals.metadata.parsed[meta] + '">\n';
break;
default:
metadata += '<meta name="' + meta + '" content="' + globals.metadata.parsed[meta] + '">\n';
}
}
}
text = doctypeParsed + '<html' + lang + '>\n<head>\n' + title + charset + metadata + '</head>\n<body>\n' + text.trim() + '\n</body>\n</html>';
text = globals.converter._dispatch('completeHTMLDocument.after', text, options, globals);
return text;
});
/**
* Convert all tabs to spaces
*/
showdown.subParser('detab', function (text, options, globals) {
text = globals.converter._dispatch('detab.before', text, options, globals);
// expand first n-1 tabs
text = text.replace(/\t(?=\t)/g, ' '); // g_tab_width
// replace the nth with two sentinels
text = text.replace(/\t/g, '¨A¨B');
// use the sentinel to anchor our regex so it doesn't explode
text = text.replace(/¨B(.+?)¨A/g, function (wholeMatch, m1) {
var leadingText = m1,
numSpaces = 4 - leadingText.length % 4; // g_tab_width
// there *must* be a better way to do this:
for (var i = 0; i < numSpaces; i++) {
leadingText += ' ';
}
return leadingText;
});
// clean up sentinels
text = text.replace(/¨A/g, ' '); // g_tab_width
text = text.replace(/¨B/g, '');
text = globals.converter._dispatch('detab.after', text, options, globals);
return text;
});
showdown.subParser('ellipsis', function (text, options, globals) {
if (!options.ellipsis) {
return text;
}
text = globals.converter._dispatch('ellipsis.before', text, options, globals);
text = text.replace(/\.\.\./g, '…');
text = globals.converter._dispatch('ellipsis.after', text, options, globals);
return text;
});
/**
* Turn emoji codes into emojis
*
* List of supported emojis: https://github.com/showdownjs/showdown/wiki/Emojis
*/
showdown.subParser('emoji', function (text, options, globals) {
if (!options.emoji) {
return text;
}
text = globals.converter._dispatch('emoji.before', text, options, globals);
var emojiRgx = /:([\S]+?):/g;
text = text.replace(emojiRgx, function (wm, emojiCode) {
if (showdown.helper.emojis.hasOwnProperty(emojiCode)) {
return showdown.helper.emojis[emojiCode];
}
return wm;
});
text = globals.converter._dispatch('emoji.after', text, options, globals);
return text;
});
/**
* Smart processing for ampersands and angle brackets that need to be encoded.
*/
showdown.subParser('encodeAmpsAndAngles', function (text, options, globals) {
text = globals.converter._dispatch('encodeAmpsAndAngles.before', text, options, globals);
// Ampersand-encoding based entirely on Nat Irons's Amputator MT plugin:
// http://bumppo.net/projects/amputator/
text = text.replace(/&(?!#?[xX]?(?:[0-9a-fA-F]+|\w+);)/g, '&amp;');
// Encode naked <'s
text = text.replace(/<(?![a-z\/?$!])/gi, '&lt;');
// Encode <
text = text.replace(/</g, '&lt;');
// Encode >
text = text.replace(/>/g, '&gt;');
text = globals.converter._dispatch('encodeAmpsAndAngles.after', text, options, globals);
return text;
});
/**
* Returns the string, with after processing the following backslash escape sequences.
*
* attacklab: The polite way to do this is with the new escapeCharacters() function:
*
* text = escapeCharacters(text,"\\",true);
* text = escapeCharacters(text,"`*_{}[]()>#+-.!",true);
*
* ...but we're sidestepping its use of the (slow) RegExp constructor
* as an optimization for Firefox. This function gets called a LOT.
*/
showdown.subParser('encodeBackslashEscapes', function (text, options, globals) {
text = globals.converter._dispatch('encodeBackslashEscapes.before', text, options, globals);
text = text.replace(/\\(\\)/g, showdown.helper.escapeCharactersCallback);
text = text.replace(/\\([`*_{}\[\]()>#+.!~=|:-])/g, showdown.helper.escapeCharactersCallback);
text = globals.converter._dispatch('encodeBackslashEscapes.after', text, options, globals);
return text;
});
/**
* Encode/escape certain characters inside Markdown code runs.
* The point is that in code, these characters are literals,
* and lose their special Markdown meanings.
*/
showdown.subParser('encodeCode', function (text, options, globals) {
text = globals.converter._dispatch('encodeCode.before', text, options, globals);
// Encode all ampersands; HTML entities are not
// entities within a Markdown code span.
text = text
.replace(/&/g, '&amp;')
// Do the angle bracket song and dance:
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;')
// Now, escape characters that are magic in Markdown:
.replace(/([*_{}\[\]\\=~-])/g, showdown.helper.escapeCharactersCallback);
text = globals.converter._dispatch('encodeCode.after', text, options, globals);
return text;
});
/**
* Within tags -- meaning between < and > -- encode [\ ` * _ ~ =] so they
* don't conflict with their use in Markdown for code, italics and strong.
*/
showdown.subParser('escapeSpecialCharsWithinTagAttributes', function (text, options, globals) {
text = globals.converter._dispatch('escapeSpecialCharsWithinTagAttributes.before', text, options, globals);
// Build a regex to find HTML tags.
var tags = /<\/?[a-z\d_:-]+(?:[\s]+[\s\S]+?)?>/gi,
comments = /<!(--(?:(?:[^>-]|-[^>])(?:[^-]|-[^-])*)--)>/gi;
text = text.replace(tags, function (wholeMatch) {
return wholeMatch
.replace(/(.)<\/?code>(?=.)/g, '$1`')
.replace(/([\\`*_~=|])/g, showdown.helper.escapeCharactersCallback);
});
text = text.replace(comments, function (wholeMatch) {
return wholeMatch
.replace(/([\\`*_~=|])/g, showdown.helper.escapeCharactersCallback);
});
text = globals.converter._dispatch('escapeSpecialCharsWithinTagAttributes.after', text, options, globals);
return text;
});
/**
* Handle github codeblocks prior to running HashHTML so that
* HTML contained within the codeblock gets escaped properly
* Example:
* ```ruby
* def hello_world(x)
* puts "Hello, #{x}"
* end
* ```
*/
showdown.subParser('githubCodeBlocks', function (text, options, globals) {
// early exit if option is not enabled
if (!options.ghCodeBlocks) {
return text;
}
text = globals.converter._dispatch('githubCodeBlocks.before', text, options, globals);
text += '¨0';
text = text.replace(/(?:^|\n)(?: {0,3})(```+|~~~+)(?: *)([^\s`~]*)\n([\s\S]*?)\n(?: {0,3})\1/g, function (wholeMatch, delim, language, codeblock) {
var end = (options.omitExtraWLInCodeBlocks) ? '' : '\n';
// First parse the github code block
codeblock = showdown.subParser('encodeCode')(codeblock, options, globals);
codeblock = showdown.subParser('detab')(codeblock, options, globals);
codeblock = codeblock.replace(/^\n+/g, ''); // trim leading newlines
codeblock = codeblock.replace(/\n+$/g, ''); // trim trailing whitespace
codeblock = '<pre><code' + (language ? ' class="' + language + ' language-' + language + '"' : '') + '>' + codeblock + end + '</code></pre>';
codeblock = showdown.subParser('hashBlock')(codeblock, options, globals);
// Since GHCodeblocks can be false positives, we need to
// store the primitive text and the parsed text in a global var,
// and then return a token
return '\n\n¨G' + (globals.ghCodeBlocks.push({text: wholeMatch, codeblock: codeblock}) - 1) + 'G\n\n';
});
// attacklab: strip sentinel
text = text.replace(/¨0/, '');
return globals.converter._dispatch('githubCodeBlocks.after', text, options, globals);
});
showdown.subParser('hashBlock', function (text, options, globals) {
text = globals.converter._dispatch('hashBlock.before', text, options, globals);
text = text.replace(/(^\n+|\n+$)/g, '');
text = '\n\n¨K' + (globals.gHtmlBlocks.push(text) - 1) + 'K\n\n';
text = globals.converter._dispatch('hashBlock.after', text, options, globals);
return text;
});
/**
* Hash and escape <code> elements that should not be parsed as markdown
*/
showdown.subParser('hashCodeTags', function (text, options, globals) {
text = globals.converter._dispatch('hashCodeTags.before', text, options, globals);
var repFunc = function (wholeMatch, match, left, right) {
var codeblock = left + showdown.subParser('encodeCode')(match, options, globals) + right;
return '¨C' + (globals.gHtmlSpans.push(codeblock) - 1) + 'C';
};
// Hash naked <code>
text = showdown.helper.replaceRecursiveRegExp(text, repFunc, '<code\\b[^>]*>', '</code>', 'gim');
text = globals.converter._dispatch('hashCodeTags.after', text, options, globals);
return text;
});
showdown.subParser('hashElement', function (text, options, globals) {
return function (wholeMatch, m1) {
var blockText = m1;
// Undo double lines
blockText = blockText.replace(/\n\n/g, '\n');
blockText = blockText.replace(/^\n/, '');
// strip trailing blank lines
blockText = blockText.replace(/\n+$/g, '');
// Replace the element text with a marker ("¨KxK" where x is its key)
blockText = '\n\n¨K' + (globals.gHtmlBlocks.push(blockText) - 1) + 'K\n\n';
return blockText;
};
});
showdown.subParser('hashHTMLBlocks', function (text, options, globals) {
text = globals.converter._dispatch('hashHTMLBlocks.before', text, options, globals);
var blockTags = [
'pre',
'div',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'blockquote',
'table',
'dl',
'ol',
'ul',
'script',
'noscript',
'form',
'fieldset',
'iframe',
'math',
'style',
'section',
'header',
'footer',
'nav',
'article',
'aside',
'address',
'audio',
'canvas',
'figure',
'hgroup',
'output',
'video',
'p'
],
repFunc = function (wholeMatch, match, left, right) {
var txt = wholeMatch;
// check if this html element is marked as markdown
// if so, it's contents should be parsed as markdown
if (left.search(/\bmarkdown\b/) !== -1) {
txt = left + globals.converter.makeHtml(match) + right;
}
return '\n\n¨K' + (globals.gHtmlBlocks.push(txt) - 1) + 'K\n\n';
};
if (options.backslashEscapesHTMLTags) {
// encode backslash escaped HTML tags
text = text.replace(/\\<(\/?[^>]+?)>/g, function (wm, inside) {
return '&lt;' + inside + '&gt;';
});
}
// hash HTML Blocks
for (var i = 0; i < blockTags.length; ++i) {
var opTagPos,
rgx1 = new RegExp('^ {0,3}(<' + blockTags[i] + '\\b[^>]*>)', 'im'),
patLeft = '<' + blockTags[i] + '\\b[^>]*>',
patRight = '</' + blockTags[i] + '>';
// 1. Look for the first position of the first opening HTML tag in the text
while ((opTagPos = showdown.helper.regexIndexOf(text, rgx1)) !== -1) {
// if the HTML tag is \ escaped, we need to escape it and break
//2. Split the text in that position
var subTexts = showdown.helper.splitAtIndex(text, opTagPos),
//3. Match recursively
newSubText1 = showdown.helper.replaceRecursiveRegExp(subTexts[1], repFunc, patLeft, patRight, 'im');
// prevent an infinite loop
if (newSubText1 === subTexts[1]) {
break;
}
text = subTexts[0].concat(newSubText1);
}
}
// HR SPECIAL CASE
text = text.replace(/(\n {0,3}(<(hr)\b([^<>])*?\/?>)[ \t]*(?=\n{2,}))/g,
showdown.subParser('hashElement')(text, options, globals));
// Special case for standalone HTML comments
text = showdown.helper.replaceRecursiveRegExp(text, function (txt) {
return '\n\n¨K' + (globals.gHtmlBlocks.push(txt) - 1) + 'K\n\n';
}, '^ {0,3}<!--', '-->', 'gm');
// PHP and ASP-style processor instructions (<?...?> and <%...%>)
text = text.replace(/(?:\n\n)( {0,3}(?:<([?%])[^\r]*?\2>)[ \t]*(?=\n{2,}))/g,
showdown.subParser('hashElement')(text, options, globals));
text = globals.converter._dispatch('hashHTMLBlocks.after', text, options, globals);
return text;
});
/**
* Hash span elements that should not be parsed as markdown
*/
showdown.subParser('hashHTMLSpans', function (text, options, globals) {
text = globals.converter._dispatch('hashHTMLSpans.before', text, options, globals);
function hashHTMLSpan (html) {
return '¨C' + (globals.gHtmlSpans.push(html) - 1) + 'C';
}
// Hash Self Closing tags
text = text.replace(/<[^>]+?\/>/gi, function (wm) {
return hashHTMLSpan(wm);
});
// Hash tags without properties
text = text.replace(/<([^>]+?)>[\s\S]*?<\/\1>/g, function (wm) {
return hashHTMLSpan(wm);
});
// Hash tags with properties
text = text.replace(/<([^>]+?)\s[^>]+?>[\s\S]*?<\/\1>/g, function (wm) {
return hashHTMLSpan(wm);
});
// Hash self closing tags without />
text = text.replace(/<[^>]+?>/gi, function (wm) {
return hashHTMLSpan(wm);
});
/*showdown.helper.matchRecursiveRegExp(text, '<code\\b[^>]*>', '</code>', 'gi');*/
text = globals.converter._dispatch('hashHTMLSpans.after', text, options, globals);
return text;
});
/**
* Unhash HTML spans
*/
showdown.subParser('unhashHTMLSpans', function (text, options, globals) {
text = globals.converter._dispatch('unhashHTMLSpans.before', text, options, globals);
for (var i = 0; i < globals.gHtmlSpans.length; ++i) {
var repText = globals.gHtmlSpans[i],
// limiter to prevent infinite loop (assume 10 as limit for recurse)
limit = 0;
while (/¨C(\d+)C/.test(repText)) {
var num = RegExp.$1;
repText = repText.replace('¨C' + num + 'C', globals.gHtmlSpans[num]);
if (limit === 10) {
console.error('maximum nesting of 10 spans reached!!!');
break;
}
++limit;
}
text = text.replace('¨C' + i + 'C', repText);
}
text = globals.converter._dispatch('unhashHTMLSpans.after', text, options, globals);
return text;
});
/**
* Hash and escape <pre><code> elements that should not be parsed as markdown
*/
showdown.subParser('hashPreCodeTags', function (text, options, globals) {
text = globals.converter._dispatch('hashPreCodeTags.before', text, options, globals);
var repFunc = function (wholeMatch, match, left, right) {
// encode html entities
var codeblock = left + showdown.subParser('encodeCode')(match, options, globals) + right;
return '\n\n¨G' + (globals.ghCodeBlocks.push({text: wholeMatch, codeblock: codeblock}) - 1) + 'G\n\n';
};
// Hash <pre><code>
text = showdown.helper.replaceRecursiveRegExp(text, repFunc, '^ {0,3}<pre\\b[^>]*>\\s*<code\\b[^>]*>', '^ {0,3}</code>\\s*</pre>', 'gim');
text = globals.converter._dispatch('hashPreCodeTags.after', text, options, globals);
return text;
});
showdown.subParser('headers', function (text, options, globals) {
text = globals.converter._dispatch('headers.before', text, options, globals);
var headerLevelStart = (isNaN(parseInt(options.headerLevelStart))) ? 1 : parseInt(options.headerLevelStart),
// Set text-style headers:
// Header 1
// ========
//
// Header 2
// --------
//
setextRegexH1 = (options.smoothLivePreview) ? /^(.+)[ \t]*\n={2,}[ \t]*\n+/gm : /^(.+)[ \t]*\n=+[ \t]*\n+/gm,
setextRegexH2 = (options.smoothLivePreview) ? /^(.+)[ \t]*\n-{2,}[ \t]*\n+/gm : /^(.+)[ \t]*\n-+[ \t]*\n+/gm;
text = text.replace(setextRegexH1, function (wholeMatch, m1) {
var spanGamut = showdown.subParser('spanGamut')(m1, options, globals),
hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"',
hLevel = headerLevelStart,
hashBlock = '<h' + hLevel + hID + '>' + spanGamut + '</h' + hLevel + '>';
return showdown.subParser('hashBlock')(hashBlock, options, globals);
});
text = text.replace(setextRegexH2, function (matchFound, m1) {
var spanGamut = showdown.subParser('spanGamut')(m1, options, globals),
hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"',
hLevel = headerLevelStart + 1,
hashBlock = '<h' + hLevel + hID + '>' + spanGamut + '</h' + hLevel + '>';
return showdown.subParser('hashBlock')(hashBlock, options, globals);
});
// atx-style headers:
// # Header 1
// ## Header 2
// ## Header 2 with closing hashes ##
// ...
// ###### Header 6
//
var atxStyle = (options.requireSpaceBeforeHeadingText) ? /^(#{1,6})[ \t]+(.+?)[ \t]*#*\n+/gm : /^(#{1,6})[ \t]*(.+?)[ \t]*#*\n+/gm;
text = text.replace(atxStyle, function (wholeMatch, m1, m2) {
var hText = m2;
if (options.customizedHeaderId) {
hText = m2.replace(/\s?\{([^{]+?)}\s*$/, '');
}
var span = showdown.subParser('spanGamut')(hText, options, globals),
hID = (options.noHeaderId) ? '' : ' id="' + headerId(m2) + '"',
hLevel = headerLevelStart - 1 + m1.length,
header = '<h' + hLevel + hID + '>' + span + '</h' + hLevel + '>';
return showdown.subParser('hashBlock')(header, options, globals);
});
function headerId (m) {
var title,
prefix;
// It is separate from other options to allow combining prefix and customized
if (options.customizedHeaderId) {
var match = m.match(/\{([^{]+?)}\s*$/);
if (match && match[1]) {
m = match[1];
}
}
title = m;
// Prefix id to prevent causing inadvertent pre-existing style matches.
if (showdown.helper.isString(options.prefixHeaderId)) {
prefix = options.prefixHeaderId;
} else if (options.prefixHeaderId === true) {
prefix = 'section-';
} else {
prefix = '';
}
if (!options.rawPrefixHeaderId) {
title = prefix + title;
}
if (options.ghCompatibleHeaderId) {
title = title
.replace(/ /g, '-')
// replace previously escaped chars (&, ¨ and $)
.replace(/&amp;/g, '')
.replace(/¨T/g, '')
.replace(/¨D/g, '')
// replace rest of the chars (&~$ are repeated as they might have been escaped)
// borrowed from github's redcarpet (some they should produce similar results)
.replace(/[&+$,\/:;=?@"#{}|^¨~\[\]`\\*)(%.!'<>]/g, '')
.toLowerCase();
} else if (options.rawHeaderId) {
title = title
.replace(/ /g, '-')
// replace previously escaped chars (&, ¨ and $)
.replace(/&amp;/g, '&')
.replace(/¨T/g, '¨')
.replace(/¨D/g, '$')
// replace " and '
.replace(/["']/g, '-')
.toLowerCase();
} else {
title = title
.replace(/[^\w]/g, '')
.toLowerCase();
}
if (options.rawPrefixHeaderId) {
title = prefix + title;
}
if (globals.hashLinkCounts[title]) {
title = title + '-' + (globals.hashLinkCounts[title]++);
} else {
globals.hashLinkCounts[title] = 1;
}
return title;
}
text = globals.converter._dispatch('headers.after', text, options, globals);
return text;
});
/**
* Turn Markdown link shortcuts into XHTML <a> tags.
*/
showdown.subParser('horizontalRule', function (text, options, globals) {
text = globals.converter._dispatch('horizontalRule.before', text, options, globals);
var key = showdown.subParser('hashBlock')('<hr />', options, globals);
text = text.replace(/^ {0,2}( ?-){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?\*){3,}[ \t]*$/gm, key);
text = text.replace(/^ {0,2}( ?_){3,}[ \t]*$/gm, key);
text = globals.converter._dispatch('horizontalRule.after', text, options, globals);
return text;
});
/**
* Turn Markdown image shortcuts into <img> tags.
*/
showdown.subParser('images', function (text, options, globals) {
text = globals.converter._dispatch('images.before', text, options, globals);
var inlineRegExp = /!\[([^\]]*?)][ \t]*()\([ \t]?<?([\S]+?(?:\([\S]*?\)[\S]*?)?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(["'])([^"]*?)\6)?[ \t]?\)/g,
crazyRegExp = /!\[([^\]]*?)][ \t]*()\([ \t]?<([^>]*)>(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(?:(["'])([^"]*?)\6))?[ \t]?\)/g,
base64RegExp = /!\[([^\]]*?)][ \t]*()\([ \t]?<?(data:.+?\/.+?;base64,[A-Za-z0-9+/=\n]+?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(["'])([^"]*?)\6)?[ \t]?\)/g,
referenceRegExp = /!\[([^\]]*?)] ?(?:\n *)?\[([\s\S]*?)]()()()()()/g,
refShortcutRegExp = /!\[([^\[\]]+)]()()()()()/g;
function writeImageTagBase64 (wholeMatch, altText, linkId, url, width, height, m5, title) {
url = url.replace(/\s/g, '');
return writeImageTag (wholeMatch, altText, linkId, url, width, height, m5, title);
}
function writeImageTag (wholeMatch, altText, linkId, url, width, height, m5, title) {
var gUrls = globals.gUrls,
gTitles = globals.gTitles,
gDims = globals.gDimensions;
linkId = linkId.toLowerCase();
if (!title) {
title = '';
}
// Special case for explicit empty url
if (wholeMatch.search(/\(<?\s*>? ?(['"].*['"])?\)$/m) > -1) {
url = '';
} else if (url === '' || url === null) {
if (linkId === '' || linkId === null) {
// lower-case and turn embedded newlines into spaces
linkId = altText.toLowerCase().replace(/ ?\n/g, ' ');
}
url = '#' + linkId;
if (!showdown.helper.isUndefined(gUrls[linkId])) {
url = gUrls[linkId];
if (!showdown.helper.isUndefined(gTitles[linkId])) {
title = gTitles[linkId];
}
if (!showdown.helper.isUndefined(gDims[linkId])) {
width = gDims[linkId].width;
height = gDims[linkId].height;
}
} else {
return wholeMatch;
}
}
altText = altText
.replace(/"/g, '&quot;')
//altText = showdown.helper.escapeCharacters(altText, '*_', false);
.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
//url = showdown.helper.escapeCharacters(url, '*_', false);
url = url.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
var result = '<img src="' + url + '" alt="' + altText + '"';
if (title && showdown.helper.isString(title)) {
title = title
.replace(/"/g, '&quot;')
//title = showdown.helper.escapeCharacters(title, '*_', false);
.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
result += ' title="' + title + '"';
}
if (width && height) {
width = (width === '*') ? 'auto' : width;
height = (height === '*') ? 'auto' : height;
result += ' width="' + width + '"';
result += ' height="' + height + '"';
}
result += ' />';
return result;
}
// First, handle reference-style labeled images: ![alt text][id]
text = text.replace(referenceRegExp, writeImageTag);
// Next, handle inline images: ![alt text](url =<width>x<height> "optional title")
// base64 encoded images
text = text.replace(base64RegExp, writeImageTagBase64);
// cases with crazy urls like ./image/cat1).png
text = text.replace(crazyRegExp, writeImageTag);
// normal cases
text = text.replace(inlineRegExp, writeImageTag);
// handle reference-style shortcuts: ![img text]
text = text.replace(refShortcutRegExp, writeImageTag);
text = globals.converter._dispatch('images.after', text, options, globals);
return text;
});
showdown.subParser('italicsAndBold', function (text, options, globals) {
text = globals.converter._dispatch('italicsAndBold.before', text, options, globals);
// it's faster to have 3 separate regexes for each case than have just one
// because of backtracing, in some cases, it could lead to an exponential effect
// called "catastrophic backtrace". Ominous!
function parseInside (txt, left, right) {
/*
if (options.simplifiedAutoLink) {
txt = showdown.subParser('simplifiedAutoLinks')(txt, options, globals);
}
*/
return left + txt + right;
}
// Parse underscores
if (options.literalMidWordUnderscores) {
text = text.replace(/\b___(\S[\s\S]*?)___\b/g, function (wm, txt) {
return parseInside (txt, '<strong><em>', '</em></strong>');
});
text = text.replace(/\b__(\S[\s\S]*?)__\b/g, function (wm, txt) {
return parseInside (txt, '<strong>', '</strong>');
});
text = text.replace(/\b_(\S[\s\S]*?)_\b/g, function (wm, txt) {
return parseInside (txt, '<em>', '</em>');
});
} else {
text = text.replace(/___(\S[\s\S]*?)___/g, function (wm, m) {
return (/\S$/.test(m)) ? parseInside (m, '<strong><em>', '</em></strong>') : wm;
});
text = text.replace(/__(\S[\s\S]*?)__/g, function (wm, m) {
return (/\S$/.test(m)) ? parseInside (m, '<strong>', '</strong>') : wm;
});
text = text.replace(/_([^\s_][\s\S]*?)_/g, function (wm, m) {
// !/^_[^_]/.test(m) - test if it doesn't start with __ (since it seems redundant, we removed it)
return (/\S$/.test(m)) ? parseInside (m, '<em>', '</em>') : wm;
});
}
// Now parse asterisks
if (options.literalMidWordAsterisks) {
text = text.replace(/([^*]|^)\B\*\*\*(\S[\s\S]*?)\*\*\*\B(?!\*)/g, function (wm, lead, txt) {
return parseInside (txt, lead + '<strong><em>', '</em></strong>');
});
text = text.replace(/([^*]|^)\B\*\*(\S[\s\S]*?)\*\*\B(?!\*)/g, function (wm, lead, txt) {
return parseInside (txt, lead + '<strong>', '</strong>');
});
text = text.replace(/([^*]|^)\B\*(\S[\s\S]*?)\*\B(?!\*)/g, function (wm, lead, txt) {
return parseInside (txt, lead + '<em>', '</em>');
});
} else {
text = text.replace(/\*\*\*(\S[\s\S]*?)\*\*\*/g, function (wm, m) {
return (/\S$/.test(m)) ? parseInside (m, '<strong><em>', '</em></strong>') : wm;
});
text = text.replace(/\*\*(\S[\s\S]*?)\*\*/g, function (wm, m) {
return (/\S$/.test(m)) ? parseInside (m, '<strong>', '</strong>') : wm;
});
text = text.replace(/\*([^\s*][\s\S]*?)\*/g, function (wm, m) {
// !/^\*[^*]/.test(m) - test if it doesn't start with ** (since it seems redundant, we removed it)
return (/\S$/.test(m)) ? parseInside (m, '<em>', '</em>') : wm;
});
}
text = globals.converter._dispatch('italicsAndBold.after', text, options, globals);
return text;
});
/**
* Form HTML ordered (numbered) and unordered (bulleted) lists.
*/
showdown.subParser('lists', function (text, options, globals) {
/**
* Process the contents of a single ordered or unordered list, splitting it
* into individual list items.
* @param {string} listStr
* @param {boolean} trimTrailing
* @returns {string}
*/
function processListItems (listStr, trimTrailing) {
// The $g_list_level global keeps track of when we're inside a list.
// Each time we enter a list, we increment it; when we leave a list,
// we decrement. If it's zero, we're not in a list anymore.
//
// We do this because when we're not inside a list, we want to treat
// something like this:
//
// I recommend upgrading to version
// 8. Oops, now this line is treated
// as a sub-list.
//
// As a single paragraph, despite the fact that the second line starts
// with a digit-period-space sequence.
//
// Whereas when we're inside a list (or sub-list), that line will be
// treated as the start of a sub-list. What a kludge, huh? This is
// an aspect of Markdown's syntax that's hard to parse perfectly
// without resorting to mind-reading. Perhaps the solution is to
// change the syntax rules such that sub-lists must start with a
// starting cardinal number; e.g. "1." or "a.".
globals.gListLevel++;
// trim trailing blank lines:
listStr = listStr.replace(/\n{2,}$/, '\n');
// attacklab: add sentinel to emulate \z
listStr += '¨0';
var rgx = /(\n)?(^ {0,3})([*+-]|\d+[.])[ \t]+((\[(x|X| )?])?[ \t]*[^\r]+?(\n{1,2}))(?=\n*(¨0| {0,3}([*+-]|\d+[.])[ \t]+))/gm,
isParagraphed = (/\n[ \t]*\n(?!¨0)/.test(listStr));
// Since version 1.5, nesting sublists requires 4 spaces (or 1 tab) indentation,
// which is a syntax breaking change
// activating this option reverts to old behavior
if (options.disableForced4SpacesIndentedSublists) {
rgx = /(\n)?(^ {0,3})([*+-]|\d+[.])[ \t]+((\[(x|X| )?])?[ \t]*[^\r]+?(\n{1,2}))(?=\n*(¨0|\2([*+-]|\d+[.])[ \t]+))/gm;
}
listStr = listStr.replace(rgx, function (wholeMatch, m1, m2, m3, m4, taskbtn, checked) {
checked = (checked && checked.trim() !== '');
var item = showdown.subParser('outdent')(m4, options, globals),
bulletStyle = '';
// Support for github tasklists
if (taskbtn && options.tasklists) {
bulletStyle = ' class="task-list-item" style="list-style-type: none;"';
item = item.replace(/^[ \t]*\[(x|X| )?]/m, function () {
var otp = '<input type="checkbox" disabled style="margin: 0px 0.35em 0.25em -1.6em; vertical-align: middle;"';
if (checked) {
otp += ' checked';
}
otp += '>';
return otp;
});
}
// ISSUE #312
// This input: - - - a
// causes trouble to the parser, since it interprets it as:
// <ul><li><li><li>a</li></li></li></ul>
// instead of:
// <ul><li>- - a</li></ul>
// So, to prevent it, we will put a marker (¨A)in the beginning of the line
// Kind of hackish/monkey patching, but seems more effective than overcomplicating the list parser
item = item.replace(/^([-*+]|\d\.)[ \t]+[\S\n ]*/g, function (wm2) {
return '¨A' + wm2;
});
// m1 - Leading line or
// Has a double return (multi paragraph) or
// Has sublist
if (m1 || (item.search(/\n{2,}/) > -1)) {
item = showdown.subParser('githubCodeBlocks')(item, options, globals);
item = showdown.subParser('blockGamut')(item, options, globals);
} else {
// Recursion for sub-lists:
item = showdown.subParser('lists')(item, options, globals);
item = item.replace(/\n$/, ''); // chomp(item)
item = showdown.subParser('hashHTMLBlocks')(item, options, globals);
// Colapse double linebreaks
item = item.replace(/\n\n+/g, '\n\n');
if (isParagraphed) {
item = showdown.subParser('paragraphs')(item, options, globals);
} else {
item = showdown.subParser('spanGamut')(item, options, globals);
}
}
// now we need to remove the marker (¨A)
item = item.replace('¨A', '');
// we can finally wrap the line in list item tags
item = '<li' + bulletStyle + '>' + item + '</li>\n';
return item;
});
// attacklab: strip sentinel
listStr = listStr.replace(/¨0/g, '');
globals.gListLevel--;
if (trimTrailing) {
listStr = listStr.replace(/\s+$/, '');
}
return listStr;
}
function styleStartNumber (list, listType) {
// check if ol and starts by a number different than 1
if (listType === 'ol') {
var res = list.match(/^ *(\d+)\./);
if (res && res[1] !== '1') {
return ' start="' + res[1] + '"';
}
}
return '';
}
/**
* Check and parse consecutive lists (better fix for issue #142)
* @param {string} list
* @param {string} listType
* @param {boolean} trimTrailing
* @returns {string}
*/
function parseConsecutiveLists (list, listType, trimTrailing) {
// check if we caught 2 or more consecutive lists by mistake
// we use the counterRgx, meaning if listType is UL we look for OL and vice versa
var olRgx = (options.disableForced4SpacesIndentedSublists) ? /^ ?\d+\.[ \t]/gm : /^ {0,3}\d+\.[ \t]/gm,
ulRgx = (options.disableForced4SpacesIndentedSublists) ? /^ ?[*+-][ \t]/gm : /^ {0,3}[*+-][ \t]/gm,
counterRxg = (listType === 'ul') ? olRgx : ulRgx,
result = '';
if (list.search(counterRxg) !== -1) {
(function parseCL (txt) {
var pos = txt.search(counterRxg),
style = styleStartNumber(list, listType);
if (pos !== -1) {
// slice
result += '\n\n<' + listType + style + '>\n' + processListItems(txt.slice(0, pos), !!trimTrailing) + '</' + listType + '>\n';
// invert counterType and listType
listType = (listType === 'ul') ? 'ol' : 'ul';
counterRxg = (listType === 'ul') ? olRgx : ulRgx;
//recurse
parseCL(txt.slice(pos));
} else {
result += '\n\n<' + listType + style + '>\n' + processListItems(txt, !!trimTrailing) + '</' + listType + '>\n';
}
})(list);
} else {
var style = styleStartNumber(list, listType);
result = '\n\n<' + listType + style + '>\n' + processListItems(list, !!trimTrailing) + '</' + listType + '>\n';
}
return result;
}
/** Start of list parsing **/
text = globals.converter._dispatch('lists.before', text, options, globals);
// add sentinel to hack around khtml/safari bug:
// http://bugs.webkit.org/show_bug.cgi?id=11231
text += '¨0';
if (globals.gListLevel) {
text = text.replace(/^(( {0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(¨0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm,
function (wholeMatch, list, m2) {
var listType = (m2.search(/[*+-]/g) > -1) ? 'ul' : 'ol';
return parseConsecutiveLists(list, listType, true);
}
);
} else {
text = text.replace(/(\n\n|^\n?)(( {0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(¨0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm,
function (wholeMatch, m1, list, m3) {
var listType = (m3.search(/[*+-]/g) > -1) ? 'ul' : 'ol';
return parseConsecutiveLists(list, listType, false);
}
);
}
// strip sentinel
text = text.replace(/¨0/, '');
text = globals.converter._dispatch('lists.after', text, options, globals);
return text;
});
/**
* Parse metadata at the top of the document
*/
showdown.subParser('metadata', function (text, options, globals) {
if (!options.metadata) {
return text;
}
text = globals.converter._dispatch('metadata.before', text, options, globals);
function parseMetadataContents (content) {
// raw is raw so it's not changed in any way
globals.metadata.raw = content;
// escape chars forbidden in html attributes
// double quotes
content = content
// ampersand first
.replace(/&/g, '&amp;')
// double quotes
.replace(/"/g, '&quot;');
content = content.replace(/\n {4}/g, ' ');
content.replace(/^([\S ]+): +([\s\S]+?)$/gm, function (wm, key, value) {
globals.metadata.parsed[key] = value;
return '';
});
}
text = text.replace(/^\s*«««+(\S*?)\n([\s\S]+?)\n»»»+\n/, function (wholematch, format, content) {
parseMetadataContents(content);
return '¨M';
});
text = text.replace(/^\s*---+(\S*?)\n([\s\S]+?)\n---+\n/, function (wholematch, format, content) {
if (format) {
globals.metadata.format = format;
}
parseMetadataContents(content);
return '¨M';
});
text = text.replace(/¨M/g, '');
text = globals.converter._dispatch('metadata.after', text, options, globals);
return text;
});
/**
* Remove one level of line-leading tabs or spaces
*/
showdown.subParser('outdent', function (text, options, globals) {
text = globals.converter._dispatch('outdent.before', text, options, globals);
// attacklab: hack around Konqueror 3.5.4 bug:
// "----------bug".replace(/^-/g,"") == "bug"
text = text.replace(/^(\t|[ ]{1,4})/gm, '¨0'); // attacklab: g_tab_width
// attacklab: clean up hack
text = text.replace(/¨0/g, '');
text = globals.converter._dispatch('outdent.after', text, options, globals);
return text;
});
/**
*
*/
showdown.subParser('paragraphs', function (text, options, globals) {
text = globals.converter._dispatch('paragraphs.before', text, options, globals);
// Strip leading and trailing lines:
text = text.replace(/^\n+/g, '');
text = text.replace(/\n+$/g, '');
var grafs = text.split(/\n{2,}/g),
grafsOut = [],
end = grafs.length; // Wrap <p> tags
for (var i = 0; i < end; i++) {
var str = grafs[i];
// if this is an HTML marker, copy it
if (str.search(/¨(K|G)(\d+)\1/g) >= 0) {
grafsOut.push(str);
// test for presence of characters to prevent empty lines being parsed
// as paragraphs (resulting in undesired extra empty paragraphs)
} else if (str.search(/\S/) >= 0) {
str = showdown.subParser('spanGamut')(str, options, globals);
str = str.replace(/^([ \t]*)/g, '<p>');
str += '</p>';
grafsOut.push(str);
}
}
/** Unhashify HTML blocks */
end = grafsOut.length;
for (i = 0; i < end; i++) {
var blockText = '',
grafsOutIt = grafsOut[i],
codeFlag = false;
// if this is a marker for an html block...
// use RegExp.test instead of string.search because of QML bug
while (/¨(K|G)(\d+)\1/.test(grafsOutIt)) {
var delim = RegExp.$1,
num = RegExp.$2;
if (delim === 'K') {
blockText = globals.gHtmlBlocks[num];
} else {
// we need to check if ghBlock is a false positive
if (codeFlag) {
// use encoded version of all text
blockText = showdown.subParser('encodeCode')(globals.ghCodeBlocks[num].text, options, globals);
} else {
blockText = globals.ghCodeBlocks[num].codeblock;
}
}
blockText = blockText.replace(/\$/g, '$$$$'); // Escape any dollar signs
grafsOutIt = grafsOutIt.replace(/(\n\n)?¨(K|G)\d+\2(\n\n)?/, blockText);
// Check if grafsOutIt is a pre->code
if (/^<pre\b[^>]*>\s*<code\b[^>]*>/.test(grafsOutIt)) {
codeFlag = true;
}
}
grafsOut[i] = grafsOutIt;
}
text = grafsOut.join('\n');
// Strip leading and trailing lines:
text = text.replace(/^\n+/g, '');
text = text.replace(/\n+$/g, '');
return globals.converter._dispatch('paragraphs.after', text, options, globals);
});
/**
* Run extension
*/
showdown.subParser('runExtension', function (ext, text, options, globals) {
if (ext.filter) {
text = ext.filter(text, globals.converter, options);
} else if (ext.regex) {
// TODO remove this when old extension loading mechanism is deprecated
var re = ext.regex;
if (!(re instanceof RegExp)) {
re = new RegExp(re, 'g');
}
text = text.replace(re, ext.replace);
}
return text;
});
/**
* These are all the transformations that occur *within* block-level
* tags like paragraphs, headers, and list items.
*/
showdown.subParser('spanGamut', function (text, options, globals) {
text = globals.converter._dispatch('spanGamut.before', text, options, globals);
text = showdown.subParser('codeSpans')(text, options, globals);
text = showdown.subParser('escapeSpecialCharsWithinTagAttributes')(text, options, globals);
text = showdown.subParser('encodeBackslashEscapes')(text, options, globals);
// Process anchor and image tags. Images must come first,
// because ![foo][f] looks like an anchor.
text = showdown.subParser('images')(text, options, globals);
text = showdown.subParser('anchors')(text, options, globals);
// Make links out of things like `<http://example.com/>`
// Must come after anchors, because you can use < and >
// delimiters in inline links like [this](<url>).
text = showdown.subParser('autoLinks')(text, options, globals);
text = showdown.subParser('simplifiedAutoLinks')(text, options, globals);
text = showdown.subParser('emoji')(text, options, globals);
text = showdown.subParser('underline')(text, options, globals);
text = showdown.subParser('italicsAndBold')(text, options, globals);
text = showdown.subParser('strikethrough')(text, options, globals);
text = showdown.subParser('ellipsis')(text, options, globals);
// we need to hash HTML tags inside spans
text = showdown.subParser('hashHTMLSpans')(text, options, globals);
// now we encode amps and angles
text = showdown.subParser('encodeAmpsAndAngles')(text, options, globals);
// Do hard breaks
if (options.simpleLineBreaks) {
// GFM style hard breaks
// only add line breaks if the text does not contain a block (special case for lists)
if (!/\n\n¨K/.test(text)) {
text = text.replace(/\n+/g, '<br />\n');
}
} else {
// Vanilla hard breaks
text = text.replace(/ +\n/g, '<br />\n');
}
text = globals.converter._dispatch('spanGamut.after', text, options, globals);
return text;
});
showdown.subParser('strikethrough', function (text, options, globals) {
function parseInside (txt) {
if (options.simplifiedAutoLink) {
txt = showdown.subParser('simplifiedAutoLinks')(txt, options, globals);
}
return '<del>' + txt + '</del>';
}
if (options.strikethrough) {
text = globals.converter._dispatch('strikethrough.before', text, options, globals);
text = text.replace(/(?:~){2}([\s\S]+?)(?:~){2}/g, function (wm, txt) { return parseInside(txt); });
text = globals.converter._dispatch('strikethrough.after', text, options, globals);
}
return text;
});
/**
* Strips link definitions from text, stores the URLs and titles in
* hash references.
* Link defs are in the form: ^[id]: url "optional title"
*/
showdown.subParser('stripLinkDefinitions', function (text, options, globals) {
var regex = /^ {0,3}\[([^\]]+)]:[ \t]*\n?[ \t]*<?([^>\s]+)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*\n?[ \t]*(?:(\n*)["|'(](.+?)["|')][ \t]*)?(?:\n+|(?=¨0))/gm,
base64Regex = /^ {0,3}\[([^\]]+)]:[ \t]*\n?[ \t]*<?(data:.+?\/.+?;base64,[A-Za-z0-9+/=\n]+?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*\n?[ \t]*(?:(\n*)["|'(](.+?)["|')][ \t]*)?(?:\n\n|(?=¨0)|(?=\n\[))/gm;
// attacklab: sentinel workarounds for lack of \A and \Z, safari\khtml bug
text += '¨0';
var replaceFunc = function (wholeMatch, linkId, url, width, height, blankLines, title) {
// if there aren't two instances of linkId it must not be a reference link so back out
linkId = linkId.toLowerCase();
if (text.toLowerCase().split(linkId).length - 1 < 2) {
return wholeMatch;
}
if (url.match(/^data:.+?\/.+?;base64,/)) {
// remove newlines
globals.gUrls[linkId] = url.replace(/\s/g, '');
} else {
globals.gUrls[linkId] = showdown.subParser('encodeAmpsAndAngles')(url, options, globals); // Link IDs are case-insensitive
}
if (blankLines) {
// Oops, found blank lines, so it's not a title.
// Put back the parenthetical statement we stole.
return blankLines + title;
} else {
if (title) {
globals.gTitles[linkId] = title.replace(/"|'/g, '&quot;');
}
if (options.parseImgDimensions && width && height) {
globals.gDimensions[linkId] = {
width: width,
height: height
};
}
}
// Completely remove the definition from the text
return '';
};
// first we try to find base64 link references
text = text.replace(base64Regex, replaceFunc);
text = text.replace(regex, replaceFunc);
// attacklab: strip sentinel
text = text.replace(/¨0/, '');
return text;
});
showdown.subParser('tables', function (text, options, globals) {
if (!options.tables) {
return text;
}
var tableRgx = /^ {0,3}\|?.+\|.+\n {0,3}\|?[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*:?[ \t]*(?:[-=]){2,}[\s\S]+?(?:\n\n|¨0)/gm,
//singeColTblRgx = /^ {0,3}\|.+\|\n {0,3}\|[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*\n(?: {0,3}\|.+\|\n)+(?:\n\n|¨0)/gm;
singeColTblRgx = /^ {0,3}\|.+\|[ \t]*\n {0,3}\|[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*\n( {0,3}\|.+\|[ \t]*\n)*(?:\n|¨0)/gm;
function parseStyles (sLine) {
if (/^:[ \t]*--*$/.test(sLine)) {
return ' style="text-align:left;"';
} else if (/^--*[ \t]*:[ \t]*$/.test(sLine)) {
return ' style="text-align:right;"';
} else if (/^:[ \t]*--*[ \t]*:$/.test(sLine)) {
return ' style="text-align:center;"';
} else {
return '';
}
}
function parseHeaders (header, style) {
var id = '';
header = header.trim();
// support both tablesHeaderId and tableHeaderId due to error in documentation so we don't break backwards compatibility
if (options.tablesHeaderId || options.tableHeaderId) {
id = ' id="' + header.replace(/ /g, '_').toLowerCase() + '"';
}
header = showdown.subParser('spanGamut')(header, options, globals);
return '<th' + id + style + '>' + header + '</th>\n';
}
function parseCells (cell, style) {
var subText = showdown.subParser('spanGamut')(cell, options, globals);
return '<td' + style + '>' + subText + '</td>\n';
}
function buildTable (headers, cells) {
var tb = '<table>\n<thead>\n<tr>\n',
tblLgn = headers.length;
for (var i = 0; i < tblLgn; ++i) {
tb += headers[i];
}
tb += '</tr>\n</thead>\n<tbody>\n';
for (i = 0; i < cells.length; ++i) {
tb += '<tr>\n';
for (var ii = 0; ii < tblLgn; ++ii) {
tb += cells[i][ii];
}
tb += '</tr>\n';
}
tb += '</tbody>\n</table>\n';
return tb;
}
function parseTable (rawTable) {
var i, tableLines = rawTable.split('\n');
for (i = 0; i < tableLines.length; ++i) {
// strip wrong first and last column if wrapped tables are used
if (/^ {0,3}\|/.test(tableLines[i])) {
tableLines[i] = tableLines[i].replace(/^ {0,3}\|/, '');
}
if (/\|[ \t]*$/.test(tableLines[i])) {
tableLines[i] = tableLines[i].replace(/\|[ \t]*$/, '');
}
// parse code spans first, but we only support one line code spans
tableLines[i] = showdown.subParser('codeSpans')(tableLines[i], options, globals);
}
var rawHeaders = tableLines[0].split('|').map(function (s) { return s.trim();}),
rawStyles = tableLines[1].split('|').map(function (s) { return s.trim();}),
rawCells = [],
headers = [],
styles = [],
cells = [];
tableLines.shift();
tableLines.shift();
for (i = 0; i < tableLines.length; ++i) {
if (tableLines[i].trim() === '') {
continue;
}
rawCells.push(
tableLines[i]
.split('|')
.map(function (s) {
return s.trim();
})
);
}
if (rawHeaders.length < rawStyles.length) {
return rawTable;
}
for (i = 0; i < rawStyles.length; ++i) {
styles.push(parseStyles(rawStyles[i]));
}
for (i = 0; i < rawHeaders.length; ++i) {
if (showdown.helper.isUndefined(styles[i])) {
styles[i] = '';
}
headers.push(parseHeaders(rawHeaders[i], styles[i]));
}
for (i = 0; i < rawCells.length; ++i) {
var row = [];
for (var ii = 0; ii < headers.length; ++ii) {
if (showdown.helper.isUndefined(rawCells[i][ii])) ;
row.push(parseCells(rawCells[i][ii], styles[ii]));
}
cells.push(row);
}
return buildTable(headers, cells);
}
text = globals.converter._dispatch('tables.before', text, options, globals);
// find escaped pipe characters
text = text.replace(/\\(\|)/g, showdown.helper.escapeCharactersCallback);
// parse multi column tables
text = text.replace(tableRgx, parseTable);
// parse one column tables
text = text.replace(singeColTblRgx, parseTable);
text = globals.converter._dispatch('tables.after', text, options, globals);
return text;
});
showdown.subParser('underline', function (text, options, globals) {
if (!options.underline) {
return text;
}
text = globals.converter._dispatch('underline.before', text, options, globals);
if (options.literalMidWordUnderscores) {
text = text.replace(/\b___(\S[\s\S]*?)___\b/g, function (wm, txt) {
return '<u>' + txt + '</u>';
});
text = text.replace(/\b__(\S[\s\S]*?)__\b/g, function (wm, txt) {
return '<u>' + txt + '</u>';
});
} else {
text = text.replace(/___(\S[\s\S]*?)___/g, function (wm, m) {
return (/\S$/.test(m)) ? '<u>' + m + '</u>' : wm;
});
text = text.replace(/__(\S[\s\S]*?)__/g, function (wm, m) {
return (/\S$/.test(m)) ? '<u>' + m + '</u>' : wm;
});
}
// escape remaining underscores to prevent them being parsed by italic and bold
text = text.replace(/(_)/g, showdown.helper.escapeCharactersCallback);
text = globals.converter._dispatch('underline.after', text, options, globals);
return text;
});
/**
* Swap back in all the special characters we've hidden.
*/
showdown.subParser('unescapeSpecialChars', function (text, options, globals) {
text = globals.converter._dispatch('unescapeSpecialChars.before', text, options, globals);
text = text.replace(/¨E(\d+)E/g, function (wholeMatch, m1) {
var charCodeToReplace = parseInt(m1);
return String.fromCharCode(charCodeToReplace);
});
text = globals.converter._dispatch('unescapeSpecialChars.after', text, options, globals);
return text;
});
showdown.subParser('makeMarkdown.blockquote', function (node, globals) {
var txt = '';
if (node.hasChildNodes()) {
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
var innerTxt = showdown.subParser('makeMarkdown.node')(children[i], globals);
if (innerTxt === '') {
continue;
}
txt += innerTxt;
}
}
// cleanup
txt = txt.trim();
txt = '> ' + txt.split('\n').join('\n> ');
return txt;
});
showdown.subParser('makeMarkdown.codeBlock', function (node, globals) {
var lang = node.getAttribute('language'),
num = node.getAttribute('precodenum');
return '```' + lang + '\n' + globals.preList[num] + '\n```';
});
showdown.subParser('makeMarkdown.codeSpan', function (node) {
return '`' + node.innerHTML + '`';
});
showdown.subParser('makeMarkdown.emphasis', function (node, globals) {
var txt = '';
if (node.hasChildNodes()) {
txt += '*';
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
txt += '*';
}
return txt;
});
showdown.subParser('makeMarkdown.header', function (node, globals, headerLevel) {
var headerMark = new Array(headerLevel + 1).join('#'),
txt = '';
if (node.hasChildNodes()) {
txt = headerMark + ' ';
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
}
return txt;
});
showdown.subParser('makeMarkdown.hr', function () {
return '---';
});
showdown.subParser('makeMarkdown.image', function (node) {
var txt = '';
if (node.hasAttribute('src')) {
txt += '![' + node.getAttribute('alt') + '](';
txt += '<' + node.getAttribute('src') + '>';
if (node.hasAttribute('width') && node.hasAttribute('height')) {
txt += ' =' + node.getAttribute('width') + 'x' + node.getAttribute('height');
}
if (node.hasAttribute('title')) {
txt += ' "' + node.getAttribute('title') + '"';
}
txt += ')';
}
return txt;
});
showdown.subParser('makeMarkdown.links', function (node, globals) {
var txt = '';
if (node.hasChildNodes() && node.hasAttribute('href')) {
var children = node.childNodes,
childrenLength = children.length;
txt = '[';
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
txt += '](';
txt += '<' + node.getAttribute('href') + '>';
if (node.hasAttribute('title')) {
txt += ' "' + node.getAttribute('title') + '"';
}
txt += ')';
}
return txt;
});
showdown.subParser('makeMarkdown.list', function (node, globals, type) {
var txt = '';
if (!node.hasChildNodes()) {
return '';
}
var listItems = node.childNodes,
listItemsLenght = listItems.length,
listNum = node.getAttribute('start') || 1;
for (var i = 0; i < listItemsLenght; ++i) {
if (typeof listItems[i].tagName === 'undefined' || listItems[i].tagName.toLowerCase() !== 'li') {
continue;
}
// define the bullet to use in list
var bullet = '';
if (type === 'ol') {
bullet = listNum.toString() + '. ';
} else {
bullet = '- ';
}
// parse list item
txt += bullet + showdown.subParser('makeMarkdown.listItem')(listItems[i], globals);
++listNum;
}
// add comment at the end to prevent consecutive lists to be parsed as one
txt += '\n<!-- -->\n';
return txt.trim();
});
showdown.subParser('makeMarkdown.listItem', function (node, globals) {
var listItemTxt = '';
var children = node.childNodes,
childrenLenght = children.length;
for (var i = 0; i < childrenLenght; ++i) {
listItemTxt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
// if it's only one liner, we need to add a newline at the end
if (!/\n$/.test(listItemTxt)) {
listItemTxt += '\n';
} else {
// it's multiparagraph, so we need to indent
listItemTxt = listItemTxt
.split('\n')
.join('\n ')
.replace(/^ {4}$/gm, '')
.replace(/\n\n+/g, '\n\n');
}
return listItemTxt;
});
showdown.subParser('makeMarkdown.node', function (node, globals, spansOnly) {
spansOnly = spansOnly || false;
var txt = '';
// edge case of text without wrapper paragraph
if (node.nodeType === 3) {
return showdown.subParser('makeMarkdown.txt')(node, globals);
}
// HTML comment
if (node.nodeType === 8) {
return '<!--' + node.data + '-->\n\n';
}
// process only node elements
if (node.nodeType !== 1) {
return '';
}
var tagName = node.tagName.toLowerCase();
switch (tagName) {
//
// BLOCKS
//
case 'h1':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 1) + '\n\n'; }
break;
case 'h2':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 2) + '\n\n'; }
break;
case 'h3':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 3) + '\n\n'; }
break;
case 'h4':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 4) + '\n\n'; }
break;
case 'h5':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 5) + '\n\n'; }
break;
case 'h6':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 6) + '\n\n'; }
break;
case 'p':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.paragraph')(node, globals) + '\n\n'; }
break;
case 'blockquote':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.blockquote')(node, globals) + '\n\n'; }
break;
case 'hr':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.hr')(node, globals) + '\n\n'; }
break;
case 'ol':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.list')(node, globals, 'ol') + '\n\n'; }
break;
case 'ul':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.list')(node, globals, 'ul') + '\n\n'; }
break;
case 'precode':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.codeBlock')(node, globals) + '\n\n'; }
break;
case 'pre':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.pre')(node, globals) + '\n\n'; }
break;
case 'table':
if (!spansOnly) { txt = showdown.subParser('makeMarkdown.table')(node, globals) + '\n\n'; }
break;
//
// SPANS
//
case 'code':
txt = showdown.subParser('makeMarkdown.codeSpan')(node, globals);
break;
case 'em':
case 'i':
txt = showdown.subParser('makeMarkdown.emphasis')(node, globals);
break;
case 'strong':
case 'b':
txt = showdown.subParser('makeMarkdown.strong')(node, globals);
break;
case 'del':
txt = showdown.subParser('makeMarkdown.strikethrough')(node, globals);
break;
case 'a':
txt = showdown.subParser('makeMarkdown.links')(node, globals);
break;
case 'img':
txt = showdown.subParser('makeMarkdown.image')(node, globals);
break;
default:
txt = node.outerHTML + '\n\n';
}
// common normalization
// TODO eventually
return txt;
});
showdown.subParser('makeMarkdown.paragraph', function (node, globals) {
var txt = '';
if (node.hasChildNodes()) {
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
}
// some text normalization
txt = txt.trim();
return txt;
});
showdown.subParser('makeMarkdown.pre', function (node, globals) {
var num = node.getAttribute('prenum');
return '<pre>' + globals.preList[num] + '</pre>';
});
showdown.subParser('makeMarkdown.strikethrough', function (node, globals) {
var txt = '';
if (node.hasChildNodes()) {
txt += '~~';
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
txt += '~~';
}
return txt;
});
showdown.subParser('makeMarkdown.strong', function (node, globals) {
var txt = '';
if (node.hasChildNodes()) {
txt += '**';
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
}
txt += '**';
}
return txt;
});
showdown.subParser('makeMarkdown.table', function (node, globals) {
var txt = '',
tableArray = [[], []],
headings = node.querySelectorAll('thead>tr>th'),
rows = node.querySelectorAll('tbody>tr'),
i, ii;
for (i = 0; i < headings.length; ++i) {
var headContent = showdown.subParser('makeMarkdown.tableCell')(headings[i], globals),
allign = '---';
if (headings[i].hasAttribute('style')) {
var style = headings[i].getAttribute('style').toLowerCase().replace(/\s/g, '');
switch (style) {
case 'text-align:left;':
allign = ':---';
break;
case 'text-align:right;':
allign = '---:';
break;
case 'text-align:center;':
allign = ':---:';
break;
}
}
tableArray[0][i] = headContent.trim();
tableArray[1][i] = allign;
}
for (i = 0; i < rows.length; ++i) {
var r = tableArray.push([]) - 1,
cols = rows[i].getElementsByTagName('td');
for (ii = 0; ii < headings.length; ++ii) {
var cellContent = ' ';
if (typeof cols[ii] !== 'undefined') {
cellContent = showdown.subParser('makeMarkdown.tableCell')(cols[ii], globals);
}
tableArray[r].push(cellContent);
}
}
var cellSpacesCount = 3;
for (i = 0; i < tableArray.length; ++i) {
for (ii = 0; ii < tableArray[i].length; ++ii) {
var strLen = tableArray[i][ii].length;
if (strLen > cellSpacesCount) {
cellSpacesCount = strLen;
}
}
}
for (i = 0; i < tableArray.length; ++i) {
for (ii = 0; ii < tableArray[i].length; ++ii) {
if (i === 1) {
if (tableArray[i][ii].slice(-1) === ':') {
tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii].slice(-1), cellSpacesCount - 1, '-') + ':';
} else {
tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii], cellSpacesCount, '-');
}
} else {
tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii], cellSpacesCount);
}
}
txt += '| ' + tableArray[i].join(' | ') + ' |\n';
}
return txt.trim();
});
showdown.subParser('makeMarkdown.tableCell', function (node, globals) {
var txt = '';
if (!node.hasChildNodes()) {
return '';
}
var children = node.childNodes,
childrenLength = children.length;
for (var i = 0; i < childrenLength; ++i) {
txt += showdown.subParser('makeMarkdown.node')(children[i], globals, true);
}
return txt.trim();
});
showdown.subParser('makeMarkdown.txt', function (node) {
var txt = node.nodeValue;
// multiple spaces are collapsed
txt = txt.replace(/ +/g, ' ');
// replace the custom ¨NBSP; with a space
txt = txt.replace(/¨NBSP;/g, ' ');
// ", <, > and & should replace escaped html entities
txt = showdown.helper.unescapeHTMLEntities(txt);
// escape markdown magic characters
// emphasis, strong and strikethrough - can appear everywhere
// we also escape pipe (|) because of tables
// and escape ` because of code blocks and spans
txt = txt.replace(/([*_~|`])/g, '\\$1');
// escape > because of blockquotes
txt = txt.replace(/^(\s*)>/g, '\\$1>');
// hash character, only troublesome at the beginning of a line because of headers
txt = txt.replace(/^#/gm, '\\#');
// horizontal rules
txt = txt.replace(/^(\s*)([-=]{3,})(\s*)$/, '$1\\$2$3');
// dot, because of ordered lists, only troublesome at the beginning of a line when preceded by an integer
txt = txt.replace(/^( {0,3}\d+)\./gm, '$1\\.');
// +, * and -, at the beginning of a line becomes a list, so we need to escape them also (asterisk was already escaped)
txt = txt.replace(/^( {0,3})([+-])/gm, '$1\\$2');
// images and links, ] followed by ( is problematic, so we escape it
txt = txt.replace(/]([\s]*)\(/g, '\\]$1\\(');
// reference URIs must also be escaped
txt = txt.replace(/^ {0,3}\[([\S \t]*?)]:/gm, '\\[$1]:');
return txt;
});
var root = this;
// AMD Loader
if (module.exports) {
module.exports = showdown;
// Regular Browser loader
} else {
root.showdown = showdown;
}
}).call(commonjsGlobal);
});
/**
* RegexEscape
* Escapes a string for using it in a regular expression.
*
* @name RegexEscape
* @function
* @param {String} input The string that must be escaped.
* @return {String} The escaped string.
*/
function RegexEscape(input) {
return input.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
}
/**
* proto
* Adds the `RegexEscape` function to `RegExp` class.
*
* @name proto
* @function
* @return {Function} The `RegexEscape` function.
*/
RegexEscape.proto = function () {
RegExp.escape = RegexEscape;
return RegexEscape;
};
var he = createCommonjsModule(function (module, exports) {
(function(root) {
// Detect free variables `exports`.
var freeExports = exports;
// Detect free variable `module`.
var freeModule = module &&
module.exports == freeExports && module;
// Detect free variable `global`, from Node.js or Browserified code,
// and use it as `root`.
var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal;
if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) {
root = freeGlobal;
}
/*--------------------------------------------------------------------------*/
// All astral symbols.
var regexAstralSymbols = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g;
// All ASCII symbols (not just printable ASCII) except those listed in the
// first column of the overrides table.
// https://html.spec.whatwg.org/multipage/syntax.html#table-charref-overrides
var regexAsciiWhitelist = /[\x01-\x7F]/g;
// All BMP symbols that are not ASCII newlines, printable ASCII symbols, or
// code points listed in the first column of the overrides table on
// https://html.spec.whatwg.org/multipage/syntax.html#table-charref-overrides.
var regexBmpWhitelist = /[\x01-\t\x0B\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g;
var regexEncodeNonAscii = /<\u20D2|=\u20E5|>\u20D2|\u205F\u200A|\u219D\u0338|\u2202\u0338|\u2220\u20D2|\u2229\uFE00|\u222A\uFE00|\u223C\u20D2|\u223D\u0331|\u223E\u0333|\u2242\u0338|\u224B\u0338|\u224D\u20D2|\u224E\u0338|\u224F\u0338|\u2250\u0338|\u2261\u20E5|\u2264\u20D2|\u2265\u20D2|\u2266\u0338|\u2267\u0338|\u2268\uFE00|\u2269\uFE00|\u226A\u0338|\u226A\u20D2|\u226B\u0338|\u226B\u20D2|\u227F\u0338|\u2282\u20D2|\u2283\u20D2|\u228A\uFE00|\u228B\uFE00|\u228F\u0338|\u2290\u0338|\u2293\uFE00|\u2294\uFE00|\u22B4\u20D2|\u22B5\u20D2|\u22D8\u0338|\u22D9\u0338|\u22DA\uFE00|\u22DB\uFE00|\u22F5\u0338|\u22F9\u0338|\u2933\u0338|\u29CF\u0338|\u29D0\u0338|\u2A6D\u0338|\u2A70\u0338|\u2A7D\u0338|\u2A7E\u0338|\u2AA1\u0338|\u2AA2\u0338|\u2AAC\uFE00|\u2AAD\uFE00|\u2AAF\u0338|\u2AB0\u0338|\u2AC5\u0338|\u2AC6\u0338|\u2ACB\uFE00|\u2ACC\uFE00|\u2AFD\u20E5|[\xA0-\u0113\u0116-\u0122\u0124-\u012B\u012E-\u014D\u0150-\u017E\u0192\u01B5\u01F5\u0237\u02C6\u02C7\u02D8-\u02DD\u0311\u0391-\u03A1\u03A3-\u03A9\u03B1-\u03C9\u03D1\u03D2\u03D5\u03D6\u03DC\u03DD\u03F0\u03F1\u03F5\u03F6\u0401-\u040C\u040E-\u044F\u0451-\u045C\u045E\u045F\u2002-\u2005\u2007-\u2010\u2013-\u2016\u2018-\u201A\u201C-\u201E\u2020-\u2022\u2025\u2026\u2030-\u2035\u2039\u203A\u203E\u2041\u2043\u2044\u204F\u2057\u205F-\u2063\u20AC\u20DB\u20DC\u2102\u2105\u210A-\u2113\u2115-\u211E\u2122\u2124\u2127-\u2129\u212C\u212D\u212F-\u2131\u2133-\u2138\u2145-\u2148\u2153-\u215E\u2190-\u219B\u219D-\u21A7\u21A9-\u21AE\u21B0-\u21B3\u21B5-\u21B7\u21BA-\u21DB\u21DD\u21E4\u21E5\u21F5\u21FD-\u2205\u2207-\u2209\u220B\u220C\u220F-\u2214\u2216-\u2218\u221A\u221D-\u2238\u223A-\u2257\u2259\u225A\u225C\u225F-\u2262\u2264-\u228B\u228D-\u229B\u229D-\u22A5\u22A7-\u22B0\u22B2-\u22BB\u22BD-\u22DB\u22DE-\u22E3\u22E6-\u22F7\u22F9-\u22FE\u2305\u2306\u2308-\u2310\u2312\u2313\u2315\u2316\u231C-\u231F\u2322\u2323\u232D\u232E\u2336\u233D\u233F\u237C\u23B0\u23B1\u23B4-\u23B6\u23DC-\u23DF\u23E2\u23E7\u2423\u24C8\u2500\u2502\u250C\u2510\u2514\u2518\u251C\u2524\u252C\u2534\u253C\u2550-\u256C\u2580\u2584\u2588\u2591-\u2593\u25A1\u25AA\u25AB\u25AD\u25AE\u25B1\u25B3-\u25B5\u25B8\u25B9\u25BD-\u25BF\u25C2\u25C3\u25CA\u25CB\u25EC\u25EF\u25F8-\u25FC\u2605\u2606\u260E\u2640\u2642\u2660\u2663\u2665\u2666\u266A\u266D-\u266F\u2713\u2717\u2720\u2736\u2758\u2772\u2773\u27C8\u27C9\u27E6-\u27ED\u27F5-\u27FA\u27FC\u27FF\u2902-\u2905\u290C-\u2913\u2916\u2919-\u2920\u2923-\u292A\u2933\u2935-\u2939\u293C\u293D\u2945\u2948-\u294B\u294E-\u2976\u2978\u2979\u297B-\u297F\u2985\u2986\u298B-\u2996\u299A\u299C\u299D\u29A4-\u29B7\u29B9\u29BB\u29BC\u29BE-\u29C5\u29C9\u29CD-\u29D0\u29DC-\u29DE\u29E3-\u29E5\u29EB\u29F4\u29F6\u2A00-\u2A02\u2A04\u2A06\u2A0C\u2A0D\u2A10-\u2A17\u2A22-\u2A27\u2A29\u2A2A\u2A2D-\u2A31\u2A33-\u2A3C\u2A3F\u2A40\u2A42-\u2A4D\u2A50\u2A53-\u2A58\u2A5A-\u2A5D\u2A5F\u2A66\u2A6A\u2A6D-\u2A75\u2A77-\u2A9A\u2A9D-\u2AA2\u2AA4-\u2AB0\u2AB3-\u2AC8\u2ACB\u2ACC\u2ACF-\u2ADB\u2AE4\u2AE6-\u2AE9\u2AEB-\u2AF3\u2AFD\uFB00-\uFB04]|\uD835[\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDCCF\uDD04\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDD6B]/g;
var encodeMap = {'\xAD':'shy','\u200C':'zwnj','\u200D':'zwj','\u200E':'lrm','\u2063':'ic','\u2062':'it','\u2061':'af','\u200F':'rlm','\u200B':'ZeroWidthSpace','\u2060':'NoBreak','\u0311':'DownBreve','\u20DB':'tdot','\u20DC':'DotDot','\t':'Tab','\n':'NewLine','\u2008':'puncsp','\u205F':'MediumSpace','\u2009':'thinsp','\u200A':'hairsp','\u2004':'emsp13','\u2002':'ensp','\u2005':'emsp14','\u2003':'emsp','\u2007':'numsp','\xA0':'nbsp','\u205F\u200A':'ThickSpace','\u203E':'oline','_':'lowbar','\u2010':'dash','\u2013':'ndash','\u2014':'mdash','\u2015':'horbar',',':'comma',';':'semi','\u204F':'bsemi',':':'colon','\u2A74':'Colone','!':'excl','\xA1':'iexcl','?':'quest','\xBF':'iquest','.':'period','\u2025':'nldr','\u2026':'mldr','\xB7':'middot','\'':'apos','\u2018':'lsquo','\u2019':'rsquo','\u201A':'sbquo','\u2039':'lsaquo','\u203A':'rsaquo','"':'quot','\u201C':'ldquo','\u201D':'rdquo','\u201E':'bdquo','\xAB':'laquo','\xBB':'raquo','(':'lpar',')':'rpar','[':'lsqb',']':'rsqb','{':'lcub','}':'rcub','\u2308':'lceil','\u2309':'rceil','\u230A':'lfloor','\u230B':'rfloor','\u2985':'lopar','\u2986':'ropar','\u298B':'lbrke','\u298C':'rbrke','\u298D':'lbrkslu','\u298E':'rbrksld','\u298F':'lbrksld','\u2990':'rbrkslu','\u2991':'langd','\u2992':'rangd','\u2993':'lparlt','\u2994':'rpargt','\u2995':'gtlPar','\u2996':'ltrPar','\u27E6':'lobrk','\u27E7':'robrk','\u27E8':'lang','\u27E9':'rang','\u27EA':'Lang','\u27EB':'Rang','\u27EC':'loang','\u27ED':'roang','\u2772':'lbbrk','\u2773':'rbbrk','\u2016':'Vert','\xA7':'sect','\xB6':'para','@':'commat','*':'ast','/':'sol','undefined':null,'&':'amp','#':'num','%':'percnt','\u2030':'permil','\u2031':'pertenk','\u2020':'dagger','\u2021':'Dagger','\u2022':'bull','\u2043':'hybull','\u2032':'prime','\u2033':'Prime','\u2034':'tprime','\u2057':'qprime','\u2035':'bprime','\u2041':'caret','`':'grave','\xB4':'acute','\u02DC':'tilde','^':'Hat','\xAF':'macr','\u02D8':'breve','\u02D9':'dot','\xA8':'die','\u02DA':'ring','\u02DD':'dblac','\xB8':'cedil','\u02DB':'ogon','\u02C6':'circ','\u02C7':'caron','\xB0':'deg','\xA9':'copy','\xAE':'reg','\u2117':'copysr','\u2118':'wp','\u211E':'rx','\u2127':'mho','\u2129':'iiota','\u2190':'larr','\u219A':'nlarr','\u2192':'rarr','\u219B':'nrarr','\u2191':'uarr','\u2193':'darr','\u2194':'harr','\u21AE':'nharr','\u2195':'varr','\u2196':'nwarr','\u2197':'nearr','\u2198':'searr','\u2199':'swarr','\u219D':'rarrw','\u219D\u0338':'nrarrw','\u219E':'Larr','\u219F':'Uarr','\u21A0':'Rarr','\u21A1':'Darr','\u21A2':'larrtl','\u21A3':'rarrtl','\u21A4':'mapstoleft','\u21A5':'mapstoup','\u21A6':'map','\u21A7':'mapstodown','\u21A9':'larrhk','\u21AA':'rarrhk','\u21AB':'larrlp','\u21AC':'rarrlp','\u21AD':'harrw','\u21B0':'lsh','\u21B1':'rsh','\u21B2':'ldsh','\u21B3':'rdsh','\u21B5':'crarr','\u21B6':'cularr','\u21B7':'curarr','\u21BA':'olarr','\u21BB':'orarr','\u21BC':'lharu','\u21BD':'lhard','\u21BE':'uharr','\u21BF':'uharl','\u21C0':'rharu','\u21C1':'rhard','\u21C2':'dharr','\u21C3':'dharl','\u21C4':'rlarr','\u21C5':'udarr','\u21C6':'lrarr','\u21C7':'llarr','\u21C8':'uuarr','\u21C9':'rrarr','\u21CA':'ddarr','\u21CB':'lrhar','\u21CC':'rlhar','\u21D0':'lArr','\u21CD':'nlArr','\u21D1':'uArr','\u21D2':'rArr','\u21CF':'nrArr','\u21D3':'dArr','\u21D4':'iff','\u21CE':'nhArr','\u21D5':'vArr','\u21D6':'nwArr','\u21D7':'neArr','\u21D8':'seArr','\u21D9':'swArr','\u21DA':'lAarr','\u21DB':'rAarr','\u21DD':'zigrarr','\u21E4':'larrb','\u21E5':'rarrb','\u21F5':'duarr','\u21FD':'loarr','\u21FE':'roarr','\u21FF':'hoarr','\u2200':'forall','\u2201':'comp','\u2202':'part','\u2202\u0338':'npart','\u2203':'exist','\u2204':'nexist','\u2205':'empty','\u2207':'Del','\u2208':'in','\u2209':'notin','\u220B':'ni','\u220C':'notni','\u03F6':'bepsi','\u220F':'prod','\u2210':'coprod','\u2211':'sum','+':'plus','\xB1':'pm','\xF7':'div','\xD7':'times','<':'lt','\u226E':'nlt','<\u20D2':'nvlt','=':'equals','\u2260':'ne','=\u20E5':'bne','\u2A75':'Equal','>':'gt','\u226F':'ngt','>\u20D2':'nvgt','\xAC':'not','|':'vert','\xA6':'brvbar','\u2212':'minus','\u2213':'mp','\u2214':'plusdo','\u2044':'frasl','\u2216':'setmn','\u2217':'lowast','\u2218':'compfn','\u221A':'Sqrt','\u221D':'prop','\u221E':'infin','\u221F':'angrt','\u2220':'ang','\u2220\u20D2':'nang','\u2221':'angmsd','\u2222':'angsph','\u2223':'mid','\u2224':'nmid','\u2225':'par','\u2226':'npar','\u2227':'and','\u2228':'or','\u2229':'cap','\u2229\uFE00':'caps','\u222A':'cup','\u222A\uFE00':'cups','\u222B':'int','\u222C':'Int','\u222D':'tint','\u2A0C':'qint','\u222E':'oint','\u222F':'Conint','\u2230':'Cconint','\u2231':'cwint','\u2232':'cwconint','\u2233':'awconint','\u2234':'there4','\u2235':'becaus','\u2236':'ratio','\u2237':'Colon','\u2238':'minusd','\u223A':'mDDot','\u223B':'homtht','\u223C':'sim','\u2241':'nsim','\u223C\u20D2':'nvsim','\u223D':'bsim','\u223D\u0331':'race','\u223E':'ac','\u223E\u0333':'acE','\u223F':'acd','\u2240':'wr','\u2242':'esim','\u2242\u0338':'nesim','\u2243':'sime','\u2244':'nsime','\u2245':'cong','\u2247':'ncong','\u2246':'simne','\u2248':'ap','\u2249':'nap','\u224A':'ape','\u224B':'apid','\u224B\u0338':'napid','\u224C':'bcong','\u224D':'CupCap','\u226D':'NotCupCap','\u224D\u20D2':'nvap','\u224E':'bump','\u224E\u0338':'nbump','\u224F':'bumpe','\u224F\u0338':'nbumpe','\u2250':'doteq','\u2250\u0338':'nedot','\u2251':'eDot','\u2252':'efDot','\u2253':'erDot','\u2254':'colone','\u2255':'ecolon','\u2256':'ecir','\u2257':'cire','\u2259':'wedgeq','\u225A':'veeeq','\u225C':'trie','\u225F':'equest','\u2261':'equiv','\u2262':'nequiv','\u2261\u20E5':'bnequiv','\u2264':'le','\u2270':'nle','\u2264\u20D2':'nvle','\u2265':'ge','\u2271':'nge','\u2265\u20D2':'nvge','\u2266':'lE','\u2266\u0338':'nlE','\u2267':'gE','\u2267\u0338':'ngE','\u2268\uFE00':'lvnE','\u2268':'lnE','\u2269':'gnE','\u2269\uFE00':'gvnE','\u226A':'ll','\u226A\u0338':'nLtv','\u226A\u20D2':'nLt','\u226B':'gg','\u226B\u0338':'nGtv','\u226B\u20D2':'nGt','\u226C':'twixt','\u2272':'lsim','\u2274':'nlsim','\u2273':'gsim','\u2275':'ngsim','\u2276':'lg','\u2278':'ntlg','\u2277':'gl','\u2279':'ntgl','\u227A':'pr','\u2280':'npr','\u227B':'sc','\u2281':'nsc','\u227C':'prcue','\u22E0':'nprcue','\u227D':'sccue','\u22E1':'nsccue','\u227E':'prsim','\u227F':'scsim','\u227F\u0338':'NotSucceedsTilde','\u2282':'sub','\u2284':'nsub','\u2282\u20D2':'vnsub','\u2283':'sup','\u2285':'nsup','\u2283\u20D2':'vnsup','\u2286':'sube','\u2288':'nsube','\u2287':'supe','\u2289':'nsupe','\u228A\uFE00':'vsubne','\u228A':'subne','\u228B\uFE00':'vsupne','\u228B':'supne','\u228D':'cupdot','\u228E':'uplus','\u228F':'sqsub','\u228F\u0338':'NotSquareSubset','\u2290':'sqsup','\u2290\u0338':'NotSquareSuperset','\u2291':'sqsube','\u22E2':'nsqsube','\u2292':'sqsupe','\u22E3':'nsqsupe','\u2293':'sqcap','\u2293\uFE00':'sqcaps','\u2294':'sqcup','\u2294\uFE00':'sqcups','\u2295':'oplus','\u2296':'ominus','\u2297':'otimes','\u2298':'osol','\u2299':'odot','\u229A':'ocir','\u229B':'oast','\u229D':'odash','\u229E':'plusb','\u229F':'minusb','\u22A0':'timesb','\u22A1':'sdotb','\u22A2':'vdash','\u22AC':'nvdash','\u22A3':'dashv','\u22A4':'top','\u22A5':'bot','\u22A7':'models','\u22A8':'vDash','\u22AD':'nvDash','\u22A9':'Vdash','\u22AE':'nVdash','\u22AA':'Vvdash','\u22AB':'VDash','\u22AF':'nVDash','\u22B0':'prurel','\u22B2':'vltri','\u22EA':'nltri','\u22B3':'vrtri','\u22EB':'nrtri','\u22B4':'ltrie','\u22EC':'nltrie','\u22B4\u20D2':'nvltrie','\u22B5':'rtrie','\u22ED':'nrtrie','\u22B5\u20D2':'nvrtrie','\u22B6':'origof','\u22B7':'imof','\u22B8':'mumap','\u22B9':'hercon','\u22BA':'intcal','\u22BB':'veebar','\u22BD':'barvee','\u22BE':'angrtvb','\u22BF':'lrtri','\u22C0':'Wedge','\u22C1':'Vee','\u22C2':'xcap','\u22C3':'xcup','\u22C4':'diam','\u22C5':'sdot','\u22C6':'Star','\u22C7':'divonx','\u22C8':'bowtie','\u22C9':'ltimes','\u22CA':'rtimes','\u22CB':'lthree','\u22CC':'rthree','\u22CD':'bsime','\u22CE':'cuvee','\u22CF':'cuwed','\u22D0':'Sub','\u22D1':'Sup','\u22D2':'Cap','\u22D3':'Cup','\u22D4':'fork','\u22D5':'epar','\u22D6':'ltdot','\u22D7':'gtdot','\u22D8':'Ll','\u22D8\u0338':'nLl','\u22D9':'Gg','\u22D9\u0338':'nGg','\u22DA\uFE00':'lesg','\u22DA':'leg','\u22DB':'gel','\u22DB\uFE00':'gesl','\u22DE':'cuepr','\u22DF':'cuesc','\u22E6':'lnsim','\u22E7':'gnsim','\u22E8':'prnsim','\u22E9':'scnsim','\u22EE':'vellip','\u22EF':'ctdot','\u22F0':'utdot','\u22F1':'dtdot','\u22F2':'disin','\u22F3':'isinsv','\u22F4':'isins','\u22F5':'isindot','\u22F5\u0338':'notindot','\u22F6':'notinvc','\u22F7':'notinvb','\u22F9':'isinE','\u22F9\u0338':'notinE','\u22FA':'nisd','\u22FB':'xnis','\u22FC':'nis','\u22FD':'notnivc','\u22FE':'notnivb','\u2305':'barwed','\u2306':'Barwed','\u230C':'drcrop','\u230D':'dlcrop','\u230E':'urcrop','\u230F':'ulcrop','\u2310':'bnot','\u2312':'profline','\u2313':'profsurf','\u2315':'telrec','\u2316':'target','\u231C':'ulcorn','\u231D':'urcorn','\u231E':'dlcorn','\u231F':'drcorn','\u2322':'frown','\u2323':'smile','\u232D':'cylcty','\u232E':'profalar','\u2336':'topbot','\u233D':'ovbar','\u233F':'solbar','\u237C':'angzarr','\u23B0':'lmoust','\u23B1':'rmoust','\u23B4':'tbrk','\u23B5':'bbrk','\u23B6':'bbrktbrk','\u23DC':'OverParenthesis','\u23DD':'UnderParenthesis','\u23DE':'OverBrace','\u23DF':'UnderBrace','\u23E2':'trpezium','\u23E7':'elinters','\u2423':'blank','\u2500':'boxh','\u2502':'boxv','\u250C':'boxdr','\u2510':'boxdl','\u2514':'boxur','\u2518':'boxul','\u251C':'boxvr','\u2524':'boxvl','\u252C':'boxhd','\u2534':'boxhu','\u253C':'boxvh','\u2550':'boxH','\u2551':'boxV','\u2552':'boxdR','\u2553':'boxDr','\u2554':'boxDR','\u2555':'boxdL','\u2556':'boxDl','\u2557':'boxDL','\u2558':'boxuR','\u2559':'boxUr','\u255A':'boxUR','\u255B':'boxuL','\u255C':'boxUl','\u255D':'boxUL','\u255E':'boxvR','\u255F':'boxVr','\u2560':'boxVR','\u2561':'boxvL','\u2562':'boxVl','\u2563':'boxVL','\u2564':'boxHd','\u2565':'boxhD','\u2566':'boxHD','\u2567':'boxHu','\u2568':'boxhU','\u2569':'boxHU','\u256A':'boxvH','\u256B':'boxVh','\u256C':'boxVH','\u2580':'uhblk','\u2584':'lhblk','\u2588':'block','\u2591':'blk14','\u2592':'blk12','\u2593':'blk34','\u25A1':'squ','\u25AA':'squf','\u25AB':'EmptyVerySmallSquare','\u25AD':'rect','\u25AE':'marker','\u25B1':'fltns','\u25B3':'xutri','\u25B4':'utrif','\u25B5':'utri','\u25B8':'rtrif','\u25B9':'rtri','\u25BD':'xdtri','\u25BE':'dtrif','\u25BF':'dtri','\u25C2':'ltrif','\u25C3':'ltri','\u25CA':'loz','\u25CB':'cir','\u25EC':'tridot','\u25EF':'xcirc','\u25F8':'ultri','\u25F9':'urtri','\u25FA':'lltri','\u25FB':'EmptySmallSquare','\u25FC':'FilledSmallSquare','\u2605':'starf','\u2606':'star','\u260E':'phone','\u2640':'female','\u2642':'male','\u2660':'spades','\u2663':'clubs','\u2665':'hearts','\u2666':'diams','\u266A':'sung','\u2713':'check','\u2717':'cross','\u2720':'malt','\u2736':'sext','\u2758':'VerticalSeparator','\u27C8':'bsolhsub','\u27C9':'suphsol','\u27F5':'xlarr','\u27F6':'xrarr','\u27F7':'xharr','\u27F8':'xlArr','\u27F9':'xrArr','\u27FA':'xhArr','\u27FC':'xmap','\u27FF':'dzigrarr','\u2902':'nvlArr','\u2903':'nvrArr','\u2904':'nvHarr','\u2905':'Map','\u290C':'lbarr','\u290D':'rbarr','\u290E':'lBarr','\u290F':'rBarr','\u2910':'RBarr','\u2911':'DDotrahd','\u2912':'UpArrowBar','\u2913':'DownArrowBar','\u2916':'Rarrtl','\u2919':'latail','\u291A':'ratail','\u291B':'lAtail','\u291C':'rAtail','\u291D':'larrfs','\u291E':'rarrfs','\u291F':'larrbfs','\u2920':'rarrbfs','\u2923':'nwarhk','\u2924':'nearhk','\u2925':'searhk','\u2926':'swarhk','\u2927':'nwnear','\u2928':'toea','\u2929':'tosa','\u292A':'swnwar','\u2933':'rarrc','\u2933\u0338':'nrarrc','\u2935':'cudarrr','\u2936':'ldca','\u2937':'rdca','\u2938':'cudarrl','\u2939':'larrpl','\u293C':'curarrm','\u293D':'cularrp','\u2945':'rarrpl','\u2948':'harrcir','\u2949':'Uarrocir','\u294A':'lurdshar','\u294B':'ldrushar','\u294E':'LeftRightVector','\u294F':'RightUpDownVector','\u2950':'DownLeftRightVector','\u2951':'LeftUpDownVector','\u2952':'LeftVectorBar','\u2953':'RightVectorBar','\u2954':'RightUpVectorBar','\u2955':'RightDownVectorBar','\u2956':'DownLeftVectorBar','\u2957':'DownRightVectorBar','\u2958':'LeftUpVectorBar','\u2959':'LeftDownVectorBar','\u295A':'LeftTeeVector','\u295B':'RightTeeVector','\u295C':'RightUpTeeVector','\u295D':'RightDownTeeVector','\u295E':'DownLeftTeeVector','\u295F':'DownRightTeeVector','\u2960':'LeftUpTeeVector','\u2961':'LeftDownTeeVector','\u2962':'lHar','\u2963':'uHar','\u2964':'rHar','\u2965':'dHar','\u2966':'luruhar','\u2967':'ldrdhar','\u2968':'ruluhar','\u2969':'rdldhar','\u296A':'lharul','\u296B':'llhard','\u296C':'rharul','\u296D':'lrhard','\u296E':'udhar','\u296F':'duhar','\u2970':'RoundImplies','\u2971':'erarr','\u2972':'simrarr','\u2973':'larrsim','\u2974':'rarrsim','\u2975':'rarrap','\u2976':'ltlarr','\u2978':'gtrarr','\u2979':'subrarr','\u297B':'suplarr','\u297C':'lfisht','\u297D':'rfisht','\u297E':'ufisht','\u297F':'dfisht','\u299A':'vzigzag','\u299C':'vangrt','\u299D':'angrtvbd','\u29A4':'ange','\u29A5':'range','\u29A6':'dwangle','\u29A7':'uwangle','\u29A8':'angmsdaa','\u29A9':'angmsdab','\u29AA':'angmsdac','\u29AB':'angmsdad','\u29AC':'angmsdae','\u29AD':'angmsdaf','\u29AE':'angmsdag','\u29AF':'angmsdah','\u29B0':'bemptyv','\u29B1':'demptyv','\u29B2':'cemptyv','\u29B3':'raemptyv','\u29B4':'laemptyv','\u29B5':'ohbar','\u29B6':'omid','\u29B7':'opar','\u29B9':'operp','\u29BB':'olcross','\u29BC':'odsold','\u29BE':'olcir','\u29BF':'ofcir','\u29C0':'olt','\u29C1':'ogt','\u29C2':'cirscir','\u29C3':'cirE','\u29C4':'solb','\u29C5':'bsolb','\u29C9':'boxbox','\u29CD':'trisb','\u29CE':'rtriltri','\u29CF':'LeftTriangleBar','\u29CF\u0338':'NotLeftTriangleBar','\u29D0':'RightTriangleBar','\u29D0\u0338':'NotRightTriangleBar','\u29DC':'iinfin','\u29DD':'infintie','\u29DE':'nvinfin','\u29E3':'eparsl','\u29E4':'smeparsl','\u29E5':'eqvparsl','\u29EB':'lozf','\u29F4':'RuleDelayed','\u29F6':'dsol','\u2A00':'xodot','\u2A01':'xoplus','\u2A02':'xotime','\u2A04':'xuplus','\u2A06':'xsqcup','\u2A0D':'fpartint','\u2A10':'cirfnint','\u2A11':'awint','\u2A12':'rppolint','\u2A13':'scpolint','\u2A14':'npolint','\u2A15':'pointint','\u2A16':'quatint','\u2A17':'intlarhk','\u2A22':'pluscir','\u2A23':'plusacir','\u2A24':'simplus','\u2A25':'plusdu','\u2A26':'plussim','\u2A27':'plustwo','\u2A29':'mcomma','\u2A2A':'minusdu','\u2A2D':'loplus','\u2A2E':'roplus','\u2A2F':'Cross','\u2A30':'timesd','\u2A31':'timesbar','\u2A33':'smashp','\u2A34':'lotimes','\u2A35':'rotimes','\u2A36':'otimesas','\u2A37':'Otimes','\u2A38':'odiv','\u2A39':'triplus','\u2A3A':'triminus','\u2A3B':'tritime','\u2A3C':'iprod','\u2A3F':'amalg','\u2A40':'capdot','\u2A42':'ncup','\u2A43':'ncap','\u2A44':'capand','\u2A45':'cupor','\u2A46':'cupcap','\u2A47':'capcup','\u2A48':'cupbrcap','\u2A49':'capbrcup','\u2A4A':'cupcup','\u2A4B':'capcap','\u2A4C':'ccups','\u2A4D':'ccaps','\u2A50':'ccupssm','\u2A53':'And','\u2A54':'Or','\u2A55':'andand','\u2A56':'oror','\u2A57':'orslope','\u2A58':'andslope','\u2A5A':'andv','\u2A5B':'orv','\u2A5C':'andd','\u2A5D':'ord','\u2A5F':'wedbar','\u2A66':'sdote','\u2A6A':'simdot','\u2A6D':'congdot','\u2A6D\u0338':'ncongdot','\u2A6E':'easter','\u2A6F':'apacir','\u2A70':'apE','\u2A70\u0338':'napE','\u2A71':'eplus','\u2A72':'pluse','\u2A73':'Esim','\u2A77':'eDDot','\u2A78':'equivDD','\u2A79':'ltcir','\u2A7A':'gtcir','\u2A7B':'ltquest','\u2A7C':'gtquest','\u2A7D':'les','\u2A7D\u0338':'nles','\u2A7E':'ges','\u2A7E\u0338':'nges','\u2A7F':'lesdot','\u2A80':'gesdot','\u2A81':'lesdoto','\u2A82':'gesdoto','\u2A83':'lesdotor','\u2A84':'gesdotol','\u2A85':'lap','\u2A86':'gap','\u2A87':'lne','\u2A88':'gne','\u2A89':'lnap','\u2A8A':'gnap','\u2A8B':'lEg','\u2A8C':'gEl','\u2A8D':'lsime','\u2A8E':'gsime','\u2A8F':'lsimg','\u2A90':'gsiml','\u2A91':'lgE','\u2A92':'glE','\u2A93':'lesges','\u2A94':'gesles','\u2A95':'els','\u2A96':'egs','\u2A97':'elsdot','\u2A98':'egsdot','\u2A99':'el','\u2A9A':'eg','\u2A9D':'siml','\u2A9E':'simg','\u2A9F':'simlE','\u2AA0':'simgE','\u2AA1':'LessLess','\u2AA1\u0338':'NotNestedLessLess','\u2AA2':'GreaterGreater','\u2AA2\u0338':'NotNestedGreaterGreater','\u2AA4':'glj','\u2AA5':'gla','\u2AA6':'ltcc','\u2AA7':'gtcc','\u2AA8':'lescc','\u2AA9':'gescc','\u2AAA':'smt','\u2AAB':'lat','\u2AAC':'smte','\u2AAC\uFE00':'smtes','\u2AAD':'late','\u2AAD\uFE00':'lates','\u2AAE':'bumpE','\u2AAF':'pre','\u2AAF\u0338':'npre','\u2AB0':'sce','\u2AB0\u0338':'nsce','\u2AB3':'prE','\u2AB4':'scE','\u2AB5':'prnE','\u2AB6':'scnE','\u2AB7':'prap','\u2AB8':'scap','\u2AB9':'prnap','\u2ABA':'scnap','\u2ABB':'Pr','\u2ABC':'Sc','\u2ABD':'subdot','\u2ABE':'supdot','\u2ABF':'subplus','\u2AC0':'supplus','\u2AC1':'submult','\u2AC2':'supmult','\u2AC3':'subedot','\u2AC4':'supedot','\u2AC5':'subE','\u2AC5\u0338':'nsubE','\u2AC6':'supE','\u2AC6\u0338':'nsupE','\u2AC7':'subsim','\u2AC8':'supsim','\u2ACB\uFE00':'vsubnE','\u2ACB':'subnE','\u2ACC\uFE00':'vsupnE','\u2ACC':'supnE','\u2ACF':'csub','\u2AD0':'csup','\u2AD1':'csube','\u2AD2':'csupe','\u2AD3':'subsup','\u2AD4':'supsub','\u2AD5':'subsub','\u2AD6':'supsup','\u2AD7':'suphsub','\u2AD8':'supdsub','\u2AD9':'forkv','\u2ADA':'topfork','\u2ADB':'mlcp','\u2AE4':'Dashv','\u2AE6':'Vdashl','\u2AE7':'Barv','\u2AE8':'vBar','\u2AE9':'vBarv','\u2AEB':'Vbar','\u2AEC':'Not','\u2AED':'bNot','\u2AEE':'rnmid','\u2AEF':'cirmid','\u2AF0':'midcir','\u2AF1':'topcir','\u2AF2':'nhpar','\u2AF3':'parsim','\u2AFD':'parsl','\u2AFD\u20E5':'nparsl','\u266D':'flat','\u266E':'natur','\u266F':'sharp','\xA4':'curren','\xA2':'cent','$':'dollar','\xA3':'pound','\xA5':'yen','\u20AC':'euro','\xB9':'sup1','\xBD':'half','\u2153':'frac13','\xBC':'frac14','\u2155':'frac15','\u2159':'frac16','\u215B':'frac18','\xB2':'sup2','\u2154':'frac23','\u2156':'frac25','\xB3':'sup3','\xBE':'frac34','\u2157':'frac35','\u215C':'frac38','\u2158':'frac45','\u215A':'frac56','\u215D':'frac58','\u215E':'frac78','\uD835\uDCB6':'ascr','\uD835\uDD52':'aopf','\uD835\uDD1E':'afr','\uD835\uDD38':'Aopf','\uD835\uDD04':'Afr','\uD835\uDC9C':'Ascr','\xAA':'ordf','\xE1':'aacute','\xC1':'Aacute','\xE0':'agrave','\xC0':'Agrave','\u0103':'abreve','\u0102':'Abreve','\xE2':'acirc','\xC2':'Acirc','\xE5':'aring','\xC5':'angst','\xE4':'auml','\xC4':'Auml','\xE3':'atilde','\xC3':'Atilde','\u0105':'aogon','\u0104':'Aogon','\u0101':'amacr','\u0100':'Amacr','\xE6':'aelig','\xC6':'AElig','\uD835\uDCB7':'bscr','\uD835\uDD53':'bopf','\uD835\uDD1F':'bfr','\uD835\uDD39':'Bopf','\u212C':'Bscr','\uD835\uDD05':'Bfr','\uD835\uDD20':'cfr','\uD835\uDCB8':'cscr','\uD835\uDD54':'copf','\u212D':'Cfr','\uD835\uDC9E':'Cscr','\u2102':'Copf','\u0107':'cacute','\u0106':'Cacute','\u0109':'ccirc','\u0108':'Ccirc','\u010D':'ccaron','\u010C':'Ccaron','\u010B':'cdot','\u010A':'Cdot','\xE7':'ccedil','\xC7':'Ccedil','\u2105':'incare','\uD835\uDD21':'dfr','\u2146':'dd','\uD835\uDD55':'dopf','\uD835\uDCB9':'dscr','\uD835\uDC9F':'Dscr','\uD835\uDD07':'Dfr','\u2145':'DD','\uD835\uDD3B':'Dopf','\u010F':'dcaron','\u010E':'Dcaron','\u0111':'dstrok','\u0110':'Dstrok','\xF0':'eth','\xD0':'ETH','\u2147':'ee','\u212F':'escr','\uD835\uDD22':'efr','\uD835\uDD56':'eopf','\u2130':'Escr','\uD835\uDD08':'Efr','\uD835\uDD3C':'Eopf','\xE9':'eacute','\xC9':'Eacute','\xE8':'egrave','\xC8':'Egrave','\xEA':'ecirc','\xCA':'Ecirc','\u011B':'ecaron','\u011A':'Ecaron','\xEB':'euml','\xCB':'Euml','\u0117':'edot','\u0116':'Edot','\u0119':'eogon','\u0118':'Eogon','\u0113':'emacr','\u0112':'Emacr','\uD835\uDD23':'ffr','\uD835\uDD57':'fopf','\uD835\uDCBB':'fscr','\uD835\uDD09':'Ffr','\uD835\uDD3D':'Fopf','\u2131':'Fscr','\uFB00':'fflig','\uFB03':'ffilig','\uFB04':'ffllig','\uFB01':'filig','fj':'fjlig','\uFB02':'fllig','\u0192':'fnof','\u210A':'gscr','\uD835\uDD58':'gopf','\uD835\uDD24':'gfr','\uD835\uDCA2':'Gscr','\uD835\uDD3E':'Gopf','\uD835\uDD0A':'Gfr','\u01F5':'gacute','\u011F':'gbreve','\u011E':'Gbreve','\u011D':'gcirc','\u011C':'Gcirc','\u0121':'gdot','\u0120':'Gdot','\u0122':'Gcedil','\uD835\uDD25':'hfr','\u210E':'planckh','\uD835\uDCBD':'hscr','\uD835\uDD59':'hopf','\u210B':'Hscr','\u210C':'Hfr','\u210D':'Hopf','\u0125':'hcirc','\u0124':'Hcirc','\u210F':'hbar','\u0127':'hstrok','\u0126':'Hstrok','\uD835\uDD5A':'iopf','\uD835\uDD26':'ifr','\uD835\uDCBE':'iscr','\u2148':'ii','\uD835\uDD40':'Iopf','\u2110':'Iscr','\u2111':'Im','\xED':'iacute','\xCD':'Iacute','\xEC':'igrave','\xCC':'Igrave','\xEE':'icirc','\xCE':'Icirc','\xEF':'iuml','\xCF':'Iuml','\u0129':'itilde','\u0128':'Itilde','\u0130':'Idot','\u012F':'iogon','\u012E':'Iogon','\u012B':'imacr','\u012A':'Imacr','\u0133':'ijlig','\u0132':'IJlig','\u0131':'imath','\uD835\uDCBF':'jscr','\uD835\uDD5B':'jopf','\uD835\uDD27':'jfr','\uD835\uDCA5':'Jscr','\uD835\uDD0D':'Jfr','\uD835\uDD41':'Jopf','\u0135':'jcirc','\u0134':'Jcirc','\u0237':'jmath','\uD835\uDD5C':'kopf','\uD835\uDCC0':'kscr','\uD835\uDD28':'kfr','\uD835\uDCA6':'Kscr','\uD835\uDD42':'Kopf','\uD835\uDD0E':'Kfr','\u0137':'kcedil','\u0136':'Kcedil','\uD835\uDD29':'lfr','\uD835\uDCC1':'lscr','\u2113':'ell','\uD835\uDD5D':'lopf','\u2112':'Lscr','\uD835\uDD0F':'Lfr','\uD835\uDD43':'Lopf','\u013A':'lacute','\u0139':'Lacute','\u013E':'lcaron','\u013D':'Lcaron','\u013C':'lcedil','\u013B':'Lcedil','\u0142':'lstrok','\u0141':'Lstrok','\u0140':'lmidot','\u013F':'Lmidot','\uD835\uDD2A':'mfr','\uD835\uDD5E':'mopf','\uD835\uDCC2':'mscr','\uD835\uDD10':'Mfr','\uD835\uDD44':'Mopf','\u2133':'Mscr','\uD835\uDD2B':'nfr','\uD835\uDD5F':'nopf','\uD835\uDCC3':'nscr','\u2115':'Nopf','\uD835\uDCA9':'Nscr','\uD835\uDD11':'Nfr','\u0144':'nacute','\u0143':'Nacute','\u0148':'ncaron','\u0147':'Ncaron','\xF1':'ntilde','\xD1':'Ntilde','\u0146':'ncedil','\u0145':'Ncedil','\u2116':'numero','\u014B':'eng','\u014A':'ENG','\uD835\uDD60':'oopf','\uD835\uDD2C':'ofr','\u2134':'oscr','\uD835\uDCAA':'Oscr','\uD835\uDD12':'Ofr','\uD835\uDD46':'Oopf','\xBA':'ordm','\xF3':'oacute','\xD3':'Oacute','\xF2':'ograve','\xD2':'Ograve','\xF4':'ocirc','\xD4':'Ocirc','\xF6':'ouml','\xD6':'Ouml','\u0151':'odblac','\u0150':'Odblac','\xF5':'otilde','\xD5':'Otilde','\xF8':'oslash','\xD8':'Oslash','\u014D':'omacr','\u014C':'Omacr','\u0153':'oelig','\u0152':'OElig','\uD835\uDD2D':'pfr','\uD835\uDCC5':'pscr','\uD835\uDD61':'popf','\u2119':'Popf','\uD835\uDD13':'Pfr','\uD835\uDCAB':'Pscr','\uD835\uDD62':'qopf','\uD835\uDD2E':'qfr','\uD835\uDCC6':'qscr','\uD835\uDCAC':'Qscr','\uD835\uDD14':'Qfr','\u211A':'Qopf','\u0138':'kgreen','\uD835\uDD2F':'rfr','\uD835\uDD63':'ropf','\uD835\uDCC7':'rscr','\u211B':'Rscr','\u211C':'Re','\u211D':'Ropf','\u0155':'racute','\u0154':'Racute','\u0159':'rcaron','\u0158':'Rcaron','\u0157':'rcedil','\u0156':'Rcedil','\uD835\uDD64':'sopf','\uD835\uDCC8':'sscr','\uD835\uDD30':'sfr','\uD835\uDD4A':'Sopf','\uD835\uDD16':'Sfr','\uD835\uDCAE':'Sscr','\u24C8':'oS','\u015B':'sacute','\u015A':'Sacute','\u015D':'scirc','\u015C':'Scirc','\u0161':'scaron','\u0160':'Scaron','\u015F':'scedil','\u015E':'Scedil','\xDF':'szlig','\uD835\uDD31':'tfr','\uD835\uDCC9':'tscr','\uD835\uDD65':'topf','\uD835\uDCAF':'Tscr','\uD835\uDD17':'Tfr','\uD835\uDD4B':'Topf','\u0165':'tcaron','\u0164':'Tcaron','\u0163':'tcedil','\u0162':'Tcedil','\u2122':'trade','\u0167':'tstrok','\u0166':'Tstrok','\uD835\uDCCA':'uscr','\uD835\uDD66':'uopf','\uD835\uDD32':'ufr','\uD835\uDD4C':'Uopf','\uD835\uDD18':'Ufr','\uD835\uDCB0':'Uscr','\xFA':'uacute','\xDA':'Uacute','\xF9':'ugrave','\xD9':'Ugrave','\u016D':'ubreve','\u016C':'Ubreve','\xFB':'ucirc','\xDB':'Ucirc','\u016F':'uring','\u016E':'Uring','\xFC':'uuml','\xDC':'Uuml','\u0171':'udblac','\u0170':'Udblac','\u0169':'utilde','\u0168':'Utilde','\u0173':'uogon','\u0172':'Uogon','\u016B':'umacr','\u016A':'Umacr','\uD835\uDD33':'vfr','\uD835\uDD67':'vopf','\uD835\uDCCB':'vscr','\uD835\uDD19':'Vfr','\uD835\uDD4D':'Vopf','\uD835\uDCB1':'Vscr','\uD835\uDD68':'wopf','\uD835\uDCCC':'wscr','\uD835\uDD34':'wfr','\uD835\uDCB2':'Wscr','\uD835\uDD4E':'Wopf','\uD835\uDD1A':'Wfr','\u0175':'wcirc','\u0174':'Wcirc','\uD835\uDD35':'xfr','\uD835\uDCCD':'xscr','\uD835\uDD69':'xopf','\uD835\uDD4F':'Xopf','\uD835\uDD1B':'Xfr','\uD835\uDCB3':'Xscr','\uD835\uDD36':'yfr','\uD835\uDCCE':'yscr','\uD835\uDD6A':'yopf','\uD835\uDCB4':'Yscr','\uD835\uDD1C':'Yfr','\uD835\uDD50':'Yopf','\xFD':'yacute','\xDD':'Yacute','\u0177':'ycirc','\u0176':'Ycirc','\xFF':'yuml','\u0178':'Yuml','\uD835\uDCCF':'zscr','\uD835\uDD37':'zfr','\uD835\uDD6B':'zopf','\u2128':'Zfr','\u2124':'Zopf','\uD835\uDCB5':'Zscr','\u017A':'zacute','\u0179':'Zacute','\u017E':'zcaron','\u017D':'Zcaron','\u017C':'zdot','\u017B':'Zdot','\u01B5':'imped','\xFE':'thorn','\xDE':'THORN','\u0149':'napos','\u03B1':'alpha','\u0391':'Alpha','\u03B2':'beta','\u0392':'Beta','\u03B3':'gamma','\u0393':'Gamma','\u03B4':'delta','\u0394':'Delta','\u03B5':'epsi','\u03F5':'epsiv','\u0395':'Epsilon','\u03DD':'gammad','\u03DC':'Gammad','\u03B6':'zeta','\u0396':'Zeta','\u03B7':'eta','\u0397':'Eta','\u03B8':'theta','\u03D1':'thetav','\u0398':'Theta','\u03B9':'iota','\u0399':'Iota','\u03BA':'kappa','\u03F0':'kappav','\u039A':'Kappa','\u03BB':'lambda','\u039B':'Lambda','\u03BC':'mu','\xB5':'micro','\u039C':'Mu','\u03BD':'nu','\u039D':'Nu','\u03BE':'xi','\u039E':'Xi','\u03BF':'omicron','\u039F':'Omicron','\u03C0':'pi','\u03D6':'piv','\u03A0':'Pi','\u03C1':'rho','\u03F1':'rhov','\u03A1':'Rho','\u03C3':'sigma','\u03A3':'Sigma','\u03C2':'sigmaf','\u03C4':'tau','\u03A4':'Tau','\u03C5':'upsi','\u03A5':'Upsilon','\u03D2':'Upsi','\u03C6':'phi','\u03D5':'phiv','\u03A6':'Phi','\u03C7':'chi','\u03A7':'Chi','\u03C8':'psi','\u03A8':'Psi','\u03C9':'omega','\u03A9':'ohm','\u0430':'acy','\u0410':'Acy','\u0431':'bcy','\u0411':'Bcy','\u0432':'vcy','\u0412':'Vcy','\u0433':'gcy','\u0413':'Gcy','\u0453':'gjcy','\u0403':'GJcy','\u0434':'dcy','\u0414':'Dcy','\u0452':'djcy','\u0402':'DJcy','\u0435':'iecy','\u0415':'IEcy','\u0451':'iocy','\u0401':'IOcy','\u0454':'jukcy','\u0404':'Jukcy','\u0436':'zhcy','\u0416':'ZHcy','\u0437':'zcy','\u0417':'Zcy','\u0455':'dscy','\u0405':'DScy','\u0438':'icy','\u0418':'Icy','\u0456':'iukcy','\u0406':'Iukcy','\u0457':'yicy','\u0407':'YIcy','\u0439':'jcy','\u0419':'Jcy','\u0458':'jsercy','\u0408':'Jsercy','\u043A':'kcy','\u041A':'Kcy','\u045C':'kjcy','\u040C':'KJcy','\u043B':'lcy','\u041B':'Lcy','\u0459':'ljcy','\u0409':'LJcy','\u043C':'mcy','\u041C':'Mcy','\u043D':'ncy','\u041D':'Ncy','\u045A':'njcy','\u040A':'NJcy','\u043E':'ocy','\u041E':'Ocy','\u043F':'pcy','\u041F':'Pcy','\u0440':'rcy','\u0420':'Rcy','\u0441':'scy','\u0421':'Scy','\u0442':'tcy','\u0422':'Tcy','\u045B':'tshcy','\u040B':'TSHcy','\u0443':'ucy','\u0423':'Ucy','\u045E':'ubrcy','\u040E':'Ubrcy','\u0444':'fcy','\u0424':'Fcy','\u0445':'khcy','\u0425':'KHcy','\u0446':'tscy','\u0426':'TScy','\u0447':'chcy','\u0427':'CHcy','\u045F':'dzcy','\u040F':'DZcy','\u0448':'shcy','\u0428':'SHcy','\u0449':'shchcy','\u0429':'SHCHcy','\u044A':'hardcy','\u042A':'HARDcy','\u044B':'ycy','\u042B':'Ycy','\u044C':'softcy','\u042C':'SOFTcy','\u044D':'ecy','\u042D':'Ecy','\u044E':'yucy','\u042E':'YUcy','\u044F':'yacy','\u042F':'YAcy','\u2135':'aleph','\u2136':'beth','\u2137':'gimel','\u2138':'daleth'};
var regexEscape = /["&'<>`]/g;
var escapeMap = {
'"': '&quot;',
'&': '&amp;',
'\'': '&#x27;',
'<': '&lt;',
// See https://mathiasbynens.be/notes/ambiguous-ampersands: in HTML, the
// following is not strictly necessary unless its part of a tag or an
// unquoted attribute value. Were only escaping it to support those
// situations, and for XML support.
'>': '&gt;',
// In Internet Explorer ≤ 8, the backtick character can be used
// to break out of (un)quoted attribute values or HTML comments.
// See http://html5sec.org/#102, http://html5sec.org/#108, and
// http://html5sec.org/#133.
'`': '&#x60;'
};
var regexInvalidEntity = /&#(?:[xX][^a-fA-F0-9]|[^0-9xX])/;
var regexInvalidRawCodePoint = /[\0-\x08\x0B\x0E-\x1F\x7F-\x9F\uFDD0-\uFDEF\uFFFE\uFFFF]|[\uD83F\uD87F\uD8BF\uD8FF\uD93F\uD97F\uD9BF\uD9FF\uDA3F\uDA7F\uDABF\uDAFF\uDB3F\uDB7F\uDBBF\uDBFF][\uDFFE\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;
var regexDecode = /&(CounterClockwiseContourIntegral|DoubleLongLeftRightArrow|ClockwiseContourIntegral|NotNestedGreaterGreater|NotSquareSupersetEqual|DiacriticalDoubleAcute|NotRightTriangleEqual|NotSucceedsSlantEqual|NotPrecedesSlantEqual|CloseCurlyDoubleQuote|NegativeVeryThinSpace|DoubleContourIntegral|FilledVerySmallSquare|CapitalDifferentialD|OpenCurlyDoubleQuote|EmptyVerySmallSquare|NestedGreaterGreater|DoubleLongRightArrow|NotLeftTriangleEqual|NotGreaterSlantEqual|ReverseUpEquilibrium|DoubleLeftRightArrow|NotSquareSubsetEqual|NotDoubleVerticalBar|RightArrowLeftArrow|NotGreaterFullEqual|NotRightTriangleBar|SquareSupersetEqual|DownLeftRightVector|DoubleLongLeftArrow|leftrightsquigarrow|LeftArrowRightArrow|NegativeMediumSpace|blacktriangleright|RightDownVectorBar|PrecedesSlantEqual|RightDoubleBracket|SucceedsSlantEqual|NotLeftTriangleBar|RightTriangleEqual|SquareIntersection|RightDownTeeVector|ReverseEquilibrium|NegativeThickSpace|longleftrightarrow|Longleftrightarrow|LongLeftRightArrow|DownRightTeeVector|DownRightVectorBar|GreaterSlantEqual|SquareSubsetEqual|LeftDownVectorBar|LeftDoubleBracket|VerticalSeparator|rightleftharpoons|NotGreaterGreater|NotSquareSuperset|blacktriangleleft|blacktriangledown|NegativeThinSpace|LeftDownTeeVector|NotLessSlantEqual|leftrightharpoons|DoubleUpDownArrow|DoubleVerticalBar|LeftTriangleEqual|FilledSmallSquare|twoheadrightarrow|NotNestedLessLess|DownLeftTeeVector|DownLeftVectorBar|RightAngleBracket|NotTildeFullEqual|NotReverseElement|RightUpDownVector|DiacriticalTilde|NotSucceedsTilde|circlearrowright|NotPrecedesEqual|rightharpoondown|DoubleRightArrow|NotSucceedsEqual|NonBreakingSpace|NotRightTriangle|LessEqualGreater|RightUpTeeVector|LeftAngleBracket|GreaterFullEqual|DownArrowUpArrow|RightUpVectorBar|twoheadleftarrow|GreaterEqualLess|downharpoonright|RightTriangleBar|ntrianglerighteq|NotSupersetEqual|LeftUpDownVector|DiacriticalAcute|rightrightarrows|vartriangleright|UpArrowDownArrow|DiacriticalGrave|UnderParenthesis|EmptySmallSquare|LeftUpVectorBar|leftrightarrows|DownRightVector|downharpoonleft|trianglerighteq|ShortRightArrow|OverParenthesis|DoubleLeftArrow|DoubleDownArrow|NotSquareSubset|bigtriangledown|ntrianglelefteq|UpperRightArrow|curvearrowright|vartriangleleft|NotLeftTriangle|nleftrightarrow|LowerRightArrow|NotHumpDownHump|NotGreaterTilde|rightthreetimes|LeftUpTeeVector|NotGreaterEqual|straightepsilon|LeftTriangleBar|rightsquigarrow|ContourIntegral|rightleftarrows|CloseCurlyQuote|RightDownVector|LeftRightVector|nLeftrightarrow|leftharpoondown|circlearrowleft|SquareSuperset|OpenCurlyQuote|hookrightarrow|HorizontalLine|DiacriticalDot|NotLessGreater|ntriangleright|DoubleRightTee|InvisibleComma|InvisibleTimes|LowerLeftArrow|DownLeftVector|NotSubsetEqual|curvearrowleft|trianglelefteq|NotVerticalBar|TildeFullEqual|downdownarrows|NotGreaterLess|RightTeeVector|ZeroWidthSpace|looparrowright|LongRightArrow|doublebarwedge|ShortLeftArrow|ShortDownArrow|RightVectorBar|GreaterGreater|ReverseElement|rightharpoonup|LessSlantEqual|leftthreetimes|upharpoonright|rightarrowtail|LeftDownVector|Longrightarrow|NestedLessLess|UpperLeftArrow|nshortparallel|leftleftarrows|leftrightarrow|Leftrightarrow|LeftRightArrow|longrightarrow|upharpoonleft|RightArrowBar|ApplyFunction|LeftTeeVector|leftarrowtail|NotEqualTilde|varsubsetneqq|varsupsetneqq|RightTeeArrow|SucceedsEqual|SucceedsTilde|LeftVectorBar|SupersetEqual|hookleftarrow|DifferentialD|VerticalTilde|VeryThinSpace|blacktriangle|bigtriangleup|LessFullEqual|divideontimes|leftharpoonup|UpEquilibrium|ntriangleleft|RightTriangle|measuredangle|shortparallel|longleftarrow|Longleftarrow|LongLeftArrow|DoubleLeftTee|Poincareplane|PrecedesEqual|triangleright|DoubleUpArrow|RightUpVector|fallingdotseq|looparrowleft|PrecedesTilde|NotTildeEqual|NotTildeTilde|smallsetminus|Proportional|triangleleft|triangledown|UnderBracket|NotHumpEqual|exponentiale|ExponentialE|NotLessTilde|HilbertSpace|RightCeiling|blacklozenge|varsupsetneq|HumpDownHump|GreaterEqual|VerticalLine|LeftTeeArrow|NotLessEqual|DownTeeArrow|LeftTriangle|varsubsetneq|Intersection|NotCongruent|DownArrowBar|LeftUpVector|LeftArrowBar|risingdotseq|GreaterTilde|RoundImplies|SquareSubset|ShortUpArrow|NotSuperset|quaternions|precnapprox|backepsilon|preccurlyeq|OverBracket|blacksquare|MediumSpace|VerticalBar|circledcirc|circleddash|CircleMinus|CircleTimes|LessGreater|curlyeqprec|curlyeqsucc|diamondsuit|UpDownArrow|Updownarrow|RuleDelayed|Rrightarrow|updownarrow|RightVector|nRightarrow|nrightarrow|eqslantless|LeftCeiling|Equilibrium|SmallCircle|expectation|NotSucceeds|thickapprox|GreaterLess|SquareUnion|NotPrecedes|NotLessLess|straightphi|succnapprox|succcurlyeq|SubsetEqual|sqsupseteq|Proportion|Laplacetrf|ImaginaryI|supsetneqq|NotGreater|gtreqqless|NotElement|ThickSpace|TildeEqual|TildeTilde|Fouriertrf|rmoustache|EqualTilde|eqslantgtr|UnderBrace|LeftVector|UpArrowBar|nLeftarrow|nsubseteqq|subsetneqq|nsupseteqq|nleftarrow|succapprox|lessapprox|UpTeeArrow|upuparrows|curlywedge|lesseqqgtr|varepsilon|varnothing|RightFloor|complement|CirclePlus|sqsubseteq|Lleftarrow|circledast|RightArrow|Rightarrow|rightarrow|lmoustache|Bernoullis|precapprox|mapstoleft|mapstodown|longmapsto|dotsquare|downarrow|DoubleDot|nsubseteq|supsetneq|leftarrow|nsupseteq|subsetneq|ThinSpace|ngeqslant|subseteqq|HumpEqual|NotSubset|triangleq|NotCupCap|lesseqgtr|heartsuit|TripleDot|Leftarrow|Coproduct|Congruent|varpropto|complexes|gvertneqq|LeftArrow|LessTilde|supseteqq|MinusPlus|CircleDot|nleqslant|NotExists|gtreqless|nparallel|UnionPlus|LeftFloor|checkmark|CenterDot|centerdot|Mellintrf|gtrapprox|bigotimes|OverBrace|spadesuit|therefore|pitchfork|rationals|PlusMinus|Backslash|Therefore|DownBreve|backsimeq|backprime|DownArrow|nshortmid|Downarrow|lvertneqq|eqvparsl|imagline|imagpart|infintie|integers|Integral|intercal|LessLess|Uarrocir|intlarhk|sqsupset|angmsdaf|sqsubset|llcorner|vartheta|cupbrcap|lnapprox|Superset|SuchThat|succnsim|succneqq|angmsdag|biguplus|curlyvee|trpezium|Succeeds|NotTilde|bigwedge|angmsdah|angrtvbd|triminus|cwconint|fpartint|lrcorner|smeparsl|subseteq|urcorner|lurdshar|laemptyv|DDotrahd|approxeq|ldrushar|awconint|mapstoup|backcong|shortmid|triangle|geqslant|gesdotol|timesbar|circledR|circledS|setminus|multimap|naturals|scpolint|ncongdot|RightTee|boxminus|gnapprox|boxtimes|andslope|thicksim|angmsdaa|varsigma|cirfnint|rtriltri|angmsdab|rppolint|angmsdac|barwedge|drbkarow|clubsuit|thetasym|bsolhsub|capbrcup|dzigrarr|doteqdot|DotEqual|dotminus|UnderBar|NotEqual|realpart|otimesas|ulcorner|hksearow|hkswarow|parallel|PartialD|elinters|emptyset|plusacir|bbrktbrk|angmsdad|pointint|bigoplus|angmsdae|Precedes|bigsqcup|varkappa|notindot|supseteq|precneqq|precnsim|profalar|profline|profsurf|leqslant|lesdotor|raemptyv|subplus|notnivb|notnivc|subrarr|zigrarr|vzigzag|submult|subedot|Element|between|cirscir|larrbfs|larrsim|lotimes|lbrksld|lbrkslu|lozenge|ldrdhar|dbkarow|bigcirc|epsilon|simrarr|simplus|ltquest|Epsilon|luruhar|gtquest|maltese|npolint|eqcolon|npreceq|bigodot|ddagger|gtrless|bnequiv|harrcir|ddotseq|equivDD|backsim|demptyv|nsqsube|nsqsupe|Upsilon|nsubset|upsilon|minusdu|nsucceq|swarrow|nsupset|coloneq|searrow|boxplus|napprox|natural|asympeq|alefsym|congdot|nearrow|bigstar|diamond|supplus|tritime|LeftTee|nvinfin|triplus|NewLine|nvltrie|nvrtrie|nwarrow|nexists|Diamond|ruluhar|Implies|supmult|angzarr|suplarr|suphsub|questeq|because|digamma|Because|olcross|bemptyv|omicron|Omicron|rotimes|NoBreak|intprod|angrtvb|orderof|uwangle|suphsol|lesdoto|orslope|DownTee|realine|cudarrl|rdldhar|OverBar|supedot|lessdot|supdsub|topfork|succsim|rbrkslu|rbrksld|pertenk|cudarrr|isindot|planckh|lessgtr|pluscir|gesdoto|plussim|plustwo|lesssim|cularrp|rarrsim|Cayleys|notinva|notinvb|notinvc|UpArrow|Uparrow|uparrow|NotLess|dwangle|precsim|Product|curarrm|Cconint|dotplus|rarrbfs|ccupssm|Cedilla|cemptyv|notniva|quatint|frac35|frac38|frac45|frac56|frac58|frac78|tridot|xoplus|gacute|gammad|Gammad|lfisht|lfloor|bigcup|sqsupe|gbreve|Gbreve|lharul|sqsube|sqcups|Gcedil|apacir|llhard|lmidot|Lmidot|lmoust|andand|sqcaps|approx|Abreve|spades|circeq|tprime|divide|topcir|Assign|topbot|gesdot|divonx|xuplus|timesd|gesles|atilde|solbar|SOFTcy|loplus|timesb|lowast|lowbar|dlcorn|dlcrop|softcy|dollar|lparlt|thksim|lrhard|Atilde|lsaquo|smashp|bigvee|thinsp|wreath|bkarow|lsquor|lstrok|Lstrok|lthree|ltimes|ltlarr|DotDot|simdot|ltrPar|weierp|xsqcup|angmsd|sigmav|sigmaf|zeetrf|Zcaron|zcaron|mapsto|vsupne|thetav|cirmid|marker|mcomma|Zacute|vsubnE|there4|gtlPar|vsubne|bottom|gtrarr|SHCHcy|shchcy|midast|midcir|middot|minusb|minusd|gtrdot|bowtie|sfrown|mnplus|models|colone|seswar|Colone|mstpos|searhk|gtrsim|nacute|Nacute|boxbox|telrec|hairsp|Tcedil|nbumpe|scnsim|ncaron|Ncaron|ncedil|Ncedil|hamilt|Scedil|nearhk|hardcy|HARDcy|tcedil|Tcaron|commat|nequiv|nesear|tcaron|target|hearts|nexist|varrho|scedil|Scaron|scaron|hellip|Sacute|sacute|hercon|swnwar|compfn|rtimes|rthree|rsquor|rsaquo|zacute|wedgeq|homtht|barvee|barwed|Barwed|rpargt|horbar|conint|swarhk|roplus|nltrie|hslash|hstrok|Hstrok|rmoust|Conint|bprime|hybull|hyphen|iacute|Iacute|supsup|supsub|supsim|varphi|coprod|brvbar|agrave|Supset|supset|igrave|Igrave|notinE|Agrave|iiiint|iinfin|copysr|wedbar|Verbar|vangrt|becaus|incare|verbar|inodot|bullet|drcorn|intcal|drcrop|cularr|vellip|Utilde|bumpeq|cupcap|dstrok|Dstrok|CupCap|cupcup|cupdot|eacute|Eacute|supdot|iquest|easter|ecaron|Ecaron|ecolon|isinsv|utilde|itilde|Itilde|curarr|succeq|Bumpeq|cacute|ulcrop|nparsl|Cacute|nprcue|egrave|Egrave|nrarrc|nrarrw|subsup|subsub|nrtrie|jsercy|nsccue|Jsercy|kappav|kcedil|Kcedil|subsim|ulcorn|nsimeq|egsdot|veebar|kgreen|capand|elsdot|Subset|subset|curren|aacute|lacute|Lacute|emptyv|ntilde|Ntilde|lagran|lambda|Lambda|capcap|Ugrave|langle|subdot|emsp13|numero|emsp14|nvdash|nvDash|nVdash|nVDash|ugrave|ufisht|nvHarr|larrfs|nvlArr|larrhk|larrlp|larrpl|nvrArr|Udblac|nwarhk|larrtl|nwnear|oacute|Oacute|latail|lAtail|sstarf|lbrace|odblac|Odblac|lbrack|udblac|odsold|eparsl|lcaron|Lcaron|ograve|Ograve|lcedil|Lcedil|Aacute|ssmile|ssetmn|squarf|ldquor|capcup|ominus|cylcty|rharul|eqcirc|dagger|rfloor|rfisht|Dagger|daleth|equals|origof|capdot|equest|dcaron|Dcaron|rdquor|oslash|Oslash|otilde|Otilde|otimes|Otimes|urcrop|Ubreve|ubreve|Yacute|Uacute|uacute|Rcedil|rcedil|urcorn|parsim|Rcaron|Vdashl|rcaron|Tstrok|percnt|period|permil|Exists|yacute|rbrack|rbrace|phmmat|ccaron|Ccaron|planck|ccedil|plankv|tstrok|female|plusdo|plusdu|ffilig|plusmn|ffllig|Ccedil|rAtail|dfisht|bernou|ratail|Rarrtl|rarrtl|angsph|rarrpl|rarrlp|rarrhk|xwedge|xotime|forall|ForAll|Vvdash|vsupnE|preceq|bigcap|frac12|frac13|frac14|primes|rarrfs|prnsim|frac15|Square|frac16|square|lesdot|frac18|frac23|propto|prurel|rarrap|rangle|puncsp|frac25|Racute|qprime|racute|lesges|frac34|abreve|AElig|eqsim|utdot|setmn|urtri|Equal|Uring|seArr|uring|searr|dashv|Dashv|mumap|nabla|iogon|Iogon|sdote|sdotb|scsim|napid|napos|equiv|natur|Acirc|dblac|erarr|nbump|iprod|erDot|ucirc|awint|esdot|angrt|ncong|isinE|scnap|Scirc|scirc|ndash|isins|Ubrcy|nearr|neArr|isinv|nedot|ubrcy|acute|Ycirc|iukcy|Iukcy|xutri|nesim|caret|jcirc|Jcirc|caron|twixt|ddarr|sccue|exist|jmath|sbquo|ngeqq|angst|ccaps|lceil|ngsim|UpTee|delta|Delta|rtrif|nharr|nhArr|nhpar|rtrie|jukcy|Jukcy|kappa|rsquo|Kappa|nlarr|nlArr|TSHcy|rrarr|aogon|Aogon|fflig|xrarr|tshcy|ccirc|nleqq|filig|upsih|nless|dharl|nlsim|fjlig|ropar|nltri|dharr|robrk|roarr|fllig|fltns|roang|rnmid|subnE|subne|lAarr|trisb|Ccirc|acirc|ccups|blank|VDash|forkv|Vdash|langd|cedil|blk12|blk14|laquo|strns|diams|notin|vDash|larrb|blk34|block|disin|uplus|vdash|vBarv|aelig|starf|Wedge|check|xrArr|lates|lbarr|lBarr|notni|lbbrk|bcong|frasl|lbrke|frown|vrtri|vprop|vnsup|gamma|Gamma|wedge|xodot|bdquo|srarr|doteq|ldquo|boxdl|boxdL|gcirc|Gcirc|boxDl|boxDL|boxdr|boxdR|boxDr|TRADE|trade|rlhar|boxDR|vnsub|npart|vltri|rlarr|boxhd|boxhD|nprec|gescc|nrarr|nrArr|boxHd|boxHD|boxhu|boxhU|nrtri|boxHu|clubs|boxHU|times|colon|Colon|gimel|xlArr|Tilde|nsime|tilde|nsmid|nspar|THORN|thorn|xlarr|nsube|nsubE|thkap|xhArr|comma|nsucc|boxul|boxuL|nsupe|nsupE|gneqq|gnsim|boxUl|boxUL|grave|boxur|boxuR|boxUr|boxUR|lescc|angle|bepsi|boxvh|varpi|boxvH|numsp|Theta|gsime|gsiml|theta|boxVh|boxVH|boxvl|gtcir|gtdot|boxvL|boxVl|boxVL|crarr|cross|Cross|nvsim|boxvr|nwarr|nwArr|sqsup|dtdot|Uogon|lhard|lharu|dtrif|ocirc|Ocirc|lhblk|duarr|odash|sqsub|Hacek|sqcup|llarr|duhar|oelig|OElig|ofcir|boxvR|uogon|lltri|boxVr|csube|uuarr|ohbar|csupe|ctdot|olarr|olcir|harrw|oline|sqcap|omacr|Omacr|omega|Omega|boxVR|aleph|lneqq|lnsim|loang|loarr|rharu|lobrk|hcirc|operp|oplus|rhard|Hcirc|orarr|Union|order|ecirc|Ecirc|cuepr|szlig|cuesc|breve|reals|eDDot|Breve|hoarr|lopar|utrif|rdquo|Umacr|umacr|efDot|swArr|ultri|alpha|rceil|ovbar|swarr|Wcirc|wcirc|smtes|smile|bsemi|lrarr|aring|parsl|lrhar|bsime|uhblk|lrtri|cupor|Aring|uharr|uharl|slarr|rbrke|bsolb|lsime|rbbrk|RBarr|lsimg|phone|rBarr|rbarr|icirc|lsquo|Icirc|emacr|Emacr|ratio|simne|plusb|simlE|simgE|simeq|pluse|ltcir|ltdot|empty|xharr|xdtri|iexcl|Alpha|ltrie|rarrw|pound|ltrif|xcirc|bumpe|prcue|bumpE|asymp|amacr|cuvee|Sigma|sigma|iiint|udhar|iiota|ijlig|IJlig|supnE|imacr|Imacr|prime|Prime|image|prnap|eogon|Eogon|rarrc|mdash|mDDot|cuwed|imath|supne|imped|Amacr|udarr|prsim|micro|rarrb|cwint|raquo|infin|eplus|range|rangd|Ucirc|radic|minus|amalg|veeeq|rAarr|epsiv|ycirc|quest|sharp|quot|zwnj|Qscr|race|qscr|Qopf|qopf|qint|rang|Rang|Zscr|zscr|Zopf|zopf|rarr|rArr|Rarr|Pscr|pscr|prop|prod|prnE|prec|ZHcy|zhcy|prap|Zeta|zeta|Popf|popf|Zdot|plus|zdot|Yuml|yuml|phiv|YUcy|yucy|Yscr|yscr|perp|Yopf|yopf|part|para|YIcy|Ouml|rcub|yicy|YAcy|rdca|ouml|osol|Oscr|rdsh|yacy|real|oscr|xvee|andd|rect|andv|Xscr|oror|ordm|ordf|xscr|ange|aopf|Aopf|rHar|Xopf|opar|Oopf|xopf|xnis|rhov|oopf|omid|xmap|oint|apid|apos|ogon|ascr|Ascr|odot|odiv|xcup|xcap|ocir|oast|nvlt|nvle|nvgt|nvge|nvap|Wscr|wscr|auml|ntlg|ntgl|nsup|nsub|nsim|Nscr|nscr|nsce|Wopf|ring|npre|wopf|npar|Auml|Barv|bbrk|Nopf|nopf|nmid|nLtv|beta|ropf|Ropf|Beta|beth|nles|rpar|nleq|bnot|bNot|nldr|NJcy|rscr|Rscr|Vscr|vscr|rsqb|njcy|bopf|nisd|Bopf|rtri|Vopf|nGtv|ngtr|vopf|boxh|boxH|boxv|nges|ngeq|boxV|bscr|scap|Bscr|bsim|Vert|vert|bsol|bull|bump|caps|cdot|ncup|scnE|ncap|nbsp|napE|Cdot|cent|sdot|Vbar|nang|vBar|chcy|Mscr|mscr|sect|semi|CHcy|Mopf|mopf|sext|circ|cire|mldr|mlcp|cirE|comp|shcy|SHcy|vArr|varr|cong|copf|Copf|copy|COPY|malt|male|macr|lvnE|cscr|ltri|sime|ltcc|simg|Cscr|siml|csub|Uuml|lsqb|lsim|uuml|csup|Lscr|lscr|utri|smid|lpar|cups|smte|lozf|darr|Lopf|Uscr|solb|lopf|sopf|Sopf|lneq|uscr|spar|dArr|lnap|Darr|dash|Sqrt|LJcy|ljcy|lHar|dHar|Upsi|upsi|diam|lesg|djcy|DJcy|leqq|dopf|Dopf|dscr|Dscr|dscy|ldsh|ldca|squf|DScy|sscr|Sscr|dsol|lcub|late|star|Star|Uopf|Larr|lArr|larr|uopf|dtri|dzcy|sube|subE|Lang|lang|Kscr|kscr|Kopf|kopf|KJcy|kjcy|KHcy|khcy|DZcy|ecir|edot|eDot|Jscr|jscr|succ|Jopf|jopf|Edot|uHar|emsp|ensp|Iuml|iuml|eopf|isin|Iscr|iscr|Eopf|epar|sung|epsi|escr|sup1|sup2|sup3|Iota|iota|supe|supE|Iopf|iopf|IOcy|iocy|Escr|esim|Esim|imof|Uarr|QUOT|uArr|uarr|euml|IEcy|iecy|Idot|Euml|euro|excl|Hscr|hscr|Hopf|hopf|TScy|tscy|Tscr|hbar|tscr|flat|tbrk|fnof|hArr|harr|half|fopf|Fopf|tdot|gvnE|fork|trie|gtcc|fscr|Fscr|gdot|gsim|Gscr|gscr|Gopf|gopf|gneq|Gdot|tosa|gnap|Topf|topf|geqq|toea|GJcy|gjcy|tint|gesl|mid|Sfr|ggg|top|ges|gla|glE|glj|geq|gne|gEl|gel|gnE|Gcy|gcy|gap|Tfr|tfr|Tcy|tcy|Hat|Tau|Ffr|tau|Tab|hfr|Hfr|ffr|Fcy|fcy|icy|Icy|iff|ETH|eth|ifr|Ifr|Eta|eta|int|Int|Sup|sup|ucy|Ucy|Sum|sum|jcy|ENG|ufr|Ufr|eng|Jcy|jfr|els|ell|egs|Efr|efr|Jfr|uml|kcy|Kcy|Ecy|ecy|kfr|Kfr|lap|Sub|sub|lat|lcy|Lcy|leg|Dot|dot|lEg|leq|les|squ|div|die|lfr|Lfr|lgE|Dfr|dfr|Del|deg|Dcy|dcy|lne|lnE|sol|loz|smt|Cup|lrm|cup|lsh|Lsh|sim|shy|map|Map|mcy|Mcy|mfr|Mfr|mho|gfr|Gfr|sfr|cir|Chi|chi|nap|Cfr|vcy|Vcy|cfr|Scy|scy|ncy|Ncy|vee|Vee|Cap|cap|nfr|scE|sce|Nfr|nge|ngE|nGg|vfr|Vfr|ngt|bot|nGt|nis|niv|Rsh|rsh|nle|nlE|bne|Bfr|bfr|nLl|nlt|nLt|Bcy|bcy|not|Not|rlm|wfr|Wfr|npr|nsc|num|ocy|ast|Ocy|ofr|xfr|Xfr|Ofr|ogt|ohm|apE|olt|Rho|ape|rho|Rfr|rfr|ord|REG|ang|reg|orv|And|and|AMP|Rcy|amp|Afr|ycy|Ycy|yen|yfr|Yfr|rcy|par|pcy|Pcy|pfr|Pfr|phi|Phi|afr|Acy|acy|zcy|Zcy|piv|acE|acd|zfr|Zfr|pre|prE|psi|Psi|qfr|Qfr|zwj|Or|ge|Gg|gt|gg|el|oS|lt|Lt|LT|Re|lg|gl|eg|ne|Im|it|le|DD|wp|wr|nu|Nu|dd|lE|Sc|sc|pi|Pi|ee|af|ll|Ll|rx|gE|xi|pm|Xi|ic|pr|Pr|in|ni|mp|mu|ac|Mu|or|ap|Gt|GT|ii);|&(Aacute|Agrave|Atilde|Ccedil|Eacute|Egrave|Iacute|Igrave|Ntilde|Oacute|Ograve|Oslash|Otilde|Uacute|Ugrave|Yacute|aacute|agrave|atilde|brvbar|ccedil|curren|divide|eacute|egrave|frac12|frac14|frac34|iacute|igrave|iquest|middot|ntilde|oacute|ograve|oslash|otilde|plusmn|uacute|ugrave|yacute|AElig|Acirc|Aring|Ecirc|Icirc|Ocirc|THORN|Ucirc|acirc|acute|aelig|aring|cedil|ecirc|icirc|iexcl|laquo|micro|ocirc|pound|raquo|szlig|thorn|times|ucirc|Auml|COPY|Euml|Iuml|Ouml|QUOT|Uuml|auml|cent|copy|euml|iuml|macr|nbsp|ordf|ordm|ouml|para|quot|sect|sup1|sup2|sup3|uuml|yuml|AMP|ETH|REG|amp|deg|eth|not|reg|shy|uml|yen|GT|LT|gt|lt)(?!;)([=a-zA-Z0-9]?)|&#([0-9]+)(;?)|&#[xX]([a-fA-F0-9]+)(;?)|&([0-9a-zA-Z]+)/g;
var decodeMap = {'aacute':'\xE1','Aacute':'\xC1','abreve':'\u0103','Abreve':'\u0102','ac':'\u223E','acd':'\u223F','acE':'\u223E\u0333','acirc':'\xE2','Acirc':'\xC2','acute':'\xB4','acy':'\u0430','Acy':'\u0410','aelig':'\xE6','AElig':'\xC6','af':'\u2061','afr':'\uD835\uDD1E','Afr':'\uD835\uDD04','agrave':'\xE0','Agrave':'\xC0','alefsym':'\u2135','aleph':'\u2135','alpha':'\u03B1','Alpha':'\u0391','amacr':'\u0101','Amacr':'\u0100','amalg':'\u2A3F','amp':'&','AMP':'&','and':'\u2227','And':'\u2A53','andand':'\u2A55','andd':'\u2A5C','andslope':'\u2A58','andv':'\u2A5A','ang':'\u2220','ange':'\u29A4','angle':'\u2220','angmsd':'\u2221','angmsdaa':'\u29A8','angmsdab':'\u29A9','angmsdac':'\u29AA','angmsdad':'\u29AB','angmsdae':'\u29AC','angmsdaf':'\u29AD','angmsdag':'\u29AE','angmsdah':'\u29AF','angrt':'\u221F','angrtvb':'\u22BE','angrtvbd':'\u299D','angsph':'\u2222','angst':'\xC5','angzarr':'\u237C','aogon':'\u0105','Aogon':'\u0104','aopf':'\uD835\uDD52','Aopf':'\uD835\uDD38','ap':'\u2248','apacir':'\u2A6F','ape':'\u224A','apE':'\u2A70','apid':'\u224B','apos':'\'','ApplyFunction':'\u2061','approx':'\u2248','approxeq':'\u224A','aring':'\xE5','Aring':'\xC5','ascr':'\uD835\uDCB6','Ascr':'\uD835\uDC9C','Assign':'\u2254','ast':'*','asymp':'\u2248','asympeq':'\u224D','atilde':'\xE3','Atilde':'\xC3','auml':'\xE4','Auml':'\xC4','awconint':'\u2233','awint':'\u2A11','backcong':'\u224C','backepsilon':'\u03F6','backprime':'\u2035','backsim':'\u223D','backsimeq':'\u22CD','Backslash':'\u2216','Barv':'\u2AE7','barvee':'\u22BD','barwed':'\u2305','Barwed':'\u2306','barwedge':'\u2305','bbrk':'\u23B5','bbrktbrk':'\u23B6','bcong':'\u224C','bcy':'\u0431','Bcy':'\u0411','bdquo':'\u201E','becaus':'\u2235','because':'\u2235','Because':'\u2235','bemptyv':'\u29B0','bepsi':'\u03F6','bernou':'\u212C','Bernoullis':'\u212C','beta':'\u03B2','Beta':'\u0392','beth':'\u2136','between':'\u226C','bfr':'\uD835\uDD1F','Bfr':'\uD835\uDD05','bigcap':'\u22C2','bigcirc':'\u25EF','bigcup':'\u22C3','bigodot':'\u2A00','bigoplus':'\u2A01','bigotimes':'\u2A02','bigsqcup':'\u2A06','bigstar':'\u2605','bigtriangledown':'\u25BD','bigtriangleup':'\u25B3','biguplus':'\u2A04','bigvee':'\u22C1','bigwedge':'\u22C0','bkarow':'\u290D','blacklozenge':'\u29EB','blacksquare':'\u25AA','blacktriangle':'\u25B4','blacktriangledown':'\u25BE','blacktriangleleft':'\u25C2','blacktriangleright':'\u25B8','blank':'\u2423','blk12':'\u2592','blk14':'\u2591','blk34':'\u2593','block':'\u2588','bne':'=\u20E5','bnequiv':'\u2261\u20E5','bnot':'\u2310','bNot':'\u2AED','bopf':'\uD835\uDD53','Bopf':'\uD835\uDD39','bot':'\u22A5','bottom':'\u22A5','bowtie':'\u22C8','boxbox':'\u29C9','boxdl':'\u2510','boxdL':'\u2555','boxDl':'\u2556','boxDL':'\u2557','boxdr':'\u250C','boxdR':'\u2552','boxDr':'\u2553','boxDR':'\u2554','boxh':'\u2500','boxH':'\u2550','boxhd':'\u252C','boxhD':'\u2565','boxHd':'\u2564','boxHD':'\u2566','boxhu':'\u2534','boxhU':'\u2568','boxHu':'\u2567','boxHU':'\u2569','boxminus':'\u229F','boxplus':'\u229E','boxtimes':'\u22A0','boxul':'\u2518','boxuL':'\u255B','boxUl':'\u255C','boxUL':'\u255D','boxur':'\u2514','boxuR':'\u2558','boxUr':'\u2559','boxUR':'\u255A','boxv':'\u2502','boxV':'\u2551','boxvh':'\u253C','boxvH':'\u256A','boxVh':'\u256B','boxVH':'\u256C','boxvl':'\u2524','boxvL':'\u2561','boxVl':'\u2562','boxVL':'\u2563','boxvr':'\u251C','boxvR':'\u255E','boxVr':'\u255F','boxVR':'\u2560','bprime':'\u2035','breve':'\u02D8','Breve':'\u02D8','brvbar':'\xA6','bscr':'\uD835\uDCB7','Bscr':'\u212C','bsemi':'\u204F','bsim':'\u223D','bsime':'\u22CD','bsol':'\\','bsolb':'\u29C5','bsolhsub':'\u27C8','bull':'\u2022','bullet':'\u2022','bump':'\u224E','bumpe':'\u224F','bumpE':'\u2AAE','bumpeq':'\u224F','Bumpeq':'\u224E','cacute':'\u0107','Cacute':'\u0106','cap':'\u2229','Cap':'\u22D2','capand':'\u2A44','capbrcup':'\u2A49','capcap':'\u2A4B','capcup':'\u2A47','capdot':'\u2A40','CapitalDifferentialD':'\u2145','caps':'\u2229\uFE00','caret':'\u2041','caron':'\u02C7','Cayleys':'\u212D','ccaps':'\u2A4D','ccaron':'\u010D','Ccaron':'\u010C','ccedil':'\xE7','Ccedil':'\xC7','ccirc':'\u0109','Ccirc':'\u0108','Cconint':'\u2230','ccups':'\u2A4C','ccupssm':'\u2A50','cdot':'\u010B','Cdot':'\u010A','cedil':'\xB8','Cedilla':'\xB8','cemptyv':'\u29B2','cent':'\xA2','centerdot':'\xB7','CenterDot':'\xB7','cfr':'\uD835\uDD20','Cfr':'\u212D','chcy':'\u0447','CHcy':'\u0427','check':'\u2713','checkmark':'\u2713','chi':'\u03C7','Chi':'\u03A7','cir':'\u25CB','circ':'\u02C6','circeq':'\u2257','circlearrowleft':'\u21BA','circlearrowright':'\u21BB','circledast':'\u229B','circledcirc':'\u229A','circleddash':'\u229D','CircleDot':'\u2299','circledR':'\xAE','circledS':'\u24C8','CircleMinus':'\u2296','CirclePlus':'\u2295','CircleTimes':'\u2297','cire':'\u2257','cirE':'\u29C3','cirfnint':'\u2A10','cirmid':'\u2AEF','cirscir':'\u29C2','ClockwiseContourIntegral':'\u2232','CloseCurlyDoubleQuote':'\u201D','CloseCurlyQuote':'\u2019','clubs':'\u2663','clubsuit':'\u2663','colon':':','Colon':'\u2237','colone':'\u2254','Colone':'\u2A74','coloneq':'\u2254','comma':',','commat':'@','comp':'\u2201','compfn':'\u2218','complement':'\u2201','complexes':'\u2102','cong':'\u2245','congdot':'\u2A6D','Congruent':'\u2261','conint':'\u222E','Conint':'\u222F','ContourIntegral':'\u222E','copf':'\uD835\uDD54','Copf':'\u2102','coprod':'\u2210','Coproduct':'\u2210','copy':'\xA9','COPY':'\xA9','copysr':'\u2117','CounterClockwiseContourIntegral':'\u2233','crarr':'\u21B5','cross':'\u2717','Cross':'\u2A2F','cscr':'\uD835\uDCB8','Cscr':'\uD835\uDC9E','csub':'\u2ACF','csube':'\u2AD1','csup':'\u2AD0','csupe':'\u2AD2','ctdot':'\u22EF','cudarrl':'\u2938','cudarrr':'\u2935','cuepr':'\u22DE','cuesc':'\u22DF','cularr':'\u21B6','cularrp':'\u293D','cup':'\u222A','Cup':'\u22D3','cupbrcap':'\u2A48','cupcap':'\u2A46','CupCap':'\u224D','cupcup':'\u2A4A','cupdot':'\u228D','cupor':'\u2A45','cups':'\u222A\uFE00','curarr':'\u21B7','curarrm':'\u293C','curlyeqprec':'\u22DE','curlyeqsucc':'\u22DF','curlyvee':'\u22CE','curlywedge':'\u22CF','curren':'\xA4','curvearrowleft':'\u21B6','curvearrowright':'\u21B7','cuvee':'\u22CE','cuwed':'\u22CF','cwconint':'\u2232','cwint':'\u2231','cylcty':'\u232D','dagger':'\u2020','Dagger':'\u2021','daleth':'\u2138','darr':'\u2193','dArr':'\u21D3','Darr':'\u21A1','dash':'\u2010','dashv':'\u22A3','Dashv':'\u2AE4','dbkarow':'\u290F','dblac':'\u02DD','dcaron':'\u010F','Dcaron':'\u010E','dcy':'\u0434','Dcy':'\u0414','dd':'\u2146','DD':'\u2145','ddagger':'\u2021','ddarr':'\u21CA','DDotrahd':'\u2911','ddotseq':'\u2A77','deg':'\xB0','Del':'\u2207','delta':'\u03B4','Delta':'\u0394','demptyv':'\u29B1','dfisht':'\u297F','dfr':'\uD835\uDD21','Dfr':'\uD835\uDD07','dHar':'\u2965','dharl':'\u21C3','dharr':'\u21C2','DiacriticalAcute':'\xB4','DiacriticalDot':'\u02D9','DiacriticalDoubleAcute':'\u02DD','DiacriticalGrave':'`','DiacriticalTilde':'\u02DC','diam':'\u22C4','diamond':'\u22C4','Diamond':'\u22C4','diamondsuit':'\u2666','diams':'\u2666','die':'\xA8','DifferentialD':'\u2146','digamma':'\u03DD','disin':'\u22F2','div':'\xF7','divide':'\xF7','divideontimes':'\u22C7','divonx':'\u22C7','djcy':'\u0452','DJcy':'\u0402','dlcorn':'\u231E','dlcrop':'\u230D','dollar':'$','dopf':'\uD835\uDD55','Dopf':'\uD835\uDD3B','dot':'\u02D9','Dot':'\xA8','DotDot':'\u20DC','doteq':'\u2250','doteqdot':'\u2251','DotEqual':'\u2250','dotminus':'\u2238','dotplus':'\u2214','dotsquare':'\u22A1','doublebarwedge':'\u2306','DoubleContourIntegral':'\u222F','DoubleDot':'\xA8','DoubleDownArrow':'\u21D3','DoubleLeftArrow':'\u21D0','DoubleLeftRightArrow':'\u21D4','DoubleLeftTee':'\u2AE4','DoubleLongLeftArrow':'\u27F8','DoubleLongLeftRightArrow':'\u27FA','DoubleLongRightArrow':'\u27F9','DoubleRightArrow':'\u21D2','DoubleRightTee':'\u22A8','DoubleUpArrow':'\u21D1','DoubleUpDownArrow':'\u21D5','DoubleVerticalBar':'\u2225','downarrow':'\u2193','Downarrow':'\u21D3','DownArrow':'\u2193','DownArrowBar':'\u2913','DownArrowUpArrow':'\u21F5','DownBreve':'\u0311','downdownarrows':'\u21CA','downharpoonleft':'\u21C3','downharpoonright':'\u21C2','DownLeftRightVector':'\u2950','DownLeftTeeVector':'\u295E','DownLeftVector':'\u21BD','DownLeftVectorBar':'\u2956','DownRightTeeVector':'\u295F','DownRightVector':'\u21C1','DownRightVectorBar':'\u2957','DownTee':'\u22A4','DownTeeArrow':'\u21A7','drbkarow':'\u2910','drcorn':'\u231F','drcrop':'\u230C','dscr':'\uD835\uDCB9','Dscr':'\uD835\uDC9F','dscy':'\u0455','DScy':'\u0405','dsol':'\u29F6','dstrok':'\u0111','Dstrok':'\u0110','dtdot':'\u22F1','dtri':'\u25BF','dtrif':'\u25BE','duarr':'\u21F5','duhar':'\u296F','dwangle':'\u29A6','dzcy':'\u045F','DZcy':'\u040F','dzigrarr':'\u27FF','eacute':'\xE9','Eacute':'\xC9','easter':'\u2A6E','ecaron':'\u011B','Ecaron':'\u011A','ecir':'\u2256','ecirc':'\xEA','Ecirc':'\xCA','ecolon':'\u2255','ecy':'\u044D','Ecy':'\u042D','eDDot':'\u2A77','edot':'\u0117','eDot':'\u2251','Edot':'\u0116','ee':'\u2147','efDot':'\u2252','efr':'\uD835\uDD22','Efr':'\uD835\uDD08','eg':'\u2A9A','egrave':'\xE8','Egrave':'\xC8','egs':'\u2A96','egsdot':'\u2A98','el':'\u2A99','Element':'\u2208','elinters':'\u23E7','ell':'\u2113','els':'\u2A95','elsdot':'\u2A97','emacr':'\u0113','Emacr':'\u0112','empty':'\u2205','emptyset':'\u2205','EmptySmallSquare':'\u25FB','emptyv':'\u2205','EmptyVerySmallSquare':'\u25AB','emsp':'\u2003','emsp13':'\u2004','emsp14':'\u2005','eng':'\u014B','ENG':'\u014A','ensp':'\u2002','eogon':'\u0119','Eogon':'\u0118','eopf':'\uD835\uDD56','Eopf':'\uD835\uDD3C','epar':'\u22D5','eparsl':'\u29E3','eplus':'\u2A71','epsi':'\u03B5','epsilon':'\u03B5','Epsilon':'\u0395','epsiv':'\u03F5','eqcirc':'\u2256','eqcolon':'\u2255','eqsim':'\u2242','eqslantgtr':'\u2A96','eqslantless':'\u2A95','Equal':'\u2A75','equals':'=','EqualTilde':'\u2242','equest':'\u225F','Equilibrium':'\u21CC','equiv':'\u2261','equivDD':'\u2A78','eqvparsl':'\u29E5','erarr':'\u2971','erDot':'\u2253','escr':'\u212F','Escr':'\u2130','esdot':'\u2250','esim':'\u2242','Esim':'\u2A73','eta':'\u03B7','Eta':'\u0397','eth':'\xF0','ETH':'\xD0','euml':'\xEB','Euml':'\xCB','euro':'\u20AC','excl':'!','exist':'\u2203','Exists':'\u2203','expectation':'\u2130','exponentiale':'\u2147','ExponentialE':'\u2147','fallingdotseq':'\u2252','fcy':'\u0444','Fcy':'\u0424','female':'\u2640','ffilig':'\uFB03','fflig':'\uFB00','ffllig':'\uFB04','ffr':'\uD835\uDD23','Ffr':'\uD835\uDD09','filig':'\uFB01','FilledSmallSquare':'\u25FC','FilledVerySmallSquare':'\u25AA','fjlig':'fj','flat':'\u266D','fllig':'\uFB02','fltns':'\u25B1','fnof':'\u0192','fopf':'\uD835\uDD57','Fopf':'\uD835\uDD3D','forall':'\u2200','ForAll':'\u2200','fork':'\u22D4','forkv':'\u2AD9','Fouriertrf':'\u2131','fpartint':'\u2A0D','frac12':'\xBD','frac13':'\u2153','frac14':'\xBC','frac15':'\u2155','frac16':'\u2159','frac18':'\u215B','frac23':'\u2154','frac25':'\u2156','frac34':'\xBE','frac35':'\u2157','frac38':'\u215C','frac45':'\u2158','frac56':'\u215A','frac58':'\u215D','frac78':'\u215E','frasl':'\u2044','frown':'\u2322','fscr':'\uD835\uDCBB','Fscr':'\u2131','gacute':'\u01F5','gamma':'\u03B3','Gamma':'\u0393','gammad':'\u03DD','Gammad':'\u03DC','gap':'\u2A86','gbreve':'\u011F','Gbreve':'\u011E','Gcedil':'\u0122','gcirc':'\u011D','Gcirc':'\u011C','gcy':'\u0433','Gcy':'\u0413','gdot':'\u0121','Gdot':'\u0120','ge':'\u2265','gE':'\u2267','gel':'\u22DB','gEl':'\u2A8C','geq':'\u2265','geqq':'\u2267','geqslant':'\u2A7E','ges':'\u2A7E','gescc':'\u2AA9','gesdot':'\u2A80','gesdoto':'\u2A82','gesdotol':'\u2A84','gesl':'\u22DB\uFE00','gesles':'\u2A94','gfr':'\uD835\uDD24','Gfr':'\uD835\uDD0A','gg':'\u226B','Gg':'\u22D9','ggg':'\u22D9','gimel':'\u2137','gjcy':'\u0453','GJcy':'\u0403','gl':'\u2277','gla':'\u2AA5','glE':'\u2A92','glj':'\u2AA4','gnap':'\u2A8A','gnapprox':'\u2A8A','gne':'\u2A88','gnE':'\u2269','gneq':'\u2A88','gneqq':'\u2269','gnsim':'\u22E7','gopf':'\uD835\uDD58','Gopf':'\uD835\uDD3E','grave':'`','GreaterEqual':'\u2265','GreaterEqualLess':'\u22DB','GreaterFullEqual':'\u2267','GreaterGreater':'\u2AA2','GreaterLess':'\u2277','GreaterSlantEqual':'\u2A7E','GreaterTilde':'\u2273','gscr':'\u210A','Gscr':'\uD835\uDCA2','gsim':'\u2273','gsime':'\u2A8E','gsiml':'\u2A90','gt':'>','Gt':'\u226B','GT':'>','gtcc':'\u2AA7','gtcir':'\u2A7A','gtdot':'\u22D7','gtlPar':'\u2995','gtquest':'\u2A7C','gtrapprox':'\u2A86','gtrarr':'\u2978','gtrdot':'\u22D7','gtreqless':'\u22DB','gtreqqless':'\u2A8C','gtrless':'\u2277','gtrsim':'\u2273','gvertneqq':'\u2269\uFE00','gvnE':'\u2269\uFE00','Hacek':'\u02C7','hairsp':'\u200A','half':'\xBD','hamilt':'\u210B','hardcy':'\u044A','HARDcy':'\u042A','harr':'\u2194','hArr':'\u21D4','harrcir':'\u2948','harrw':'\u21AD','Hat':'^','hbar':'\u210F','hcirc':'\u0125','Hcirc':'\u0124','hearts':'\u2665','heartsuit':'\u2665','hellip':'\u2026','hercon':'\u22B9','hfr':'\uD835\uDD25','Hfr':'\u210C','HilbertSpace':'\u210B','hksearow':'\u2925','hkswarow':'\u2926','hoarr':'\u21FF','homtht':'\u223B','hookleftarrow':'\u21A9','hookrightarrow':'\u21AA','hopf':'\uD835\uDD59','Hopf':'\u210D','horbar':'\u2015','HorizontalLine':'\u2500','hscr':'\uD835\uDCBD','Hscr':'\u210B','hslash':'\u210F','hstrok':'\u0127','Hstrok':'\u0126','HumpDownHump':'\u224E','HumpEqual':'\u224F','hybull':'\u2043','hyphen':'\u2010','iacute':'\xED','Iacute':'\xCD','ic':'\u2063','icirc':'\xEE','Icirc':'\xCE','icy':'\u0438','Icy':'\u0418','Idot':'\u0130','iecy':'\u0435','IEcy':'\u0415','iexcl':'\xA1','iff':'\u21D4','ifr':'\uD835\uDD26','Ifr':'\u2111','igrave':'\xEC','Igrave':'\xCC','ii':'\u2148','iiiint':'\u2A0C','iiint':'\u222D','iinfin':'\u29DC','iiota':'\u2129','ijlig':'\u0133','IJlig':'\u0132','Im':'\u2111','imacr':'\u012B','Imacr':'\u012A','image':'\u2111','ImaginaryI':'\u2148','imagline':'\u2110','imagpart':'\u2111','imath':'\u0131','imof':'\u22B7','imped':'\u01B5','Implies':'\u21D2','in':'\u2208','incare':'\u2105','infin':'\u221E','infintie':'\u29DD','inodot':'\u0131','int':'\u222B','Int':'\u222C','intcal':'\u22BA','integers':'\u2124','Integral':'\u222B','intercal':'\u22BA','Intersection':'\u22C2','intlarhk':'\u2A17','intprod':'\u2A3C','InvisibleComma':'\u2063','InvisibleTimes':'\u2062','iocy':'\u0451','IOcy':'\u0401','iogon':'\u012F','Iogon':'\u012E','iopf':'\uD835\uDD5A','Iopf':'\uD835\uDD40','iota':'\u03B9','Iota':'\u0399','iprod':'\u2A3C','iquest':'\xBF','iscr':'\uD835\uDCBE','Iscr':'\u2110','isin':'\u2208','isindot':'\u22F5','isinE':'\u22F9','isins':'\u22F4','isinsv':'\u22F3','isinv':'\u2208','it':'\u2062','itilde':'\u0129','Itilde':'\u0128','iukcy':'\u0456','Iukcy':'\u0406','iuml':'\xEF','Iuml':'\xCF','jcirc':'\u0135','Jcirc':'\u0134','jcy':'\u0439','Jcy':'\u0419','jfr':'\uD835\uDD27','Jfr':'\uD835\uDD0D','jmath':'\u0237','jopf':'\uD835\uDD5B','Jopf':'\uD835\uDD41','jscr':'\uD835\uDCBF','Jscr':'\uD835\uDCA5','jsercy':'\u0458','Jsercy':'\u0408','jukcy':'\u0454','Jukcy':'\u0404','kappa':'\u03BA','Kappa':'\u039A','kappav':'\u03F0','kcedil':'\u0137','Kcedil':'\u0136','kcy':'\u043A','Kcy':'\u041A','kfr':'\uD835\uDD28','Kfr':'\uD835\uDD0E','kgreen':'\u0138','khcy':'\u0445','KHcy':'\u0425','kjcy':'\u045C','KJcy':'\u040C','kopf':'\uD835\uDD5C','Kopf':'\uD835\uDD42','kscr':'\uD835\uDCC0','Kscr':'\uD835\uDCA6','lAarr':'\u21DA','lacute':'\u013A','Lacute':'\u0139','laemptyv':'\u29B4','lagran':'\u2112','lambda':'\u03BB','Lambda':'\u039B','lang':'\u27E8','Lang':'\u27EA','langd':'\u2991','langle':'\u27E8','lap':'\u2A85','Laplacetrf':'\u2112','laquo':'\xAB','larr':'\u2190','lArr':'\u21D0','Larr':'\u219E','larrb':'\u21E4','larrbfs':'\u291F','larrfs':'\u291D','larrhk':'\u21A9','larrlp':'\u21AB','larrpl':'\u2939','larrsim':'\u2973','larrtl':'\u21A2','lat':'\u2AAB','latail':'\u2919','lAtail':'\u291B','late':'\u2AAD','lates':'\u2AAD\uFE00','lbarr':'\u290C','lBarr':'\u290E','lbbrk':'\u2772','lbrace':'{','lbrack':'[','lbrke':'\u298B','lbrksld':'\u298F','lbrkslu':'\u298D','lcaron':'\u013E','Lcaron':'\u013D','lcedil':'\u013C','Lcedil':'\u013B','lceil':'\u2308','lcub':'{','lcy':'\u043B','Lcy':'\u041B','ldca':'\u2936','ldquo':'\u201C','ldquor':'\u201E','ldrdhar':'\u2967','ldrushar':'\u294B','ldsh':'\u21B2','le':'\u2264','lE':'\u2266','LeftAngleBracket':'\u27E8','leftarrow':'\u2190','Leftarrow':'\u21D0','LeftArrow':'\u2190','LeftArrowBar':'\u21E4','LeftArrowRightArrow':'\u21C6','leftarrowtail':'\u21A2','LeftCeiling':'\u2308','LeftDoubleBracket':'\u27E6','LeftDownTeeVector':'\u2961','LeftDownVector':'\u21C3','LeftDownVectorBar':'\u2959','LeftFloor':'\u230A','leftharpoondown':'\u21BD','leftharpoonup':'\u21BC','leftleftarrows':'\u21C7','leftrightarrow':'\u2194','Leftrightarrow':'\u21D4','LeftRightArrow':'\u2194','leftrightarrows':'\u21C6','leftrightharpoons':'\u21CB','leftrightsquigarrow':'\u21AD','LeftRightVector':'\u294E','LeftTee':'\u22A3','LeftTeeArrow':'\u21A4','LeftTeeVector':'\u295A','leftthreetimes':'\u22CB','LeftTriangle':'\u22B2','LeftTriangleBar':'\u29CF','LeftTriangleEqual':'\u22B4','LeftUpDownVector':'\u2951','LeftUpTeeVector':'\u2960','LeftUpVector':'\u21BF','LeftUpVectorBar':'\u2958','LeftVector':'\u21BC','LeftVectorBar':'\u2952','leg':'\u22DA','lEg':'\u2A8B','leq':'\u2264','leqq':'\u2266','leqslant':'\u2A7D','les':'\u2A7D','lescc':'\u2AA8','lesdot':'\u2A7F','lesdoto':'\u2A81','lesdotor':'\u2A83','lesg':'\u22DA\uFE00','lesges':'\u2A93','lessapprox':'\u2A85','lessdot':'\u22D6','lesseqgtr':'\u22DA','lesseqqgtr':'\u2A8B','LessEqualGreater':'\u22DA','LessFullEqual':'\u2266','LessGreater':'\u2276','lessgtr':'\u2276','LessLess':'\u2AA1','lesssim':'\u2272','LessSlantEqual':'\u2A7D','LessTilde':'\u2272','lfisht':'\u297C','lfloor':'\u230A','lfr':'\uD835\uDD29','Lfr':'\uD835\uDD0F','lg':'\u2276','lgE':'\u2A91','lHar':'\u2962','lhard':'\u21BD','lharu':'\u21BC','lharul':'\u296A','lhblk':'\u2584','ljcy':'\u0459','LJcy':'\u0409','ll':'\u226A','Ll':'\u22D8','llarr':'\u21C7','llcorner':'\u231E','Lleftarrow':'\u21DA','llhard':'\u296B','lltri':'\u25FA','lmidot':'\u0140','Lmidot':'\u013F','lmoust':'\u23B0','lmoustache':'\u23B0','lnap':'\u2A89','lnapprox':'\u2A89','lne':'\u2A87','lnE':'\u2268','lneq':'\u2A87','lneqq':'\u2268','lnsim':'\u22E6','loang':'\u27EC','loarr':'\u21FD','lobrk':'\u27E6','longleftarrow':'\u27F5','Longleftarrow':'\u27F8','LongLeftArrow':'\u27F5','longleftrightarrow':'\u27F7','Longleftrightarrow':'\u27FA','LongLeftRightArrow':'\u27F7','longmapsto':'\u27FC','longrightarrow':'\u27F6','Longrightarrow':'\u27F9','LongRightArrow':'\u27F6','looparrowleft':'\u21AB','looparrowright':'\u21AC','lopar':'\u2985','lopf':'\uD835\uDD5D','Lopf':'\uD835\uDD43','loplus':'\u2A2D','lotimes':'\u2A34','lowast':'\u2217','lowbar':'_','LowerLeftArrow':'\u2199','LowerRightArrow':'\u2198','loz':'\u25CA','lozenge':'\u25CA','lozf':'\u29EB','lpar':'(','lparlt':'\u2993','lrarr':'\u21C6','lrcorner':'\u231F','lrhar':'\u21CB','lrhard':'\u296D','lrm':'\u200E','lrtri':'\u22BF','lsaquo':'\u2039','lscr':'\uD835\uDCC1','Lscr':'\u2112','lsh':'\u21B0','Lsh':'\u21B0','lsim':'\u2272','lsime':'\u2A8D','lsimg':'\u2A8F','lsqb':'[','lsquo':'\u2018','lsquor':'\u201A','lstrok':'\u0142','Lstrok':'\u0141','lt':'<','Lt':'\u226A','LT':'<','ltcc':'\u2AA6','ltcir':'\u2A79','ltdot':'\u22D6','lthree':'\u22CB','ltimes':'\u22C9','ltlarr':'\u2976','ltquest':'\u2A7B','ltri':'\u25C3','ltrie':'\u22B4','ltrif':'\u25C2','ltrPar':'\u2996','lurdshar':'\u294A','luruhar':'\u2966','lvertneqq':'\u2268\uFE00','lvnE':'\u2268\uFE00','macr':'\xAF','male':'\u2642','malt':'\u2720','maltese':'\u2720','map':'\u21A6','Map':'\u2905','mapsto':'\u21A6','mapstodown':'\u21A7','mapstoleft':'\u21A4','mapstoup':'\u21A5','marker':'\u25AE','mcomma':'\u2A29','mcy':'\u043C','Mcy':'\u041C','mdash':'\u2014','mDDot':'\u223A','measuredangle':'\u2221','MediumSpace':'\u205F','Mellintrf':'\u2133','mfr':'\uD835\uDD2A','Mfr':'\uD835\uDD10','mho':'\u2127','micro':'\xB5','mid':'\u2223','midast':'*','midcir':'\u2AF0','middot':'\xB7','minus':'\u2212','minusb':'\u229F','minusd':'\u2238','minusdu':'\u2A2A','MinusPlus':'\u2213','mlcp':'\u2ADB','mldr':'\u2026','mnplus':'\u2213','models':'\u22A7','mopf':'\uD835\uDD5E','Mopf':'\uD835\uDD44','mp':'\u2213','mscr':'\uD835\uDCC2','Mscr':'\u2133','mstpos':'\u223E','mu':'\u03BC','Mu':'\u039C','multimap':'\u22B8','mumap':'\u22B8','nabla':'\u2207','nacute':'\u0144','Nacute':'\u0143','nang':'\u2220\u20D2','nap':'\u2249','napE':'\u2A70\u0338','napid':'\u224B\u0338','napos':'\u0149','napprox':'\u2249','natur':'\u266E','natural':'\u266E','naturals':'\u2115','nbsp':'\xA0','nbump':'\u224E\u0338','nbumpe':'\u224F\u0338','ncap':'\u2A43','ncaron':'\u0148','Ncaron':'\u0147','ncedil':'\u0146','Ncedil':'\u0145','ncong':'\u2247','ncongdot':'\u2A6D\u0338','ncup':'\u2A42','ncy':'\u043D','Ncy':'\u041D','ndash':'\u2013','ne':'\u2260','nearhk':'\u2924','nearr':'\u2197','neArr':'\u21D7','nearrow':'\u2197','nedot':'\u2250\u0338','NegativeMediumSpace':'\u200B','NegativeThickSpace':'\u200B','NegativeThinSpace':'\u200B','NegativeVeryThinSpace':'\u200B','nequiv':'\u2262','nesear':'\u2928','nesim':'\u2242\u0338','NestedGreaterGreater':'\u226B','NestedLessLess':'\u226A','NewLine':'\n','nexist':'\u2204','nexists':'\u2204','nfr':'\uD835\uDD2B','Nfr':'\uD835\uDD11','nge':'\u2271','ngE':'\u2267\u0338','ngeq':'\u2271','ngeqq':'\u2267\u0338','ngeqslant':'\u2A7E\u0338','nges':'\u2A7E\u0338','nGg':'\u22D9\u0338','ngsim':'\u2275','ngt':'\u226F','nGt':'\u226B\u20D2','ngtr':'\u226F','nGtv':'\u226B\u0338','nharr':'\u21AE','nhArr':'\u21CE','nhpar':'\u2AF2','ni':'\u220B','nis':'\u22FC','nisd':'\u22FA','niv':'\u220B','njcy':'\u045A','NJcy':'\u040A','nlarr':'\u219A','nlArr':'\u21CD','nldr':'\u2025','nle':'\u2270','nlE':'\u2266\u0338','nleftarrow':'\u219A','nLeftarrow':'\u21CD','nleftrightarrow':'\u21AE','nLeftrightarrow':'\u21CE','nleq':'\u2270','nleqq':'\u2266\u0338','nleqslant':'\u2A7D\u0338','nles':'\u2A7D\u0338','nless':'\u226E','nLl':'\u22D8\u0338','nlsim':'\u2274','nlt':'\u226E','nLt':'\u226A\u20D2','nltri':'\u22EA','nltrie':'\u22EC','nLtv':'\u226A\u0338','nmid':'\u2224','NoBreak':'\u2060','NonBreakingSpace':'\xA0','nopf':'\uD835\uDD5F','Nopf':'\u2115','not':'\xAC','Not':'\u2AEC','NotCongruent':'\u2262','NotCupCap':'\u226D','NotDoubleVerticalBar':'\u2226','NotElement':'\u2209','NotEqual':'\u2260','NotEqualTilde':'\u2242\u0338','NotExists':'\u2204','NotGreater':'\u226F','NotGreaterEqual':'\u2271','NotGreaterFullEqual':'\u2267\u0338','NotGreaterGreater':'\u226B\u0338','NotGreaterLess':'\u2279','NotGreaterSlantEqual':'\u2A7E\u0338','NotGreaterTilde':'\u2275','NotHumpDownHump':'\u224E\u0338','NotHumpEqual':'\u224F\u0338','notin':'\u2209','notindot':'\u22F5\u0338','notinE':'\u22F9\u0338','notinva':'\u2209','notinvb':'\u22F7','notinvc':'\u22F6','NotLeftTriangle':'\u22EA','NotLeftTriangleBar':'\u29CF\u0338','NotLeftTriangleEqual':'\u22EC','NotLess':'\u226E','NotLessEqual':'\u2270','NotLessGreater':'\u2278','NotLessLess':'\u226A\u0338','NotLessSlantEqual':'\u2A7D\u0338','NotLessTilde':'\u2274','NotNestedGreaterGreater':'\u2AA2\u0338','NotNestedLessLess':'\u2AA1\u0338','notni':'\u220C','notniva':'\u220C','notnivb':'\u22FE','notnivc':'\u22FD','NotPrecedes':'\u2280','NotPrecedesEqual':'\u2AAF\u0338','NotPrecedesSlantEqual':'\u22E0','NotReverseElement':'\u220C','NotRightTriangle':'\u22EB','NotRightTriangleBar':'\u29D0\u0338','NotRightTriangleEqual':'\u22ED','NotSquareSubset':'\u228F\u0338','NotSquareSubsetEqual':'\u22E2','NotSquareSuperset':'\u2290\u0338','NotSquareSupersetEqual':'\u22E3','NotSubset':'\u2282\u20D2','NotSubsetEqual':'\u2288','NotSucceeds':'\u2281','NotSucceedsEqual':'\u2AB0\u0338','NotSucceedsSlantEqual':'\u22E1','NotSucceedsTilde':'\u227F\u0338','NotSuperset':'\u2283\u20D2','NotSupersetEqual':'\u2289','NotTilde':'\u2241','NotTildeEqual':'\u2244','NotTildeFullEqual':'\u2247','NotTildeTilde':'\u2249','NotVerticalBar':'\u2224','npar':'\u2226','nparallel':'\u2226','nparsl':'\u2AFD\u20E5','npart':'\u2202\u0338','npolint':'\u2A14','npr':'\u2280','nprcue':'\u22E0','npre':'\u2AAF\u0338','nprec':'\u2280','npreceq':'\u2AAF\u0338','nrarr':'\u219B','nrArr':'\u21CF','nrarrc':'\u2933\u0338','nrarrw':'\u219D\u0338','nrightarrow':'\u219B','nRightarrow':'\u21CF','nrtri':'\u22EB','nrtrie':'\u22ED','nsc':'\u2281','nsccue':'\u22E1','nsce':'\u2AB0\u0338','nscr':'\uD835\uDCC3','Nscr':'\uD835\uDCA9','nshortmid':'\u2224','nshortparallel':'\u2226','nsim':'\u2241','nsime':'\u2244','nsimeq':'\u2244','nsmid':'\u2224','nspar':'\u2226','nsqsube':'\u22E2','nsqsupe':'\u22E3','nsub':'\u2284','nsube':'\u2288','nsubE':'\u2AC5\u0338','nsubset':'\u2282\u20D2','nsubseteq':'\u2288','nsubseteqq':'\u2AC5\u0338','nsucc':'\u2281','nsucceq':'\u2AB0\u0338','nsup':'\u2285','nsupe':'\u2289','nsupE':'\u2AC6\u0338','nsupset':'\u2283\u20D2','nsupseteq':'\u2289','nsupseteqq':'\u2AC6\u0338','ntgl':'\u2279','ntilde':'\xF1','Ntilde':'\xD1','ntlg':'\u2278','ntriangleleft':'\u22EA','ntrianglelefteq':'\u22EC','ntriangleright':'\u22EB','ntrianglerighteq':'\u22ED','nu':'\u03BD','Nu':'\u039D','num':'#','numero':'\u2116','numsp':'\u2007','nvap':'\u224D\u20D2','nvdash':'\u22AC','nvDash':'\u22AD','nVdash':'\u22AE','nVDash':'\u22AF','nvge':'\u2265\u20D2','nvgt':'>\u20D2','nvHarr':'\u2904','nvinfin':'\u29DE','nvlArr':'\u2902','nvle':'\u2264\u20D2','nvlt':'<\u20D2','nvltrie':'\u22B4\u20D2','nvrArr':'\u2903','nvrtrie':'\u22B5\u20D2','nvsim':'\u223C\u20D2','nwarhk':'\u2923','nwarr':'\u2196','nwArr':'\u21D6','nwarrow':'\u2196','nwnear':'\u2927','oacute':'\xF3','Oacute':'\xD3','oast':'\u229B','ocir':'\u229A','ocirc':'\xF4','Ocirc':'\xD4','ocy':'\u043E','Ocy':'\u041E','odash':'\u229D','odblac':'\u0151','Odblac':'\u0150','odiv':'\u2A38','odot':'\u2299','odsold':'\u29BC','oelig':'\u0153','OElig':'\u0152','ofcir':'\u29BF','ofr':'\uD835\uDD2C','Ofr':'\uD835\uDD12','ogon':'\u02DB','ograve':'\xF2','Ograve':'\xD2','ogt':'\u29C1','ohbar':'\u29B5','ohm':'\u03A9','oint':'\u222E','olarr':'\u21BA','olcir':'\u29BE','olcross':'\u29BB','oline':'\u203E','olt':'\u29C0','omacr':'\u014D','Omacr':'\u014C','omega':'\u03C9','Omega':'\u03A9','omicron':'\u03BF','Omicron':'\u039F','omid':'\u29B6','ominus':'\u2296','oopf':'\uD835\uDD60','Oopf':'\uD835\uDD46','opar':'\u29B7','OpenCurlyDoubleQuote':'\u201C','OpenCurlyQuote':'\u2018','operp':'\u29B9','oplus':'\u2295','or':'\u2228','Or':'\u2A54','orarr':'\u21BB','ord':'\u2A5D','order':'\u2134','orderof':'\u2134','ordf':'\xAA','ordm':'\xBA','origof':'\u22B6','oror':'\u2A56','orslope':'\u2A57','orv':'\u2A5B','oS':'\u24C8','oscr':'\u2134','Oscr':'\uD835\uDCAA','oslash':'\xF8','Oslash':'\xD8','osol':'\u2298','otilde':'\xF5','Otilde':'\xD5','otimes':'\u2297','Otimes':'\u2A37','otimesas':'\u2A36','ouml':'\xF6','Ouml':'\xD6','ovbar':'\u233D','OverBar':'\u203E','OverBrace':'\u23DE','OverBracket':'\u23B4','OverParenthesis':'\u23DC','par':'\u2225','para':'\xB6','parallel':'\u2225','parsim':'\u2AF3','parsl':'\u2AFD','part':'\u2202','PartialD':'\u2202','pcy':'\u043F','Pcy':'\u041F','percnt':'%','period':'.','permil':'\u2030','perp':'\u22A5','pertenk':'\u2031','pfr':'\uD835\uDD2D','Pfr':'\uD835\uDD13','phi':'\u03C6','Phi':'\u03A6','phiv':'\u03D5','phmmat':'\u2133','phone':'\u260E','pi':'\u03C0','Pi':'\u03A0','pitchfork':'\u22D4','piv':'\u03D6','planck':'\u210F','planckh':'\u210E','plankv':'\u210F','plus':'+','plusacir':'\u2A23','plusb':'\u229E','pluscir':'\u2A22','plusdo':'\u2214','plusdu':'\u2A25','pluse':'\u2A72','PlusMinus':'\xB1','plusmn':'\xB1','plussim':'\u2A26','plustwo':'\u2A27','pm':'\xB1','Poincareplane':'\u210C','pointint':'\u2A15','popf':'\uD835\uDD61','Popf':'\u2119','pound':'\xA3','pr':'\u227A','Pr':'\u2ABB','prap':'\u2AB7','prcue':'\u227C','pre':'\u2AAF','prE':'\u2AB3','prec':'\u227A','precapprox':'\u2AB7','preccurlyeq':'\u227C','Precedes':'\u227A','PrecedesEqual':'\u2AAF','PrecedesSlantEqual':'\u227C','PrecedesTilde':'\u227E','preceq':'\u2AAF','precnapprox':'\u2AB9','precneqq':'\u2AB5','precnsim':'\u22E8','precsim':'\u227E','prime':'\u2032','Prime':'\u2033','primes':'\u2119','prnap':'\u2AB9','prnE':'\u2AB5','prnsim':'\u22E8','prod':'\u220F','Product':'\u220F','profalar':'\u232E','profline':'\u2312','profsurf':'\u2313','prop':'\u221D','Proportion':'\u2237','Proportional':'\u221D','propto':'\u221D','prsim':'\u227E','prurel':'\u22B0','pscr':'\uD835\uDCC5','Pscr':'\uD835\uDCAB','psi':'\u03C8','Psi':'\u03A8','puncsp':'\u2008','qfr':'\uD835\uDD2E','Qfr':'\uD835\uDD14','qint':'\u2A0C','qopf':'\uD835\uDD62','Qopf':'\u211A','qprime':'\u2057','qscr':'\uD835\uDCC6','Qscr':'\uD835\uDCAC','quaternions':'\u210D','quatint':'\u2A16','quest':'?','questeq':'\u225F','quot':'"','QUOT':'"','rAarr':'\u21DB','race':'\u223D\u0331','racute':'\u0155','Racute':'\u0154','radic':'\u221A','raemptyv':'\u29B3','rang':'\u27E9','Rang':'\u27EB','rangd':'\u2992','range':'\u29A5','rangle':'\u27E9','raquo':'\xBB','rarr':'\u2192','rArr':'\u21D2','Rarr':'\u21A0','rarrap':'\u2975','rarrb':'\u21E5','rarrbfs':'\u2920','rarrc':'\u2933','rarrfs':'\u291E','rarrhk':'\u21AA','rarrlp':'\u21AC','rarrpl':'\u2945','rarrsim':'\u2974','rarrtl':'\u21A3','Rarrtl':'\u2916','rarrw':'\u219D','ratail':'\u291A','rAtail':'\u291C','ratio':'\u2236','rationals':'\u211A','rbarr':'\u290D','rBarr':'\u290F','RBarr':'\u2910','rbbrk':'\u2773','rbrace':'}','rbrack':']','rbrke':'\u298C','rbrksld':'\u298E','rbrkslu':'\u2990','rcaron':'\u0159','Rcaron':'\u0158','rcedil':'\u0157','Rcedil':'\u0156','rceil':'\u2309','rcub':'}','rcy':'\u0440','Rcy':'\u0420','rdca':'\u2937','rdldhar':'\u2969','rdquo':'\u201D','rdquor':'\u201D','rdsh':'\u21B3','Re':'\u211C','real':'\u211C','realine':'\u211B','realpart':'\u211C','reals':'\u211D','rect':'\u25AD','reg':'\xAE','REG':'\xAE','ReverseElement':'\u220B','ReverseEquilibrium':'\u21CB','ReverseUpEquilibrium':'\u296F','rfisht':'\u297D','rfloor':'\u230B','rfr':'\uD835\uDD2F','Rfr':'\u211C','rHar':'\u2964','rhard':'\u21C1','rharu':'\u21C0','rharul':'\u296C','rho':'\u03C1','Rho':'\u03A1','rhov':'\u03F1','RightAngleBracket':'\u27E9','rightarrow':'\u2192','Rightarrow':'\u21D2','RightArrow':'\u2192','RightArrowBar':'\u21E5','RightArrowLeftArrow':'\u21C4','rightarrowtail':'\u21A3','RightCeiling':'\u2309','RightDoubleBracket':'\u27E7','RightDownTeeVector':'\u295D','RightDownVector':'\u21C2','RightDownVectorBar':'\u2955','RightFloor':'\u230B','rightharpoondown':'\u21C1','rightharpoonup':'\u21C0','rightleftarrows':'\u21C4','rightleftharpoons':'\u21CC','rightrightarrows':'\u21C9','rightsquigarrow':'\u219D','RightTee':'\u22A2','RightTeeArrow':'\u21A6','RightTeeVector':'\u295B','rightthreetimes':'\u22CC','RightTriangle':'\u22B3','RightTriangleBar':'\u29D0','RightTriangleEqual':'\u22B5','RightUpDownVector':'\u294F','RightUpTeeVector':'\u295C','RightUpVector':'\u21BE','RightUpVectorBar':'\u2954','RightVector':'\u21C0','RightVectorBar':'\u2953','ring':'\u02DA','risingdotseq':'\u2253','rlarr':'\u21C4','rlhar':'\u21CC','rlm':'\u200F','rmoust':'\u23B1','rmoustache':'\u23B1','rnmid':'\u2AEE','roang':'\u27ED','roarr':'\u21FE','robrk':'\u27E7','ropar':'\u2986','ropf':'\uD835\uDD63','Ropf':'\u211D','roplus':'\u2A2E','rotimes':'\u2A35','RoundImplies':'\u2970','rpar':')','rpargt':'\u2994','rppolint':'\u2A12','rrarr':'\u21C9','Rrightarrow':'\u21DB','rsaquo':'\u203A','rscr':'\uD835\uDCC7','Rscr':'\u211B','rsh':'\u21B1','Rsh':'\u21B1','rsqb':']','rsquo':'\u2019','rsquor':'\u2019','rthree':'\u22CC','rtimes':'\u22CA','rtri':'\u25B9','rtrie':'\u22B5','rtrif':'\u25B8','rtriltri':'\u29CE','RuleDelayed':'\u29F4','ruluhar':'\u2968','rx':'\u211E','sacute':'\u015B','Sacute':'\u015A','sbquo':'\u201A','sc':'\u227B','Sc':'\u2ABC','scap':'\u2AB8','scaron':'\u0161','Scaron':'\u0160','sccue':'\u227D','sce':'\u2AB0','scE':'\u2AB4','scedil':'\u015F','Scedil':'\u015E','scirc':'\u015D','Scirc':'\u015C','scnap':'\u2ABA','scnE':'\u2AB6','scnsim':'\u22E9','scpolint':'\u2A13','scsim':'\u227F','scy':'\u0441','Scy':'\u0421','sdot':'\u22C5','sdotb':'\u22A1','sdote':'\u2A66','searhk':'\u2925','searr':'\u2198','seArr':'\u21D8','searrow':'\u2198','sect':'\xA7','semi':';','seswar':'\u2929','setminus':'\u2216','setmn':'\u2216','sext':'\u2736','sfr':'\uD835\uDD30','Sfr':'\uD835\uDD16','sfrown':'\u2322','sharp':'\u266F','shchcy':'\u0449','SHCHcy':'\u0429','shcy':'\u0448','SHcy':'\u0428','ShortDownArrow':'\u2193','ShortLeftArrow':'\u2190','shortmid':'\u2223','shortparallel':'\u2225','ShortRightArrow':'\u2192','ShortUpArrow':'\u2191','shy':'\xAD','sigma':'\u03C3','Sigma':'\u03A3','sigmaf':'\u03C2','sigmav':'\u03C2','sim':'\u223C','simdot':'\u2A6A','sime':'\u2243','simeq':'\u2243','simg':'\u2A9E','simgE':'\u2AA0','siml':'\u2A9D','simlE':'\u2A9F','simne':'\u2246','simplus':'\u2A24','simrarr':'\u2972','slarr':'\u2190','SmallCircle':'\u2218','smallsetminus':'\u2216','smashp':'\u2A33','smeparsl':'\u29E4','smid':'\u2223','smile':'\u2323','smt':'\u2AAA','smte':'\u2AAC','smtes':'\u2AAC\uFE00','softcy':'\u044C','SOFTcy':'\u042C','sol':'/','solb':'\u29C4','solbar':'\u233F','sopf':'\uD835\uDD64','Sopf':'\uD835\uDD4A','spades':'\u2660','spadesuit':'\u2660','spar':'\u2225','sqcap':'\u2293','sqcaps':'\u2293\uFE00','sqcup':'\u2294','sqcups':'\u2294\uFE00','Sqrt':'\u221A','sqsub':'\u228F','sqsube':'\u2291','sqsubset':'\u228F','sqsubseteq':'\u2291','sqsup':'\u2290','sqsupe':'\u2292','sqsupset':'\u2290','sqsupseteq':'\u2292','squ':'\u25A1','square':'\u25A1','Square':'\u25A1','SquareIntersection':'\u2293','SquareSubset':'\u228F','SquareSubsetEqual':'\u2291','SquareSuperset':'\u2290','SquareSupersetEqual':'\u2292','SquareUnion':'\u2294','squarf':'\u25AA','squf':'\u25AA','srarr':'\u2192','sscr':'\uD835\uDCC8','Sscr':'\uD835\uDCAE','ssetmn':'\u2216','ssmile':'\u2323','sstarf':'\u22C6','star':'\u2606','Star':'\u22C6','starf':'\u2605','straightepsilon':'\u03F5','straightphi':'\u03D5','strns':'\xAF','sub':'\u2282','Sub':'\u22D0','subdot':'\u2ABD','sube':'\u2286','subE':'\u2AC5','subedot':'\u2AC3','submult':'\u2AC1','subne':'\u228A','subnE':'\u2ACB','subplus':'\u2ABF','subrarr':'\u2979','subset':'\u2282','Subset':'\u22D0','subseteq':'\u2286','subseteqq':'\u2AC5','SubsetEqual':'\u2286','subsetneq':'\u228A','subsetneqq':'\u2ACB','subsim':'\u2AC7','subsub':'\u2AD5','subsup':'\u2AD3','succ':'\u227B','succapprox':'\u2AB8','succcurlyeq':'\u227D','Succeeds':'\u227B','SucceedsEqual':'\u2AB0','SucceedsSlantEqual':'\u227D','SucceedsTilde':'\u227F','succeq':'\u2AB0','succnapprox':'\u2ABA','succneqq':'\u2AB6','succnsim':'\u22E9','succsim':'\u227F','SuchThat':'\u220B','sum':'\u2211','Sum':'\u2211','sung':'\u266A','sup':'\u2283','Sup':'\u22D1','sup1':'\xB9','sup2':'\xB2','sup3':'\xB3','supdot':'\u2ABE','supdsub':'\u2AD8','supe':'\u2287','supE':'\u2AC6','supedot':'\u2AC4','Superset':'\u2283','SupersetEqual':'\u2287','suphsol':'\u27C9','suphsub':'\u2AD7','suplarr':'\u297B','supmult':'\u2AC2','supne':'\u228B','supnE':'\u2ACC','supplus':'\u2AC0','supset':'\u2283','Supset':'\u22D1','supseteq':'\u2287','supseteqq':'\u2AC6','supsetneq':'\u228B','supsetneqq':'\u2ACC','supsim':'\u2AC8','supsub':'\u2AD4','supsup':'\u2AD6','swarhk':'\u2926','swarr':'\u2199','swArr':'\u21D9','swarrow':'\u2199','swnwar':'\u292A','szlig':'\xDF','Tab':'\t','target':'\u2316','tau':'\u03C4','Tau':'\u03A4','tbrk':'\u23B4','tcaron':'\u0165','Tcaron':'\u0164','tcedil':'\u0163','Tcedil':'\u0162','tcy':'\u0442','Tcy':'\u0422','tdot':'\u20DB','telrec':'\u2315','tfr':'\uD835\uDD31','Tfr':'\uD835\uDD17','there4':'\u2234','therefore':'\u2234','Therefore':'\u2234','theta':'\u03B8','Theta':'\u0398','thetasym':'\u03D1','thetav':'\u03D1','thickapprox':'\u2248','thicksim':'\u223C','ThickSpace':'\u205F\u200A','thinsp':'\u2009','ThinSpace':'\u2009','thkap':'\u2248','thksim':'\u223C','thorn':'\xFE','THORN':'\xDE','tilde':'\u02DC','Tilde':'\u223C','TildeEqual':'\u2243','TildeFullEqual':'\u2245','TildeTilde':'\u2248','times':'\xD7','timesb':'\u22A0','timesbar':'\u2A31','timesd':'\u2A30','tint':'\u222D','toea':'\u2928','top':'\u22A4','topbot':'\u2336','topcir':'\u2AF1','topf':'\uD835\uDD65','Topf':'\uD835\uDD4B','topfork':'\u2ADA','tosa':'\u2929','tprime':'\u2034','trade':'\u2122','TRADE':'\u2122','triangle':'\u25B5','triangledown':'\u25BF','triangleleft':'\u25C3','trianglelefteq':'\u22B4','triangleq':'\u225C','triangleright':'\u25B9','trianglerighteq':'\u22B5','tridot':'\u25EC','trie':'\u225C','triminus':'\u2A3A','TripleDot':'\u20DB','triplus':'\u2A39','trisb':'\u29CD','tritime':'\u2A3B','trpezium':'\u23E2','tscr':'\uD835\uDCC9','Tscr':'\uD835\uDCAF','tscy':'\u0446','TScy':'\u0426','tshcy':'\u045B','TSHcy':'\u040B','tstrok':'\u0167','Tstrok':'\u0166','twixt':'\u226C','twoheadleftarrow':'\u219E','twoheadrightarrow':'\u21A0','uacute':'\xFA','Uacute':'\xDA','uarr':'\u2191','uArr':'\u21D1','Uarr':'\u219F','Uarrocir':'\u2949','ubrcy':'\u045E','Ubrcy':'\u040E','ubreve':'\u016D','Ubreve':'\u016C','ucirc':'\xFB','Ucirc':'\xDB','ucy':'\u0443','Ucy':'\u0423','udarr':'\u21C5','udblac':'\u0171','Udblac':'\u0170','udhar':'\u296E','ufisht':'\u297E','ufr':'\uD835\uDD32','Ufr':'\uD835\uDD18','ugrave':'\xF9','Ugrave':'\xD9','uHar':'\u2963','uharl':'\u21BF','uharr':'\u21BE','uhblk':'\u2580','ulcorn':'\u231C','ulcorner':'\u231C','ulcrop':'\u230F','ultri':'\u25F8','umacr':'\u016B','Umacr':'\u016A','uml':'\xA8','UnderBar':'_','UnderBrace':'\u23DF','UnderBracket':'\u23B5','UnderParenthesis':'\u23DD','Union':'\u22C3','UnionPlus':'\u228E','uogon':'\u0173','Uogon':'\u0172','uopf':'\uD835\uDD66','Uopf':'\uD835\uDD4C','uparrow':'\u2191','Uparrow':'\u21D1','UpArrow':'\u2191','UpArrowBar':'\u2912','UpArrowDownArrow':'\u21C5','updownarrow':'\u2195','Updownarrow':'\u21D5','UpDownArrow':'\u2195','UpEquilibrium':'\u296E','upharpoonleft':'\u21BF','upharpoonright':'\u21BE','uplus':'\u228E','UpperLeftArrow':'\u2196','UpperRightArrow':'\u2197','upsi':'\u03C5','Upsi':'\u03D2','upsih':'\u03D2','upsilon':'\u03C5','Upsilon':'\u03A5','UpTee':'\u22A5','UpTeeArrow':'\u21A5','upuparrows':'\u21C8','urcorn':'\u231D','urcorner':'\u231D','urcrop':'\u230E','uring':'\u016F','Uring':'\u016E','urtri':'\u25F9','uscr':'\uD835\uDCCA','Uscr':'\uD835\uDCB0','utdot':'\u22F0','utilde':'\u0169','Utilde':'\u0168','utri':'\u25B5','utrif':'\u25B4','uuarr':'\u21C8','uuml':'\xFC','Uuml':'\xDC','uwangle':'\u29A7','vangrt':'\u299C','varepsilon':'\u03F5','varkappa':'\u03F0','varnothing':'\u2205','varphi':'\u03D5','varpi':'\u03D6','varpropto':'\u221D','varr':'\u2195','vArr':'\u21D5','varrho':'\u03F1','varsigma':'\u03C2','varsubsetneq':'\u228A\uFE00','varsubsetneqq':'\u2ACB\uFE00','varsupsetneq':'\u228B\uFE00','varsupsetneqq':'\u2ACC\uFE00','vartheta':'\u03D1','vartriangleleft':'\u22B2','vartriangleright':'\u22B3','vBar':'\u2AE8','Vbar':'\u2AEB','vBarv':'\u2AE9','vcy':'\u0432','Vcy':'\u0412','vdash':'\u22A2','vDash':'\u22A8','Vdash':'\u22A9','VDash':'\u22AB','Vdashl':'\u2AE6','vee':'\u2228','Vee':'\u22C1','veebar':'\u22BB','veeeq':'\u225A','vellip':'\u22EE','verbar':'|','Verbar':'\u2016','vert':'|','Vert':'\u2016','VerticalBar':'\u2223','VerticalLine':'|','VerticalSeparator':'\u2758','VerticalTilde':'\u2240','VeryThinSpace':'\u200A','vfr':'\uD835\uDD33','Vfr':'\uD835\uDD19','vltri':'\u22B2','vnsub':'\u2282\u20D2','vnsup':'\u2283\u20D2','vopf':'\uD835\uDD67','Vopf':'\uD835\uDD4D','vprop':'\u221D','vrtri':'\u22B3','vscr':'\uD835\uDCCB','Vscr':'\uD835\uDCB1','vsubne':'\u228A\uFE00','vsubnE':'\u2ACB\uFE00','vsupne':'\u228B\uFE00','vsupnE':'\u2ACC\uFE00','Vvdash':'\u22AA','vzigzag':'\u299A','wcirc':'\u0175','Wcirc':'\u0174','wedbar':'\u2A5F','wedge':'\u2227','Wedge':'\u22C0','wedgeq':'\u2259','weierp':'\u2118','wfr':'\uD835\uDD34','Wfr':'\uD835\uDD1A','wopf':'\uD835\uDD68','Wopf':'\uD835\uDD4E','wp':'\u2118','wr':'\u2240','wreath':'\u2240','wscr':'\uD835\uDCCC','Wscr':'\uD835\uDCB2','xcap':'\u22C2','xcirc':'\u25EF','xcup':'\u22C3','xdtri':'\u25BD','xfr':'\uD835\uDD35','Xfr':'\uD835\uDD1B','xharr':'\u27F7','xhArr':'\u27FA','xi':'\u03BE','Xi':'\u039E','xlarr':'\u27F5','xlArr':'\u27F8','xmap':'\u27FC','xnis':'\u22FB','xodot':'\u2A00','xopf':'\uD835\uDD69','Xopf':'\uD835\uDD4F','xoplus':'\u2A01','xotime':'\u2A02','xrarr':'\u27F6','xrArr':'\u27F9','xscr':'\uD835\uDCCD','Xscr':'\uD835\uDCB3','xsqcup':'\u2A06','xuplus':'\u2A04','xutri':'\u25B3','xvee':'\u22C1','xwedge':'\u22C0','yacute':'\xFD','Yacute':'\xDD','yacy':'\u044F','YAcy':'\u042F','ycirc':'\u0177','Ycirc':'\u0176','ycy':'\u044B','Ycy':'\u042B','yen':'\xA5','yfr':'\uD835\uDD36','Yfr':'\uD835\uDD1C','yicy':'\u0457','YIcy':'\u0407','yopf':'\uD835\uDD6A','Yopf':'\uD835\uDD50','yscr':'\uD835\uDCCE','Yscr':'\uD835\uDCB4','yucy':'\u044E','YUcy':'\u042E','yuml':'\xFF','Yuml':'\u0178','zacute':'\u017A','Zacute':'\u0179','zcaron':'\u017E','Zcaron':'\u017D','zcy':'\u0437','Zcy':'\u0417','zdot':'\u017C','Zdot':'\u017B','zeetrf':'\u2128','ZeroWidthSpace':'\u200B','zeta':'\u03B6','Zeta':'\u0396','zfr':'\uD835\uDD37','Zfr':'\u2128','zhcy':'\u0436','ZHcy':'\u0416','zigrarr':'\u21DD','zopf':'\uD835\uDD6B','Zopf':'\u2124','zscr':'\uD835\uDCCF','Zscr':'\uD835\uDCB5','zwj':'\u200D','zwnj':'\u200C'};
var decodeMapLegacy = {'aacute':'\xE1','Aacute':'\xC1','acirc':'\xE2','Acirc':'\xC2','acute':'\xB4','aelig':'\xE6','AElig':'\xC6','agrave':'\xE0','Agrave':'\xC0','amp':'&','AMP':'&','aring':'\xE5','Aring':'\xC5','atilde':'\xE3','Atilde':'\xC3','auml':'\xE4','Auml':'\xC4','brvbar':'\xA6','ccedil':'\xE7','Ccedil':'\xC7','cedil':'\xB8','cent':'\xA2','copy':'\xA9','COPY':'\xA9','curren':'\xA4','deg':'\xB0','divide':'\xF7','eacute':'\xE9','Eacute':'\xC9','ecirc':'\xEA','Ecirc':'\xCA','egrave':'\xE8','Egrave':'\xC8','eth':'\xF0','ETH':'\xD0','euml':'\xEB','Euml':'\xCB','frac12':'\xBD','frac14':'\xBC','frac34':'\xBE','gt':'>','GT':'>','iacute':'\xED','Iacute':'\xCD','icirc':'\xEE','Icirc':'\xCE','iexcl':'\xA1','igrave':'\xEC','Igrave':'\xCC','iquest':'\xBF','iuml':'\xEF','Iuml':'\xCF','laquo':'\xAB','lt':'<','LT':'<','macr':'\xAF','micro':'\xB5','middot':'\xB7','nbsp':'\xA0','not':'\xAC','ntilde':'\xF1','Ntilde':'\xD1','oacute':'\xF3','Oacute':'\xD3','ocirc':'\xF4','Ocirc':'\xD4','ograve':'\xF2','Ograve':'\xD2','ordf':'\xAA','ordm':'\xBA','oslash':'\xF8','Oslash':'\xD8','otilde':'\xF5','Otilde':'\xD5','ouml':'\xF6','Ouml':'\xD6','para':'\xB6','plusmn':'\xB1','pound':'\xA3','quot':'"','QUOT':'"','raquo':'\xBB','reg':'\xAE','REG':'\xAE','sect':'\xA7','shy':'\xAD','sup1':'\xB9','sup2':'\xB2','sup3':'\xB3','szlig':'\xDF','thorn':'\xFE','THORN':'\xDE','times':'\xD7','uacute':'\xFA','Uacute':'\xDA','ucirc':'\xFB','Ucirc':'\xDB','ugrave':'\xF9','Ugrave':'\xD9','uml':'\xA8','uuml':'\xFC','Uuml':'\xDC','yacute':'\xFD','Yacute':'\xDD','yen':'\xA5','yuml':'\xFF'};
var decodeMapNumeric = {'0':'\uFFFD','128':'\u20AC','130':'\u201A','131':'\u0192','132':'\u201E','133':'\u2026','134':'\u2020','135':'\u2021','136':'\u02C6','137':'\u2030','138':'\u0160','139':'\u2039','140':'\u0152','142':'\u017D','145':'\u2018','146':'\u2019','147':'\u201C','148':'\u201D','149':'\u2022','150':'\u2013','151':'\u2014','152':'\u02DC','153':'\u2122','154':'\u0161','155':'\u203A','156':'\u0153','158':'\u017E','159':'\u0178'};
var invalidReferenceCodePoints = [1,2,3,4,5,6,7,8,11,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,64976,64977,64978,64979,64980,64981,64982,64983,64984,64985,64986,64987,64988,64989,64990,64991,64992,64993,64994,64995,64996,64997,64998,64999,65000,65001,65002,65003,65004,65005,65006,65007,65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111];
/*--------------------------------------------------------------------------*/
var stringFromCharCode = String.fromCharCode;
var object = {};
var hasOwnProperty = object.hasOwnProperty;
var has = function(object, propertyName) {
return hasOwnProperty.call(object, propertyName);
};
var contains = function(array, value) {
var index = -1;
var length = array.length;
while (++index < length) {
if (array[index] == value) {
return true;
}
}
return false;
};
var merge = function(options, defaults) {
if (!options) {
return defaults;
}
var result = {};
var key;
for (key in defaults) {
// A `hasOwnProperty` check is not needed here, since only recognized
// option names are used anyway. Any others are ignored.
result[key] = has(options, key) ? options[key] : defaults[key];
}
return result;
};
// Modified version of `ucs2encode`; see https://mths.be/punycode.
var codePointToSymbol = function(codePoint, strict) {
var output = '';
if ((codePoint >= 0xD800 && codePoint <= 0xDFFF) || codePoint > 0x10FFFF) {
// See issue #4:
// “Otherwise, if the number is in the range 0xD800 to 0xDFFF or is
// greater than 0x10FFFF, then this is a parse error. Return a U+FFFD
// REPLACEMENT CHARACTER.”
if (strict) {
parseError('character reference outside the permissible Unicode range');
}
return '\uFFFD';
}
if (has(decodeMapNumeric, codePoint)) {
if (strict) {
parseError('disallowed character reference');
}
return decodeMapNumeric[codePoint];
}
if (strict && contains(invalidReferenceCodePoints, codePoint)) {
parseError('disallowed character reference');
}
if (codePoint > 0xFFFF) {
codePoint -= 0x10000;
output += stringFromCharCode(codePoint >>> 10 & 0x3FF | 0xD800);
codePoint = 0xDC00 | codePoint & 0x3FF;
}
output += stringFromCharCode(codePoint);
return output;
};
var hexEscape = function(codePoint) {
return '&#x' + codePoint.toString(16).toUpperCase() + ';';
};
var decEscape = function(codePoint) {
return '&#' + codePoint + ';';
};
var parseError = function(message) {
throw Error('Parse error: ' + message);
};
/*--------------------------------------------------------------------------*/
var encode = function(string, options) {
options = merge(options, encode.options);
var strict = options.strict;
if (strict && regexInvalidRawCodePoint.test(string)) {
parseError('forbidden code point');
}
var encodeEverything = options.encodeEverything;
var useNamedReferences = options.useNamedReferences;
var allowUnsafeSymbols = options.allowUnsafeSymbols;
var escapeCodePoint = options.decimal ? decEscape : hexEscape;
var escapeBmpSymbol = function(symbol) {
return escapeCodePoint(symbol.charCodeAt(0));
};
if (encodeEverything) {
// Encode ASCII symbols.
string = string.replace(regexAsciiWhitelist, function(symbol) {
// Use named references if requested & possible.
if (useNamedReferences && has(encodeMap, symbol)) {
return '&' + encodeMap[symbol] + ';';
}
return escapeBmpSymbol(symbol);
});
// Shorten a few escapes that represent two symbols, of which at least one
// is within the ASCII range.
if (useNamedReferences) {
string = string
.replace(/&gt;\u20D2/g, '&nvgt;')
.replace(/&lt;\u20D2/g, '&nvlt;')
.replace(/&#x66;&#x6A;/g, '&fjlig;');
}
// Encode non-ASCII symbols.
if (useNamedReferences) {
// Encode non-ASCII symbols that can be replaced with a named reference.
string = string.replace(regexEncodeNonAscii, function(string) {
// Note: there is no need to check `has(encodeMap, string)` here.
return '&' + encodeMap[string] + ';';
});
}
// Note: any remaining non-ASCII symbols are handled outside of the `if`.
} else if (useNamedReferences) {
// Apply named character references.
// Encode `<>"'&` using named character references.
if (!allowUnsafeSymbols) {
string = string.replace(regexEscape, function(string) {
return '&' + encodeMap[string] + ';'; // no need to check `has()` here
});
}
// Shorten escapes that represent two symbols, of which at least one is
// `<>"'&`.
string = string
.replace(/&gt;\u20D2/g, '&nvgt;')
.replace(/&lt;\u20D2/g, '&nvlt;');
// Encode non-ASCII symbols that can be replaced with a named reference.
string = string.replace(regexEncodeNonAscii, function(string) {
// Note: there is no need to check `has(encodeMap, string)` here.
return '&' + encodeMap[string] + ';';
});
} else if (!allowUnsafeSymbols) {
// Encode `<>"'&` using hexadecimal escapes, now that theyre not handled
// using named character references.
string = string.replace(regexEscape, escapeBmpSymbol);
}
return string
// Encode astral symbols.
.replace(regexAstralSymbols, function($0) {
// https://mathiasbynens.be/notes/javascript-encoding#surrogate-formulae
var high = $0.charCodeAt(0);
var low = $0.charCodeAt(1);
var codePoint = (high - 0xD800) * 0x400 + low - 0xDC00 + 0x10000;
return escapeCodePoint(codePoint);
})
// Encode any remaining BMP symbols that are not printable ASCII symbols
// using a hexadecimal escape.
.replace(regexBmpWhitelist, escapeBmpSymbol);
};
// Expose default options (so they can be overridden globally).
encode.options = {
'allowUnsafeSymbols': false,
'encodeEverything': false,
'strict': false,
'useNamedReferences': false,
'decimal' : false
};
var decode = function(html, options) {
options = merge(options, decode.options);
var strict = options.strict;
if (strict && regexInvalidEntity.test(html)) {
parseError('malformed character reference');
}
return html.replace(regexDecode, function($0, $1, $2, $3, $4, $5, $6, $7, $8) {
var codePoint;
var semicolon;
var decDigits;
var hexDigits;
var reference;
var next;
if ($1) {
reference = $1;
// Note: there is no need to check `has(decodeMap, reference)`.
return decodeMap[reference];
}
if ($2) {
// Decode named character references without trailing `;`, e.g. `&amp`.
// This is only a parse error if it gets converted to `&`, or if it is
// followed by `=` in an attribute context.
reference = $2;
next = $3;
if (next && options.isAttributeValue) {
if (strict && next == '=') {
parseError('`&` did not start a character reference');
}
return $0;
} else {
if (strict) {
parseError(
'named character reference was not terminated by a semicolon'
);
}
// Note: there is no need to check `has(decodeMapLegacy, reference)`.
return decodeMapLegacy[reference] + (next || '');
}
}
if ($4) {
// Decode decimal escapes, e.g. `&#119558;`.
decDigits = $4;
semicolon = $5;
if (strict && !semicolon) {
parseError('character reference was not terminated by a semicolon');
}
codePoint = parseInt(decDigits, 10);
return codePointToSymbol(codePoint, strict);
}
if ($6) {
// Decode hexadecimal escapes, e.g. `&#x1D306;`.
hexDigits = $6;
semicolon = $7;
if (strict && !semicolon) {
parseError('character reference was not terminated by a semicolon');
}
codePoint = parseInt(hexDigits, 16);
return codePointToSymbol(codePoint, strict);
}
// If were still here, `if ($7)` is implied; its an ambiguous
// ampersand for sure. https://mths.be/notes/ambiguous-ampersands
if (strict) {
parseError(
'named character reference was not terminated by a semicolon'
);
}
return $0;
});
};
// Expose default options (so they can be overridden globally).
decode.options = {
'isAttributeValue': false,
'strict': false
};
var escape = function(string) {
return string.replace(regexEscape, function($0) {
// Note: there is no need to check `has(escapeMap, $0)` here.
return escapeMap[$0];
});
};
/*--------------------------------------------------------------------------*/
var he = {
'version': '1.2.0',
'encode': encode,
'decode': decode,
'escape': escape,
'unescape': decode
};
// Some AMD build optimizers, like r.js, check for specific condition patterns
// like the following:
if (freeExports && !freeExports.nodeType) {
if (freeModule) { // in Node.js, io.js, or RingoJS v0.8.0+
freeModule.exports = he;
} else { // in Narwhal or RingoJS v0.7.0-
for (var key in he) {
has(he, key) && (freeExports[key] = he[key]);
}
}
} else { // in Rhino or a web browser
root.he = he;
}
}(commonjsGlobal));
});
var lib$2 = {
/**
* decode
* Decodes an encoded string.
*
* @name decode
* @function
* @param {String} input The encoded string.
* @returns {String} The decoded string.
*/
decode: function decode(input) {
return he.decode(input);
}
/**
* encode
* Encodes a string.
*
* @name encode
* @function
* @param {String} input The string that must be encoded.
* @returns {String} The encoded string.
*/
,
encode: function encode(input) {
return he.encode(input);
}
};
/* eslint-disable no-multi-assign */
function deepFreeze(obj) {
if (obj instanceof Map) {
obj.clear =
obj.delete =
obj.set =
function () {
throw new Error('map is read-only');
};
} else if (obj instanceof Set) {
obj.add =
obj.clear =
obj.delete =
function () {
throw new Error('set is read-only');
};
}
// Freeze self
Object.freeze(obj);
Object.getOwnPropertyNames(obj).forEach((name) => {
const prop = obj[name];
const type = typeof prop;
// Freeze prop if it is an object or function and also not already frozen
if ((type === 'object' || type === 'function') && !Object.isFrozen(prop)) {
deepFreeze(prop);
}
});
return obj;
}
/** @typedef {import('highlight.js').CallbackResponse} CallbackResponse */
/** @typedef {import('highlight.js').CompiledMode} CompiledMode */
/** @implements CallbackResponse */
class Response {
/**
* @param {CompiledMode} mode
*/
constructor(mode) {
// eslint-disable-next-line no-undefined
if (mode.data === undefined) mode.data = {};
this.data = mode.data;
this.isMatchIgnored = false;
}
ignoreMatch() {
this.isMatchIgnored = true;
}
}
/**
* @param {string} value
* @returns {string}
*/
function escapeHTML(value) {
return value
.replace(/&/g, '&amp;')
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;')
.replace(/"/g, '&quot;')
.replace(/'/g, '&#x27;');
}
/**
* performs a shallow merge of multiple objects into one
*
* @template T
* @param {T} original
* @param {Record<string,any>[]} objects
* @returns {T} a single new object
*/
function inherit$1(original, ...objects) {
/** @type Record<string,any> */
const result = Object.create(null);
for (const key in original) {
result[key] = original[key];
}
objects.forEach(function(obj) {
for (const key in obj) {
result[key] = obj[key];
}
});
return /** @type {T} */ (result);
}
/**
* @typedef {object} Renderer
* @property {(text: string) => void} addText
* @property {(node: Node) => void} openNode
* @property {(node: Node) => void} closeNode
* @property {() => string} value
*/
/** @typedef {{scope?: string, language?: string, sublanguage?: boolean}} Node */
/** @typedef {{walk: (r: Renderer) => void}} Tree */
/** */
const SPAN_CLOSE = '</span>';
/**
* Determines if a node needs to be wrapped in <span>
*
* @param {Node} node */
const emitsWrappingTags = (node) => {
// rarely we can have a sublanguage where language is undefined
// TODO: track down why
return !!node.scope;
};
/**
*
* @param {string} name
* @param {{prefix:string}} options
*/
const scopeToCSSClass = (name, { prefix }) => {
// sub-language
if (name.startsWith("language:")) {
return name.replace("language:", "language-");
}
// tiered scope: comment.line
if (name.includes(".")) {
const pieces = name.split(".");
return [
`${prefix}${pieces.shift()}`,
...(pieces.map((x, i) => `${x}${"_".repeat(i + 1)}`))
].join(" ");
}
// simple scope
return `${prefix}${name}`;
};
/** @type {Renderer} */
class HTMLRenderer {
/**
* Creates a new HTMLRenderer
*
* @param {Tree} parseTree - the parse tree (must support `walk` API)
* @param {{classPrefix: string}} options
*/
constructor(parseTree, options) {
this.buffer = "";
this.classPrefix = options.classPrefix;
parseTree.walk(this);
}
/**
* Adds texts to the output stream
*
* @param {string} text */
addText(text) {
this.buffer += escapeHTML(text);
}
/**
* Adds a node open to the output stream (if needed)
*
* @param {Node} node */
openNode(node) {
if (!emitsWrappingTags(node)) return;
const className = scopeToCSSClass(node.scope,
{ prefix: this.classPrefix });
this.span(className);
}
/**
* Adds a node close to the output stream (if needed)
*
* @param {Node} node */
closeNode(node) {
if (!emitsWrappingTags(node)) return;
this.buffer += SPAN_CLOSE;
}
/**
* returns the accumulated buffer
*/
value() {
return this.buffer;
}
// helpers
/**
* Builds a span element
*
* @param {string} className */
span(className) {
this.buffer += `<span class="${className}">`;
}
}
/** @typedef {{scope?: string, language?: string, children: Node[]} | string} Node */
/** @typedef {{scope?: string, language?: string, children: Node[]} } DataNode */
/** @typedef {import('highlight.js').Emitter} Emitter */
/** */
/** @returns {DataNode} */
const newNode = (opts = {}) => {
/** @type DataNode */
const result = { children: [] };
Object.assign(result, opts);
return result;
};
class TokenTree {
constructor() {
/** @type DataNode */
this.rootNode = newNode();
this.stack = [this.rootNode];
}
get top() {
return this.stack[this.stack.length - 1];
}
get root() { return this.rootNode; }
/** @param {Node} node */
add(node) {
this.top.children.push(node);
}
/** @param {string} scope */
openNode(scope) {
/** @type Node */
const node = newNode({ scope });
this.add(node);
this.stack.push(node);
}
closeNode() {
if (this.stack.length > 1) {
return this.stack.pop();
}
// eslint-disable-next-line no-undefined
return undefined;
}
closeAllNodes() {
while (this.closeNode());
}
toJSON() {
return JSON.stringify(this.rootNode, null, 4);
}
/**
* @typedef { import("./html_renderer").Renderer } Renderer
* @param {Renderer} builder
*/
walk(builder) {
// this does not
return this.constructor._walk(builder, this.rootNode);
// this works
// return TokenTree._walk(builder, this.rootNode);
}
/**
* @param {Renderer} builder
* @param {Node} node
*/
static _walk(builder, node) {
if (typeof node === "string") {
builder.addText(node);
} else if (node.children) {
builder.openNode(node);
node.children.forEach((child) => this._walk(builder, child));
builder.closeNode(node);
}
return builder;
}
/**
* @param {Node} node
*/
static _collapse(node) {
if (typeof node === "string") return;
if (!node.children) return;
if (node.children.every(el => typeof el === "string")) {
// node.text = node.children.join("");
// delete node.children;
node.children = [node.children.join("")];
} else {
node.children.forEach((child) => {
TokenTree._collapse(child);
});
}
}
}
/**
Currently this is all private API, but this is the minimal API necessary
that an Emitter must implement to fully support the parser.
Minimal interface:
- addText(text)
- __addSublanguage(emitter, subLanguageName)
- startScope(scope)
- endScope()
- finalize()
- toHTML()
*/
/**
* @implements {Emitter}
*/
class TokenTreeEmitter extends TokenTree {
/**
* @param {*} options
*/
constructor(options) {
super();
this.options = options;
}
/**
* @param {string} text
*/
addText(text) {
if (text === "") { return; }
this.add(text);
}
/** @param {string} scope */
startScope(scope) {
this.openNode(scope);
}
endScope() {
this.closeNode();
}
/**
* @param {Emitter & {root: DataNode}} emitter
* @param {string} name
*/
__addSublanguage(emitter, name) {
/** @type DataNode */
const node = emitter.root;
if (name) node.scope = `language:${name}`;
this.add(node);
}
toHTML() {
const renderer = new HTMLRenderer(this, this.options);
return renderer.value();
}
finalize() {
this.closeAllNodes();
return true;
}
}
/**
* @param {string} value
* @returns {RegExp}
* */
/**
* @param {RegExp | string } re
* @returns {string}
*/
function source$2(re) {
if (!re) return null;
if (typeof re === "string") return re;
return re.source;
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function lookahead$2(re) {
return concat$2('(?=', re, ')');
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function anyNumberOfTimes(re) {
return concat$2('(?:', re, ')*');
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function optional(re) {
return concat$2('(?:', re, ')?');
}
/**
* @param {...(RegExp | string) } args
* @returns {string}
*/
function concat$2(...args) {
const joined = args.map((x) => source$2(x)).join("");
return joined;
}
/**
* @param { Array<string | RegExp | Object> } args
* @returns {object}
*/
function stripOptionsFromArgs$2(args) {
const opts = args[args.length - 1];
if (typeof opts === 'object' && opts.constructor === Object) {
args.splice(args.length - 1, 1);
return opts;
} else {
return {};
}
}
/** @typedef { {capture?: boolean} } RegexEitherOptions */
/**
* Any of the passed expresssions may match
*
* Creates a huge this | this | that | that match
* @param {(RegExp | string)[] | [...(RegExp | string)[], RegexEitherOptions]} args
* @returns {string}
*/
function either$2(...args) {
/** @type { object & {capture?: boolean} } */
const opts = stripOptionsFromArgs$2(args);
const joined = '('
+ (opts.capture ? "" : "?:")
+ args.map((x) => source$2(x)).join("|") + ")";
return joined;
}
/**
* @param {RegExp | string} re
* @returns {number}
*/
function countMatchGroups(re) {
return (new RegExp(re.toString() + '|')).exec('').length - 1;
}
/**
* Does lexeme start with a regular expression match at the beginning
* @param {RegExp} re
* @param {string} lexeme
*/
function startsWith(re, lexeme) {
const match = re && re.exec(lexeme);
return match && match.index === 0;
}
// BACKREF_RE matches an open parenthesis or backreference. To avoid
// an incorrect parse, it additionally matches the following:
// - [...] elements, where the meaning of parentheses and escapes change
// - other escape sequences, so we do not misparse escape sequences as
// interesting elements
// - non-matching or lookahead parentheses, which do not capture. These
// follow the '(' with a '?'.
const BACKREF_RE = /\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;
// **INTERNAL** Not intended for outside usage
// join logically computes regexps.join(separator), but fixes the
// backreferences so they continue to match.
// it also places each individual regular expression into it's own
// match group, keeping track of the sequencing of those match groups
// is currently an exercise for the caller. :-)
/**
* @param {(string | RegExp)[]} regexps
* @param {{joinWith: string}} opts
* @returns {string}
*/
function _rewriteBackreferences(regexps, { joinWith }) {
let numCaptures = 0;
return regexps.map((regex) => {
numCaptures += 1;
const offset = numCaptures;
let re = source$2(regex);
let out = '';
while (re.length > 0) {
const match = BACKREF_RE.exec(re);
if (!match) {
out += re;
break;
}
out += re.substring(0, match.index);
re = re.substring(match.index + match[0].length);
if (match[0][0] === '\\' && match[1]) {
// Adjust the backreference.
out += '\\' + String(Number(match[1]) + offset);
} else {
out += match[0];
if (match[0] === '(') {
numCaptures++;
}
}
}
return out;
}).map(re => `(${re})`).join(joinWith);
}
/** @typedef {import('highlight.js').Mode} Mode */
/** @typedef {import('highlight.js').ModeCallback} ModeCallback */
// Common regexps
const MATCH_NOTHING_RE = /\b\B/;
const IDENT_RE$2 = '[a-zA-Z]\\w*';
const UNDERSCORE_IDENT_RE = '[a-zA-Z_]\\w*';
const NUMBER_RE = '\\b\\d+(\\.\\d+)?';
const C_NUMBER_RE = '(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)'; // 0x..., 0..., decimal, float
const BINARY_NUMBER_RE = '\\b(0b[01]+)'; // 0b...
const RE_STARTERS_RE = '!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~';
/**
* @param { Partial<Mode> & {binary?: string | RegExp} } opts
*/
const SHEBANG = (opts = {}) => {
const beginShebang = /^#![ ]*\//;
if (opts.binary) {
opts.begin = concat$2(
beginShebang,
/.*\b/,
opts.binary,
/\b.*/);
}
return inherit$1({
scope: 'meta',
begin: beginShebang,
end: /$/,
relevance: 0,
/** @type {ModeCallback} */
"on:begin": (m, resp) => {
if (m.index !== 0) resp.ignoreMatch();
}
}, opts);
};
// Common modes
const BACKSLASH_ESCAPE = {
begin: '\\\\[\\s\\S]', relevance: 0
};
const APOS_STRING_MODE = {
scope: 'string',
begin: '\'',
end: '\'',
illegal: '\\n',
contains: [BACKSLASH_ESCAPE]
};
const QUOTE_STRING_MODE = {
scope: 'string',
begin: '"',
end: '"',
illegal: '\\n',
contains: [BACKSLASH_ESCAPE]
};
const PHRASAL_WORDS_MODE = {
begin: /\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/
};
/**
* Creates a comment mode
*
* @param {string | RegExp} begin
* @param {string | RegExp} end
* @param {Mode | {}} [modeOptions]
* @returns {Partial<Mode>}
*/
const COMMENT = function(begin, end, modeOptions = {}) {
const mode = inherit$1(
{
scope: 'comment',
begin,
end,
contains: []
},
modeOptions
);
mode.contains.push({
scope: 'doctag',
// hack to avoid the space from being included. the space is necessary to
// match here to prevent the plain text rule below from gobbling up doctags
begin: '[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)',
end: /(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,
excludeBegin: true,
relevance: 0
});
const ENGLISH_WORD = either$2(
// list of common 1 and 2 letter words in English
"I",
"a",
"is",
"so",
"us",
"to",
"at",
"if",
"in",
"it",
"on",
// note: this is not an exhaustive list of contractions, just popular ones
/[A-Za-z]+['](d|ve|re|ll|t|s|n)/, // contractions - can't we'd they're let's, etc
/[A-Za-z]+[-][a-z]+/, // `no-way`, etc.
/[A-Za-z][a-z]{2,}/ // allow capitalized words at beginning of sentences
);
// looking like plain text, more likely to be a comment
mode.contains.push(
{
// TODO: how to include ", (, ) without breaking grammars that use these for
// comment delimiters?
// begin: /[ ]+([()"]?([A-Za-z'-]{3,}|is|a|I|so|us|[tT][oO]|at|if|in|it|on)[.]?[()":]?([.][ ]|[ ]|\))){3}/
// ---
// this tries to find sequences of 3 english words in a row (without any
// "programming" type syntax) this gives us a strong signal that we've
// TRULY found a comment - vs perhaps scanning with the wrong language.
// It's possible to find something that LOOKS like the start of the
// comment - but then if there is no readable text - good chance it is a
// false match and not a comment.
//
// for a visual example please see:
// https://github.com/highlightjs/highlight.js/issues/2827
begin: concat$2(
/[ ]+/, // necessary to prevent us gobbling up doctags like /* @author Bob Mcgill */
'(',
ENGLISH_WORD,
/[.]?[:]?([.][ ]|[ ])/,
'){3}') // look for 3 words in a row
}
);
return mode;
};
const C_LINE_COMMENT_MODE = COMMENT('//', '$');
const C_BLOCK_COMMENT_MODE = COMMENT('/\\*', '\\*/');
const HASH_COMMENT_MODE = COMMENT('#', '$');
const NUMBER_MODE = {
scope: 'number',
begin: NUMBER_RE,
relevance: 0
};
const C_NUMBER_MODE = {
scope: 'number',
begin: C_NUMBER_RE,
relevance: 0
};
const BINARY_NUMBER_MODE = {
scope: 'number',
begin: BINARY_NUMBER_RE,
relevance: 0
};
const REGEXP_MODE = {
scope: "regexp",
begin: /\/(?=[^/\n]*\/)/,
end: /\/[gimuy]*/,
contains: [
BACKSLASH_ESCAPE,
{
begin: /\[/,
end: /\]/,
relevance: 0,
contains: [BACKSLASH_ESCAPE]
}
]
};
const TITLE_MODE = {
scope: 'title',
begin: IDENT_RE$2,
relevance: 0
};
const UNDERSCORE_TITLE_MODE = {
scope: 'title',
begin: UNDERSCORE_IDENT_RE,
relevance: 0
};
const METHOD_GUARD = {
// excludes method names from keyword processing
begin: '\\.\\s*' + UNDERSCORE_IDENT_RE,
relevance: 0
};
/**
* Adds end same as begin mechanics to a mode
*
* Your mode must include at least a single () match group as that first match
* group is what is used for comparison
* @param {Partial<Mode>} mode
*/
const END_SAME_AS_BEGIN = function(mode) {
return Object.assign(mode,
{
/** @type {ModeCallback} */
'on:begin': (m, resp) => { resp.data._beginMatch = m[1]; },
/** @type {ModeCallback} */
'on:end': (m, resp) => { if (resp.data._beginMatch !== m[1]) resp.ignoreMatch(); }
});
};
var MODES$4 = /*#__PURE__*/Object.freeze({
__proto__: null,
APOS_STRING_MODE: APOS_STRING_MODE,
BACKSLASH_ESCAPE: BACKSLASH_ESCAPE,
BINARY_NUMBER_MODE: BINARY_NUMBER_MODE,
BINARY_NUMBER_RE: BINARY_NUMBER_RE,
COMMENT: COMMENT,
C_BLOCK_COMMENT_MODE: C_BLOCK_COMMENT_MODE,
C_LINE_COMMENT_MODE: C_LINE_COMMENT_MODE,
C_NUMBER_MODE: C_NUMBER_MODE,
C_NUMBER_RE: C_NUMBER_RE,
END_SAME_AS_BEGIN: END_SAME_AS_BEGIN,
HASH_COMMENT_MODE: HASH_COMMENT_MODE,
IDENT_RE: IDENT_RE$2,
MATCH_NOTHING_RE: MATCH_NOTHING_RE,
METHOD_GUARD: METHOD_GUARD,
NUMBER_MODE: NUMBER_MODE,
NUMBER_RE: NUMBER_RE,
PHRASAL_WORDS_MODE: PHRASAL_WORDS_MODE,
QUOTE_STRING_MODE: QUOTE_STRING_MODE,
REGEXP_MODE: REGEXP_MODE,
RE_STARTERS_RE: RE_STARTERS_RE,
SHEBANG: SHEBANG,
TITLE_MODE: TITLE_MODE,
UNDERSCORE_IDENT_RE: UNDERSCORE_IDENT_RE,
UNDERSCORE_TITLE_MODE: UNDERSCORE_TITLE_MODE
});
/**
@typedef {import('highlight.js').CallbackResponse} CallbackResponse
@typedef {import('highlight.js').CompilerExt} CompilerExt
*/
// Grammar extensions / plugins
// See: https://github.com/highlightjs/highlight.js/issues/2833
// Grammar extensions allow "syntactic sugar" to be added to the grammar modes
// without requiring any underlying changes to the compiler internals.
// `compileMatch` being the perfect small example of now allowing a grammar
// author to write `match` when they desire to match a single expression rather
// than being forced to use `begin`. The extension then just moves `match` into
// `begin` when it runs. Ie, no features have been added, but we've just made
// the experience of writing (and reading grammars) a little bit nicer.
// ------
// TODO: We need negative look-behind support to do this properly
/**
* Skip a match if it has a preceding dot
*
* This is used for `beginKeywords` to prevent matching expressions such as
* `bob.keyword.do()`. The mode compiler automatically wires this up as a
* special _internal_ 'on:begin' callback for modes with `beginKeywords`
* @param {RegExpMatchArray} match
* @param {CallbackResponse} response
*/
function skipIfHasPrecedingDot(match, response) {
const before = match.input[match.index - 1];
if (before === ".") {
response.ignoreMatch();
}
}
/**
*
* @type {CompilerExt}
*/
function scopeClassName(mode, _parent) {
// eslint-disable-next-line no-undefined
if (mode.className !== undefined) {
mode.scope = mode.className;
delete mode.className;
}
}
/**
* `beginKeywords` syntactic sugar
* @type {CompilerExt}
*/
function beginKeywords(mode, parent) {
if (!parent) return;
if (!mode.beginKeywords) return;
// for languages with keywords that include non-word characters checking for
// a word boundary is not sufficient, so instead we check for a word boundary
// or whitespace - this does no harm in any case since our keyword engine
// doesn't allow spaces in keywords anyways and we still check for the boundary
// first
mode.begin = '\\b(' + mode.beginKeywords.split(' ').join('|') + ')(?!\\.)(?=\\b|\\s)';
mode.__beforeBegin = skipIfHasPrecedingDot;
mode.keywords = mode.keywords || mode.beginKeywords;
delete mode.beginKeywords;
// prevents double relevance, the keywords themselves provide
// relevance, the mode doesn't need to double it
// eslint-disable-next-line no-undefined
if (mode.relevance === undefined) mode.relevance = 0;
}
/**
* Allow `illegal` to contain an array of illegal values
* @type {CompilerExt}
*/
function compileIllegal(mode, _parent) {
if (!Array.isArray(mode.illegal)) return;
mode.illegal = either$2(...mode.illegal);
}
/**
* `match` to match a single expression for readability
* @type {CompilerExt}
*/
function compileMatch(mode, _parent) {
if (!mode.match) return;
if (mode.begin || mode.end) throw new Error("begin & end are not supported with match");
mode.begin = mode.match;
delete mode.match;
}
/**
* provides the default 1 relevance to all modes
* @type {CompilerExt}
*/
function compileRelevance(mode, _parent) {
// eslint-disable-next-line no-undefined
if (mode.relevance === undefined) mode.relevance = 1;
}
// allow beforeMatch to act as a "qualifier" for the match
// the full match begin must be [beforeMatch][begin]
const beforeMatchExt = (mode, parent) => {
if (!mode.beforeMatch) return;
// starts conflicts with endsParent which we need to make sure the child
// rule is not matched multiple times
if (mode.starts) throw new Error("beforeMatch cannot be used with starts");
const originalMode = Object.assign({}, mode);
Object.keys(mode).forEach((key) => { delete mode[key]; });
mode.keywords = originalMode.keywords;
mode.begin = concat$2(originalMode.beforeMatch, lookahead$2(originalMode.begin));
mode.starts = {
relevance: 0,
contains: [
Object.assign(originalMode, { endsParent: true })
]
};
mode.relevance = 0;
delete originalMode.beforeMatch;
};
// keywords that should have no default relevance value
const COMMON_KEYWORDS = [
'of',
'and',
'for',
'in',
'not',
'or',
'if',
'then',
'parent', // common variable name
'list', // common variable name
'value' // common variable name
];
const DEFAULT_KEYWORD_SCOPE = "keyword";
/**
* Given raw keywords from a language definition, compile them.
*
* @param {string | Record<string,string|string[]> | Array<string>} rawKeywords
* @param {boolean} caseInsensitive
*/
function compileKeywords(rawKeywords, caseInsensitive, scopeName = DEFAULT_KEYWORD_SCOPE) {
/** @type {import("highlight.js/private").KeywordDict} */
const compiledKeywords = Object.create(null);
// input can be a string of keywords, an array of keywords, or a object with
// named keys representing scopeName (which can then point to a string or array)
if (typeof rawKeywords === 'string') {
compileList(scopeName, rawKeywords.split(" "));
} else if (Array.isArray(rawKeywords)) {
compileList(scopeName, rawKeywords);
} else {
Object.keys(rawKeywords).forEach(function(scopeName) {
// collapse all our objects back into the parent object
Object.assign(
compiledKeywords,
compileKeywords(rawKeywords[scopeName], caseInsensitive, scopeName)
);
});
}
return compiledKeywords;
// ---
/**
* Compiles an individual list of keywords
*
* Ex: "for if when while|5"
*
* @param {string} scopeName
* @param {Array<string>} keywordList
*/
function compileList(scopeName, keywordList) {
if (caseInsensitive) {
keywordList = keywordList.map(x => x.toLowerCase());
}
keywordList.forEach(function(keyword) {
const pair = keyword.split('|');
compiledKeywords[pair[0]] = [scopeName, scoreForKeyword(pair[0], pair[1])];
});
}
}
/**
* Returns the proper score for a given keyword
*
* Also takes into account comment keywords, which will be scored 0 UNLESS
* another score has been manually assigned.
* @param {string} keyword
* @param {string} [providedScore]
*/
function scoreForKeyword(keyword, providedScore) {
// manual scores always win over common keywords
// so you can force a score of 1 if you really insist
if (providedScore) {
return Number(providedScore);
}
return commonKeyword(keyword) ? 0 : 1;
}
/**
* Determines if a given keyword is common or not
*
* @param {string} keyword */
function commonKeyword(keyword) {
return COMMON_KEYWORDS.includes(keyword.toLowerCase());
}
/*
For the reasoning behind this please see:
https://github.com/highlightjs/highlight.js/issues/2880#issuecomment-747275419
*/
/**
* @type {Record<string, boolean>}
*/
const seenDeprecations = {};
/**
* @param {string} message
*/
const error = (message) => {
console.error(message);
};
/**
* @param {string} message
* @param {any} args
*/
const warn = (message, ...args) => {
console.log(`WARN: ${message}`, ...args);
};
/**
* @param {string} version
* @param {string} message
*/
const deprecated = (version, message) => {
if (seenDeprecations[`${version}/${message}`]) return;
console.log(`Deprecated as of ${version}. ${message}`);
seenDeprecations[`${version}/${message}`] = true;
};
/* eslint-disable no-throw-literal */
/**
@typedef {import('highlight.js').CompiledMode} CompiledMode
*/
const MultiClassError = new Error();
/**
* Renumbers labeled scope names to account for additional inner match
* groups that otherwise would break everything.
*
* Lets say we 3 match scopes:
*
* { 1 => ..., 2 => ..., 3 => ... }
*
* So what we need is a clean match like this:
*
* (a)(b)(c) => [ "a", "b", "c" ]
*
* But this falls apart with inner match groups:
*
* (a)(((b)))(c) => ["a", "b", "b", "b", "c" ]
*
* Our scopes are now "out of alignment" and we're repeating `b` 3 times.
* What needs to happen is the numbers are remapped:
*
* { 1 => ..., 2 => ..., 5 => ... }
*
* We also need to know that the ONLY groups that should be output
* are 1, 2, and 5. This function handles this behavior.
*
* @param {CompiledMode} mode
* @param {Array<RegExp | string>} regexes
* @param {{key: "beginScope"|"endScope"}} opts
*/
function remapScopeNames(mode, regexes, { key }) {
let offset = 0;
const scopeNames = mode[key];
/** @type Record<number,boolean> */
const emit = {};
/** @type Record<number,string> */
const positions = {};
for (let i = 1; i <= regexes.length; i++) {
positions[i + offset] = scopeNames[i];
emit[i + offset] = true;
offset += countMatchGroups(regexes[i - 1]);
}
// we use _emit to keep track of which match groups are "top-level" to avoid double
// output from inside match groups
mode[key] = positions;
mode[key]._emit = emit;
mode[key]._multi = true;
}
/**
* @param {CompiledMode} mode
*/
function beginMultiClass(mode) {
if (!Array.isArray(mode.begin)) return;
if (mode.skip || mode.excludeBegin || mode.returnBegin) {
error("skip, excludeBegin, returnBegin not compatible with beginScope: {}");
throw MultiClassError;
}
if (typeof mode.beginScope !== "object" || mode.beginScope === null) {
error("beginScope must be object");
throw MultiClassError;
}
remapScopeNames(mode, mode.begin, { key: "beginScope" });
mode.begin = _rewriteBackreferences(mode.begin, { joinWith: "" });
}
/**
* @param {CompiledMode} mode
*/
function endMultiClass(mode) {
if (!Array.isArray(mode.end)) return;
if (mode.skip || mode.excludeEnd || mode.returnEnd) {
error("skip, excludeEnd, returnEnd not compatible with endScope: {}");
throw MultiClassError;
}
if (typeof mode.endScope !== "object" || mode.endScope === null) {
error("endScope must be object");
throw MultiClassError;
}
remapScopeNames(mode, mode.end, { key: "endScope" });
mode.end = _rewriteBackreferences(mode.end, { joinWith: "" });
}
/**
* this exists only to allow `scope: {}` to be used beside `match:`
* Otherwise `beginScope` would necessary and that would look weird
{
match: [ /def/, /\w+/ ]
scope: { 1: "keyword" , 2: "title" }
}
* @param {CompiledMode} mode
*/
function scopeSugar(mode) {
if (mode.scope && typeof mode.scope === "object" && mode.scope !== null) {
mode.beginScope = mode.scope;
delete mode.scope;
}
}
/**
* @param {CompiledMode} mode
*/
function MultiClass(mode) {
scopeSugar(mode);
if (typeof mode.beginScope === "string") {
mode.beginScope = { _wrap: mode.beginScope };
}
if (typeof mode.endScope === "string") {
mode.endScope = { _wrap: mode.endScope };
}
beginMultiClass(mode);
endMultiClass(mode);
}
/**
@typedef {import('highlight.js').Mode} Mode
@typedef {import('highlight.js').CompiledMode} CompiledMode
@typedef {import('highlight.js').Language} Language
@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin
@typedef {import('highlight.js').CompiledLanguage} CompiledLanguage
*/
// compilation
/**
* Compiles a language definition result
*
* Given the raw result of a language definition (Language), compiles this so
* that it is ready for highlighting code.
* @param {Language} language
* @returns {CompiledLanguage}
*/
function compileLanguage(language) {
/**
* Builds a regex with the case sensitivity of the current language
*
* @param {RegExp | string} value
* @param {boolean} [global]
*/
function langRe(value, global) {
return new RegExp(
source$2(value),
'm'
+ (language.case_insensitive ? 'i' : '')
+ (language.unicodeRegex ? 'u' : '')
+ (global ? 'g' : '')
);
}
/**
Stores multiple regular expressions and allows you to quickly search for
them all in a string simultaneously - returning the first match. It does
this by creating a huge (a|b|c) regex - each individual item wrapped with ()
and joined by `|` - using match groups to track position. When a match is
found checking which position in the array has content allows us to figure
out which of the original regexes / match groups triggered the match.
The match object itself (the result of `Regex.exec`) is returned but also
enhanced by merging in any meta-data that was registered with the regex.
This is how we keep track of which mode matched, and what type of rule
(`illegal`, `begin`, end, etc).
*/
class MultiRegex {
constructor() {
this.matchIndexes = {};
// @ts-ignore
this.regexes = [];
this.matchAt = 1;
this.position = 0;
}
// @ts-ignore
addRule(re, opts) {
opts.position = this.position++;
// @ts-ignore
this.matchIndexes[this.matchAt] = opts;
this.regexes.push([opts, re]);
this.matchAt += countMatchGroups(re) + 1;
}
compile() {
if (this.regexes.length === 0) {
// avoids the need to check length every time exec is called
// @ts-ignore
this.exec = () => null;
}
const terminators = this.regexes.map(el => el[1]);
this.matcherRe = langRe(_rewriteBackreferences(terminators, { joinWith: '|' }), true);
this.lastIndex = 0;
}
/** @param {string} s */
exec(s) {
this.matcherRe.lastIndex = this.lastIndex;
const match = this.matcherRe.exec(s);
if (!match) { return null; }
// eslint-disable-next-line no-undefined
const i = match.findIndex((el, i) => i > 0 && el !== undefined);
// @ts-ignore
const matchData = this.matchIndexes[i];
// trim off any earlier non-relevant match groups (ie, the other regex
// match groups that make up the multi-matcher)
match.splice(0, i);
return Object.assign(match, matchData);
}
}
/*
Created to solve the key deficiently with MultiRegex - there is no way to
test for multiple matches at a single location. Why would we need to do
that? In the future a more dynamic engine will allow certain matches to be
ignored. An example: if we matched say the 3rd regex in a large group but
decided to ignore it - we'd need to started testing again at the 4th
regex... but MultiRegex itself gives us no real way to do that.
So what this class creates MultiRegexs on the fly for whatever search
position they are needed.
NOTE: These additional MultiRegex objects are created dynamically. For most
grammars most of the time we will never actually need anything more than the
first MultiRegex - so this shouldn't have too much overhead.
Say this is our search group, and we match regex3, but wish to ignore it.
regex1 | regex2 | regex3 | regex4 | regex5 ' ie, startAt = 0
What we need is a new MultiRegex that only includes the remaining
possibilities:
regex4 | regex5 ' ie, startAt = 3
This class wraps all that complexity up in a simple API... `startAt` decides
where in the array of expressions to start doing the matching. It
auto-increments, so if a match is found at position 2, then startAt will be
set to 3. If the end is reached startAt will return to 0.
MOST of the time the parser will be setting startAt manually to 0.
*/
class ResumableMultiRegex {
constructor() {
// @ts-ignore
this.rules = [];
// @ts-ignore
this.multiRegexes = [];
this.count = 0;
this.lastIndex = 0;
this.regexIndex = 0;
}
// @ts-ignore
getMatcher(index) {
if (this.multiRegexes[index]) return this.multiRegexes[index];
const matcher = new MultiRegex();
this.rules.slice(index).forEach(([re, opts]) => matcher.addRule(re, opts));
matcher.compile();
this.multiRegexes[index] = matcher;
return matcher;
}
resumingScanAtSamePosition() {
return this.regexIndex !== 0;
}
considerAll() {
this.regexIndex = 0;
}
// @ts-ignore
addRule(re, opts) {
this.rules.push([re, opts]);
if (opts.type === "begin") this.count++;
}
/** @param {string} s */
exec(s) {
const m = this.getMatcher(this.regexIndex);
m.lastIndex = this.lastIndex;
let result = m.exec(s);
// The following is because we have no easy way to say "resume scanning at the
// existing position but also skip the current rule ONLY". What happens is
// all prior rules are also skipped which can result in matching the wrong
// thing. Example of matching "booger":
// our matcher is [string, "booger", number]
//
// ....booger....
// if "booger" is ignored then we'd really need a regex to scan from the
// SAME position for only: [string, number] but ignoring "booger" (if it
// was the first match), a simple resume would scan ahead who knows how
// far looking only for "number", ignoring potential string matches (or
// future "booger" matches that might be valid.)
// So what we do: We execute two matchers, one resuming at the same
// position, but the second full matcher starting at the position after:
// /--- resume first regex match here (for [number])
// |/---- full match here for [string, "booger", number]
// vv
// ....booger....
// Which ever results in a match first is then used. So this 3-4 step
// process essentially allows us to say "match at this position, excluding
// a prior rule that was ignored".
//
// 1. Match "booger" first, ignore. Also proves that [string] does non match.
// 2. Resume matching for [number]
// 3. Match at index + 1 for [string, "booger", number]
// 4. If #2 and #3 result in matches, which came first?
if (this.resumingScanAtSamePosition()) {
if (result && result.index === this.lastIndex) ; else { // use the second matcher result
const m2 = this.getMatcher(0);
m2.lastIndex = this.lastIndex + 1;
result = m2.exec(s);
}
}
if (result) {
this.regexIndex += result.position + 1;
if (this.regexIndex === this.count) {
// wrap-around to considering all matches again
this.considerAll();
}
}
return result;
}
}
/**
* Given a mode, builds a huge ResumableMultiRegex that can be used to walk
* the content and find matches.
*
* @param {CompiledMode} mode
* @returns {ResumableMultiRegex}
*/
function buildModeRegex(mode) {
const mm = new ResumableMultiRegex();
mode.contains.forEach(term => mm.addRule(term.begin, { rule: term, type: "begin" }));
if (mode.terminatorEnd) {
mm.addRule(mode.terminatorEnd, { type: "end" });
}
if (mode.illegal) {
mm.addRule(mode.illegal, { type: "illegal" });
}
return mm;
}
/** skip vs abort vs ignore
*
* @skip - The mode is still entered and exited normally (and contains rules apply),
* but all content is held and added to the parent buffer rather than being
* output when the mode ends. Mostly used with `sublanguage` to build up
* a single large buffer than can be parsed by sublanguage.
*
* - The mode begin ands ends normally.
* - Content matched is added to the parent mode buffer.
* - The parser cursor is moved forward normally.
*
* @abort - A hack placeholder until we have ignore. Aborts the mode (as if it
* never matched) but DOES NOT continue to match subsequent `contains`
* modes. Abort is bad/suboptimal because it can result in modes
* farther down not getting applied because an earlier rule eats the
* content but then aborts.
*
* - The mode does not begin.
* - Content matched by `begin` is added to the mode buffer.
* - The parser cursor is moved forward accordingly.
*
* @ignore - Ignores the mode (as if it never matched) and continues to match any
* subsequent `contains` modes. Ignore isn't technically possible with
* the current parser implementation.
*
* - The mode does not begin.
* - Content matched by `begin` is ignored.
* - The parser cursor is not moved forward.
*/
/**
* Compiles an individual mode
*
* This can raise an error if the mode contains certain detectable known logic
* issues.
* @param {Mode} mode
* @param {CompiledMode | null} [parent]
* @returns {CompiledMode | never}
*/
function compileMode(mode, parent) {
const cmode = /** @type CompiledMode */ (mode);
if (mode.isCompiled) return cmode;
[
scopeClassName,
// do this early so compiler extensions generally don't have to worry about
// the distinction between match/begin
compileMatch,
MultiClass,
beforeMatchExt
].forEach(ext => ext(mode, parent));
language.compilerExtensions.forEach(ext => ext(mode, parent));
// __beforeBegin is considered private API, internal use only
mode.__beforeBegin = null;
[
beginKeywords,
// do this later so compiler extensions that come earlier have access to the
// raw array if they wanted to perhaps manipulate it, etc.
compileIllegal,
// default to 1 relevance if not specified
compileRelevance
].forEach(ext => ext(mode, parent));
mode.isCompiled = true;
let keywordPattern = null;
if (typeof mode.keywords === "object" && mode.keywords.$pattern) {
// we need a copy because keywords might be compiled multiple times
// so we can't go deleting $pattern from the original on the first
// pass
mode.keywords = Object.assign({}, mode.keywords);
keywordPattern = mode.keywords.$pattern;
delete mode.keywords.$pattern;
}
keywordPattern = keywordPattern || /\w+/;
if (mode.keywords) {
mode.keywords = compileKeywords(mode.keywords, language.case_insensitive);
}
cmode.keywordPatternRe = langRe(keywordPattern, true);
if (parent) {
if (!mode.begin) mode.begin = /\B|\b/;
cmode.beginRe = langRe(cmode.begin);
if (!mode.end && !mode.endsWithParent) mode.end = /\B|\b/;
if (mode.end) cmode.endRe = langRe(cmode.end);
cmode.terminatorEnd = source$2(cmode.end) || '';
if (mode.endsWithParent && parent.terminatorEnd) {
cmode.terminatorEnd += (mode.end ? '|' : '') + parent.terminatorEnd;
}
}
if (mode.illegal) cmode.illegalRe = langRe(/** @type {RegExp | string} */ (mode.illegal));
if (!mode.contains) mode.contains = [];
mode.contains = [].concat(...mode.contains.map(function(c) {
return expandOrCloneMode(c === 'self' ? mode : c);
}));
mode.contains.forEach(function(c) { compileMode(/** @type Mode */ (c), cmode); });
if (mode.starts) {
compileMode(mode.starts, parent);
}
cmode.matcher = buildModeRegex(cmode);
return cmode;
}
if (!language.compilerExtensions) language.compilerExtensions = [];
// self is not valid at the top-level
if (language.contains && language.contains.includes('self')) {
throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");
}
// we need a null object, which inherit will guarantee
language.classNameAliases = inherit$1(language.classNameAliases || {});
return compileMode(/** @type Mode */ (language));
}
/**
* Determines if a mode has a dependency on it's parent or not
*
* If a mode does have a parent dependency then often we need to clone it if
* it's used in multiple places so that each copy points to the correct parent,
* where-as modes without a parent can often safely be re-used at the bottom of
* a mode chain.
*
* @param {Mode | null} mode
* @returns {boolean} - is there a dependency on the parent?
* */
function dependencyOnParent(mode) {
if (!mode) return false;
return mode.endsWithParent || dependencyOnParent(mode.starts);
}
/**
* Expands a mode or clones it if necessary
*
* This is necessary for modes with parental dependenceis (see notes on
* `dependencyOnParent`) and for nodes that have `variants` - which must then be
* exploded into their own individual modes at compile time.
*
* @param {Mode} mode
* @returns {Mode | Mode[]}
* */
function expandOrCloneMode(mode) {
if (mode.variants && !mode.cachedVariants) {
mode.cachedVariants = mode.variants.map(function(variant) {
return inherit$1(mode, { variants: null }, variant);
});
}
// EXPAND
// if we have variants then essentially "replace" the mode with the variants
// this happens in compileMode, where this function is called from
if (mode.cachedVariants) {
return mode.cachedVariants;
}
// CLONE
// if we have dependencies on parents then we need a unique
// instance of ourselves, so we can be reused with many
// different parents without issue
if (dependencyOnParent(mode)) {
return inherit$1(mode, { starts: mode.starts ? inherit$1(mode.starts) : null });
}
if (Object.isFrozen(mode)) {
return inherit$1(mode);
}
// no special dependency issues, just return ourselves
return mode;
}
var version = "11.9.0";
class HTMLInjectionError extends Error {
constructor(reason, html) {
super(reason);
this.name = "HTMLInjectionError";
this.html = html;
}
}
/*
Syntax highlighting with language autodetection.
https://highlightjs.org/
*/
/**
@typedef {import('highlight.js').Mode} Mode
@typedef {import('highlight.js').CompiledMode} CompiledMode
@typedef {import('highlight.js').CompiledScope} CompiledScope
@typedef {import('highlight.js').Language} Language
@typedef {import('highlight.js').HLJSApi} HLJSApi
@typedef {import('highlight.js').HLJSPlugin} HLJSPlugin
@typedef {import('highlight.js').PluginEvent} PluginEvent
@typedef {import('highlight.js').HLJSOptions} HLJSOptions
@typedef {import('highlight.js').LanguageFn} LanguageFn
@typedef {import('highlight.js').HighlightedHTMLElement} HighlightedHTMLElement
@typedef {import('highlight.js').BeforeHighlightContext} BeforeHighlightContext
@typedef {import('highlight.js/private').MatchType} MatchType
@typedef {import('highlight.js/private').KeywordData} KeywordData
@typedef {import('highlight.js/private').EnhancedMatch} EnhancedMatch
@typedef {import('highlight.js/private').AnnotatedError} AnnotatedError
@typedef {import('highlight.js').AutoHighlightResult} AutoHighlightResult
@typedef {import('highlight.js').HighlightOptions} HighlightOptions
@typedef {import('highlight.js').HighlightResult} HighlightResult
*/
const escape$2 = escapeHTML;
const inherit = inherit$1;
const NO_MATCH = Symbol("nomatch");
const MAX_KEYWORD_HITS = 7;
/**
* @param {any} hljs - object that is extended (legacy)
* @returns {HLJSApi}
*/
const HLJS = function(hljs) {
// Global internal variables used within the highlight.js library.
/** @type {Record<string, Language>} */
const languages = Object.create(null);
/** @type {Record<string, string>} */
const aliases = Object.create(null);
/** @type {HLJSPlugin[]} */
const plugins = [];
// safe/production mode - swallows more errors, tries to keep running
// even if a single syntax or parse hits a fatal error
let SAFE_MODE = true;
const LANGUAGE_NOT_FOUND = "Could not find the language '{}', did you forget to load/include a language module?";
/** @type {Language} */
const PLAINTEXT_LANGUAGE = { disableAutodetect: true, name: 'Plain text', contains: [] };
// Global options used when within external APIs. This is modified when
// calling the `hljs.configure` function.
/** @type HLJSOptions */
let options = {
ignoreUnescapedHTML: false,
throwUnescapedHTML: false,
noHighlightRe: /^(no-?highlight)$/i,
languageDetectRe: /\blang(?:uage)?-([\w-]+)\b/i,
classPrefix: 'hljs-',
cssSelector: 'pre code',
languages: null,
// beta configuration options, subject to change, welcome to discuss
// https://github.com/highlightjs/highlight.js/issues/1086
__emitter: TokenTreeEmitter
};
/* Utility functions */
/**
* Tests a language name to see if highlighting should be skipped
* @param {string} languageName
*/
function shouldNotHighlight(languageName) {
return options.noHighlightRe.test(languageName);
}
/**
* @param {HighlightedHTMLElement} block - the HTML element to determine language for
*/
function blockLanguage(block) {
let classes = block.className + ' ';
classes += block.parentNode ? block.parentNode.className : '';
// language-* takes precedence over non-prefixed class names.
const match = options.languageDetectRe.exec(classes);
if (match) {
const language = getLanguage(match[1]);
if (!language) {
warn(LANGUAGE_NOT_FOUND.replace("{}", match[1]));
warn("Falling back to no-highlight mode for this block.", block);
}
return language ? match[1] : 'no-highlight';
}
return classes
.split(/\s+/)
.find((_class) => shouldNotHighlight(_class) || getLanguage(_class));
}
/**
* Core highlighting function.
*
* OLD API
* highlight(lang, code, ignoreIllegals, continuation)
*
* NEW API
* highlight(code, {lang, ignoreIllegals})
*
* @param {string} codeOrLanguageName - the language to use for highlighting
* @param {string | HighlightOptions} optionsOrCode - the code to highlight
* @param {boolean} [ignoreIllegals] - whether to ignore illegal matches, default is to bail
*
* @returns {HighlightResult} Result - an object that represents the result
* @property {string} language - the language name
* @property {number} relevance - the relevance score
* @property {string} value - the highlighted HTML code
* @property {string} code - the original raw code
* @property {CompiledMode} top - top of the current mode stack
* @property {boolean} illegal - indicates whether any illegal matches were found
*/
function highlight(codeOrLanguageName, optionsOrCode, ignoreIllegals) {
let code = "";
let languageName = "";
if (typeof optionsOrCode === "object") {
code = codeOrLanguageName;
ignoreIllegals = optionsOrCode.ignoreIllegals;
languageName = optionsOrCode.language;
} else {
// old API
deprecated("10.7.0", "highlight(lang, code, ...args) has been deprecated.");
deprecated("10.7.0", "Please use highlight(code, options) instead.\nhttps://github.com/highlightjs/highlight.js/issues/2277");
languageName = codeOrLanguageName;
code = optionsOrCode;
}
// https://github.com/highlightjs/highlight.js/issues/3149
// eslint-disable-next-line no-undefined
if (ignoreIllegals === undefined) { ignoreIllegals = true; }
/** @type {BeforeHighlightContext} */
const context = {
code,
language: languageName
};
// the plugin can change the desired language or the code to be highlighted
// just be changing the object it was passed
fire("before:highlight", context);
// a before plugin can usurp the result completely by providing it's own
// in which case we don't even need to call highlight
const result = context.result
? context.result
: _highlight(context.language, context.code, ignoreIllegals);
result.code = context.code;
// the plugin can change anything in result to suite it
fire("after:highlight", result);
return result;
}
/**
* private highlight that's used internally and does not fire callbacks
*
* @param {string} languageName - the language to use for highlighting
* @param {string} codeToHighlight - the code to highlight
* @param {boolean?} [ignoreIllegals] - whether to ignore illegal matches, default is to bail
* @param {CompiledMode?} [continuation] - current continuation mode, if any
* @returns {HighlightResult} - result of the highlight operation
*/
function _highlight(languageName, codeToHighlight, ignoreIllegals, continuation) {
const keywordHits = Object.create(null);
/**
* Return keyword data if a match is a keyword
* @param {CompiledMode} mode - current mode
* @param {string} matchText - the textual match
* @returns {KeywordData | false}
*/
function keywordData(mode, matchText) {
return mode.keywords[matchText];
}
function processKeywords() {
if (!top.keywords) {
emitter.addText(modeBuffer);
return;
}
let lastIndex = 0;
top.keywordPatternRe.lastIndex = 0;
let match = top.keywordPatternRe.exec(modeBuffer);
let buf = "";
while (match) {
buf += modeBuffer.substring(lastIndex, match.index);
const word = language.case_insensitive ? match[0].toLowerCase() : match[0];
const data = keywordData(top, word);
if (data) {
const [kind, keywordRelevance] = data;
emitter.addText(buf);
buf = "";
keywordHits[word] = (keywordHits[word] || 0) + 1;
if (keywordHits[word] <= MAX_KEYWORD_HITS) relevance += keywordRelevance;
if (kind.startsWith("_")) {
// _ implied for relevance only, do not highlight
// by applying a class name
buf += match[0];
} else {
const cssClass = language.classNameAliases[kind] || kind;
emitKeyword(match[0], cssClass);
}
} else {
buf += match[0];
}
lastIndex = top.keywordPatternRe.lastIndex;
match = top.keywordPatternRe.exec(modeBuffer);
}
buf += modeBuffer.substring(lastIndex);
emitter.addText(buf);
}
function processSubLanguage() {
if (modeBuffer === "") return;
/** @type HighlightResult */
let result = null;
if (typeof top.subLanguage === 'string') {
if (!languages[top.subLanguage]) {
emitter.addText(modeBuffer);
return;
}
result = _highlight(top.subLanguage, modeBuffer, true, continuations[top.subLanguage]);
continuations[top.subLanguage] = /** @type {CompiledMode} */ (result._top);
} else {
result = highlightAuto(modeBuffer, top.subLanguage.length ? top.subLanguage : null);
}
// Counting embedded language score towards the host language may be disabled
// with zeroing the containing mode relevance. Use case in point is Markdown that
// allows XML everywhere and makes every XML snippet to have a much larger Markdown
// score.
if (top.relevance > 0) {
relevance += result.relevance;
}
emitter.__addSublanguage(result._emitter, result.language);
}
function processBuffer() {
if (top.subLanguage != null) {
processSubLanguage();
} else {
processKeywords();
}
modeBuffer = '';
}
/**
* @param {string} text
* @param {string} scope
*/
function emitKeyword(keyword, scope) {
if (keyword === "") return;
emitter.startScope(scope);
emitter.addText(keyword);
emitter.endScope();
}
/**
* @param {CompiledScope} scope
* @param {RegExpMatchArray} match
*/
function emitMultiClass(scope, match) {
let i = 1;
const max = match.length - 1;
while (i <= max) {
if (!scope._emit[i]) { i++; continue; }
const klass = language.classNameAliases[scope[i]] || scope[i];
const text = match[i];
if (klass) {
emitKeyword(text, klass);
} else {
modeBuffer = text;
processKeywords();
modeBuffer = "";
}
i++;
}
}
/**
* @param {CompiledMode} mode - new mode to start
* @param {RegExpMatchArray} match
*/
function startNewMode(mode, match) {
if (mode.scope && typeof mode.scope === "string") {
emitter.openNode(language.classNameAliases[mode.scope] || mode.scope);
}
if (mode.beginScope) {
// beginScope just wraps the begin match itself in a scope
if (mode.beginScope._wrap) {
emitKeyword(modeBuffer, language.classNameAliases[mode.beginScope._wrap] || mode.beginScope._wrap);
modeBuffer = "";
} else if (mode.beginScope._multi) {
// at this point modeBuffer should just be the match
emitMultiClass(mode.beginScope, match);
modeBuffer = "";
}
}
top = Object.create(mode, { parent: { value: top } });
return top;
}
/**
* @param {CompiledMode } mode - the mode to potentially end
* @param {RegExpMatchArray} match - the latest match
* @param {string} matchPlusRemainder - match plus remainder of content
* @returns {CompiledMode | void} - the next mode, or if void continue on in current mode
*/
function endOfMode(mode, match, matchPlusRemainder) {
let matched = startsWith(mode.endRe, matchPlusRemainder);
if (matched) {
if (mode["on:end"]) {
const resp = new Response(mode);
mode["on:end"](match, resp);
if (resp.isMatchIgnored) matched = false;
}
if (matched) {
while (mode.endsParent && mode.parent) {
mode = mode.parent;
}
return mode;
}
}
// even if on:end fires an `ignore` it's still possible
// that we might trigger the end node because of a parent mode
if (mode.endsWithParent) {
return endOfMode(mode.parent, match, matchPlusRemainder);
}
}
/**
* Handle matching but then ignoring a sequence of text
*
* @param {string} lexeme - string containing full match text
*/
function doIgnore(lexeme) {
if (top.matcher.regexIndex === 0) {
// no more regexes to potentially match here, so we move the cursor forward one
// space
modeBuffer += lexeme[0];
return 1;
} else {
// no need to move the cursor, we still have additional regexes to try and
// match at this very spot
resumeScanAtSamePosition = true;
return 0;
}
}
/**
* Handle the start of a new potential mode match
*
* @param {EnhancedMatch} match - the current match
* @returns {number} how far to advance the parse cursor
*/
function doBeginMatch(match) {
const lexeme = match[0];
const newMode = match.rule;
const resp = new Response(newMode);
// first internal before callbacks, then the public ones
const beforeCallbacks = [newMode.__beforeBegin, newMode["on:begin"]];
for (const cb of beforeCallbacks) {
if (!cb) continue;
cb(match, resp);
if (resp.isMatchIgnored) return doIgnore(lexeme);
}
if (newMode.skip) {
modeBuffer += lexeme;
} else {
if (newMode.excludeBegin) {
modeBuffer += lexeme;
}
processBuffer();
if (!newMode.returnBegin && !newMode.excludeBegin) {
modeBuffer = lexeme;
}
}
startNewMode(newMode, match);
return newMode.returnBegin ? 0 : lexeme.length;
}
/**
* Handle the potential end of mode
*
* @param {RegExpMatchArray} match - the current match
*/
function doEndMatch(match) {
const lexeme = match[0];
const matchPlusRemainder = codeToHighlight.substring(match.index);
const endMode = endOfMode(top, match, matchPlusRemainder);
if (!endMode) { return NO_MATCH; }
const origin = top;
if (top.endScope && top.endScope._wrap) {
processBuffer();
emitKeyword(lexeme, top.endScope._wrap);
} else if (top.endScope && top.endScope._multi) {
processBuffer();
emitMultiClass(top.endScope, match);
} else if (origin.skip) {
modeBuffer += lexeme;
} else {
if (!(origin.returnEnd || origin.excludeEnd)) {
modeBuffer += lexeme;
}
processBuffer();
if (origin.excludeEnd) {
modeBuffer = lexeme;
}
}
do {
if (top.scope) {
emitter.closeNode();
}
if (!top.skip && !top.subLanguage) {
relevance += top.relevance;
}
top = top.parent;
} while (top !== endMode.parent);
if (endMode.starts) {
startNewMode(endMode.starts, match);
}
return origin.returnEnd ? 0 : lexeme.length;
}
function processContinuations() {
const list = [];
for (let current = top; current !== language; current = current.parent) {
if (current.scope) {
list.unshift(current.scope);
}
}
list.forEach(item => emitter.openNode(item));
}
/** @type {{type?: MatchType, index?: number, rule?: Mode}}} */
let lastMatch = {};
/**
* Process an individual match
*
* @param {string} textBeforeMatch - text preceding the match (since the last match)
* @param {EnhancedMatch} [match] - the match itself
*/
function processLexeme(textBeforeMatch, match) {
const lexeme = match && match[0];
// add non-matched text to the current mode buffer
modeBuffer += textBeforeMatch;
if (lexeme == null) {
processBuffer();
return 0;
}
// we've found a 0 width match and we're stuck, so we need to advance
// this happens when we have badly behaved rules that have optional matchers to the degree that
// sometimes they can end up matching nothing at all
// Ref: https://github.com/highlightjs/highlight.js/issues/2140
if (lastMatch.type === "begin" && match.type === "end" && lastMatch.index === match.index && lexeme === "") {
// spit the "skipped" character that our regex choked on back into the output sequence
modeBuffer += codeToHighlight.slice(match.index, match.index + 1);
if (!SAFE_MODE) {
/** @type {AnnotatedError} */
const err = new Error(`0 width match regex (${languageName})`);
err.languageName = languageName;
err.badRule = lastMatch.rule;
throw err;
}
return 1;
}
lastMatch = match;
if (match.type === "begin") {
return doBeginMatch(match);
} else if (match.type === "illegal" && !ignoreIllegals) {
// illegal match, we do not continue processing
/** @type {AnnotatedError} */
const err = new Error('Illegal lexeme "' + lexeme + '" for mode "' + (top.scope || '<unnamed>') + '"');
err.mode = top;
throw err;
} else if (match.type === "end") {
const processed = doEndMatch(match);
if (processed !== NO_MATCH) {
return processed;
}
}
// edge case for when illegal matches $ (end of line) which is technically
// a 0 width match but not a begin/end match so it's not caught by the
// first handler (when ignoreIllegals is true)
if (match.type === "illegal" && lexeme === "") {
// advance so we aren't stuck in an infinite loop
return 1;
}
// infinite loops are BAD, this is a last ditch catch all. if we have a
// decent number of iterations yet our index (cursor position in our
// parsing) still 3x behind our index then something is very wrong
// so we bail
if (iterations > 100000 && iterations > match.index * 3) {
const err = new Error('potential infinite loop, way more iterations than matches');
throw err;
}
/*
Why might be find ourselves here? An potential end match that was
triggered but could not be completed. IE, `doEndMatch` returned NO_MATCH.
(this could be because a callback requests the match be ignored, etc)
This causes no real harm other than stopping a few times too many.
*/
modeBuffer += lexeme;
return lexeme.length;
}
const language = getLanguage(languageName);
if (!language) {
error(LANGUAGE_NOT_FOUND.replace("{}", languageName));
throw new Error('Unknown language: "' + languageName + '"');
}
const md = compileLanguage(language);
let result = '';
/** @type {CompiledMode} */
let top = continuation || md;
/** @type Record<string,CompiledMode> */
const continuations = {}; // keep continuations for sub-languages
const emitter = new options.__emitter(options);
processContinuations();
let modeBuffer = '';
let relevance = 0;
let index = 0;
let iterations = 0;
let resumeScanAtSamePosition = false;
try {
if (!language.__emitTokens) {
top.matcher.considerAll();
for (;;) {
iterations++;
if (resumeScanAtSamePosition) {
// only regexes not matched previously will now be
// considered for a potential match
resumeScanAtSamePosition = false;
} else {
top.matcher.considerAll();
}
top.matcher.lastIndex = index;
const match = top.matcher.exec(codeToHighlight);
// console.log("match", match[0], match.rule && match.rule.begin)
if (!match) break;
const beforeMatch = codeToHighlight.substring(index, match.index);
const processedCount = processLexeme(beforeMatch, match);
index = match.index + processedCount;
}
processLexeme(codeToHighlight.substring(index));
} else {
language.__emitTokens(codeToHighlight, emitter);
}
emitter.finalize();
result = emitter.toHTML();
return {
language: languageName,
value: result,
relevance,
illegal: false,
_emitter: emitter,
_top: top
};
} catch (err) {
if (err.message && err.message.includes('Illegal')) {
return {
language: languageName,
value: escape$2(codeToHighlight),
illegal: true,
relevance: 0,
_illegalBy: {
message: err.message,
index,
context: codeToHighlight.slice(index - 100, index + 100),
mode: err.mode,
resultSoFar: result
},
_emitter: emitter
};
} else if (SAFE_MODE) {
return {
language: languageName,
value: escape$2(codeToHighlight),
illegal: false,
relevance: 0,
errorRaised: err,
_emitter: emitter,
_top: top
};
} else {
throw err;
}
}
}
/**
* returns a valid highlight result, without actually doing any actual work,
* auto highlight starts with this and it's possible for small snippets that
* auto-detection may not find a better match
* @param {string} code
* @returns {HighlightResult}
*/
function justTextHighlightResult(code) {
const result = {
value: escape$2(code),
illegal: false,
relevance: 0,
_top: PLAINTEXT_LANGUAGE,
_emitter: new options.__emitter(options)
};
result._emitter.addText(code);
return result;
}
/**
Highlighting with language detection. Accepts a string with the code to
highlight. Returns an object with the following properties:
- language (detected language)
- relevance (int)
- value (an HTML string with highlighting markup)
- secondBest (object with the same structure for second-best heuristically
detected language, may be absent)
@param {string} code
@param {Array<string>} [languageSubset]
@returns {AutoHighlightResult}
*/
function highlightAuto(code, languageSubset) {
languageSubset = languageSubset || options.languages || Object.keys(languages);
const plaintext = justTextHighlightResult(code);
const results = languageSubset.filter(getLanguage).filter(autoDetection).map(name =>
_highlight(name, code, false)
);
results.unshift(plaintext); // plaintext is always an option
const sorted = results.sort((a, b) => {
// sort base on relevance
if (a.relevance !== b.relevance) return b.relevance - a.relevance;
// always award the tie to the base language
// ie if C++ and Arduino are tied, it's more likely to be C++
if (a.language && b.language) {
if (getLanguage(a.language).supersetOf === b.language) {
return 1;
} else if (getLanguage(b.language).supersetOf === a.language) {
return -1;
}
}
// otherwise say they are equal, which has the effect of sorting on
// relevance while preserving the original ordering - which is how ties
// have historically been settled, ie the language that comes first always
// wins in the case of a tie
return 0;
});
const [best, secondBest] = sorted;
/** @type {AutoHighlightResult} */
const result = best;
result.secondBest = secondBest;
return result;
}
/**
* Builds new class name for block given the language name
*
* @param {HTMLElement} element
* @param {string} [currentLang]
* @param {string} [resultLang]
*/
function updateClassName(element, currentLang, resultLang) {
const language = (currentLang && aliases[currentLang]) || resultLang;
element.classList.add("hljs");
element.classList.add(`language-${language}`);
}
/**
* Applies highlighting to a DOM node containing code.
*
* @param {HighlightedHTMLElement} element - the HTML element to highlight
*/
function highlightElement(element) {
/** @type HTMLElement */
let node = null;
const language = blockLanguage(element);
if (shouldNotHighlight(language)) return;
fire("before:highlightElement",
{ el: element, language });
if (element.dataset.highlighted) {
console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.", element);
return;
}
// we should be all text, no child nodes (unescaped HTML) - this is possibly
// an HTML injection attack - it's likely too late if this is already in
// production (the code has likely already done its damage by the time
// we're seeing it)... but we yell loudly about this so that hopefully it's
// more likely to be caught in development before making it to production
if (element.children.length > 0) {
if (!options.ignoreUnescapedHTML) {
console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk.");
console.warn("https://github.com/highlightjs/highlight.js/wiki/security");
console.warn("The element with unescaped HTML:");
console.warn(element);
}
if (options.throwUnescapedHTML) {
const err = new HTMLInjectionError(
"One of your code blocks includes unescaped HTML.",
element.innerHTML
);
throw err;
}
}
node = element;
const text = node.textContent;
const result = language ? highlight(text, { language, ignoreIllegals: true }) : highlightAuto(text);
element.innerHTML = result.value;
element.dataset.highlighted = "yes";
updateClassName(element, language, result.language);
element.result = {
language: result.language,
// TODO: remove with version 11.0
re: result.relevance,
relevance: result.relevance
};
if (result.secondBest) {
element.secondBest = {
language: result.secondBest.language,
relevance: result.secondBest.relevance
};
}
fire("after:highlightElement", { el: element, result, text });
}
/**
* Updates highlight.js global options with the passed options
*
* @param {Partial<HLJSOptions>} userOptions
*/
function configure(userOptions) {
options = inherit(options, userOptions);
}
// TODO: remove v12, deprecated
const initHighlighting = () => {
highlightAll();
deprecated("10.6.0", "initHighlighting() deprecated. Use highlightAll() now.");
};
// TODO: remove v12, deprecated
function initHighlightingOnLoad() {
highlightAll();
deprecated("10.6.0", "initHighlightingOnLoad() deprecated. Use highlightAll() now.");
}
let wantsHighlight = false;
/**
* auto-highlights all pre>code elements on the page
*/
function highlightAll() {
// if we are called too early in the loading process
if (document.readyState === "loading") {
wantsHighlight = true;
return;
}
const blocks = document.querySelectorAll(options.cssSelector);
blocks.forEach(highlightElement);
}
function boot() {
// if a highlight was requested before DOM was loaded, do now
if (wantsHighlight) highlightAll();
}
// make sure we are in the browser environment
if (typeof window !== 'undefined' && window.addEventListener) {
window.addEventListener('DOMContentLoaded', boot, false);
}
/**
* Register a language grammar module
*
* @param {string} languageName
* @param {LanguageFn} languageDefinition
*/
function registerLanguage(languageName, languageDefinition) {
let lang = null;
try {
lang = languageDefinition(hljs);
} catch (error$1) {
error("Language definition for '{}' could not be registered.".replace("{}", languageName));
// hard or soft error
if (!SAFE_MODE) { throw error$1; } else { error(error$1); }
// languages that have serious errors are replaced with essentially a
// "plaintext" stand-in so that the code blocks will still get normal
// css classes applied to them - and one bad language won't break the
// entire highlighter
lang = PLAINTEXT_LANGUAGE;
}
// give it a temporary name if it doesn't have one in the meta-data
if (!lang.name) lang.name = languageName;
languages[languageName] = lang;
lang.rawDefinition = languageDefinition.bind(null, hljs);
if (lang.aliases) {
registerAliases(lang.aliases, { languageName });
}
}
/**
* Remove a language grammar module
*
* @param {string} languageName
*/
function unregisterLanguage(languageName) {
delete languages[languageName];
for (const alias of Object.keys(aliases)) {
if (aliases[alias] === languageName) {
delete aliases[alias];
}
}
}
/**
* @returns {string[]} List of language internal names
*/
function listLanguages() {
return Object.keys(languages);
}
/**
* @param {string} name - name of the language to retrieve
* @returns {Language | undefined}
*/
function getLanguage(name) {
name = (name || '').toLowerCase();
return languages[name] || languages[aliases[name]];
}
/**
*
* @param {string|string[]} aliasList - single alias or list of aliases
* @param {{languageName: string}} opts
*/
function registerAliases(aliasList, { languageName }) {
if (typeof aliasList === 'string') {
aliasList = [aliasList];
}
aliasList.forEach(alias => { aliases[alias.toLowerCase()] = languageName; });
}
/**
* Determines if a given language has auto-detection enabled
* @param {string} name - name of the language
*/
function autoDetection(name) {
const lang = getLanguage(name);
return lang && !lang.disableAutodetect;
}
/**
* Upgrades the old highlightBlock plugins to the new
* highlightElement API
* @param {HLJSPlugin} plugin
*/
function upgradePluginAPI(plugin) {
// TODO: remove with v12
if (plugin["before:highlightBlock"] && !plugin["before:highlightElement"]) {
plugin["before:highlightElement"] = (data) => {
plugin["before:highlightBlock"](
Object.assign({ block: data.el }, data)
);
};
}
if (plugin["after:highlightBlock"] && !plugin["after:highlightElement"]) {
plugin["after:highlightElement"] = (data) => {
plugin["after:highlightBlock"](
Object.assign({ block: data.el }, data)
);
};
}
}
/**
* @param {HLJSPlugin} plugin
*/
function addPlugin(plugin) {
upgradePluginAPI(plugin);
plugins.push(plugin);
}
/**
* @param {HLJSPlugin} plugin
*/
function removePlugin(plugin) {
const index = plugins.indexOf(plugin);
if (index !== -1) {
plugins.splice(index, 1);
}
}
/**
*
* @param {PluginEvent} event
* @param {any} args
*/
function fire(event, args) {
const cb = event;
plugins.forEach(function(plugin) {
if (plugin[cb]) {
plugin[cb](args);
}
});
}
/**
* DEPRECATED
* @param {HighlightedHTMLElement} el
*/
function deprecateHighlightBlock(el) {
deprecated("10.7.0", "highlightBlock will be removed entirely in v12.0");
deprecated("10.7.0", "Please use highlightElement now.");
return highlightElement(el);
}
/* Interface definition */
Object.assign(hljs, {
highlight,
highlightAuto,
highlightAll,
highlightElement,
// TODO: Remove with v12 API
highlightBlock: deprecateHighlightBlock,
configure,
initHighlighting,
initHighlightingOnLoad,
registerLanguage,
unregisterLanguage,
listLanguages,
getLanguage,
registerAliases,
autoDetection,
inherit,
addPlugin,
removePlugin
});
hljs.debugMode = function() { SAFE_MODE = false; };
hljs.safeMode = function() { SAFE_MODE = true; };
hljs.versionString = version;
hljs.regex = {
concat: concat$2,
lookahead: lookahead$2,
either: either$2,
optional: optional,
anyNumberOfTimes: anyNumberOfTimes
};
for (const key in MODES$4) {
// @ts-ignore
if (typeof MODES$4[key] === "object") {
// @ts-ignore
deepFreeze(MODES$4[key]);
}
}
// merge all the modes/regexes into our main object
Object.assign(hljs, MODES$4);
return hljs;
};
// Other names for the variable may break build script
const highlight = HLJS({});
// returns a new instance of the highlighter to be used for extensions
// check https://github.com/wooorm/lowlight/issues/47
highlight.newInstance = () => HLJS({});
var core = highlight;
highlight.HighlightJS = highlight;
highlight.default = highlight;
/*
Language: 1C:Enterprise
Author: Stanislav Belov <stbelov@gmail.com>
Description: built-in language 1C:Enterprise (v7, v8)
Category: enterprise
*/
function _1c(hljs) {
// общий паттерн для определения идентификаторов
const UNDERSCORE_IDENT_RE = '[A-Za-zА-Яа-яёЁ_][A-Za-zА-Яа-яёЁ_0-9]+';
// v7 уникальные ключевые слова, отсутствующие в v8 ==> keyword
const v7_keywords =
'далее ';
// v8 ключевые слова ==> keyword
const v8_keywords =
'возврат вызватьисключение выполнить для если и из или иначе иначеесли исключение каждого конецесли '
+ 'конецпопытки конеццикла не новый перейти перем по пока попытка прервать продолжить тогда цикл экспорт ';
// keyword : ключевые слова
const KEYWORD = v7_keywords + v8_keywords;
// v7 уникальные директивы, отсутствующие в v8 ==> meta-keyword
const v7_meta_keywords =
'загрузитьизфайла ';
// v8 ключевые слова в инструкциях препроцессора, директивах компиляции, аннотациях ==> meta-keyword
const v8_meta_keywords =
'вебклиент вместо внешнеесоединение клиент конецобласти мобильноеприложениеклиент мобильноеприложениесервер '
+ 'наклиенте наклиентенасервере наклиентенасерверебезконтекста насервере насерверебезконтекста область перед '
+ 'после сервер толстыйклиентобычноеприложение толстыйклиентуправляемоеприложение тонкийклиент ';
// meta-keyword : ключевые слова в инструкциях препроцессора, директивах компиляции, аннотациях
const METAKEYWORD = v7_meta_keywords + v8_meta_keywords;
// v7 системные константы ==> built_in
const v7_system_constants =
'разделительстраниц разделительстрок символтабуляции ';
// v7 уникальные методы глобального контекста, отсутствующие в v8 ==> built_in
const v7_global_context_methods =
'ansitooem oemtoansi ввестивидсубконто ввестиперечисление ввестипериод ввестиплансчетов выбранныйплансчетов '
+ 'датагод датамесяц датачисло заголовоксистемы значениевстроку значениеизстроки каталогиб каталогпользователя '
+ 'кодсимв конгода конецпериодаби конецрассчитанногопериодаби конецстандартногоинтервала конквартала конмесяца '
+ 'коннедели лог лог10 максимальноеколичествосубконто названиеинтерфейса названиенабораправ назначитьвид '
+ 'назначитьсчет найтиссылки началопериодаби началостандартногоинтервала начгода начквартала начмесяца '
+ 'начнедели номерднягода номерднянедели номернеделигода обработкаожидания основнойжурналрасчетов '
+ 'основнойплансчетов основнойязык очиститьокносообщений периодстр получитьвремята получитьдатута '
+ 'получитьдокументта получитьзначенияотбора получитьпозициюта получитьпустоезначение получитьта '
+ 'префиксавтонумерации пропись пустоезначение разм разобратьпозициюдокумента рассчитатьрегистрына '
+ 'рассчитатьрегистрыпо симв создатьобъект статусвозврата стрколичествострок сформироватьпозициюдокумента '
+ 'счетпокоду текущеевремя типзначения типзначениястр установитьтана установитьтапо фиксшаблон шаблон ';
// v8 методы глобального контекста ==> built_in
const v8_global_context_methods =
'acos asin atan base64значение base64строка cos exp log log10 pow sin sqrt tan xmlзначение xmlстрока '
+ 'xmlтип xmlтипзнч активноеокно безопасныйрежим безопасныйрежимразделенияданных булево ввестидату ввестизначение '
+ 'ввестистроку ввестичисло возможностьчтенияxml вопрос восстановитьзначение врег выгрузитьжурналрегистрации '
+ 'выполнитьобработкуоповещения выполнитьпроверкуправдоступа вычислить год данныеформывзначение дата день деньгода '
+ 'деньнедели добавитьмесяц заблокироватьданныедляредактирования заблокироватьработупользователя завершитьработусистемы '
+ 'загрузитьвнешнююкомпоненту закрытьсправку записатьjson записатьxml записатьдатуjson записьжурналарегистрации '
+ 'заполнитьзначениясвойств запроситьразрешениепользователя запуститьприложение запуститьсистему зафиксироватьтранзакцию '
+ 'значениевданныеформы значениевстрокувнутр значениевфайл значениезаполнено значениеизстрокивнутр значениеизфайла '
+ 'изxmlтипа импортмоделиxdto имякомпьютера имяпользователя инициализироватьпредопределенныеданные информацияобошибке '
+ 'каталогбиблиотекимобильногоустройства каталогвременныхфайлов каталогдокументов каталогпрограммы кодироватьстроку '
+ 'кодлокализацииинформационнойбазы кодсимвола командасистемы конецгода конецдня конецквартала конецмесяца конецминуты '
+ 'конецнедели конецчаса конфигурациябазыданныхизмененадинамически конфигурацияизменена копироватьданныеформы '
+ 'копироватьфайл краткоепредставлениеошибки лев макс местноевремя месяц мин минута монопольныйрежим найти '
+ 'найтинедопустимыесимволыxml найтиокнопонавигационнойссылке найтипомеченныенаудаление найтипоссылкам найтифайлы '
+ 'началогода началодня началоквартала началомесяца началоминуты началонедели началочаса начатьзапросразрешенияпользователя '
+ 'начатьзапускприложения начатькопированиефайла начатьперемещениефайла начатьподключениевнешнейкомпоненты '
+ 'начатьподключениерасширенияработыскриптографией начатьподключениерасширенияработысфайлами начатьпоискфайлов '
+ 'начатьполучениекаталогавременныхфайлов начатьполучениекаталогадокументов начатьполучениерабочегокаталогаданныхпользователя '
+ 'начатьполучениефайлов начатьпомещениефайла начатьпомещениефайлов начатьсозданиедвоичныхданныхизфайла начатьсозданиекаталога '
+ 'начатьтранзакцию начатьудалениефайлов начатьустановкувнешнейкомпоненты начатьустановкурасширенияработыскриптографией '
+ 'начатьустановкурасширенияработысфайлами неделягода необходимостьзавершениясоединения номерсеансаинформационнойбазы '
+ 'номерсоединенияинформационнойбазы нрег нстр обновитьинтерфейс обновитьнумерациюобъектов обновитьповторноиспользуемыезначения '
+ 'обработкапрерыванияпользователя объединитьфайлы окр описаниеошибки оповестить оповеститьобизменении '
+ 'отключитьобработчикзапросанастроекклиенталицензирования отключитьобработчикожидания отключитьобработчикоповещения '
+ 'открытьзначение открытьиндекссправки открытьсодержаниесправки открытьсправку открытьформу открытьформумодально '
+ 'отменитьтранзакцию очиститьжурналрегистрации очиститьнастройкипользователя очиститьсообщения параметрыдоступа '
+ 'перейтипонавигационнойссылке переместитьфайл подключитьвнешнююкомпоненту '
+ 'подключитьобработчикзапросанастроекклиенталицензирования подключитьобработчикожидания подключитьобработчикоповещения '
+ 'подключитьрасширениеработыскриптографией подключитьрасширениеработысфайлами подробноепредставлениеошибки '
+ 'показатьвводдаты показатьвводзначения показатьвводстроки показатьвводчисла показатьвопрос показатьзначение '
+ 'показатьинформациюобошибке показатьнакарте показатьоповещениепользователя показатьпредупреждение полноеимяпользователя '
+ 'получитьcomобъект получитьxmlтип получитьадреспоместоположению получитьблокировкусеансов получитьвремязавершенияспящегосеанса '
+ 'получитьвремязасыпанияпассивногосеанса получитьвремяожиданияблокировкиданных получитьданныевыбора '
+ 'получитьдополнительныйпараметрклиенталицензирования получитьдопустимыекодылокализации получитьдопустимыечасовыепояса '
+ 'получитьзаголовокклиентскогоприложения получитьзаголовоксистемы получитьзначенияотборажурналарегистрации '
+ 'получитьидентификаторконфигурации получитьизвременногохранилища получитьимявременногофайла '
+ 'получитьимяклиенталицензирования получитьинформациюэкрановклиента получитьиспользованиежурналарегистрации '
+ 'получитьиспользованиесобытияжурналарегистрации получитькраткийзаголовокприложения получитьмакетоформления '
+ 'получитьмаскувсефайлы получитьмаскувсефайлыклиента получитьмаскувсефайлысервера получитьместоположениепоадресу '
+ 'получитьминимальнуюдлинупаролейпользователей получитьнавигационнуюссылку получитьнавигационнуюссылкуинформационнойбазы '
+ 'получитьобновлениеконфигурациибазыданных получитьобновлениепредопределенныхданныхинформационнойбазы получитьобщиймакет '
+ 'получитьобщуюформу получитьокна получитьоперативнуюотметкувремени получитьотключениебезопасногорежима '
+ 'получитьпараметрыфункциональныхопцийинтерфейса получитьполноеимяпредопределенногозначения '
+ 'получитьпредставлениянавигационныхссылок получитьпроверкусложностипаролейпользователей получитьразделительпути '
+ 'получитьразделительпутиклиента получитьразделительпутисервера получитьсеансыинформационнойбазы '
+ 'получитьскоростьклиентскогосоединения получитьсоединенияинформационнойбазы получитьсообщенияпользователю '
+ 'получитьсоответствиеобъектаиформы получитьсоставстандартногоинтерфейсаodata получитьструктурухранениябазыданных '
+ 'получитьтекущийсеансинформационнойбазы получитьфайл получитьфайлы получитьформу получитьфункциональнуюопцию '
+ 'получитьфункциональнуюопциюинтерфейса получитьчасовойпоясинформационнойбазы пользователиос поместитьвовременноехранилище '
+ 'поместитьфайл поместитьфайлы прав праводоступа предопределенноезначение представлениекодалокализации представлениепериода '
+ 'представлениеправа представлениеприложения представлениесобытияжурналарегистрации представлениечасовогопояса предупреждение '
+ 'прекратитьработусистемы привилегированныйрежим продолжитьвызов прочитатьjson прочитатьxml прочитатьдатуjson пустаястрока '
+ 'рабочийкаталогданныхпользователя разблокироватьданныедляредактирования разделитьфайл разорватьсоединениесвнешнимисточникомданных '
+ 'раскодироватьстроку рольдоступна секунда сигнал символ скопироватьжурналрегистрации смещениелетнеговремени '
+ 'смещениестандартноговремени соединитьбуферыдвоичныхданных создатькаталог создатьфабрикуxdto сокрл сокрлп сокрп сообщить '
+ 'состояние сохранитьзначение сохранитьнастройкипользователя сред стрдлина стрзаканчиваетсяна стрзаменить стрнайти стрначинаетсяс '
+ 'строка строкасоединенияинформационнойбазы стрполучитьстроку стрразделить стрсоединить стрсравнить стрчисловхождений '
+ 'стрчислострок стршаблон текущаядата текущаядатасеанса текущаяуниверсальнаядата текущаяуниверсальнаядатавмиллисекундах '
+ 'текущийвариантинтерфейсаклиентскогоприложения текущийвариантосновногошрифтаклиентскогоприложения текущийкодлокализации '
+ 'текущийрежимзапуска текущийязык текущийязыксистемы тип типзнч транзакцияактивна трег удалитьданныеинформационнойбазы '
+ 'удалитьизвременногохранилища удалитьобъекты удалитьфайлы универсальноевремя установитьбезопасныйрежим '
+ 'установитьбезопасныйрежимразделенияданных установитьблокировкусеансов установитьвнешнююкомпоненту '
+ 'установитьвремязавершенияспящегосеанса установитьвремязасыпанияпассивногосеанса установитьвремяожиданияблокировкиданных '
+ 'установитьзаголовокклиентскогоприложения установитьзаголовоксистемы установитьиспользованиежурналарегистрации '
+ 'установитьиспользованиесобытияжурналарегистрации установитькраткийзаголовокприложения '
+ 'установитьминимальнуюдлинупаролейпользователей установитьмонопольныйрежим установитьнастройкиклиенталицензирования '
+ 'установитьобновлениепредопределенныхданныхинформационнойбазы установитьотключениебезопасногорежима '
+ 'установитьпараметрыфункциональныхопцийинтерфейса установитьпривилегированныйрежим '
+ 'установитьпроверкусложностипаролейпользователей установитьрасширениеработыскриптографией '
+ 'установитьрасширениеработысфайлами установитьсоединениесвнешнимисточникомданных установитьсоответствиеобъектаиформы '
+ 'установитьсоставстандартногоинтерфейсаodata установитьчасовойпоясинформационнойбазы установитьчасовойпояссеанса '
+ 'формат цел час часовойпояс часовойпояссеанса число числопрописью этоадресвременногохранилища ';
// v8 свойства глобального контекста ==> built_in
const v8_global_context_property =
'wsссылки библиотекакартинок библиотекамакетовоформлениякомпоновкиданных библиотекастилей бизнеспроцессы '
+ 'внешниеисточникиданных внешниеобработки внешниеотчеты встроенныепокупки главныйинтерфейс главныйстиль '
+ 'документы доставляемыеуведомления журналыдокументов задачи информацияобинтернетсоединении использованиерабочейдаты '
+ 'историяработыпользователя константы критерииотбора метаданные обработки отображениерекламы отправкадоставляемыхуведомлений '
+ 'отчеты панельзадачос параметрзапуска параметрысеанса перечисления планывидоврасчета планывидовхарактеристик '
+ 'планыобмена планысчетов полнотекстовыйпоиск пользователиинформационнойбазы последовательности проверкавстроенныхпокупок '
+ 'рабочаядата расширенияконфигурации регистрыбухгалтерии регистрынакопления регистрырасчета регистрысведений '
+ 'регламентныезадания сериализаторxdto справочники средствагеопозиционирования средствакриптографии средствамультимедиа '
+ 'средстваотображениярекламы средствапочты средствателефонии фабрикаxdto файловыепотоки фоновыезадания хранилищанастроек '
+ 'хранилищевариантовотчетов хранилищенастроекданныхформ хранилищеобщихнастроек хранилищепользовательскихнастроекдинамическихсписков '
+ 'хранилищепользовательскихнастроекотчетов хранилищесистемныхнастроек ';
// built_in : встроенные или библиотечные объекты (константы, классы, функции)
const BUILTIN =
v7_system_constants
+ v7_global_context_methods + v8_global_context_methods
+ v8_global_context_property;
// v8 системные наборы значений ==> class
const v8_system_sets_of_values =
'webцвета windowsцвета windowsшрифты библиотекакартинок рамкистиля символы цветастиля шрифтыстиля ';
// v8 системные перечисления - интерфейсные ==> class
const v8_system_enums_interface =
'автоматическоесохранениеданныхформывнастройках автонумерациявформе автораздвижениесерий '
+ 'анимациядиаграммы вариантвыравниванияэлементовизаголовков вариантуправлениявысотойтаблицы '
+ 'вертикальнаяпрокруткаформы вертикальноеположение вертикальноеположениеэлемента видгруппыформы '
+ 'виддекорацииформы виддополненияэлементаформы видизмененияданных видкнопкиформы видпереключателя '
+ 'видподписейкдиаграмме видполяформы видфлажка влияниеразмеранапузырекдиаграммы горизонтальноеположение '
+ 'горизонтальноеположениеэлемента группировкаколонок группировкаподчиненныхэлементовформы '
+ 'группыиэлементы действиеперетаскивания дополнительныйрежимотображения допустимыедействияперетаскивания '
+ 'интервалмеждуэлементамиформы использованиевывода использованиеполосыпрокрутки '
+ 'используемоезначениеточкибиржевойдиаграммы историявыборапривводе источникзначенийоситочекдиаграммы '
+ 'источникзначенияразмерапузырькадиаграммы категориягруппыкоманд максимумсерий начальноеотображениедерева '
+ 'начальноеотображениесписка обновлениетекстаредактирования ориентациядендрограммы ориентациядиаграммы '
+ 'ориентацияметокдиаграммы ориентацияметоксводнойдиаграммы ориентацияэлементаформы отображениевдиаграмме '
+ 'отображениевлегендедиаграммы отображениегруппыкнопок отображениезаголовкашкалыдиаграммы '
+ 'отображениезначенийсводнойдиаграммы отображениезначенияизмерительнойдиаграммы '
+ 'отображениеинтерваладиаграммыганта отображениекнопки отображениекнопкивыбора отображениеобсужденийформы '
+ 'отображениеобычнойгруппы отображениеотрицательныхзначенийпузырьковойдиаграммы отображениепанелипоиска '
+ 'отображениеподсказки отображениепредупрежденияприредактировании отображениеразметкиполосырегулирования '
+ 'отображениестраницформы отображениетаблицы отображениетекстазначениядиаграммыганта '
+ 'отображениеуправленияобычнойгруппы отображениефигурыкнопки палитрацветовдиаграммы поведениеобычнойгруппы '
+ 'поддержкамасштабадендрограммы поддержкамасштабадиаграммыганта поддержкамасштабасводнойдиаграммы '
+ 'поисквтаблицепривводе положениезаголовкаэлементаформы положениекартинкикнопкиформы '
+ 'положениекартинкиэлементаграфическойсхемы положениекоманднойпанелиформы положениекоманднойпанелиэлементаформы '
+ 'положениеопорнойточкиотрисовки положениеподписейкдиаграмме положениеподписейшкалызначенийизмерительнойдиаграммы '
+ 'положениесостоянияпросмотра положениестрокипоиска положениетекстасоединительнойлинии положениеуправленияпоиском '
+ 'положениешкалывремени порядокотображенияточекгоризонтальнойгистограммы порядоксерийвлегендедиаграммы '
+ 'размеркартинки расположениезаголовкашкалыдиаграммы растягиваниеповертикалидиаграммыганта '
+ 'режимавтоотображениясостояния режимвводастроктаблицы режимвыборанезаполненного режимвыделениядаты '
+ 'режимвыделениястрокитаблицы режимвыделениятаблицы режимизмененияразмера режимизменениясвязанногозначения '
+ 'режимиспользованиядиалогапечати режимиспользованияпараметракоманды режиммасштабированияпросмотра '
+ 'режимосновногоокнаклиентскогоприложения режимоткрытияокнаформы режимотображениявыделения '
+ 'режимотображениягеографическойсхемы режимотображениязначенийсерии режимотрисовкисеткиграфическойсхемы '
+ 'режимполупрозрачностидиаграммы режимпробеловдиаграммы режимразмещениянастранице режимредактированияколонки '
+ 'режимсглаживаниядиаграммы режимсглаживанияиндикатора режимсписказадач сквозноевыравнивание '
+ 'сохранениеданныхформывнастройках способзаполнениятекстазаголовкашкалыдиаграммы '
+ 'способопределенияограничивающегозначениядиаграммы стандартнаягруппакоманд стандартноеоформление '
+ 'статусоповещенияпользователя стильстрелки типаппроксимациилиниитрендадиаграммы типдиаграммы '
+ 'типединицышкалывремени типимпортасерийслоягеографическойсхемы типлиниигеографическойсхемы типлиниидиаграммы '
+ 'типмаркерагеографическойсхемы типмаркерадиаграммы типобластиоформления '
+ 'типорганизацииисточникаданныхгеографическойсхемы типотображениясериислоягеографическойсхемы '
+ 'типотображенияточечногообъектагеографическойсхемы типотображенияшкалыэлементалегендыгеографическойсхемы '
+ 'типпоискаобъектовгеографическойсхемы типпроекциигеографическойсхемы типразмещенияизмерений '
+ 'типразмещенияреквизитовизмерений типрамкиэлементауправления типсводнойдиаграммы '
+ 'типсвязидиаграммыганта типсоединениязначенийпосериямдиаграммы типсоединенияточекдиаграммы '
+ 'типсоединительнойлинии типстороныэлементаграфическойсхемы типформыотчета типшкалырадарнойдиаграммы '
+ 'факторлиниитрендадиаграммы фигуракнопки фигурыграфическойсхемы фиксациявтаблице форматдняшкалывремени '
+ 'форматкартинки ширинаподчиненныхэлементовформы ';
// v8 системные перечисления - свойства прикладных объектов ==> class
const v8_system_enums_objects_properties =
'виддвижениябухгалтерии виддвижениянакопления видпериодарегистрарасчета видсчета видточкимаршрутабизнеспроцесса '
+ 'использованиеагрегатарегистранакопления использованиегруппиэлементов использованиережимапроведения '
+ 'использованиесреза периодичностьагрегатарегистранакопления режимавтовремя режимзаписидокумента режимпроведениядокумента ';
// v8 системные перечисления - планы обмена ==> class
const v8_system_enums_exchange_plans =
'авторегистрацияизменений допустимыйномерсообщения отправкаэлементаданных получениеэлементаданных ';
// v8 системные перечисления - табличный документ ==> class
const v8_system_enums_tabular_document =
'использованиерасшифровкитабличногодокумента ориентациястраницы положениеитоговколоноксводнойтаблицы '
+ 'положениеитоговстроксводнойтаблицы положениетекстаотносительнокартинки расположениезаголовкагруппировкитабличногодокумента '
+ 'способчтениязначенийтабличногодокумента типдвустороннейпечати типзаполненияобластитабличногодокумента '
+ 'типкурсоровтабличногодокумента типлиниирисункатабличногодокумента типлинииячейкитабличногодокумента '
+ 'типнаправленияпереходатабличногодокумента типотображениявыделениятабличногодокумента типотображениялинийсводнойтаблицы '
+ 'типразмещениятекстатабличногодокумента типрисункатабличногодокумента типсмещениятабличногодокумента '
+ 'типузоратабличногодокумента типфайлатабличногодокумента точностьпечати чередованиерасположениястраниц ';
// v8 системные перечисления - планировщик ==> class
const v8_system_enums_sheduler =
'отображениевремениэлементовпланировщика ';
// v8 системные перечисления - форматированный документ ==> class
const v8_system_enums_formatted_document =
'типфайлаформатированногодокумента ';
// v8 системные перечисления - запрос ==> class
const v8_system_enums_query =
'обходрезультатазапроса типзаписизапроса ';
// v8 системные перечисления - построитель отчета ==> class
const v8_system_enums_report_builder =
'видзаполнениярасшифровкипостроителяотчета типдобавленияпредставлений типизмеренияпостроителяотчета типразмещенияитогов ';
// v8 системные перечисления - работа с файлами ==> class
const v8_system_enums_files =
'доступкфайлу режимдиалогавыборафайла режимоткрытияфайла ';
// v8 системные перечисления - построитель запроса ==> class
const v8_system_enums_query_builder =
'типизмеренияпостроителязапроса ';
// v8 системные перечисления - анализ данных ==> class
const v8_system_enums_data_analysis =
'видданныханализа методкластеризации типединицыинтервалавременианализаданных типзаполнениятаблицырезультатаанализаданных '
+ 'типиспользованиячисловыхзначенийанализаданных типисточникаданныхпоискаассоциаций типколонкианализаданныхдереворешений '
+ 'типколонкианализаданныхкластеризация типколонкианализаданныхобщаястатистика типколонкианализаданныхпоискассоциаций '
+ 'типколонкианализаданныхпоискпоследовательностей типколонкимоделипрогноза типмерырасстоянияанализаданных '
+ 'типотсеченияправилассоциации типполяанализаданных типстандартизациианализаданных типупорядочиванияправилассоциациианализаданных '
+ 'типупорядочиванияшаблоновпоследовательностейанализаданных типупрощениядереварешений ';
// v8 системные перечисления - xml, json, xs, dom, xdto, web-сервисы ==> class
const v8_system_enums_xml_json_xs_dom_xdto_ws =
'wsнаправлениепараметра вариантxpathxs вариантзаписидатыjson вариантпростоготипаxs видгруппымоделиxs видфасетаxdto '
+ 'действиепостроителяdom завершенностьпростоготипаxs завершенностьсоставноготипаxs завершенностьсхемыxs запрещенныеподстановкиxs '
+ 'исключениягруппподстановкиxs категорияиспользованияатрибутаxs категорияограниченияидентичностиxs категорияограниченияпространствименxs '
+ 'методнаследованияxs модельсодержимогоxs назначениетипаxml недопустимыеподстановкиxs обработкапробельныхсимволовxs обработкасодержимогоxs '
+ 'ограничениезначенияxs параметрыотбораузловdom переносстрокjson позициявдокументеdom пробельныесимволыxml типатрибутаxml типзначенияjson '
+ 'типканоническогоxml типкомпонентыxs типпроверкиxml типрезультатаdomxpath типузлаdom типузлаxml формаxml формапредставленияxs '
+ 'форматдатыjson экранированиесимволовjson ';
// v8 системные перечисления - система компоновки данных ==> class
const v8_system_enums_data_composition_system =
'видсравнениякомпоновкиданных действиеобработкирасшифровкикомпоновкиданных направлениесортировкикомпоновкиданных '
+ 'расположениевложенныхэлементоврезультатакомпоновкиданных расположениеитоговкомпоновкиданных расположениегруппировкикомпоновкиданных '
+ 'расположениеполейгруппировкикомпоновкиданных расположениеполякомпоновкиданных расположениереквизитовкомпоновкиданных '
+ 'расположениересурсовкомпоновкиданных типбухгалтерскогоостаткакомпоновкиданных типвыводатекстакомпоновкиданных '
+ 'типгруппировкикомпоновкиданных типгруппыэлементовотборакомпоновкиданных типдополненияпериодакомпоновкиданных '
+ 'типзаголовкаполейкомпоновкиданных типмакетагруппировкикомпоновкиданных типмакетаобластикомпоновкиданных типостаткакомпоновкиданных '
+ 'типпериодакомпоновкиданных типразмещениятекстакомпоновкиданных типсвязинаборовданныхкомпоновкиданных типэлементарезультатакомпоновкиданных '
+ 'расположениелегендыдиаграммыкомпоновкиданных типпримененияотборакомпоновкиданных режимотображенияэлементанастройкикомпоновкиданных '
+ 'режимотображениянастроеккомпоновкиданных состояниеэлементанастройкикомпоновкиданных способвосстановлениянастроеккомпоновкиданных '
+ 'режимкомпоновкирезультата использованиепараметракомпоновкиданных автопозицияресурсовкомпоновкиданных '
+ 'вариантиспользованиягруппировкикомпоновкиданных расположениересурсоввдиаграммекомпоновкиданных фиксациякомпоновкиданных '
+ 'использованиеусловногооформлениякомпоновкиданных ';
// v8 системные перечисления - почта ==> class
const v8_system_enums_email =
'важностьинтернетпочтовогосообщения обработкатекстаинтернетпочтовогосообщения способкодированияинтернетпочтовоговложения '
+ 'способкодированиянеasciiсимволовинтернетпочтовогосообщения типтекстапочтовогосообщения протоколинтернетпочты '
+ 'статусразборапочтовогосообщения ';
// v8 системные перечисления - журнал регистрации ==> class
const v8_system_enums_logbook =
'режимтранзакциизаписижурналарегистрации статустранзакциизаписижурналарегистрации уровеньжурналарегистрации ';
// v8 системные перечисления - криптография ==> class
const v8_system_enums_cryptography =
'расположениехранилищасертификатовкриптографии режимвключениясертификатовкриптографии режимпроверкисертификатакриптографии '
+ 'типхранилищасертификатовкриптографии ';
// v8 системные перечисления - ZIP ==> class
const v8_system_enums_zip =
одировкаименфайловвzipфайле методсжатияzip методшифрованияzip режимвосстановленияпутейфайловzip режимобработкиподкаталоговzip '
+ 'режимсохраненияпутейzip уровеньсжатияzip ';
// v8 системные перечисления -
// Блокировка данных, Фоновые задания, Автоматизированное тестирование,
// Доставляемые уведомления, Встроенные покупки, Интернет, Работа с двоичными данными ==> class
const v8_system_enums_other =
'звуковоеоповещение направлениепереходакстроке позициявпотоке порядокбайтов режимблокировкиданных режимуправленияблокировкойданных '
+ 'сервисвстроенныхпокупок состояниефоновогозадания типподписчикадоставляемыхуведомлений уровеньиспользованиязащищенногосоединенияftp ';
// v8 системные перечисления - схема запроса ==> class
const v8_system_enums_request_schema =
'направлениепорядкасхемызапроса типдополненияпериодамисхемызапроса типконтрольнойточкисхемызапроса типобъединениясхемызапроса '
+ 'типпараметрадоступнойтаблицысхемызапроса типсоединениясхемызапроса ';
// v8 системные перечисления - свойства объектов метаданных ==> class
const v8_system_enums_properties_of_metadata_objects =
'httpметод автоиспользованиеобщегореквизита автопрефиксномеразадачи вариантвстроенногоязыка видиерархии видрегистранакопления '
+ 'видтаблицывнешнегоисточникаданных записьдвиженийприпроведении заполнениепоследовательностей индексирование '
+ 'использованиебазыпланавидоврасчета использованиебыстроговыбора использованиеобщегореквизита использованиеподчинения '
+ 'использованиеполнотекстовогопоиска использованиеразделяемыхданныхобщегореквизита использованиереквизита '
+ 'назначениеиспользованияприложения назначениерасширенияконфигурации направлениепередачи обновлениепредопределенныхданных '
+ 'оперативноепроведение основноепредставлениевидарасчета основноепредставлениевидахарактеристики основноепредставлениезадачи '
+ 'основноепредставлениепланаобмена основноепредставлениесправочника основноепредставлениесчета перемещениеграницыприпроведении '
+ 'периодичностьномерабизнеспроцесса периодичностьномерадокумента периодичностьрегистрарасчета периодичностьрегистрасведений '
+ 'повторноеиспользованиевозвращаемыхзначений полнотекстовыйпоискпривводепостроке принадлежностьобъекта проведение '
+ 'разделениеаутентификацииобщегореквизита разделениеданныхобщегореквизита разделениерасширенийконфигурацииобщегореквизита '
+ 'режимавтонумерацииобъектов режимзаписирегистра режимиспользованиямодальности '
+ 'режимиспользованиясинхронныхвызововрасширенийплатформыивнешнихкомпонент режимповторногоиспользованиясеансов '
+ 'режимполученияданныхвыборапривводепостроке режимсовместимости режимсовместимостиинтерфейса '
+ 'режимуправленияблокировкойданныхпоумолчанию сериикодовпланавидовхарактеристик сериикодовпланасчетов '
+ 'сериикодовсправочника созданиепривводе способвыбора способпоискастрокипривводепостроке способредактирования '
+ 'типданныхтаблицывнешнегоисточникаданных типкодапланавидоврасчета типкодасправочника типмакета типномерабизнеспроцесса '
+ 'типномерадокумента типномеразадачи типформы удалениедвижений ';
// v8 системные перечисления - разные ==> class
const v8_system_enums_differents =
'важностьпроблемыприменениярасширенияконфигурации вариантинтерфейсаклиентскогоприложения вариантмасштабаформклиентскогоприложения '
+ 'вариантосновногошрифтаклиентскогоприложения вариантстандартногопериода вариантстандартнойдатыначала видграницы видкартинки '
+ 'видотображенияполнотекстовогопоиска видрамки видсравнения видцвета видчисловогозначения видшрифта допустимаядлина допустимыйзнак '
+ 'использованиеbyteordermark использованиеметаданныхполнотекстовогопоиска источникрасширенийконфигурации клавиша кодвозвратадиалога '
+ 'кодировкаxbase кодировкатекста направлениепоиска направлениесортировки обновлениепредопределенныхданных обновлениеприизмененииданных '
+ 'отображениепанелиразделов проверказаполнения режимдиалогавопрос режимзапускаклиентскогоприложения режимокругления режимоткрытияформприложения '
+ 'режимполнотекстовогопоиска скоростьклиентскогосоединения состояниевнешнегоисточникаданных состояниеобновленияконфигурациибазыданных '
+ 'способвыборасертификатаwindows способкодированиястроки статуссообщения типвнешнейкомпоненты типплатформы типповеденияклавишиenter '
+ 'типэлементаинформацииовыполненииобновленияконфигурациибазыданных уровеньизоляциитранзакций хешфункция частидаты';
// class: встроенные наборы значений, системные перечисления (содержат дочерние значения, обращения к которым через разыменование)
const CLASS =
v8_system_sets_of_values
+ v8_system_enums_interface
+ v8_system_enums_objects_properties
+ v8_system_enums_exchange_plans
+ v8_system_enums_tabular_document
+ v8_system_enums_sheduler
+ v8_system_enums_formatted_document
+ v8_system_enums_query
+ v8_system_enums_report_builder
+ v8_system_enums_files
+ v8_system_enums_query_builder
+ v8_system_enums_data_analysis
+ v8_system_enums_xml_json_xs_dom_xdto_ws
+ v8_system_enums_data_composition_system
+ v8_system_enums_email
+ v8_system_enums_logbook
+ v8_system_enums_cryptography
+ v8_system_enums_zip
+ v8_system_enums_other
+ v8_system_enums_request_schema
+ v8_system_enums_properties_of_metadata_objects
+ v8_system_enums_differents;
// v8 общие объекты (у объектов есть конструктор, экземпляры создаются методом НОВЫЙ) ==> type
const v8_shared_object =
'comобъект ftpсоединение httpзапрос httpсервисответ httpсоединение wsопределения wsпрокси xbase анализданных аннотацияxs '
+ 'блокировкаданных буфердвоичныхданных включениеxs выражениекомпоновкиданных генераторслучайныхчисел географическаясхема '
+ 'географическиекоординаты графическаясхема группамоделиxs данныерасшифровкикомпоновкиданных двоичныеданные дендрограмма '
+ 'диаграмма диаграммаганта диалогвыборафайла диалогвыборацвета диалогвыборашрифта диалограсписаниярегламентногозадания '
+ 'диалогредактированиястандартногопериода диапазон документdom документhtml документацияxs доставляемоеуведомление '
+ 'записьdom записьfastinfoset записьhtml записьjson записьxml записьzipфайла записьданных записьтекста записьузловdom '
+ 'запрос защищенноесоединениеopenssl значенияполейрасшифровкикомпоновкиданных извлечениетекста импортxs интернетпочта '
+ 'интернетпочтовоесообщение интернетпочтовыйпрофиль интернетпрокси интернетсоединение информациядляприложенияxs '
+ 'использованиеатрибутаxs использованиесобытияжурналарегистрации источникдоступныхнастроеккомпоновкиданных '
+ 'итераторузловdom картинка квалификаторыдаты квалификаторыдвоичныхданных квалификаторыстроки квалификаторычисла '
+ 'компоновщикмакетакомпоновкиданных компоновщикнастроеккомпоновкиданных конструктормакетаоформлениякомпоновкиданных '
+ 'конструкторнастроеккомпоновкиданных конструкторформатнойстроки линия макеткомпоновкиданных макетобластикомпоновкиданных '
+ 'макетоформлениякомпоновкиданных маскаxs менеджеркриптографии наборсхемxml настройкикомпоновкиданных настройкисериализацииjson '
+ 'обработкакартинок обработкарасшифровкикомпоновкиданных обходдереваdom объявлениеатрибутаxs объявлениенотацииxs '
+ 'объявлениеэлементаxs описаниеиспользованиясобытиядоступжурналарегистрации '
+ 'описаниеиспользованиясобытияотказвдоступежурналарегистрации описаниеобработкирасшифровкикомпоновкиданных '
+ 'описаниепередаваемогофайла описаниетипов определениегруппыатрибутовxs определениегруппымоделиxs '
+ 'определениеограниченияидентичностиxs определениепростоготипаxs определениесоставноготипаxs определениетипадокументаdom '
+ 'определенияxpathxs отборкомпоновкиданных пакетотображаемыхдокументов параметрвыбора параметркомпоновкиданных '
+ 'параметрызаписиjson параметрызаписиxml параметрычтенияxml переопределениеxs планировщик полеанализаданных '
+ 'полекомпоновкиданных построительdom построительзапроса построительотчета построительотчетаанализаданных '
+ 'построительсхемxml поток потоквпамяти почта почтовоесообщение преобразованиеxsl преобразованиекканоническомуxml '
+ 'процессорвыводарезультатакомпоновкиданныхвколлекциюзначений процессорвыводарезультатакомпоновкиданныхвтабличныйдокумент '
+ 'процессоркомпоновкиданных разыменовательпространствименdom рамка расписаниерегламентногозадания расширенноеимяxml '
+ 'результатчтенияданных своднаядиаграмма связьпараметравыбора связьпотипу связьпотипукомпоновкиданных сериализаторxdto '
+ 'сертификатклиентаwindows сертификатклиентафайл сертификаткриптографии сертификатыудостоверяющихцентровwindows '
+ 'сертификатыудостоверяющихцентровфайл сжатиеданных системнаяинформация сообщениепользователю сочетаниеклавиш '
+ 'сравнениезначений стандартнаядатаначала стандартныйпериод схемаxml схемакомпоновкиданных табличныйдокумент '
+ 'текстовыйдокумент тестируемоеприложение типданныхxml уникальныйидентификатор фабрикаxdto файл файловыйпоток '
+ 'фасетдлиныxs фасетколичестваразрядовдробнойчастиxs фасетмаксимальноговключающегозначенияxs '
+ 'фасетмаксимальногоисключающегозначенияxs фасетмаксимальнойдлиныxs фасетминимальноговключающегозначенияxs '
+ 'фасетминимальногоисключающегозначенияxs фасетминимальнойдлиныxs фасетобразцаxs фасетобщегоколичестваразрядовxs '
+ 'фасетперечисленияxs фасетпробельныхсимволовxs фильтрузловdom форматированнаястрока форматированныйдокумент '
+ 'фрагментxs хешированиеданных хранилищезначения цвет чтениеfastinfoset чтениеhtml чтениеjson чтениеxml чтениеzipфайла '
+ 'чтениеданных чтениетекста чтениеузловdom шрифт элементрезультатакомпоновкиданных ';
// v8 универсальные коллекции значений ==> type
const v8_universal_collection =
'comsafearray деревозначений массив соответствие списокзначений структура таблицазначений фиксированнаяструктура '
+ 'фиксированноесоответствие фиксированныймассив ';
// type : встроенные типы
const TYPE =
v8_shared_object
+ v8_universal_collection;
// literal : примитивные типы
const LITERAL = 'null истина ложь неопределено';
// number : числа
const NUMBERS = hljs.inherit(hljs.NUMBER_MODE);
// string : строки
const STRINGS = {
className: 'string',
begin: '"|\\|',
end: '"|$',
contains: [ { begin: '""' } ]
};
// number : даты
const DATE = {
begin: "'",
end: "'",
excludeBegin: true,
excludeEnd: true,
contains: [
{
className: 'number',
begin: '\\d{4}([\\.\\\\/:-]?\\d{2}){0,5}'
}
]
};
// comment : комментарии
const COMMENTS = hljs.inherit(hljs.C_LINE_COMMENT_MODE);
// meta : инструкции препроцессора, директивы компиляции
const META = {
className: 'meta',
begin: '#|&',
end: '$',
keywords: {
$pattern: UNDERSCORE_IDENT_RE,
keyword: KEYWORD + METAKEYWORD
},
contains: [ COMMENTS ]
};
// symbol : метка goto
const SYMBOL = {
className: 'symbol',
begin: '~',
end: ';|:',
excludeEnd: true
};
// function : объявление процедур и функций
const FUNCTION = {
className: 'function',
variants: [
{
begin: 'процедура|функция',
end: '\\)',
keywords: 'процедура функция'
},
{
begin: 'конецпроцедуры|конецфункции',
keywords: 'конецпроцедуры конецфункции'
}
],
contains: [
{
begin: '\\(',
end: '\\)',
endsParent: true,
contains: [
{
className: 'params',
begin: UNDERSCORE_IDENT_RE,
end: ',',
excludeEnd: true,
endsWithParent: true,
keywords: {
$pattern: UNDERSCORE_IDENT_RE,
keyword: 'знач',
literal: LITERAL
},
contains: [
NUMBERS,
STRINGS,
DATE
]
},
COMMENTS
]
},
hljs.inherit(hljs.TITLE_MODE, { begin: UNDERSCORE_IDENT_RE })
]
};
return {
name: '1C:Enterprise',
case_insensitive: true,
keywords: {
$pattern: UNDERSCORE_IDENT_RE,
keyword: KEYWORD,
built_in: BUILTIN,
class: CLASS,
type: TYPE,
literal: LITERAL
},
contains: [
META,
FUNCTION,
COMMENTS,
SYMBOL,
NUMBERS,
STRINGS,
DATE
]
};
}
var _1c_1 = _1c;
/*
Language: Augmented Backus-Naur Form
Author: Alex McKibben <alex@nullscope.net>
Website: https://tools.ietf.org/html/rfc5234
Audit: 2020
*/
/** @type LanguageFn */
function abnf(hljs) {
const regex = hljs.regex;
const IDENT = /^[a-zA-Z][a-zA-Z0-9-]*/;
const KEYWORDS = [
"ALPHA",
"BIT",
"CHAR",
"CR",
"CRLF",
"CTL",
"DIGIT",
"DQUOTE",
"HEXDIG",
"HTAB",
"LF",
"LWSP",
"OCTET",
"SP",
"VCHAR",
"WSP"
];
const COMMENT = hljs.COMMENT(/;/, /$/);
const TERMINAL_BINARY = {
scope: "symbol",
match: /%b[0-1]+(-[0-1]+|(\.[0-1]+)+)?/
};
const TERMINAL_DECIMAL = {
scope: "symbol",
match: /%d[0-9]+(-[0-9]+|(\.[0-9]+)+)?/
};
const TERMINAL_HEXADECIMAL = {
scope: "symbol",
match: /%x[0-9A-F]+(-[0-9A-F]+|(\.[0-9A-F]+)+)?/
};
const CASE_SENSITIVITY = {
scope: "symbol",
match: /%[si](?=".*")/
};
const RULE_DECLARATION = {
scope: "attribute",
match: regex.concat(IDENT, /(?=\s*=)/)
};
const ASSIGNMENT = {
scope: "operator",
match: /=\/?/
};
return {
name: 'Augmented Backus-Naur Form',
illegal: /[!@#$^&',?+~`|:]/,
keywords: KEYWORDS,
contains: [
ASSIGNMENT,
RULE_DECLARATION,
COMMENT,
TERMINAL_BINARY,
TERMINAL_DECIMAL,
TERMINAL_HEXADECIMAL,
CASE_SENSITIVITY,
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE
]
};
}
var abnf_1 = abnf;
/*
Language: Apache Access Log
Author: Oleg Efimov <efimovov@gmail.com>
Description: Apache/Nginx Access Logs
Website: https://httpd.apache.org/docs/2.4/logs.html#accesslog
Category: web, logs
Audit: 2020
*/
/** @type LanguageFn */
function accesslog(hljs) {
const regex = hljs.regex;
// https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods
const HTTP_VERBS = [
"GET",
"POST",
"HEAD",
"PUT",
"DELETE",
"CONNECT",
"OPTIONS",
"PATCH",
"TRACE"
];
return {
name: 'Apache Access Log',
contains: [
// IP
{
className: 'number',
begin: /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}(:\d{1,5})?\b/,
relevance: 5
},
// Other numbers
{
className: 'number',
begin: /\b\d+\b/,
relevance: 0
},
// Requests
{
className: 'string',
begin: regex.concat(/"/, regex.either(...HTTP_VERBS)),
end: /"/,
keywords: HTTP_VERBS,
illegal: /\n/,
relevance: 5,
contains: [
{
begin: /HTTP\/[12]\.\d'/,
relevance: 5
}
]
},
// Dates
{
className: 'string',
// dates must have a certain length, this prevents matching
// simple array accesses a[123] and [] and other common patterns
// found in other languages
begin: /\[\d[^\]\n]{8,}\]/,
illegal: /\n/,
relevance: 1
},
{
className: 'string',
begin: /\[/,
end: /\]/,
illegal: /\n/,
relevance: 0
},
// User agent / relevance boost
{
className: 'string',
begin: /"Mozilla\/\d\.\d \(/,
end: /"/,
illegal: /\n/,
relevance: 3
},
// Strings
{
className: 'string',
begin: /"/,
end: /"/,
illegal: /\n/,
relevance: 0
}
]
};
}
var accesslog_1 = accesslog;
/*
Language: ActionScript
Author: Alexander Myadzel <myadzel@gmail.com>
Category: scripting
Audit: 2020
*/
/** @type LanguageFn */
function actionscript(hljs) {
const regex = hljs.regex;
const IDENT_RE = /[a-zA-Z_$][a-zA-Z0-9_$]*/;
const PKG_NAME_RE = regex.concat(
IDENT_RE,
regex.concat("(\\.", IDENT_RE, ")*")
);
const IDENT_FUNC_RETURN_TYPE_RE = /([*]|[a-zA-Z_$][a-zA-Z0-9_$]*)/;
const AS3_REST_ARG_MODE = {
className: 'rest_arg',
begin: /[.]{3}/,
end: IDENT_RE,
relevance: 10
};
const KEYWORDS = [
"as",
"break",
"case",
"catch",
"class",
"const",
"continue",
"default",
"delete",
"do",
"dynamic",
"each",
"else",
"extends",
"final",
"finally",
"for",
"function",
"get",
"if",
"implements",
"import",
"in",
"include",
"instanceof",
"interface",
"internal",
"is",
"namespace",
"native",
"new",
"override",
"package",
"private",
"protected",
"public",
"return",
"set",
"static",
"super",
"switch",
"this",
"throw",
"try",
"typeof",
"use",
"var",
"void",
"while",
"with"
];
const LITERALS = [
"true",
"false",
"null",
"undefined"
];
return {
name: 'ActionScript',
aliases: [ 'as' ],
keywords: {
keyword: KEYWORDS,
literal: LITERALS
},
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_NUMBER_MODE,
{
match: [
/\bpackage/,
/\s+/,
PKG_NAME_RE
],
className: {
1: "keyword",
3: "title.class"
}
},
{
match: [
/\b(?:class|interface|extends|implements)/,
/\s+/,
IDENT_RE
],
className: {
1: "keyword",
3: "title.class"
}
},
{
className: 'meta',
beginKeywords: 'import include',
end: /;/,
keywords: { keyword: 'import include' }
},
{
beginKeywords: 'function',
end: /[{;]/,
excludeEnd: true,
illegal: /\S/,
contains: [
hljs.inherit(hljs.TITLE_MODE, { className: "title.function" }),
{
className: 'params',
begin: /\(/,
end: /\)/,
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AS3_REST_ARG_MODE
]
},
{ begin: regex.concat(/:\s*/, IDENT_FUNC_RETURN_TYPE_RE) }
]
},
hljs.METHOD_GUARD
],
illegal: /#/
};
}
var actionscript_1 = actionscript;
/*
Language: Ada
Author: Lars Schulna <kartoffelbrei.mit.muskatnuss@gmail.org>
Description: Ada is a general-purpose programming language that has great support for saftey critical and real-time applications.
It has been developed by the DoD and thus has been used in military and safety-critical applications (like civil aviation).
The first version appeared in the 80s, but it's still actively developed today with
the newest standard being Ada2012.
*/
// We try to support full Ada2012
//
// We highlight all appearances of types, keywords, literals (string, char, number, bool)
// and titles (user defined function/procedure/package)
// CSS classes are set accordingly
//
// Languages causing problems for language detection:
// xml (broken by Foo : Bar type), elm (broken by Foo : Bar type), vbscript-html (broken by body keyword)
// sql (ada default.txt has a lot of sql keywords)
/** @type LanguageFn */
function ada(hljs) {
// Regular expression for Ada numeric literals.
// stolen form the VHDL highlighter
// Decimal literal:
const INTEGER_RE = '\\d(_|\\d)*';
const EXPONENT_RE = '[eE][-+]?' + INTEGER_RE;
const DECIMAL_LITERAL_RE = INTEGER_RE + '(\\.' + INTEGER_RE + ')?' + '(' + EXPONENT_RE + ')?';
// Based literal:
const BASED_INTEGER_RE = '\\w+';
const BASED_LITERAL_RE = INTEGER_RE + '#' + BASED_INTEGER_RE + '(\\.' + BASED_INTEGER_RE + ')?' + '#' + '(' + EXPONENT_RE + ')?';
const NUMBER_RE = '\\b(' + BASED_LITERAL_RE + '|' + DECIMAL_LITERAL_RE + ')';
// Identifier regex
const ID_REGEX = '[A-Za-z](_?[A-Za-z0-9.])*';
// bad chars, only allowed in literals
const BAD_CHARS = `[]\\{\\}%#'"`;
// Ada doesn't have block comments, only line comments
const COMMENTS = hljs.COMMENT('--', '$');
// variable declarations of the form
// Foo : Bar := Baz;
// where only Bar will be highlighted
const VAR_DECLS = {
// TODO: These spaces are not required by the Ada syntax
// however, I have yet to see handwritten Ada code where
// someone does not put spaces around :
begin: '\\s+:\\s+',
end: '\\s*(:=|;|\\)|=>|$)',
// endsWithParent: true,
// returnBegin: true,
illegal: BAD_CHARS,
contains: [
{
// workaround to avoid highlighting
// named loops and declare blocks
beginKeywords: 'loop for declare others',
endsParent: true
},
{
// properly highlight all modifiers
className: 'keyword',
beginKeywords: 'not null constant access function procedure in out aliased exception'
},
{
className: 'type',
begin: ID_REGEX,
endsParent: true,
relevance: 0
}
]
};
const KEYWORDS = [
"abort",
"else",
"new",
"return",
"abs",
"elsif",
"not",
"reverse",
"abstract",
"end",
"accept",
"entry",
"select",
"access",
"exception",
"of",
"separate",
"aliased",
"exit",
"or",
"some",
"all",
"others",
"subtype",
"and",
"for",
"out",
"synchronized",
"array",
"function",
"overriding",
"at",
"tagged",
"generic",
"package",
"task",
"begin",
"goto",
"pragma",
"terminate",
"body",
"private",
"then",
"if",
"procedure",
"type",
"case",
"in",
"protected",
"constant",
"interface",
"is",
"raise",
"use",
"declare",
"range",
"delay",
"limited",
"record",
"when",
"delta",
"loop",
"rem",
"while",
"digits",
"renames",
"with",
"do",
"mod",
"requeue",
"xor"
];
return {
name: 'Ada',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
literal: [
"True",
"False"
]
},
contains: [
COMMENTS,
// strings "foobar"
{
className: 'string',
begin: /"/,
end: /"/,
contains: [
{
begin: /""/,
relevance: 0
}
]
},
// characters ''
{
// character literals always contain one char
className: 'string',
begin: /'.'/
},
{
// number literals
className: 'number',
begin: NUMBER_RE,
relevance: 0
},
{
// Attributes
className: 'symbol',
begin: "'" + ID_REGEX
},
{
// package definition, maybe inside generic
className: 'title',
begin: '(\\bwith\\s+)?(\\bprivate\\s+)?\\bpackage\\s+(\\bbody\\s+)?',
end: '(is|$)',
keywords: 'package body',
excludeBegin: true,
excludeEnd: true,
illegal: BAD_CHARS
},
{
// function/procedure declaration/definition
// maybe inside generic
begin: '(\\b(with|overriding)\\s+)?\\b(function|procedure)\\s+',
end: '(\\bis|\\bwith|\\brenames|\\)\\s*;)',
keywords: 'overriding function procedure with is renames return',
// we need to re-match the 'function' keyword, so that
// the title mode below matches only exactly once
returnBegin: true,
contains:
[
COMMENTS,
{
// name of the function/procedure
className: 'title',
begin: '(\\bwith\\s+)?\\b(function|procedure)\\s+',
end: '(\\(|\\s+|$)',
excludeBegin: true,
excludeEnd: true,
illegal: BAD_CHARS
},
// 'self'
// // parameter types
VAR_DECLS,
{
// return type
className: 'type',
begin: '\\breturn\\s+',
end: '(\\s+|;|$)',
keywords: 'return',
excludeBegin: true,
excludeEnd: true,
// we are done with functions
endsParent: true,
illegal: BAD_CHARS
}
]
},
{
// new type declarations
// maybe inside generic
className: 'type',
begin: '\\b(sub)?type\\s+',
end: '\\s+',
keywords: 'type',
excludeBegin: true,
illegal: BAD_CHARS
},
// see comment above the definition
VAR_DECLS
// no markup
// relevance boosters for small snippets
// {begin: '\\s*=>\\s*'},
// {begin: '\\s*:=\\s*'},
// {begin: '\\s+:=\\s+'},
]
};
}
var ada_1 = ada;
/*
Language: AngelScript
Author: Melissa Geels <melissa@nimble.tools>
Category: scripting
Website: https://www.angelcode.com/angelscript/
*/
/** @type LanguageFn */
function angelscript(hljs) {
const builtInTypeMode = {
className: 'built_in',
begin: '\\b(void|bool|int8|int16|int32|int64|int|uint8|uint16|uint32|uint64|uint|string|ref|array|double|float|auto|dictionary)'
};
const objectHandleMode = {
className: 'symbol',
begin: '[a-zA-Z0-9_]+@'
};
const genericMode = {
className: 'keyword',
begin: '<',
end: '>',
contains: [
builtInTypeMode,
objectHandleMode
]
};
builtInTypeMode.contains = [ genericMode ];
objectHandleMode.contains = [ genericMode ];
const KEYWORDS = [
"for",
"in|0",
"break",
"continue",
"while",
"do|0",
"return",
"if",
"else",
"case",
"switch",
"namespace",
"is",
"cast",
"or",
"and",
"xor",
"not",
"get|0",
"in",
"inout|10",
"out",
"override",
"set|0",
"private",
"public",
"const",
"default|0",
"final",
"shared",
"external",
"mixin|10",
"enum",
"typedef",
"funcdef",
"this",
"super",
"import",
"from",
"interface",
"abstract|0",
"try",
"catch",
"protected",
"explicit",
"property"
];
return {
name: 'AngelScript',
aliases: [ 'asc' ],
keywords: KEYWORDS,
// avoid close detection with C# and JS
illegal: '(^using\\s+[A-Za-z0-9_\\.]+;$|\\bfunction\\s*[^\\(])',
contains: [
{ // 'strings'
className: 'string',
begin: '\'',
end: '\'',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ],
relevance: 0
},
// """heredoc strings"""
{
className: 'string',
begin: '"""',
end: '"""'
},
{ // "strings"
className: 'string',
begin: '"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ],
relevance: 0
},
hljs.C_LINE_COMMENT_MODE, // single-line comments
hljs.C_BLOCK_COMMENT_MODE, // comment blocks
{ // metadata
className: 'string',
begin: '^\\s*\\[',
end: '\\]'
},
{ // interface or namespace declaration
beginKeywords: 'interface namespace',
end: /\{/,
illegal: '[;.\\-]',
contains: [
{ // interface or namespace name
className: 'symbol',
begin: '[a-zA-Z0-9_]+'
}
]
},
{ // class declaration
beginKeywords: 'class',
end: /\{/,
illegal: '[;.\\-]',
contains: [
{ // class name
className: 'symbol',
begin: '[a-zA-Z0-9_]+',
contains: [
{
begin: '[:,]\\s*',
contains: [
{
className: 'symbol',
begin: '[a-zA-Z0-9_]+'
}
]
}
]
}
]
},
builtInTypeMode, // built-in types
objectHandleMode, // object handles
{ // literals
className: 'literal',
begin: '\\b(null|true|false)'
},
{ // numbers
className: 'number',
relevance: 0,
begin: '(-?)(\\b0[xXbBoOdD][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?f?|\\.\\d+f?)([eE][-+]?\\d+f?)?)'
}
]
};
}
var angelscript_1 = angelscript;
/*
Language: Apache config
Author: Ruslan Keba <rukeba@gmail.com>
Contributors: Ivan Sagalaev <maniac@softwaremaniacs.org>
Website: https://httpd.apache.org
Description: language definition for Apache configuration files (httpd.conf & .htaccess)
Category: config, web
Audit: 2020
*/
/** @type LanguageFn */
function apache(hljs) {
const NUMBER_REF = {
className: 'number',
begin: /[$%]\d+/
};
const NUMBER = {
className: 'number',
begin: /\b\d+/
};
const IP_ADDRESS = {
className: "number",
begin: /\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}(:\d{1,5})?/
};
const PORT_NUMBER = {
className: "number",
begin: /:\d{1,5}/
};
return {
name: 'Apache config',
aliases: [ 'apacheconf' ],
case_insensitive: true,
contains: [
hljs.HASH_COMMENT_MODE,
{
className: 'section',
begin: /<\/?/,
end: />/,
contains: [
IP_ADDRESS,
PORT_NUMBER,
// low relevance prevents us from claming XML/HTML where this rule would
// match strings inside of XML tags
hljs.inherit(hljs.QUOTE_STRING_MODE, { relevance: 0 })
]
},
{
className: 'attribute',
begin: /\w+/,
relevance: 0,
// keywords arent needed for highlighting per se, they only boost relevance
// for a very generally defined mode (starts with a word, ends with line-end
keywords: { _: [
"order",
"deny",
"allow",
"setenv",
"rewriterule",
"rewriteengine",
"rewritecond",
"documentroot",
"sethandler",
"errordocument",
"loadmodule",
"options",
"header",
"listen",
"serverroot",
"servername"
] },
starts: {
end: /$/,
relevance: 0,
keywords: { literal: 'on off all deny allow' },
contains: [
{
className: 'meta',
begin: /\s\[/,
end: /\]$/
},
{
className: 'variable',
begin: /[\$%]\{/,
end: /\}/,
contains: [
'self',
NUMBER_REF
]
},
IP_ADDRESS,
NUMBER,
hljs.QUOTE_STRING_MODE
]
}
}
],
illegal: /\S/
};
}
var apache_1 = apache;
/*
Language: AppleScript
Authors: Nathan Grigg <nathan@nathanamy.org>, Dr. Drang <drdrang@gmail.com>
Category: scripting
Website: https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/introduction/ASLR_intro.html
Audit: 2020
*/
/** @type LanguageFn */
function applescript(hljs) {
const regex = hljs.regex;
const STRING = hljs.inherit(
hljs.QUOTE_STRING_MODE, { illegal: null });
const PARAMS = {
className: 'params',
begin: /\(/,
end: /\)/,
contains: [
'self',
hljs.C_NUMBER_MODE,
STRING
]
};
const COMMENT_MODE_1 = hljs.COMMENT(/--/, /$/);
const COMMENT_MODE_2 = hljs.COMMENT(
/\(\*/,
/\*\)/,
{ contains: [
'self', // allow nesting
COMMENT_MODE_1
] }
);
const COMMENTS = [
COMMENT_MODE_1,
COMMENT_MODE_2,
hljs.HASH_COMMENT_MODE
];
const KEYWORD_PATTERNS = [
/apart from/,
/aside from/,
/instead of/,
/out of/,
/greater than/,
/isn't|(doesn't|does not) (equal|come before|come after|contain)/,
/(greater|less) than( or equal)?/,
/(starts?|ends|begins?) with/,
/contained by/,
/comes (before|after)/,
/a (ref|reference)/,
/POSIX (file|path)/,
/(date|time) string/,
/quoted form/
];
const BUILT_IN_PATTERNS = [
/clipboard info/,
/the clipboard/,
/info for/,
/list (disks|folder)/,
/mount volume/,
/path to/,
/(close|open for) access/,
/(get|set) eof/,
/current date/,
/do shell script/,
/get volume settings/,
/random number/,
/set volume/,
/system attribute/,
/system info/,
/time to GMT/,
/(load|run|store) script/,
/scripting components/,
/ASCII (character|number)/,
/localized string/,
/choose (application|color|file|file name|folder|from list|remote application|URL)/,
/display (alert|dialog)/
];
return {
name: 'AppleScript',
aliases: [ 'osascript' ],
keywords: {
keyword:
'about above after against and around as at back before beginning '
+ 'behind below beneath beside between but by considering '
+ 'contain contains continue copy div does eighth else end equal '
+ 'equals error every exit fifth first for fourth from front '
+ 'get given global if ignoring in into is it its last local me '
+ 'middle mod my ninth not of on onto or over prop property put ref '
+ 'reference repeat returning script second set seventh since '
+ 'sixth some tell tenth that the|0 then third through thru '
+ 'timeout times to transaction try until where while whose with '
+ 'without',
literal:
'AppleScript false linefeed return pi quote result space tab true',
built_in:
'alias application boolean class constant date file integer list '
+ 'number real record string text '
+ 'activate beep count delay launch log offset read round '
+ 'run say summarize write '
+ 'character characters contents day frontmost id item length '
+ 'month name|0 paragraph paragraphs rest reverse running time version '
+ 'weekday word words year'
},
contains: [
STRING,
hljs.C_NUMBER_MODE,
{
className: 'built_in',
begin: regex.concat(
/\b/,
regex.either(...BUILT_IN_PATTERNS),
/\b/
)
},
{
className: 'built_in',
begin: /^\s*return\b/
},
{
className: 'literal',
begin:
/\b(text item delimiters|current application|missing value)\b/
},
{
className: 'keyword',
begin: regex.concat(
/\b/,
regex.either(...KEYWORD_PATTERNS),
/\b/
)
},
{
beginKeywords: 'on',
illegal: /[${=;\n]/,
contains: [
hljs.UNDERSCORE_TITLE_MODE,
PARAMS
]
},
...COMMENTS
],
illegal: /\/\/|->|=>|\[\[/
};
}
var applescript_1 = applescript;
/*
Language: ArcGIS Arcade
Category: scripting
Author: John Foster <jfoster@esri.com>
Website: https://developers.arcgis.com/arcade/
Description: ArcGIS Arcade is an expression language used in many Esri ArcGIS products such as Pro, Online, Server, Runtime, JavaScript, and Python
*/
/** @type LanguageFn */
function arcade(hljs) {
const IDENT_RE = '[A-Za-z_][0-9A-Za-z_]*';
const KEYWORDS = {
keyword: [
"if",
"for",
"while",
"var",
"new",
"function",
"do",
"return",
"void",
"else",
"break"
],
literal: [
"BackSlash",
"DoubleQuote",
"false",
"ForwardSlash",
"Infinity",
"NaN",
"NewLine",
"null",
"PI",
"SingleQuote",
"Tab",
"TextFormatting",
"true",
"undefined"
],
built_in: [
"Abs",
"Acos",
"All",
"Angle",
"Any",
"Area",
"AreaGeodetic",
"Array",
"Asin",
"Atan",
"Atan2",
"Attachments",
"Average",
"Back",
"Bearing",
"Boolean",
"Buffer",
"BufferGeodetic",
"Ceil",
"Centroid",
"Clip",
"Concatenate",
"Console",
"Constrain",
"Contains",
"ConvertDirection",
"Cos",
"Count",
"Crosses",
"Cut",
"Date",
"DateAdd",
"DateDiff",
"Day",
"Decode",
"DefaultValue",
"Densify",
"DensifyGeodetic",
"Dictionary",
"Difference",
"Disjoint",
"Distance",
"DistanceGeodetic",
"Distinct",
"Domain",
"DomainCode",
"DomainName",
"EnvelopeIntersects",
"Equals",
"Erase",
"Exp",
"Expects",
"Extent",
"Feature",
"FeatureSet",
"FeatureSetByAssociation",
"FeatureSetById",
"FeatureSetByName",
"FeatureSetByPortalItem",
"FeatureSetByRelationshipName",
"Filter",
"Find",
"First",
"Floor",
"FromCharCode",
"FromCodePoint",
"FromJSON",
"GdbVersion",
"Generalize",
"Geometry",
"GetFeatureSet",
"GetUser",
"GroupBy",
"Guid",
"Hash",
"HasKey",
"Hour",
"IIf",
"Includes",
"IndexOf",
"Insert",
"Intersection",
"Intersects",
"IsEmpty",
"IsNan",
"ISOMonth",
"ISOWeek",
"ISOWeekday",
"ISOYear",
"IsSelfIntersecting",
"IsSimple",
"Left|0",
"Length",
"Length3D",
"LengthGeodetic",
"Log",
"Lower",
"Map",
"Max",
"Mean",
"Mid",
"Millisecond",
"Min",
"Minute",
"Month",
"MultiPartToSinglePart",
"Multipoint",
"NextSequenceValue",
"None",
"Now",
"Number",
"Offset|0",
"OrderBy",
"Overlaps",
"Point",
"Polygon",
"Polyline",
"Pop",
"Portal",
"Pow",
"Proper",
"Push",
"Random",
"Reduce",
"Relate",
"Replace",
"Resize",
"Reverse",
"Right|0",
"RingIsClockwise",
"Rotate",
"Round",
"Schema",
"Second",
"SetGeometry",
"Simplify",
"Sin",
"Slice",
"Sort",
"Splice",
"Split",
"Sqrt",
"Stdev",
"SubtypeCode",
"SubtypeName",
"Subtypes",
"Sum",
"SymmetricDifference",
"Tan",
"Text",
"Timestamp",
"ToCharCode",
"ToCodePoint",
"Today",
"ToHex",
"ToLocal",
"Top|0",
"Touches",
"ToUTC",
"TrackAccelerationAt",
"TrackAccelerationWindow",
"TrackCurrentAcceleration",
"TrackCurrentDistance",
"TrackCurrentSpeed",
"TrackCurrentTime",
"TrackDistanceAt",
"TrackDistanceWindow",
"TrackDuration",
"TrackFieldWindow",
"TrackGeometryWindow",
"TrackIndex",
"TrackSpeedAt",
"TrackSpeedWindow",
"TrackStartTime",
"TrackWindow",
"Trim",
"TypeOf",
"Union",
"Upper",
"UrlEncode",
"Variance",
"Week",
"Weekday",
"When",
"Within",
"Year"
]
};
const SYMBOL = {
className: 'symbol',
begin: '\\$[datastore|feature|layer|map|measure|sourcefeature|sourcelayer|targetfeature|targetlayer|value|view]+'
};
const NUMBER = {
className: 'number',
variants: [
{ begin: '\\b(0[bB][01]+)' },
{ begin: '\\b(0[oO][0-7]+)' },
{ begin: hljs.C_NUMBER_RE }
],
relevance: 0
};
const SUBST = {
className: 'subst',
begin: '\\$\\{',
end: '\\}',
keywords: KEYWORDS,
contains: [] // defined later
};
const TEMPLATE_STRING = {
className: 'string',
begin: '`',
end: '`',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
};
SUBST.contains = [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
TEMPLATE_STRING,
NUMBER,
hljs.REGEXP_MODE
];
const PARAMS_CONTAINS = SUBST.contains.concat([
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_LINE_COMMENT_MODE
]);
return {
name: 'ArcGIS Arcade',
case_insensitive: true,
keywords: KEYWORDS,
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
TEMPLATE_STRING,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
SYMBOL,
NUMBER,
{ // object attr container
begin: /[{,]\s*/,
relevance: 0,
contains: [
{
begin: IDENT_RE + '\\s*:',
returnBegin: true,
relevance: 0,
contains: [
{
className: 'attr',
begin: IDENT_RE,
relevance: 0
}
]
}
]
},
{ // "value" container
begin: '(' + hljs.RE_STARTERS_RE + '|\\b(return)\\b)\\s*',
keywords: 'return',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.REGEXP_MODE,
{
className: 'function',
begin: '(\\(.*?\\)|' + IDENT_RE + ')\\s*=>',
returnBegin: true,
end: '\\s*=>',
contains: [
{
className: 'params',
variants: [
{ begin: IDENT_RE },
{ begin: /\(\s*\)/ },
{
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS,
contains: PARAMS_CONTAINS
}
]
}
]
}
],
relevance: 0
},
{
beginKeywords: 'function',
end: /\{/,
excludeEnd: true,
contains: [
hljs.inherit(hljs.TITLE_MODE, {
className: "title.function",
begin: IDENT_RE
}),
{
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
contains: PARAMS_CONTAINS
}
],
illegal: /\[|%/
},
{ begin: /\$[(.]/ }
],
illegal: /#(?!!)/
};
}
var arcade_1 = arcade;
/*
Language: C++
Category: common, system
Website: https://isocpp.org
*/
/** @type LanguageFn */
function cPlusPlus(hljs) {
const regex = hljs.regex;
// added for historic reasons because `hljs.C_LINE_COMMENT_MODE` does
// not include such support nor can we be sure all the grammars depending
// on it would desire this behavior
const C_LINE_COMMENT_MODE = hljs.COMMENT('//', '$', { contains: [ { begin: /\\\n/ } ] });
const DECLTYPE_AUTO_RE = 'decltype\\(auto\\)';
const NAMESPACE_RE = '[a-zA-Z_]\\w*::';
const TEMPLATE_ARGUMENT_RE = '<[^<>]+>';
const FUNCTION_TYPE_RE = '(?!struct)('
+ DECLTYPE_AUTO_RE + '|'
+ regex.optional(NAMESPACE_RE)
+ '[a-zA-Z_]\\w*' + regex.optional(TEMPLATE_ARGUMENT_RE)
+ ')';
const CPP_PRIMITIVE_TYPES = {
className: 'type',
begin: '\\b[a-z\\d_]*_t\\b'
};
// https://en.cppreference.com/w/cpp/language/escape
// \\ \x \xFF \u2837 \u00323747 \374
const CHARACTER_ESCAPES = '\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)';
const STRINGS = {
className: 'string',
variants: [
{
begin: '(u8?|U|L)?"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '(u8?|U|L)?\'(' + CHARACTER_ESCAPES + '|.)',
end: '\'',
illegal: '.'
},
hljs.END_SAME_AS_BEGIN({
begin: /(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,
end: /\)([^()\\ ]{0,16})"/
})
]
};
const NUMBERS = {
className: 'number',
variants: [
{ begin: '\\b(0b[01\']+)' },
{ begin: '(-?)\\b([\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)' },
{ begin: '(-?)(\\b0[xX][a-fA-F0-9\']+|(\\b[\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)([eE][-+]?[\\d\']+)?)' }
],
relevance: 0
};
const PREPROCESSOR = {
className: 'meta',
begin: /#\s*[a-z]+\b/,
end: /$/,
keywords: { keyword:
'if else elif endif define undef warning error line '
+ 'pragma _Pragma ifdef ifndef include' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
hljs.inherit(STRINGS, { className: 'string' }),
{
className: 'string',
begin: /<.*?>/
},
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
const TITLE_MODE = {
className: 'title',
begin: regex.optional(NAMESPACE_RE) + hljs.IDENT_RE,
relevance: 0
};
const FUNCTION_TITLE = regex.optional(NAMESPACE_RE) + hljs.IDENT_RE + '\\s*\\(';
// https://en.cppreference.com/w/cpp/keyword
const RESERVED_KEYWORDS = [
'alignas',
'alignof',
'and',
'and_eq',
'asm',
'atomic_cancel',
'atomic_commit',
'atomic_noexcept',
'auto',
'bitand',
'bitor',
'break',
'case',
'catch',
'class',
'co_await',
'co_return',
'co_yield',
'compl',
'concept',
'const_cast|10',
'consteval',
'constexpr',
'constinit',
'continue',
'decltype',
'default',
'delete',
'do',
'dynamic_cast|10',
'else',
'enum',
'explicit',
'export',
'extern',
'false',
'final',
'for',
'friend',
'goto',
'if',
'import',
'inline',
'module',
'mutable',
'namespace',
'new',
'noexcept',
'not',
'not_eq',
'nullptr',
'operator',
'or',
'or_eq',
'override',
'private',
'protected',
'public',
'reflexpr',
'register',
'reinterpret_cast|10',
'requires',
'return',
'sizeof',
'static_assert',
'static_cast|10',
'struct',
'switch',
'synchronized',
'template',
'this',
'thread_local',
'throw',
'transaction_safe',
'transaction_safe_dynamic',
'true',
'try',
'typedef',
'typeid',
'typename',
'union',
'using',
'virtual',
'volatile',
'while',
'xor',
'xor_eq'
];
// https://en.cppreference.com/w/cpp/keyword
const RESERVED_TYPES = [
'bool',
'char',
'char16_t',
'char32_t',
'char8_t',
'double',
'float',
'int',
'long',
'short',
'void',
'wchar_t',
'unsigned',
'signed',
'const',
'static'
];
const TYPE_HINTS = [
'any',
'auto_ptr',
'barrier',
'binary_semaphore',
'bitset',
'complex',
'condition_variable',
'condition_variable_any',
'counting_semaphore',
'deque',
'false_type',
'future',
'imaginary',
'initializer_list',
'istringstream',
'jthread',
'latch',
'lock_guard',
'multimap',
'multiset',
'mutex',
'optional',
'ostringstream',
'packaged_task',
'pair',
'promise',
'priority_queue',
'queue',
'recursive_mutex',
'recursive_timed_mutex',
'scoped_lock',
'set',
'shared_future',
'shared_lock',
'shared_mutex',
'shared_timed_mutex',
'shared_ptr',
'stack',
'string_view',
'stringstream',
'timed_mutex',
'thread',
'true_type',
'tuple',
'unique_lock',
'unique_ptr',
'unordered_map',
'unordered_multimap',
'unordered_multiset',
'unordered_set',
'variant',
'vector',
'weak_ptr',
'wstring',
'wstring_view'
];
const FUNCTION_HINTS = [
'abort',
'abs',
'acos',
'apply',
'as_const',
'asin',
'atan',
'atan2',
'calloc',
'ceil',
'cerr',
'cin',
'clog',
'cos',
'cosh',
'cout',
'declval',
'endl',
'exchange',
'exit',
'exp',
'fabs',
'floor',
'fmod',
'forward',
'fprintf',
'fputs',
'free',
'frexp',
'fscanf',
'future',
'invoke',
'isalnum',
'isalpha',
'iscntrl',
'isdigit',
'isgraph',
'islower',
'isprint',
'ispunct',
'isspace',
'isupper',
'isxdigit',
'labs',
'launder',
'ldexp',
'log',
'log10',
'make_pair',
'make_shared',
'make_shared_for_overwrite',
'make_tuple',
'make_unique',
'malloc',
'memchr',
'memcmp',
'memcpy',
'memset',
'modf',
'move',
'pow',
'printf',
'putchar',
'puts',
'realloc',
'scanf',
'sin',
'sinh',
'snprintf',
'sprintf',
'sqrt',
'sscanf',
'std',
'stderr',
'stdin',
'stdout',
'strcat',
'strchr',
'strcmp',
'strcpy',
'strcspn',
'strlen',
'strncat',
'strncmp',
'strncpy',
'strpbrk',
'strrchr',
'strspn',
'strstr',
'swap',
'tan',
'tanh',
'terminate',
'to_underlying',
'tolower',
'toupper',
'vfprintf',
'visit',
'vprintf',
'vsprintf'
];
const LITERALS = [
'NULL',
'false',
'nullopt',
'nullptr',
'true'
];
// https://en.cppreference.com/w/cpp/keyword
const BUILT_IN = [ '_Pragma' ];
const CPP_KEYWORDS = {
type: RESERVED_TYPES,
keyword: RESERVED_KEYWORDS,
literal: LITERALS,
built_in: BUILT_IN,
_type_hints: TYPE_HINTS
};
const FUNCTION_DISPATCH = {
className: 'function.dispatch',
relevance: 0,
keywords: {
// Only for relevance, not highlighting.
_hint: FUNCTION_HINTS },
begin: regex.concat(
/\b/,
/(?!decltype)/,
/(?!if)/,
/(?!for)/,
/(?!switch)/,
/(?!while)/,
hljs.IDENT_RE,
regex.lookahead(/(<[^<>]+>|)\s*\(/))
};
const EXPRESSION_CONTAINS = [
FUNCTION_DISPATCH,
PREPROCESSOR,
CPP_PRIMITIVE_TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
NUMBERS,
STRINGS
];
const EXPRESSION_CONTEXT = {
// This mode covers expression context where we can't expect a function
// definition and shouldn't highlight anything that looks like one:
// `return some()`, `else if()`, `(x*sum(1, 2))`
variants: [
{
begin: /=/,
end: /;/
},
{
begin: /\(/,
end: /\)/
},
{
beginKeywords: 'new throw return else',
end: /;/
}
],
keywords: CPP_KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([
{
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([ 'self' ]),
relevance: 0
}
]),
relevance: 0
};
const FUNCTION_DECLARATION = {
className: 'function',
begin: '(' + FUNCTION_TYPE_RE + '[\\*&\\s]+)+' + FUNCTION_TITLE,
returnBegin: true,
end: /[{;=]/,
excludeEnd: true,
keywords: CPP_KEYWORDS,
illegal: /[^\w\s\*&:<>.]/,
contains: [
{ // to prevent it from being confused as the function title
begin: DECLTYPE_AUTO_RE,
keywords: CPP_KEYWORDS,
relevance: 0
},
{
begin: FUNCTION_TITLE,
returnBegin: true,
contains: [ TITLE_MODE ],
relevance: 0
},
// needed because we do not have look-behind on the below rule
// to prevent it from grabbing the final : in a :: pair
{
begin: /::/,
relevance: 0
},
// initializers
{
begin: /:/,
endsWithParent: true,
contains: [
STRINGS,
NUMBERS
]
},
// allow for multiple declarations, e.g.:
// extern void f(int), g(char);
{
relevance: 0,
match: /,/
},
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
relevance: 0,
contains: [
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
CPP_PRIMITIVE_TYPES,
// Count matching parentheses.
{
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
relevance: 0,
contains: [
'self',
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
CPP_PRIMITIVE_TYPES
]
}
]
},
CPP_PRIMITIVE_TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
PREPROCESSOR
]
};
return {
name: 'C++',
aliases: [
'cc',
'c++',
'h++',
'hpp',
'hh',
'hxx',
'cxx'
],
keywords: CPP_KEYWORDS,
illegal: '</',
classNameAliases: { 'function.dispatch': 'built_in' },
contains: [].concat(
EXPRESSION_CONTEXT,
FUNCTION_DECLARATION,
FUNCTION_DISPATCH,
EXPRESSION_CONTAINS,
[
PREPROCESSOR,
{ // containers: ie, `vector <int> rooms (9);`
begin: '\\b(deque|list|queue|priority_queue|pair|stack|vector|map|set|bitset|multiset|multimap|unordered_map|unordered_set|unordered_multiset|unordered_multimap|array|tuple|optional|variant|function)\\s*<(?!<)',
end: '>',
keywords: CPP_KEYWORDS,
contains: [
'self',
CPP_PRIMITIVE_TYPES
]
},
{
begin: hljs.IDENT_RE + '::',
keywords: CPP_KEYWORDS
},
{
match: [
// extra complexity to deal with `enum class` and `enum struct`
/\b(?:enum(?:\s+(?:class|struct))?|class|struct|union)/,
/\s+/,
/\w+/
],
className: {
1: 'keyword',
3: 'title.class'
}
}
])
};
}
/*
Language: Arduino
Author: Stefania Mellai <s.mellai@arduino.cc>
Description: The Arduino® Language is a superset of C++. This rules are designed to highlight the Arduino® source code. For info about language see http://www.arduino.cc.
Website: https://www.arduino.cc
*/
/** @type LanguageFn */
function arduino(hljs) {
const ARDUINO_KW = {
type: [
"boolean",
"byte",
"word",
"String"
],
built_in: [
"KeyboardController",
"MouseController",
"SoftwareSerial",
"EthernetServer",
"EthernetClient",
"LiquidCrystal",
"RobotControl",
"GSMVoiceCall",
"EthernetUDP",
"EsploraTFT",
"HttpClient",
"RobotMotor",
"WiFiClient",
"GSMScanner",
"FileSystem",
"Scheduler",
"GSMServer",
"YunClient",
"YunServer",
"IPAddress",
"GSMClient",
"GSMModem",
"Keyboard",
"Ethernet",
"Console",
"GSMBand",
"Esplora",
"Stepper",
"Process",
"WiFiUDP",
"GSM_SMS",
"Mailbox",
"USBHost",
"Firmata",
"PImage",
"Client",
"Server",
"GSMPIN",
"FileIO",
"Bridge",
"Serial",
"EEPROM",
"Stream",
"Mouse",
"Audio",
"Servo",
"File",
"Task",
"GPRS",
"WiFi",
"Wire",
"TFT",
"GSM",
"SPI",
"SD"
],
_hints: [
"setup",
"loop",
"runShellCommandAsynchronously",
"analogWriteResolution",
"retrieveCallingNumber",
"printFirmwareVersion",
"analogReadResolution",
"sendDigitalPortPair",
"noListenOnLocalhost",
"readJoystickButton",
"setFirmwareVersion",
"readJoystickSwitch",
"scrollDisplayRight",
"getVoiceCallStatus",
"scrollDisplayLeft",
"writeMicroseconds",
"delayMicroseconds",
"beginTransmission",
"getSignalStrength",
"runAsynchronously",
"getAsynchronously",
"listenOnLocalhost",
"getCurrentCarrier",
"readAccelerometer",
"messageAvailable",
"sendDigitalPorts",
"lineFollowConfig",
"countryNameWrite",
"runShellCommand",
"readStringUntil",
"rewindDirectory",
"readTemperature",
"setClockDivider",
"readLightSensor",
"endTransmission",
"analogReference",
"detachInterrupt",
"countryNameRead",
"attachInterrupt",
"encryptionType",
"readBytesUntil",
"robotNameWrite",
"readMicrophone",
"robotNameRead",
"cityNameWrite",
"userNameWrite",
"readJoystickY",
"readJoystickX",
"mouseReleased",
"openNextFile",
"scanNetworks",
"noInterrupts",
"digitalWrite",
"beginSpeaker",
"mousePressed",
"isActionDone",
"mouseDragged",
"displayLogos",
"noAutoscroll",
"addParameter",
"remoteNumber",
"getModifiers",
"keyboardRead",
"userNameRead",
"waitContinue",
"processInput",
"parseCommand",
"printVersion",
"readNetworks",
"writeMessage",
"blinkVersion",
"cityNameRead",
"readMessage",
"setDataMode",
"parsePacket",
"isListening",
"setBitOrder",
"beginPacket",
"isDirectory",
"motorsWrite",
"drawCompass",
"digitalRead",
"clearScreen",
"serialEvent",
"rightToLeft",
"setTextSize",
"leftToRight",
"requestFrom",
"keyReleased",
"compassRead",
"analogWrite",
"interrupts",
"WiFiServer",
"disconnect",
"playMelody",
"parseFloat",
"autoscroll",
"getPINUsed",
"setPINUsed",
"setTimeout",
"sendAnalog",
"readSlider",
"analogRead",
"beginWrite",
"createChar",
"motorsStop",
"keyPressed",
"tempoWrite",
"readButton",
"subnetMask",
"debugPrint",
"macAddress",
"writeGreen",
"randomSeed",
"attachGPRS",
"readString",
"sendString",
"remotePort",
"releaseAll",
"mouseMoved",
"background",
"getXChange",
"getYChange",
"answerCall",
"getResult",
"voiceCall",
"endPacket",
"constrain",
"getSocket",
"writeJSON",
"getButton",
"available",
"connected",
"findUntil",
"readBytes",
"exitValue",
"readGreen",
"writeBlue",
"startLoop",
"IPAddress",
"isPressed",
"sendSysex",
"pauseMode",
"gatewayIP",
"setCursor",
"getOemKey",
"tuneWrite",
"noDisplay",
"loadImage",
"switchPIN",
"onRequest",
"onReceive",
"changePIN",
"playFile",
"noBuffer",
"parseInt",
"overflow",
"checkPIN",
"knobRead",
"beginTFT",
"bitClear",
"updateIR",
"bitWrite",
"position",
"writeRGB",
"highByte",
"writeRed",
"setSpeed",
"readBlue",
"noStroke",
"remoteIP",
"transfer",
"shutdown",
"hangCall",
"beginSMS",
"endWrite",
"attached",
"maintain",
"noCursor",
"checkReg",
"checkPUK",
"shiftOut",
"isValid",
"shiftIn",
"pulseIn",
"connect",
"println",
"localIP",
"pinMode",
"getIMEI",
"display",
"noBlink",
"process",
"getBand",
"running",
"beginSD",
"drawBMP",
"lowByte",
"setBand",
"release",
"bitRead",
"prepare",
"pointTo",
"readRed",
"setMode",
"noFill",
"remove",
"listen",
"stroke",
"detach",
"attach",
"noTone",
"exists",
"buffer",
"height",
"bitSet",
"circle",
"config",
"cursor",
"random",
"IRread",
"setDNS",
"endSMS",
"getKey",
"micros",
"millis",
"begin",
"print",
"write",
"ready",
"flush",
"width",
"isPIN",
"blink",
"clear",
"press",
"mkdir",
"rmdir",
"close",
"point",
"yield",
"image",
"BSSID",
"click",
"delay",
"read",
"text",
"move",
"peek",
"beep",
"rect",
"line",
"open",
"seek",
"fill",
"size",
"turn",
"stop",
"home",
"find",
"step",
"tone",
"sqrt",
"RSSI",
"SSID",
"end",
"bit",
"tan",
"cos",
"sin",
"pow",
"map",
"abs",
"max",
"min",
"get",
"run",
"put"
],
literal: [
"DIGITAL_MESSAGE",
"FIRMATA_STRING",
"ANALOG_MESSAGE",
"REPORT_DIGITAL",
"REPORT_ANALOG",
"INPUT_PULLUP",
"SET_PIN_MODE",
"INTERNAL2V56",
"SYSTEM_RESET",
"LED_BUILTIN",
"INTERNAL1V1",
"SYSEX_START",
"INTERNAL",
"EXTERNAL",
"DEFAULT",
"OUTPUT",
"INPUT",
"HIGH",
"LOW"
]
};
const ARDUINO = cPlusPlus(hljs);
const kws = /** @type {Record<string,any>} */ (ARDUINO.keywords);
kws.type = [
...kws.type,
...ARDUINO_KW.type
];
kws.literal = [
...kws.literal,
...ARDUINO_KW.literal
];
kws.built_in = [
...kws.built_in,
...ARDUINO_KW.built_in
];
kws._hints = ARDUINO_KW._hints;
ARDUINO.name = 'Arduino';
ARDUINO.aliases = [ 'ino' ];
ARDUINO.supersetOf = "cpp";
return ARDUINO;
}
var arduino_1 = arduino;
/*
Language: ARM Assembly
Author: Dan Panzarella <alsoelp@gmail.com>
Description: ARM Assembly including Thumb and Thumb2 instructions
Category: assembler
*/
/** @type LanguageFn */
function armasm(hljs) {
// local labels: %?[FB]?[AT]?\d{1,2}\w+
const COMMENT = { variants: [
hljs.COMMENT('^[ \\t]*(?=#)', '$', {
relevance: 0,
excludeBegin: true
}),
hljs.COMMENT('[;@]', '$', { relevance: 0 }),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
] };
return {
name: 'ARM Assembly',
case_insensitive: true,
aliases: [ 'arm' ],
keywords: {
$pattern: '\\.?' + hljs.IDENT_RE,
meta:
// GNU preprocs
'.2byte .4byte .align .ascii .asciz .balign .byte .code .data .else .end .endif .endm .endr .equ .err .exitm .extern .global .hword .if .ifdef .ifndef .include .irp .long .macro .rept .req .section .set .skip .space .text .word .arm .thumb .code16 .code32 .force_thumb .thumb_func .ltorg '
// ARM directives
+ 'ALIAS ALIGN ARM AREA ASSERT ATTR CN CODE CODE16 CODE32 COMMON CP DATA DCB DCD DCDU DCDO DCFD DCFDU DCI DCQ DCQU DCW DCWU DN ELIF ELSE END ENDFUNC ENDIF ENDP ENTRY EQU EXPORT EXPORTAS EXTERN FIELD FILL FUNCTION GBLA GBLL GBLS GET GLOBAL IF IMPORT INCBIN INCLUDE INFO KEEP LCLA LCLL LCLS LTORG MACRO MAP MEND MEXIT NOFP OPT PRESERVE8 PROC QN READONLY RELOC REQUIRE REQUIRE8 RLIST FN ROUT SETA SETL SETS SN SPACE SUBT THUMB THUMBX TTL WHILE WEND ',
built_in:
'r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 ' // standard registers
+ 'w0 w1 w2 w3 w4 w5 w6 w7 w8 w9 w10 w11 w12 w13 w14 w15 ' // 32 bit ARMv8 registers
+ 'w16 w17 w18 w19 w20 w21 w22 w23 w24 w25 w26 w27 w28 w29 w30 '
+ 'x0 x1 x2 x3 x4 x5 x6 x7 x8 x9 x10 x11 x12 x13 x14 x15 ' // 64 bit ARMv8 registers
+ 'x16 x17 x18 x19 x20 x21 x22 x23 x24 x25 x26 x27 x28 x29 x30 '
+ 'pc lr sp ip sl sb fp ' // typical regs plus backward compatibility
+ 'a1 a2 a3 a4 v1 v2 v3 v4 v5 v6 v7 v8 f0 f1 f2 f3 f4 f5 f6 f7 ' // more regs and fp
+ 'p0 p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 p11 p12 p13 p14 p15 ' // coprocessor regs
+ 'c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 c10 c11 c12 c13 c14 c15 ' // more coproc
+ 'q0 q1 q2 q3 q4 q5 q6 q7 q8 q9 q10 q11 q12 q13 q14 q15 ' // advanced SIMD NEON regs
// program status registers
+ 'cpsr_c cpsr_x cpsr_s cpsr_f cpsr_cx cpsr_cxs cpsr_xs cpsr_xsf cpsr_sf cpsr_cxsf '
+ 'spsr_c spsr_x spsr_s spsr_f spsr_cx spsr_cxs spsr_xs spsr_xsf spsr_sf spsr_cxsf '
// NEON and VFP registers
+ 's0 s1 s2 s3 s4 s5 s6 s7 s8 s9 s10 s11 s12 s13 s14 s15 '
+ 's16 s17 s18 s19 s20 s21 s22 s23 s24 s25 s26 s27 s28 s29 s30 s31 '
+ 'd0 d1 d2 d3 d4 d5 d6 d7 d8 d9 d10 d11 d12 d13 d14 d15 '
+ 'd16 d17 d18 d19 d20 d21 d22 d23 d24 d25 d26 d27 d28 d29 d30 d31 '
+ '{PC} {VAR} {TRUE} {FALSE} {OPT} {CONFIG} {ENDIAN} {CODESIZE} {CPU} {FPU} {ARCHITECTURE} {PCSTOREOFFSET} {ARMASM_VERSION} {INTER} {ROPI} {RWPI} {SWST} {NOSWST} . @'
},
contains: [
{
className: 'keyword',
begin: '\\b(' // mnemonics
+ 'adc|'
+ '(qd?|sh?|u[qh]?)?add(8|16)?|usada?8|(q|sh?|u[qh]?)?(as|sa)x|'
+ 'and|adrl?|sbc|rs[bc]|asr|b[lx]?|blx|bxj|cbn?z|tb[bh]|bic|'
+ 'bfc|bfi|[su]bfx|bkpt|cdp2?|clz|clrex|cmp|cmn|cpsi[ed]|cps|'
+ 'setend|dbg|dmb|dsb|eor|isb|it[te]{0,3}|lsl|lsr|ror|rrx|'
+ 'ldm(([id][ab])|f[ds])?|ldr((s|ex)?[bhd])?|movt?|mvn|mra|mar|'
+ 'mul|[us]mull|smul[bwt][bt]|smu[as]d|smmul|smmla|'
+ 'mla|umlaal|smlal?([wbt][bt]|d)|mls|smlsl?[ds]|smc|svc|sev|'
+ 'mia([bt]{2}|ph)?|mrr?c2?|mcrr2?|mrs|msr|orr|orn|pkh(tb|bt)|rbit|'
+ 'rev(16|sh)?|sel|[su]sat(16)?|nop|pop|push|rfe([id][ab])?|'
+ 'stm([id][ab])?|str(ex)?[bhd]?|(qd?)?sub|(sh?|q|u[qh]?)?sub(8|16)|'
+ '[su]xt(a?h|a?b(16)?)|srs([id][ab])?|swpb?|swi|smi|tst|teq|'
+ 'wfe|wfi|yield'
+ ')'
+ '(eq|ne|cs|cc|mi|pl|vs|vc|hi|ls|ge|lt|gt|le|al|hs|lo)?' // condition codes
+ '[sptrx]?' // legal postfixes
+ '(?=\\s)' // followed by space
},
COMMENT,
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '\'',
end: '[^\\\\]\'',
relevance: 0
},
{
className: 'title',
begin: '\\|',
end: '\\|',
illegal: '\\n',
relevance: 0
},
{
className: 'number',
variants: [
{ // hex
begin: '[#$=]?0x[0-9a-f]+' },
{ // bin
begin: '[#$=]?0b[01]+' },
{ // literal
begin: '[#$=]\\d+' },
{ // bare number
begin: '\\b\\d+' }
],
relevance: 0
},
{
className: 'symbol',
variants: [
{ // GNU ARM syntax
begin: '^[ \\t]*[a-z_\\.\\$][a-z0-9_\\.\\$]+:' },
{ // ARM syntax
begin: '^[a-z_\\.\\$][a-z0-9_\\.\\$]+' },
{ // label reference
begin: '[=#]\\w+' }
],
relevance: 0
}
]
};
}
var armasm_1 = armasm;
/*
Language: HTML, XML
Website: https://www.w3.org/XML/
Category: common, web
Audit: 2020
*/
/** @type LanguageFn */
function xml(hljs) {
const regex = hljs.regex;
// XML names can have the following additional letters: https://www.w3.org/TR/xml/#NT-NameChar
// OTHER_NAME_CHARS = /[:\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]/;
// Element names start with NAME_START_CHAR followed by optional other Unicode letters, ASCII digits, hyphens, underscores, and periods
// const TAG_NAME_RE = regex.concat(/[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/, regex.optional(/[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*:/), /[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*/);;
// const XML_IDENT_RE = /[A-Z_a-z:\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]+/;
// const TAG_NAME_RE = regex.concat(/[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/, regex.optional(/[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*:/), /[A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*/);
// however, to cater for performance and more Unicode support rely simply on the Unicode letter class
const TAG_NAME_RE = regex.concat(/[\p{L}_]/u, regex.optional(/[\p{L}0-9_.-]*:/u), /[\p{L}0-9_.-]*/u);
const XML_IDENT_RE = /[\p{L}0-9._:-]+/u;
const XML_ENTITIES = {
className: 'symbol',
begin: /&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/
};
const XML_META_KEYWORDS = {
begin: /\s/,
contains: [
{
className: 'keyword',
begin: /#?[a-z_][a-z1-9_-]+/,
illegal: /\n/
}
]
};
const XML_META_PAR_KEYWORDS = hljs.inherit(XML_META_KEYWORDS, {
begin: /\(/,
end: /\)/
});
const APOS_META_STRING_MODE = hljs.inherit(hljs.APOS_STRING_MODE, { className: 'string' });
const QUOTE_META_STRING_MODE = hljs.inherit(hljs.QUOTE_STRING_MODE, { className: 'string' });
const TAG_INTERNALS = {
endsWithParent: true,
illegal: /</,
relevance: 0,
contains: [
{
className: 'attr',
begin: XML_IDENT_RE,
relevance: 0
},
{
begin: /=\s*/,
relevance: 0,
contains: [
{
className: 'string',
endsParent: true,
variants: [
{
begin: /"/,
end: /"/,
contains: [ XML_ENTITIES ]
},
{
begin: /'/,
end: /'/,
contains: [ XML_ENTITIES ]
},
{ begin: /[^\s"'=<>`]+/ }
]
}
]
}
]
};
return {
name: 'HTML, XML',
aliases: [
'html',
'xhtml',
'rss',
'atom',
'xjb',
'xsd',
'xsl',
'plist',
'wsf',
'svg'
],
case_insensitive: true,
unicodeRegex: true,
contains: [
{
className: 'meta',
begin: /<![a-z]/,
end: />/,
relevance: 10,
contains: [
XML_META_KEYWORDS,
QUOTE_META_STRING_MODE,
APOS_META_STRING_MODE,
XML_META_PAR_KEYWORDS,
{
begin: /\[/,
end: /\]/,
contains: [
{
className: 'meta',
begin: /<![a-z]/,
end: />/,
contains: [
XML_META_KEYWORDS,
XML_META_PAR_KEYWORDS,
QUOTE_META_STRING_MODE,
APOS_META_STRING_MODE
]
}
]
}
]
},
hljs.COMMENT(
/<!--/,
/-->/,
{ relevance: 10 }
),
{
begin: /<!\[CDATA\[/,
end: /\]\]>/,
relevance: 10
},
XML_ENTITIES,
// xml processing instructions
{
className: 'meta',
end: /\?>/,
variants: [
{
begin: /<\?xml/,
relevance: 10,
contains: [
QUOTE_META_STRING_MODE
]
},
{
begin: /<\?[a-z][a-z0-9]+/,
}
]
},
{
className: 'tag',
/*
The lookahead pattern (?=...) ensures that 'begin' only matches
'<style' as a single word, followed by a whitespace or an
ending bracket.
*/
begin: /<style(?=\s|>)/,
end: />/,
keywords: { name: 'style' },
contains: [ TAG_INTERNALS ],
starts: {
end: /<\/style>/,
returnEnd: true,
subLanguage: [
'css',
'xml'
]
}
},
{
className: 'tag',
// See the comment in the <style tag about the lookahead pattern
begin: /<script(?=\s|>)/,
end: />/,
keywords: { name: 'script' },
contains: [ TAG_INTERNALS ],
starts: {
end: /<\/script>/,
returnEnd: true,
subLanguage: [
'javascript',
'handlebars',
'xml'
]
}
},
// we need this for now for jSX
{
className: 'tag',
begin: /<>|<\/>/
},
// open tag
{
className: 'tag',
begin: regex.concat(
/</,
regex.lookahead(regex.concat(
TAG_NAME_RE,
// <tag/>
// <tag>
// <tag ...
regex.either(/\/>/, />/, /\s/)
))
),
end: /\/?>/,
contains: [
{
className: 'name',
begin: TAG_NAME_RE,
relevance: 0,
starts: TAG_INTERNALS
}
]
},
// close tag
{
className: 'tag',
begin: regex.concat(
/<\//,
regex.lookahead(regex.concat(
TAG_NAME_RE, />/
))
),
contains: [
{
className: 'name',
begin: TAG_NAME_RE,
relevance: 0
},
{
begin: />/,
relevance: 0,
endsParent: true
}
]
}
]
};
}
var xml_1 = xml;
/*
Language: AsciiDoc
Requires: xml.js
Author: Dan Allen <dan.j.allen@gmail.com>
Website: http://asciidoc.org
Description: A semantic, text-based document format that can be exported to HTML, DocBook and other backends.
Category: markup
*/
/** @type LanguageFn */
function asciidoc(hljs) {
const regex = hljs.regex;
const HORIZONTAL_RULE = {
begin: '^\'{3,}[ \\t]*$',
relevance: 10
};
const ESCAPED_FORMATTING = [
// escaped constrained formatting marks (i.e., \* \_ or \`)
{ begin: /\\[*_`]/ },
// escaped unconstrained formatting marks (i.e., \\** \\__ or \\``)
// must ignore until the next formatting marks
// this rule might not be 100% compliant with Asciidoctor 2.0 but we are entering undefined behavior territory...
{ begin: /\\\\\*{2}[^\n]*?\*{2}/ },
{ begin: /\\\\_{2}[^\n]*_{2}/ },
{ begin: /\\\\`{2}[^\n]*`{2}/ },
// guard: constrained formatting mark may not be preceded by ":", ";" or
// "}". match these so the constrained rule doesn't see them
{ begin: /[:;}][*_`](?![*_`])/ }
];
const STRONG = [
// inline unconstrained strong (single line)
{
className: 'strong',
begin: /\*{2}([^\n]+?)\*{2}/
},
// inline unconstrained strong (multi-line)
{
className: 'strong',
begin: regex.concat(
/\*\*/,
/((\*(?!\*)|\\[^\n]|[^*\n\\])+\n)+/,
/(\*(?!\*)|\\[^\n]|[^*\n\\])*/,
/\*\*/
),
relevance: 0
},
// inline constrained strong (single line)
{
className: 'strong',
// must not precede or follow a word character
begin: /\B\*(\S|\S[^\n]*?\S)\*(?!\w)/
},
// inline constrained strong (multi-line)
{
className: 'strong',
// must not precede or follow a word character
begin: /\*[^\s]([^\n]+\n)+([^\n]+)\*/
}
];
const EMPHASIS = [
// inline unconstrained emphasis (single line)
{
className: 'emphasis',
begin: /_{2}([^\n]+?)_{2}/
},
// inline unconstrained emphasis (multi-line)
{
className: 'emphasis',
begin: regex.concat(
/__/,
/((_(?!_)|\\[^\n]|[^_\n\\])+\n)+/,
/(_(?!_)|\\[^\n]|[^_\n\\])*/,
/__/
),
relevance: 0
},
// inline constrained emphasis (single line)
{
className: 'emphasis',
// must not precede or follow a word character
begin: /\b_(\S|\S[^\n]*?\S)_(?!\w)/
},
// inline constrained emphasis (multi-line)
{
className: 'emphasis',
// must not precede or follow a word character
begin: /_[^\s]([^\n]+\n)+([^\n]+)_/
},
// inline constrained emphasis using single quote (legacy)
{
className: 'emphasis',
// must not follow a word character or be followed by a single quote or space
begin: '\\B\'(?![\'\\s])',
end: '(\\n{2}|\')',
// allow escaped single quote followed by word char
contains: [
{
begin: '\\\\\'\\w',
relevance: 0
}
],
relevance: 0
}
];
const ADMONITION = {
className: 'symbol',
begin: '^(NOTE|TIP|IMPORTANT|WARNING|CAUTION):\\s+',
relevance: 10
};
const BULLET_LIST = {
className: 'bullet',
begin: '^(\\*+|-+|\\.+|[^\\n]+?::)\\s+'
};
return {
name: 'AsciiDoc',
aliases: [ 'adoc' ],
contains: [
// block comment
hljs.COMMENT(
'^/{4,}\\n',
'\\n/{4,}$',
// can also be done as...
// '^/{4,}$',
// '^/{4,}$',
{ relevance: 10 }
),
// line comment
hljs.COMMENT(
'^//',
'$',
{ relevance: 0 }
),
// title
{
className: 'title',
begin: '^\\.\\w.*$'
},
// example, admonition & sidebar blocks
{
begin: '^[=\\*]{4,}\\n',
end: '\\n^[=\\*]{4,}$',
relevance: 10
},
// headings
{
className: 'section',
relevance: 10,
variants: [
{ begin: '^(={1,6})[ \t].+?([ \t]\\1)?$' },
{ begin: '^[^\\[\\]\\n]+?\\n[=\\-~\\^\\+]{2,}$' }
]
},
// document attributes
{
className: 'meta',
begin: '^:.+?:',
end: '\\s',
excludeEnd: true,
relevance: 10
},
// block attributes
{
className: 'meta',
begin: '^\\[.+?\\]$',
relevance: 0
},
// quoteblocks
{
className: 'quote',
begin: '^_{4,}\\n',
end: '\\n_{4,}$',
relevance: 10
},
// listing and literal blocks
{
className: 'code',
begin: '^[\\-\\.]{4,}\\n',
end: '\\n[\\-\\.]{4,}$',
relevance: 10
},
// passthrough blocks
{
begin: '^\\+{4,}\\n',
end: '\\n\\+{4,}$',
contains: [
{
begin: '<',
end: '>',
subLanguage: 'xml',
relevance: 0
}
],
relevance: 10
},
BULLET_LIST,
ADMONITION,
...ESCAPED_FORMATTING,
...STRONG,
...EMPHASIS,
// inline smart quotes
{
className: 'string',
variants: [
{ begin: "``.+?''" },
{ begin: "`.+?'" }
]
},
// inline unconstrained emphasis
{
className: 'code',
begin: /`{2}/,
end: /(\n{2}|`{2})/
},
// inline code snippets (TODO should get same treatment as strong and emphasis)
{
className: 'code',
begin: '(`.+?`|\\+.+?\\+)',
relevance: 0
},
// indented literal block
{
className: 'code',
begin: '^[ \\t]',
end: '$',
relevance: 0
},
HORIZONTAL_RULE,
// images and links
{
begin: '(link:)?(http|https|ftp|file|irc|image:?):\\S+?\\[[^[]*?\\]',
returnBegin: true,
contains: [
{
begin: '(link|image:?):',
relevance: 0
},
{
className: 'link',
begin: '\\w',
end: '[^\\[]+',
relevance: 0
},
{
className: 'string',
begin: '\\[',
end: '\\]',
excludeBegin: true,
excludeEnd: true,
relevance: 0
}
],
relevance: 10
}
]
};
}
var asciidoc_1 = asciidoc;
/*
Language: AspectJ
Author: Hakan Ozler <ozler.hakan@gmail.com>
Website: https://www.eclipse.org/aspectj/
Description: Syntax Highlighting for the AspectJ Language which is a general-purpose aspect-oriented extension to the Java programming language.
Audit: 2020
*/
/** @type LanguageFn */
function aspectj(hljs) {
const regex = hljs.regex;
const KEYWORDS = [
"false",
"synchronized",
"int",
"abstract",
"float",
"private",
"char",
"boolean",
"static",
"null",
"if",
"const",
"for",
"true",
"while",
"long",
"throw",
"strictfp",
"finally",
"protected",
"import",
"native",
"final",
"return",
"void",
"enum",
"else",
"extends",
"implements",
"break",
"transient",
"new",
"catch",
"instanceof",
"byte",
"super",
"volatile",
"case",
"assert",
"short",
"package",
"default",
"double",
"public",
"try",
"this",
"switch",
"continue",
"throws",
"privileged",
"aspectOf",
"adviceexecution",
"proceed",
"cflowbelow",
"cflow",
"initialization",
"preinitialization",
"staticinitialization",
"withincode",
"target",
"within",
"execution",
"getWithinTypeName",
"handler",
"thisJoinPoint",
"thisJoinPointStaticPart",
"thisEnclosingJoinPointStaticPart",
"declare",
"parents",
"warning",
"error",
"soft",
"precedence",
"thisAspectInstance"
];
const SHORTKEYS = [
"get",
"set",
"args",
"call"
];
return {
name: 'AspectJ',
keywords: KEYWORDS,
illegal: /<\/|#/,
contains: [
hljs.COMMENT(
/\/\*\*/,
/\*\//,
{
relevance: 0,
contains: [
{
// eat up @'s in emails to prevent them to be recognized as doctags
begin: /\w+@/,
relevance: 0
},
{
className: 'doctag',
begin: /@[A-Za-z]+/
}
]
}
),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
className: 'class',
beginKeywords: 'aspect',
end: /[{;=]/,
excludeEnd: true,
illegal: /[:;"\[\]]/,
contains: [
{ beginKeywords: 'extends implements pertypewithin perthis pertarget percflowbelow percflow issingleton' },
hljs.UNDERSCORE_TITLE_MODE,
{
begin: /\([^\)]*/,
end: /[)]+/,
keywords: KEYWORDS.concat(SHORTKEYS),
excludeEnd: false
}
]
},
{
className: 'class',
beginKeywords: 'class interface',
end: /[{;=]/,
excludeEnd: true,
relevance: 0,
keywords: 'class interface',
illegal: /[:"\[\]]/,
contains: [
{ beginKeywords: 'extends implements' },
hljs.UNDERSCORE_TITLE_MODE
]
},
{
// AspectJ Constructs
beginKeywords: 'pointcut after before around throwing returning',
end: /[)]/,
excludeEnd: false,
illegal: /["\[\]]/,
contains: [
{
begin: regex.concat(hljs.UNDERSCORE_IDENT_RE, /\s*\(/),
returnBegin: true,
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
}
]
},
{
begin: /[:]/,
returnBegin: true,
end: /[{;]/,
relevance: 0,
excludeEnd: false,
keywords: KEYWORDS,
illegal: /["\[\]]/,
contains: [
{
begin: regex.concat(hljs.UNDERSCORE_IDENT_RE, /\s*\(/),
keywords: KEYWORDS.concat(SHORTKEYS),
relevance: 0
},
hljs.QUOTE_STRING_MODE
]
},
{
// this prevents 'new Name(...), or throw ...' from being recognized as a function definition
beginKeywords: 'new throw',
relevance: 0
},
{
// the function class is a bit different for AspectJ compared to the Java language
className: 'function',
begin: /\w+ +\w+(\.\w+)?\s*\([^\)]*\)\s*((throws)[\w\s,]+)?[\{;]/,
returnBegin: true,
end: /[{;=]/,
keywords: KEYWORDS,
excludeEnd: true,
contains: [
{
begin: regex.concat(hljs.UNDERSCORE_IDENT_RE, /\s*\(/),
returnBegin: true,
relevance: 0,
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
},
{
className: 'params',
begin: /\(/,
end: /\)/,
relevance: 0,
keywords: KEYWORDS,
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
hljs.C_NUMBER_MODE,
{
// annotation is also used in this language
className: 'meta',
begin: /@[A-Za-z]+/
}
]
};
}
var aspectj_1 = aspectj;
/*
Language: AutoHotkey
Author: Seongwon Lee <dlimpid@gmail.com>
Description: AutoHotkey language definition
Category: scripting
*/
/** @type LanguageFn */
function autohotkey(hljs) {
const BACKTICK_ESCAPE = { begin: '`[\\s\\S]' };
return {
name: 'AutoHotkey',
case_insensitive: true,
aliases: [ 'ahk' ],
keywords: {
keyword: 'Break Continue Critical Exit ExitApp Gosub Goto New OnExit Pause return SetBatchLines SetTimer Suspend Thread Throw Until ahk_id ahk_class ahk_pid ahk_exe ahk_group',
literal: 'true false NOT AND OR',
built_in: 'ComSpec Clipboard ClipboardAll ErrorLevel'
},
contains: [
BACKTICK_ESCAPE,
hljs.inherit(hljs.QUOTE_STRING_MODE, { contains: [ BACKTICK_ESCAPE ] }),
hljs.COMMENT(';', '$', { relevance: 0 }),
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'number',
begin: hljs.NUMBER_RE,
relevance: 0
},
{
// subst would be the most accurate however fails the point of
// highlighting. variable is comparably the most accurate that actually
// has some effect
className: 'variable',
begin: '%[a-zA-Z0-9#_$@]+%'
},
{
className: 'built_in',
begin: '^\\s*\\w+\\s*(,|%)'
// I don't really know if this is totally relevant
},
{
// symbol would be most accurate however is highlighted just like
// built_in and that makes up a lot of AutoHotkey code meaning that it
// would fail to highlight anything
className: 'title',
variants: [
{ begin: '^[^\\n";]+::(?!=)' },
{
begin: '^[^\\n";]+:(?!=)',
// zero relevance as it catches a lot of things
// followed by a single ':' in many languages
relevance: 0
}
]
},
{
className: 'meta',
begin: '^\\s*#\\w+',
end: '$',
relevance: 0
},
{
className: 'built_in',
begin: 'A_[a-zA-Z0-9]+'
},
{
// consecutive commas, not for highlighting but just for relevance
begin: ',\\s*,' }
]
};
}
var autohotkey_1 = autohotkey;
/*
Language: AutoIt
Author: Manh Tuan <junookyo@gmail.com>
Description: AutoIt language definition
Category: scripting
*/
/** @type LanguageFn */
function autoit(hljs) {
const KEYWORDS = 'ByRef Case Const ContinueCase ContinueLoop '
+ 'Dim Do Else ElseIf EndFunc EndIf EndSelect '
+ 'EndSwitch EndWith Enum Exit ExitLoop For Func '
+ 'Global If In Local Next ReDim Return Select Static '
+ 'Step Switch Then To Until Volatile WEnd While With';
const DIRECTIVES = [
"EndRegion",
"forcedef",
"forceref",
"ignorefunc",
"include",
"include-once",
"NoTrayIcon",
"OnAutoItStartRegister",
"pragma",
"Region",
"RequireAdmin",
"Tidy_Off",
"Tidy_On",
"Tidy_Parameters"
];
const LITERAL = 'True False And Null Not Or Default';
const BUILT_IN =
'Abs ACos AdlibRegister AdlibUnRegister Asc AscW ASin Assign ATan AutoItSetOption AutoItWinGetTitle AutoItWinSetTitle Beep Binary BinaryLen BinaryMid BinaryToString BitAND BitNOT BitOR BitRotate BitShift BitXOR BlockInput Break Call CDTray Ceiling Chr ChrW ClipGet ClipPut ConsoleRead ConsoleWrite ConsoleWriteError ControlClick ControlCommand ControlDisable ControlEnable ControlFocus ControlGetFocus ControlGetHandle ControlGetPos ControlGetText ControlHide ControlListView ControlMove ControlSend ControlSetText ControlShow ControlTreeView Cos Dec DirCopy DirCreate DirGetSize DirMove DirRemove DllCall DllCallAddress DllCallbackFree DllCallbackGetPtr DllCallbackRegister DllClose DllOpen DllStructCreate DllStructGetData DllStructGetPtr DllStructGetSize DllStructSetData DriveGetDrive DriveGetFileSystem DriveGetLabel DriveGetSerial DriveGetType DriveMapAdd DriveMapDel DriveMapGet DriveSetLabel DriveSpaceFree DriveSpaceTotal DriveStatus EnvGet EnvSet EnvUpdate Eval Execute Exp FileChangeDir FileClose FileCopy FileCreateNTFSLink FileCreateShortcut FileDelete FileExists FileFindFirstFile FileFindNextFile FileFlush FileGetAttrib FileGetEncoding FileGetLongName FileGetPos FileGetShortcut FileGetShortName FileGetSize FileGetTime FileGetVersion FileInstall FileMove FileOpen FileOpenDialog FileRead FileReadLine FileReadToArray FileRecycle FileRecycleEmpty FileSaveDialog FileSelectFolder FileSetAttrib FileSetEnd FileSetPos FileSetTime FileWrite FileWriteLine Floor FtpSetProxy FuncName GUICreate GUICtrlCreateAvi GUICtrlCreateButton GUICtrlCreateCheckbox GUICtrlCreateCombo GUICtrlCreateContextMenu GUICtrlCreateDate GUICtrlCreateDummy GUICtrlCreateEdit GUICtrlCreateGraphic GUICtrlCreateGroup GUICtrlCreateIcon GUICtrlCreateInput GUICtrlCreateLabel GUICtrlCreateList GUICtrlCreateListView GUICtrlCreateListViewItem GUICtrlCreateMenu GUICtrlCreateMenuItem GUICtrlCreateMonthCal GUICtrlCreateObj GUICtrlCreatePic GUICtrlCreateProgress GUICtrlCreateRadio GUICtrlCreateSlider GUICtrlCreateTab GUICtrlCreateTabItem GUICtrlCreateTreeView GUICtrlCreateTreeViewItem GUICtrlCreateUpdown GUICtrlDelete GUICtrlGetHandle GUICtrlGetState GUICtrlRead GUICtrlRecvMsg GUICtrlRegisterListViewSort GUICtrlSendMsg GUICtrlSendToDummy GUICtrlSetBkColor GUICtrlSetColor GUICtrlSetCursor GUICtrlSetData GUICtrlSetDefBkColor GUICtrlSetDefColor GUICtrlSetFont GUICtrlSetGraphic GUICtrlSetImage GUICtrlSetLimit GUICtrlSetOnEvent GUICtrlSetPos GUICtrlSetResizing GUICtrlSetState GUICtrlSetStyle GUICtrlSetTip GUIDelete GUIGetCursorInfo GUIGetMsg GUIGetStyle GUIRegisterMsg GUISetAccelerators GUISetBkColor GUISetCoord GUISetCursor GUISetFont GUISetHelp GUISetIcon GUISetOnEvent GUISetState GUISetStyle GUIStartGroup GUISwitch Hex HotKeySet HttpSetProxy HttpSetUserAgent HWnd InetClose InetGet InetGetInfo InetGetSize InetRead IniDelete IniRead IniReadSection IniReadSectionNames IniRenameSection IniWrite IniWriteSection InputBox Int IsAdmin IsArray IsBinary IsBool IsDeclared IsDllStruct IsFloat IsFunc IsHWnd IsInt IsKeyword IsNumber IsObj IsPtr IsString Log MemGetStats Mod MouseClick MouseClickDrag MouseDown MouseGetCursor MouseGetPos MouseMove MouseUp MouseWheel MsgBox Number ObjCreate ObjCreateInterface ObjEvent ObjGet ObjName OnAutoItExitRegister OnAutoItExitUnRegister Ping PixelChecksum PixelGetColor PixelSearch ProcessClose ProcessExists ProcessGetStats ProcessList ProcessSetPriority ProcessWait ProcessWaitClose ProgressOff ProgressOn ProgressSet Ptr Random RegDelete RegEnumKey RegEnumVal RegRead RegWrite Round Run RunAs RunAsWait RunWait Send SendKeepActive SetError SetExtended ShellExecute ShellExecuteWait Shutdown Sin Sleep SoundPlay SoundSetWaveVolume SplashImageOn SplashOff SplashTextOn Sqrt SRandom StatusbarGetText StderrRead StdinWrite StdioClose StdoutRead String StringAddCR StringCompare StringFormat StringFromASCIIArray StringInStr StringIsAlNum StringIsAlpha StringIsASCII StringIsDigit StringIsFloat StringIsInt StringIsLower StringIsSpace StringIsUpper StringIsXDigit StringLeft StringLen StringLower StringMid StringRegExp StringRegExpReplace StringReplace StringReverse StringRight StringSplit StringStripCR StringStripWS StringToASCIIArray StringToBinary StringTrimLeft StringTrimRight StringUpper Tan TCPAccept TCPCloseSocket TCPConnect TCPListen TCPNameToIP TCPRecv TCPSend TCPShutdown, UDPShutdown TCPStartup, UDPStartup TimerDiff TimerInit ToolTip TrayCreateItem TrayCreateMenu TrayGetMsg TrayItemDelete TrayItemGetHandle TrayItemGetState TrayItemGetText TrayItemSetOnEvent TrayItemSetState TrayItemSetText TraySetClick TraySetIcon TraySetOnEvent TraySetPauseIcon TraySetState TraySetToolTip TrayTip UBound UDPBind UDPCloseSocket UDPOpen UDPRecv UDPSend VarGetType WinActivate WinActive WinClose WinExists WinFlash WinGetCaretPos WinGetClassList WinGetClientSize WinGetHandle WinGetPos WinGetProcess WinGetState WinGetText WinGetTitle WinKill WinList WinMenuSelectItem WinMinimizeAll WinMinimizeAllUndo WinMove WinSetOnTop WinSetState WinSetTitle WinSetTrans WinWait WinWaitActive WinWaitClose WinWaitNotActive';
const COMMENT = { variants: [
hljs.COMMENT(';', '$', { relevance: 0 }),
hljs.COMMENT('#cs', '#ce'),
hljs.COMMENT('#comments-start', '#comments-end')
] };
const VARIABLE = { begin: '\\$[A-z0-9_]+' };
const STRING = {
className: 'string',
variants: [
{
begin: /"/,
end: /"/,
contains: [
{
begin: /""/,
relevance: 0
}
]
},
{
begin: /'/,
end: /'/,
contains: [
{
begin: /''/,
relevance: 0
}
]
}
]
};
const NUMBER = { variants: [
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE
] };
const PREPROCESSOR = {
className: 'meta',
begin: '#',
end: '$',
keywords: { keyword: DIRECTIVES },
contains: [
{
begin: /\\\n/,
relevance: 0
},
{
beginKeywords: 'include',
keywords: { keyword: 'include' },
end: '$',
contains: [
STRING,
{
className: 'string',
variants: [
{
begin: '<',
end: '>'
},
{
begin: /"/,
end: /"/,
contains: [
{
begin: /""/,
relevance: 0
}
]
},
{
begin: /'/,
end: /'/,
contains: [
{
begin: /''/,
relevance: 0
}
]
}
]
}
]
},
STRING,
COMMENT
]
};
const CONSTANT = {
className: 'symbol',
// begin: '@',
// end: '$',
// keywords: 'AppDataCommonDir AppDataDir AutoItExe AutoItPID AutoItVersion AutoItX64 COM_EventObj CommonFilesDir Compiled ComputerName ComSpec CPUArch CR CRLF DesktopCommonDir DesktopDepth DesktopDir DesktopHeight DesktopRefresh DesktopWidth DocumentsCommonDir error exitCode exitMethod extended FavoritesCommonDir FavoritesDir GUI_CtrlHandle GUI_CtrlId GUI_DragFile GUI_DragId GUI_DropId GUI_WinHandle HomeDrive HomePath HomeShare HotKeyPressed HOUR IPAddress1 IPAddress2 IPAddress3 IPAddress4 KBLayout LF LocalAppDataDir LogonDNSDomain LogonDomain LogonServer MDAY MIN MON MSEC MUILang MyDocumentsDir NumParams OSArch OSBuild OSLang OSServicePack OSType OSVersion ProgramFilesDir ProgramsCommonDir ProgramsDir ScriptDir ScriptFullPath ScriptLineNumber ScriptName SEC StartMenuCommonDir StartMenuDir StartupCommonDir StartupDir SW_DISABLE SW_ENABLE SW_HIDE SW_LOCK SW_MAXIMIZE SW_MINIMIZE SW_RESTORE SW_SHOW SW_SHOWDEFAULT SW_SHOWMAXIMIZED SW_SHOWMINIMIZED SW_SHOWMINNOACTIVE SW_SHOWNA SW_SHOWNOACTIVATE SW_SHOWNORMAL SW_UNLOCK SystemDir TAB TempDir TRAY_ID TrayIconFlashing TrayIconVisible UserName UserProfileDir WDAY WindowsDir WorkingDir YDAY YEAR',
// relevance: 5
begin: '@[A-z0-9_]+'
};
const FUNCTION = {
beginKeywords: 'Func',
end: '$',
illegal: '\\$|\\[|%',
contains: [
hljs.inherit(hljs.UNDERSCORE_TITLE_MODE, { className: "title.function" }),
{
className: 'params',
begin: '\\(',
end: '\\)',
contains: [
VARIABLE,
STRING,
NUMBER
]
}
]
};
return {
name: 'AutoIt',
case_insensitive: true,
illegal: /\/\*/,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_IN,
literal: LITERAL
},
contains: [
COMMENT,
VARIABLE,
STRING,
NUMBER,
PREPROCESSOR,
CONSTANT,
FUNCTION
]
};
}
var autoit_1 = autoit;
/*
Language: AVR Assembly
Author: Vladimir Ermakov <vooon341@gmail.com>
Category: assembler
Website: https://www.microchip.com/webdoc/avrassembler/avrassembler.wb_instruction_list.html
*/
/** @type LanguageFn */
function avrasm(hljs) {
return {
name: 'AVR Assembly',
case_insensitive: true,
keywords: {
$pattern: '\\.?' + hljs.IDENT_RE,
keyword:
/* mnemonic */
'adc add adiw and andi asr bclr bld brbc brbs brcc brcs break breq brge brhc brhs '
+ 'brid brie brlo brlt brmi brne brpl brsh brtc brts brvc brvs bset bst call cbi cbr '
+ 'clc clh cli cln clr cls clt clv clz com cp cpc cpi cpse dec eicall eijmp elpm eor '
+ 'fmul fmuls fmulsu icall ijmp in inc jmp ld ldd ldi lds lpm lsl lsr mov movw mul '
+ 'muls mulsu neg nop or ori out pop push rcall ret reti rjmp rol ror sbc sbr sbrc sbrs '
+ 'sec seh sbi sbci sbic sbis sbiw sei sen ser ses set sev sez sleep spm st std sts sub '
+ 'subi swap tst wdr',
built_in:
/* general purpose registers */
'r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 r16 r17 r18 r19 r20 r21 r22 '
+ 'r23 r24 r25 r26 r27 r28 r29 r30 r31 x|0 xh xl y|0 yh yl z|0 zh zl '
/* IO Registers (ATMega128) */
+ 'ucsr1c udr1 ucsr1a ucsr1b ubrr1l ubrr1h ucsr0c ubrr0h tccr3c tccr3a tccr3b tcnt3h '
+ 'tcnt3l ocr3ah ocr3al ocr3bh ocr3bl ocr3ch ocr3cl icr3h icr3l etimsk etifr tccr1c '
+ 'ocr1ch ocr1cl twcr twdr twar twsr twbr osccal xmcra xmcrb eicra spmcsr spmcr portg '
+ 'ddrg ping portf ddrf sreg sph spl xdiv rampz eicrb eimsk gimsk gicr eifr gifr timsk '
+ 'tifr mcucr mcucsr tccr0 tcnt0 ocr0 assr tccr1a tccr1b tcnt1h tcnt1l ocr1ah ocr1al '
+ 'ocr1bh ocr1bl icr1h icr1l tccr2 tcnt2 ocr2 ocdr wdtcr sfior eearh eearl eedr eecr '
+ 'porta ddra pina portb ddrb pinb portc ddrc pinc portd ddrd pind spdr spsr spcr udr0 '
+ 'ucsr0a ucsr0b ubrr0l acsr admux adcsr adch adcl porte ddre pine pinf',
meta:
'.byte .cseg .db .def .device .dseg .dw .endmacro .equ .eseg .exit .include .list '
+ '.listmac .macro .nolist .org .set'
},
contains: [
hljs.C_BLOCK_COMMENT_MODE,
hljs.COMMENT(
';',
'$',
{ relevance: 0 }
),
hljs.C_NUMBER_MODE, // 0x..., decimal, float
hljs.BINARY_NUMBER_MODE, // 0b...
{
className: 'number',
begin: '\\b(\\$[a-zA-Z0-9]+|0o[0-7]+)' // $..., 0o...
},
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '\'',
end: '[^\\\\]\'',
illegal: '[^\\\\][^\']'
},
{
className: 'symbol',
begin: '^[A-Za-z0-9_.$]+:'
},
{
className: 'meta',
begin: '#',
end: '$'
},
{ // substitution within a macro
className: 'subst',
begin: '@[0-9]+'
}
]
};
}
var avrasm_1 = avrasm;
/*
Language: Awk
Author: Matthew Daly <matthewbdaly@gmail.com>
Website: https://www.gnu.org/software/gawk/manual/gawk.html
Description: language definition for Awk scripts
*/
/** @type LanguageFn */
function awk(hljs) {
const VARIABLE = {
className: 'variable',
variants: [
{ begin: /\$[\w\d#@][\w\d_]*/ },
{ begin: /\$\{(.*?)\}/ }
]
};
const KEYWORDS = 'BEGIN END if else while do for in break continue delete next nextfile function func exit|10';
const STRING = {
className: 'string',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
{
begin: /(u|b)?r?'''/,
end: /'''/,
relevance: 10
},
{
begin: /(u|b)?r?"""/,
end: /"""/,
relevance: 10
},
{
begin: /(u|r|ur)'/,
end: /'/,
relevance: 10
},
{
begin: /(u|r|ur)"/,
end: /"/,
relevance: 10
},
{
begin: /(b|br)'/,
end: /'/
},
{
begin: /(b|br)"/,
end: /"/
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
};
return {
name: 'Awk',
keywords: { keyword: KEYWORDS },
contains: [
VARIABLE,
STRING,
hljs.REGEXP_MODE,
hljs.HASH_COMMENT_MODE,
hljs.NUMBER_MODE
]
};
}
var awk_1 = awk;
/*
Language: Microsoft X++
Description: X++ is a language used in Microsoft Dynamics 365, Dynamics AX, and Axapta.
Author: Dmitri Roudakov <dmitri@roudakov.ru>
Website: https://dynamics.microsoft.com/en-us/ax-overview/
Category: enterprise
*/
/** @type LanguageFn */
function axapta(hljs) {
const IDENT_RE = hljs.UNDERSCORE_IDENT_RE;
const BUILT_IN_KEYWORDS = [
'anytype',
'boolean',
'byte',
'char',
'container',
'date',
'double',
'enum',
'guid',
'int',
'int64',
'long',
'real',
'short',
'str',
'utcdatetime',
'var'
];
const LITERAL_KEYWORDS = [
'default',
'false',
'null',
'true'
];
const NORMAL_KEYWORDS = [
'abstract',
'as',
'asc',
'avg',
'break',
'breakpoint',
'by',
'byref',
'case',
'catch',
'changecompany',
'class',
'client',
'client',
'common',
'const',
'continue',
'count',
'crosscompany',
'delegate',
'delete_from',
'desc',
'display',
'div',
'do',
'edit',
'else',
'eventhandler',
'exists',
'extends',
'final',
'finally',
'firstfast',
'firstonly',
'firstonly1',
'firstonly10',
'firstonly100',
'firstonly1000',
'flush',
'for',
'forceliterals',
'forcenestedloop',
'forceplaceholders',
'forceselectorder',
'forupdate',
'from',
'generateonly',
'group',
'hint',
'if',
'implements',
'in',
'index',
'insert_recordset',
'interface',
'internal',
'is',
'join',
'like',
'maxof',
'minof',
'mod',
'namespace',
'new',
'next',
'nofetch',
'notexists',
'optimisticlock',
'order',
'outer',
'pessimisticlock',
'print',
'private',
'protected',
'public',
'readonly',
'repeatableread',
'retry',
'return',
'reverse',
'select',
'server',
'setting',
'static',
'sum',
'super',
'switch',
'this',
'throw',
'try',
'ttsabort',
'ttsbegin',
'ttscommit',
'unchecked',
'update_recordset',
'using',
'validtimestate',
'void',
'where',
'while'
];
const KEYWORDS = {
keyword: NORMAL_KEYWORDS,
built_in: BUILT_IN_KEYWORDS,
literal: LITERAL_KEYWORDS
};
const CLASS_DEFINITION = {
variants: [
{ match: [
/(class|interface)\s+/,
IDENT_RE,
/\s+(extends|implements)\s+/,
IDENT_RE
] },
{ match: [
/class\s+/,
IDENT_RE
] }
],
scope: {
2: "title.class",
4: "title.class.inherited"
},
keywords: KEYWORDS
};
return {
name: 'X++',
aliases: [ 'x++' ],
keywords: KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '#',
end: '$'
},
CLASS_DEFINITION
]
};
}
var axapta_1 = axapta;
/*
Language: Bash
Author: vah <vahtenberg@gmail.com>
Contributrors: Benjamin Pannell <contact@sierrasoftworks.com>
Website: https://www.gnu.org/software/bash/
Category: common
*/
/** @type LanguageFn */
function bash(hljs) {
const regex = hljs.regex;
const VAR = {};
const BRACED_VAR = {
begin: /\$\{/,
end: /\}/,
contains: [
"self",
{
begin: /:-/,
contains: [ VAR ]
} // default values
]
};
Object.assign(VAR, {
className: 'variable',
variants: [
{ begin: regex.concat(/\$[\w\d#@][\w\d_]*/,
// negative look-ahead tries to avoid matching patterns that are not
// Perl at all like $ident$, @ident@, etc.
`(?![\\w\\d])(?![$])`) },
BRACED_VAR
]
});
const SUBST = {
className: 'subst',
begin: /\$\(/,
end: /\)/,
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const HERE_DOC = {
begin: /<<-?\s*(?=\w+)/,
starts: { contains: [
hljs.END_SAME_AS_BEGIN({
begin: /(\w+)/,
end: /(\w+)/,
className: 'string'
})
] }
};
const QUOTE_STRING = {
className: 'string',
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
VAR,
SUBST
]
};
SUBST.contains.push(QUOTE_STRING);
const ESCAPED_QUOTE = {
match: /\\"/
};
const APOS_STRING = {
className: 'string',
begin: /'/,
end: /'/
};
const ESCAPED_APOS = {
match: /\\'/
};
const ARITHMETIC = {
begin: /\$?\(\(/,
end: /\)\)/,
contains: [
{
begin: /\d+#[0-9a-f]+/,
className: "number"
},
hljs.NUMBER_MODE,
VAR
]
};
const SH_LIKE_SHELLS = [
"fish",
"bash",
"zsh",
"sh",
"csh",
"ksh",
"tcsh",
"dash",
"scsh",
];
const KNOWN_SHEBANG = hljs.SHEBANG({
binary: `(${SH_LIKE_SHELLS.join("|")})`,
relevance: 10
});
const FUNCTION = {
className: 'function',
begin: /\w[\w\d_]*\s*\(\s*\)\s*\{/,
returnBegin: true,
contains: [ hljs.inherit(hljs.TITLE_MODE, { begin: /\w[\w\d_]*/ }) ],
relevance: 0
};
const KEYWORDS = [
"if",
"then",
"else",
"elif",
"fi",
"for",
"while",
"until",
"in",
"do",
"done",
"case",
"esac",
"function",
"select"
];
const LITERALS = [
"true",
"false"
];
// to consume paths to prevent keyword matches inside them
const PATH_MODE = { match: /(\/[a-z._-]+)+/ };
// http://www.gnu.org/software/bash/manual/html_node/Shell-Builtin-Commands.html
const SHELL_BUILT_INS = [
"break",
"cd",
"continue",
"eval",
"exec",
"exit",
"export",
"getopts",
"hash",
"pwd",
"readonly",
"return",
"shift",
"test",
"times",
"trap",
"umask",
"unset"
];
const BASH_BUILT_INS = [
"alias",
"bind",
"builtin",
"caller",
"command",
"declare",
"echo",
"enable",
"help",
"let",
"local",
"logout",
"mapfile",
"printf",
"read",
"readarray",
"source",
"type",
"typeset",
"ulimit",
"unalias"
];
const ZSH_BUILT_INS = [
"autoload",
"bg",
"bindkey",
"bye",
"cap",
"chdir",
"clone",
"comparguments",
"compcall",
"compctl",
"compdescribe",
"compfiles",
"compgroups",
"compquote",
"comptags",
"comptry",
"compvalues",
"dirs",
"disable",
"disown",
"echotc",
"echoti",
"emulate",
"fc",
"fg",
"float",
"functions",
"getcap",
"getln",
"history",
"integer",
"jobs",
"kill",
"limit",
"log",
"noglob",
"popd",
"print",
"pushd",
"pushln",
"rehash",
"sched",
"setcap",
"setopt",
"stat",
"suspend",
"ttyctl",
"unfunction",
"unhash",
"unlimit",
"unsetopt",
"vared",
"wait",
"whence",
"where",
"which",
"zcompile",
"zformat",
"zftp",
"zle",
"zmodload",
"zparseopts",
"zprof",
"zpty",
"zregexparse",
"zsocket",
"zstyle",
"ztcp"
];
const GNU_CORE_UTILS = [
"chcon",
"chgrp",
"chown",
"chmod",
"cp",
"dd",
"df",
"dir",
"dircolors",
"ln",
"ls",
"mkdir",
"mkfifo",
"mknod",
"mktemp",
"mv",
"realpath",
"rm",
"rmdir",
"shred",
"sync",
"touch",
"truncate",
"vdir",
"b2sum",
"base32",
"base64",
"cat",
"cksum",
"comm",
"csplit",
"cut",
"expand",
"fmt",
"fold",
"head",
"join",
"md5sum",
"nl",
"numfmt",
"od",
"paste",
"ptx",
"pr",
"sha1sum",
"sha224sum",
"sha256sum",
"sha384sum",
"sha512sum",
"shuf",
"sort",
"split",
"sum",
"tac",
"tail",
"tr",
"tsort",
"unexpand",
"uniq",
"wc",
"arch",
"basename",
"chroot",
"date",
"dirname",
"du",
"echo",
"env",
"expr",
"factor",
// "false", // keyword literal already
"groups",
"hostid",
"id",
"link",
"logname",
"nice",
"nohup",
"nproc",
"pathchk",
"pinky",
"printenv",
"printf",
"pwd",
"readlink",
"runcon",
"seq",
"sleep",
"stat",
"stdbuf",
"stty",
"tee",
"test",
"timeout",
// "true", // keyword literal already
"tty",
"uname",
"unlink",
"uptime",
"users",
"who",
"whoami",
"yes"
];
return {
name: 'Bash',
aliases: [ 'sh' ],
keywords: {
$pattern: /\b[a-z][a-z0-9._-]+\b/,
keyword: KEYWORDS,
literal: LITERALS,
built_in: [
...SHELL_BUILT_INS,
...BASH_BUILT_INS,
// Shell modifiers
"set",
"shopt",
...ZSH_BUILT_INS,
...GNU_CORE_UTILS
]
},
contains: [
KNOWN_SHEBANG, // to catch known shells and boost relevancy
hljs.SHEBANG(), // to catch unknown shells but still highlight the shebang
FUNCTION,
ARITHMETIC,
hljs.HASH_COMMENT_MODE,
HERE_DOC,
PATH_MODE,
QUOTE_STRING,
ESCAPED_QUOTE,
APOS_STRING,
ESCAPED_APOS,
VAR
]
};
}
var bash_1 = bash;
/*
Language: BASIC
Author: Raphaël Assénat <raph@raphnet.net>
Description: Based on the BASIC reference from the Tandy 1000 guide
Website: https://en.wikipedia.org/wiki/Tandy_1000
*/
/** @type LanguageFn */
function basic(hljs) {
const KEYWORDS = [
"ABS",
"ASC",
"AND",
"ATN",
"AUTO|0",
"BEEP",
"BLOAD|10",
"BSAVE|10",
"CALL",
"CALLS",
"CDBL",
"CHAIN",
"CHDIR",
"CHR$|10",
"CINT",
"CIRCLE",
"CLEAR",
"CLOSE",
"CLS",
"COLOR",
"COM",
"COMMON",
"CONT",
"COS",
"CSNG",
"CSRLIN",
"CVD",
"CVI",
"CVS",
"DATA",
"DATE$",
"DEFDBL",
"DEFINT",
"DEFSNG",
"DEFSTR",
"DEF|0",
"SEG",
"USR",
"DELETE",
"DIM",
"DRAW",
"EDIT",
"END",
"ENVIRON",
"ENVIRON$",
"EOF",
"EQV",
"ERASE",
"ERDEV",
"ERDEV$",
"ERL",
"ERR",
"ERROR",
"EXP",
"FIELD",
"FILES",
"FIX",
"FOR|0",
"FRE",
"GET",
"GOSUB|10",
"GOTO",
"HEX$",
"IF",
"THEN",
"ELSE|0",
"INKEY$",
"INP",
"INPUT",
"INPUT#",
"INPUT$",
"INSTR",
"IMP",
"INT",
"IOCTL",
"IOCTL$",
"KEY",
"ON",
"OFF",
"LIST",
"KILL",
"LEFT$",
"LEN",
"LET",
"LINE",
"LLIST",
"LOAD",
"LOC",
"LOCATE",
"LOF",
"LOG",
"LPRINT",
"USING",
"LSET",
"MERGE",
"MID$",
"MKDIR",
"MKD$",
"MKI$",
"MKS$",
"MOD",
"NAME",
"NEW",
"NEXT",
"NOISE",
"NOT",
"OCT$",
"ON",
"OR",
"PEN",
"PLAY",
"STRIG",
"OPEN",
"OPTION",
"BASE",
"OUT",
"PAINT",
"PALETTE",
"PCOPY",
"PEEK",
"PMAP",
"POINT",
"POKE",
"POS",
"PRINT",
"PRINT]",
"PSET",
"PRESET",
"PUT",
"RANDOMIZE",
"READ",
"REM",
"RENUM",
"RESET|0",
"RESTORE",
"RESUME",
"RETURN|0",
"RIGHT$",
"RMDIR",
"RND",
"RSET",
"RUN",
"SAVE",
"SCREEN",
"SGN",
"SHELL",
"SIN",
"SOUND",
"SPACE$",
"SPC",
"SQR",
"STEP",
"STICK",
"STOP",
"STR$",
"STRING$",
"SWAP",
"SYSTEM",
"TAB",
"TAN",
"TIME$",
"TIMER",
"TROFF",
"TRON",
"TO",
"USR",
"VAL",
"VARPTR",
"VARPTR$",
"VIEW",
"WAIT",
"WHILE",
"WEND",
"WIDTH",
"WINDOW",
"WRITE",
"XOR"
];
return {
name: 'BASIC',
case_insensitive: true,
illegal: '^\.',
// Support explicitly typed variables that end with $%! or #.
keywords: {
$pattern: '[a-zA-Z][a-zA-Z0-9_$%!#]*',
keyword: KEYWORDS
},
contains: [
hljs.QUOTE_STRING_MODE,
hljs.COMMENT('REM', '$', { relevance: 10 }),
hljs.COMMENT('\'', '$', { relevance: 0 }),
{
// Match line numbers
className: 'symbol',
begin: '^[0-9]+ ',
relevance: 10
},
{
// Match typed numeric constants (1000, 12.34!, 1.2e5, 1.5#, 1.2D2)
className: 'number',
begin: '\\b\\d+(\\.\\d+)?([edED]\\d+)?[#\!]?',
relevance: 0
},
{
// Match hexadecimal numbers (&Hxxxx)
className: 'number',
begin: '(&[hH][0-9a-fA-F]{1,4})'
},
{
// Match octal numbers (&Oxxxxxx)
className: 'number',
begin: '(&[oO][0-7]{1,6})'
}
]
};
}
var basic_1 = basic;
/*
Language: BackusNaur Form
Website: https://en.wikipedia.org/wiki/BackusNaur_form
Author: Oleg Efimov <efimovov@gmail.com>
*/
/** @type LanguageFn */
function bnf(hljs) {
return {
name: 'BackusNaur Form',
contains: [
// Attribute
{
className: 'attribute',
begin: /</,
end: />/
},
// Specific
{
begin: /::=/,
end: /$/,
contains: [
{
begin: /</,
end: />/
},
// Common
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
}
]
};
}
var bnf_1 = bnf;
/*
Language: Brainfuck
Author: Evgeny Stepanischev <imbolk@gmail.com>
Website: https://esolangs.org/wiki/Brainfuck
*/
/** @type LanguageFn */
function brainfuck(hljs) {
const LITERAL = {
className: 'literal',
begin: /[+-]+/,
relevance: 0
};
return {
name: 'Brainfuck',
aliases: [ 'bf' ],
contains: [
hljs.COMMENT(
/[^\[\]\.,\+\-<> \r\n]/,
/[\[\]\.,\+\-<> \r\n]/,
{
contains: [
{
match: /[ ]+[^\[\]\.,\+\-<> \r\n]/,
relevance: 0
}
],
returnEnd: true,
relevance: 0
}
),
{
className: 'title',
begin: '[\\[\\]]',
relevance: 0
},
{
className: 'string',
begin: '[\\.,]',
relevance: 0
},
{
// this mode works as the only relevance counter
// it looks ahead to find the start of a run of literals
// so only the runs are counted as relevant
begin: /(?=\+\+|--)/,
contains: [ LITERAL ]
},
LITERAL
]
};
}
var brainfuck_1 = brainfuck;
/*
Language: C
Category: common, system
Website: https://en.wikipedia.org/wiki/C_(programming_language)
*/
/** @type LanguageFn */
function c(hljs) {
const regex = hljs.regex;
// added for historic reasons because `hljs.C_LINE_COMMENT_MODE` does
// not include such support nor can we be sure all the grammars depending
// on it would desire this behavior
const C_LINE_COMMENT_MODE = hljs.COMMENT('//', '$', { contains: [ { begin: /\\\n/ } ] });
const DECLTYPE_AUTO_RE = 'decltype\\(auto\\)';
const NAMESPACE_RE = '[a-zA-Z_]\\w*::';
const TEMPLATE_ARGUMENT_RE = '<[^<>]+>';
const FUNCTION_TYPE_RE = '('
+ DECLTYPE_AUTO_RE + '|'
+ regex.optional(NAMESPACE_RE)
+ '[a-zA-Z_]\\w*' + regex.optional(TEMPLATE_ARGUMENT_RE)
+ ')';
const TYPES = {
className: 'type',
variants: [
{ begin: '\\b[a-z\\d_]*_t\\b' },
{ match: /\batomic_[a-z]{3,6}\b/ }
]
};
// https://en.cppreference.com/w/cpp/language/escape
// \\ \x \xFF \u2837 \u00323747 \374
const CHARACTER_ESCAPES = '\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)';
const STRINGS = {
className: 'string',
variants: [
{
begin: '(u8?|U|L)?"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '(u8?|U|L)?\'(' + CHARACTER_ESCAPES + "|.)",
end: '\'',
illegal: '.'
},
hljs.END_SAME_AS_BEGIN({
begin: /(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,
end: /\)([^()\\ ]{0,16})"/
})
]
};
const NUMBERS = {
className: 'number',
variants: [
{ begin: '\\b(0b[01\']+)' },
{ begin: '(-?)\\b([\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)' },
{ begin: '(-?)(\\b0[xX][a-fA-F0-9\']+|(\\b[\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)([eE][-+]?[\\d\']+)?)' }
],
relevance: 0
};
const PREPROCESSOR = {
className: 'meta',
begin: /#\s*[a-z]+\b/,
end: /$/,
keywords: { keyword:
'if else elif endif define undef warning error line '
+ 'pragma _Pragma ifdef ifndef include' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
hljs.inherit(STRINGS, { className: 'string' }),
{
className: 'string',
begin: /<.*?>/
},
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
const TITLE_MODE = {
className: 'title',
begin: regex.optional(NAMESPACE_RE) + hljs.IDENT_RE,
relevance: 0
};
const FUNCTION_TITLE = regex.optional(NAMESPACE_RE) + hljs.IDENT_RE + '\\s*\\(';
const C_KEYWORDS = [
"asm",
"auto",
"break",
"case",
"continue",
"default",
"do",
"else",
"enum",
"extern",
"for",
"fortran",
"goto",
"if",
"inline",
"register",
"restrict",
"return",
"sizeof",
"struct",
"switch",
"typedef",
"union",
"volatile",
"while",
"_Alignas",
"_Alignof",
"_Atomic",
"_Generic",
"_Noreturn",
"_Static_assert",
"_Thread_local",
// aliases
"alignas",
"alignof",
"noreturn",
"static_assert",
"thread_local",
// not a C keyword but is, for all intents and purposes, treated exactly like one.
"_Pragma"
];
const C_TYPES = [
"float",
"double",
"signed",
"unsigned",
"int",
"short",
"long",
"char",
"void",
"_Bool",
"_Complex",
"_Imaginary",
"_Decimal32",
"_Decimal64",
"_Decimal128",
// modifiers
"const",
"static",
// aliases
"complex",
"bool",
"imaginary"
];
const KEYWORDS = {
keyword: C_KEYWORDS,
type: C_TYPES,
literal: 'true false NULL',
// TODO: apply hinting work similar to what was done in cpp.js
built_in: 'std string wstring cin cout cerr clog stdin stdout stderr stringstream istringstream ostringstream '
+ 'auto_ptr deque list queue stack vector map set pair bitset multiset multimap unordered_set '
+ 'unordered_map unordered_multiset unordered_multimap priority_queue make_pair array shared_ptr abort terminate abs acos '
+ 'asin atan2 atan calloc ceil cosh cos exit exp fabs floor fmod fprintf fputs free frexp '
+ 'fscanf future isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper '
+ 'isxdigit tolower toupper labs ldexp log10 log malloc realloc memchr memcmp memcpy memset modf pow '
+ 'printf putchar puts scanf sinh sin snprintf sprintf sqrt sscanf strcat strchr strcmp '
+ 'strcpy strcspn strlen strncat strncmp strncpy strpbrk strrchr strspn strstr tanh tan '
+ 'vfprintf vprintf vsprintf endl initializer_list unique_ptr',
};
const EXPRESSION_CONTAINS = [
PREPROCESSOR,
TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
NUMBERS,
STRINGS
];
const EXPRESSION_CONTEXT = {
// This mode covers expression context where we can't expect a function
// definition and shouldn't highlight anything that looks like one:
// `return some()`, `else if()`, `(x*sum(1, 2))`
variants: [
{
begin: /=/,
end: /;/
},
{
begin: /\(/,
end: /\)/
},
{
beginKeywords: 'new throw return else',
end: /;/
}
],
keywords: KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([ 'self' ]),
relevance: 0
}
]),
relevance: 0
};
const FUNCTION_DECLARATION = {
begin: '(' + FUNCTION_TYPE_RE + '[\\*&\\s]+)+' + FUNCTION_TITLE,
returnBegin: true,
end: /[{;=]/,
excludeEnd: true,
keywords: KEYWORDS,
illegal: /[^\w\s\*&:<>.]/,
contains: [
{ // to prevent it from being confused as the function title
begin: DECLTYPE_AUTO_RE,
keywords: KEYWORDS,
relevance: 0
},
{
begin: FUNCTION_TITLE,
returnBegin: true,
contains: [ hljs.inherit(TITLE_MODE, { className: "title.function" }) ],
relevance: 0
},
// allow for multiple declarations, e.g.:
// extern void f(int), g(char);
{
relevance: 0,
match: /,/
},
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
relevance: 0,
contains: [
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
TYPES,
// Count matching parentheses.
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
relevance: 0,
contains: [
'self',
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
TYPES
]
}
]
},
TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
PREPROCESSOR
]
};
return {
name: "C",
aliases: [ 'h' ],
keywords: KEYWORDS,
// Until differentiations are added between `c` and `cpp`, `c` will
// not be auto-detected to avoid auto-detect conflicts between C and C++
disableAutodetect: true,
illegal: '</',
contains: [].concat(
EXPRESSION_CONTEXT,
FUNCTION_DECLARATION,
EXPRESSION_CONTAINS,
[
PREPROCESSOR,
{
begin: hljs.IDENT_RE + '::',
keywords: KEYWORDS
},
{
className: 'class',
beginKeywords: 'enum class struct union',
end: /[{;:<>=]/,
contains: [
{ beginKeywords: "final class struct" },
hljs.TITLE_MODE
]
}
]),
exports: {
preprocessor: PREPROCESSOR,
strings: STRINGS,
keywords: KEYWORDS
}
};
}
var c_1 = c;
/*
Language: C/AL
Author: Kenneth Fuglsang Christensen <kfuglsang@gmail.com>
Description: Provides highlighting of Microsoft Dynamics NAV C/AL code files
Website: https://docs.microsoft.com/en-us/dynamics-nav/programming-in-c-al
*/
/** @type LanguageFn */
function cal(hljs) {
const regex = hljs.regex;
const KEYWORDS = [
"div",
"mod",
"in",
"and",
"or",
"not",
"xor",
"asserterror",
"begin",
"case",
"do",
"downto",
"else",
"end",
"exit",
"for",
"local",
"if",
"of",
"repeat",
"then",
"to",
"until",
"while",
"with",
"var"
];
const LITERALS = 'false true';
const COMMENT_MODES = [
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT(
/\{/,
/\}/,
{ relevance: 0 }
),
hljs.COMMENT(
/\(\*/,
/\*\)/,
{ relevance: 10 }
)
];
const STRING = {
className: 'string',
begin: /'/,
end: /'/,
contains: [ { begin: /''/ } ]
};
const CHAR_STRING = {
className: 'string',
begin: /(#\d+)+/
};
const DATE = {
className: 'number',
begin: '\\b\\d+(\\.\\d+)?(DT|D|T)',
relevance: 0
};
const DBL_QUOTED_VARIABLE = {
className: 'string', // not a string technically but makes sense to be highlighted in the same style
begin: '"',
end: '"'
};
const PROCEDURE = {
match: [
/procedure/,
/\s+/,
/[a-zA-Z_][\w@]*/,
/\s*/
],
scope: {
1: "keyword",
3: "title.function"
},
contains: [
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [
STRING,
CHAR_STRING,
hljs.NUMBER_MODE
]
},
...COMMENT_MODES
]
};
const OBJECT_TYPES = [
"Table",
"Form",
"Report",
"Dataport",
"Codeunit",
"XMLport",
"MenuSuite",
"Page",
"Query"
];
const OBJECT = {
match: [
/OBJECT/,
/\s+/,
regex.either(...OBJECT_TYPES),
/\s+/,
/\d+/,
/\s+(?=[^\s])/,
/.*/,
/$/
],
relevance: 3,
scope: {
1: "keyword",
3: "type",
5: "number",
7: "title"
}
};
const PROPERTY = {
match: /[\w]+(?=\=)/,
scope: "attribute",
relevance: 0
};
return {
name: 'C/AL',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
literal: LITERALS
},
illegal: /\/\*/,
contains: [
PROPERTY,
STRING,
CHAR_STRING,
DATE,
DBL_QUOTED_VARIABLE,
hljs.NUMBER_MODE,
OBJECT,
PROCEDURE
]
};
}
var cal_1 = cal;
/*
Language: Capn Proto
Author: Oleg Efimov <efimovov@gmail.com>
Description: Capn Proto message definition format
Website: https://capnproto.org/capnp-tool.html
Category: protocols
*/
/** @type LanguageFn */
function capnproto(hljs) {
const KEYWORDS = [
"struct",
"enum",
"interface",
"union",
"group",
"import",
"using",
"const",
"annotation",
"extends",
"in",
"of",
"on",
"as",
"with",
"from",
"fixed"
];
const TYPES = [
"Void",
"Bool",
"Int8",
"Int16",
"Int32",
"Int64",
"UInt8",
"UInt16",
"UInt32",
"UInt64",
"Float32",
"Float64",
"Text",
"Data",
"AnyPointer",
"AnyStruct",
"Capability",
"List"
];
const LITERALS = [
"true",
"false"
];
const CLASS_DEFINITION = {
variants: [
{ match: [
/(struct|enum|interface)/,
/\s+/,
hljs.IDENT_RE
] },
{ match: [
/extends/,
/\s*\(/,
hljs.IDENT_RE,
/\s*\)/
] }
],
scope: {
1: "keyword",
3: "title.class"
}
};
return {
name: 'Capn Proto',
aliases: [ 'capnp' ],
keywords: {
keyword: KEYWORDS,
type: TYPES,
literal: LITERALS
},
contains: [
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
hljs.HASH_COMMENT_MODE,
{
className: 'meta',
begin: /@0x[\w\d]{16};/,
illegal: /\n/
},
{
className: 'symbol',
begin: /@\d+\b/
},
CLASS_DEFINITION
]
};
}
var capnproto_1 = capnproto;
/*
Language: Ceylon
Author: Lucas Werkmeister <mail@lucaswerkmeister.de>
Website: https://ceylon-lang.org
*/
/** @type LanguageFn */
function ceylon(hljs) {
// 2.3. Identifiers and keywords
const KEYWORDS = [
"assembly",
"module",
"package",
"import",
"alias",
"class",
"interface",
"object",
"given",
"value",
"assign",
"void",
"function",
"new",
"of",
"extends",
"satisfies",
"abstracts",
"in",
"out",
"return",
"break",
"continue",
"throw",
"assert",
"dynamic",
"if",
"else",
"switch",
"case",
"for",
"while",
"try",
"catch",
"finally",
"then",
"let",
"this",
"outer",
"super",
"is",
"exists",
"nonempty"
];
// 7.4.1 Declaration Modifiers
const DECLARATION_MODIFIERS = [
"shared",
"abstract",
"formal",
"default",
"actual",
"variable",
"late",
"native",
"deprecated",
"final",
"sealed",
"annotation",
"suppressWarnings",
"small"
];
// 7.4.2 Documentation
const DOCUMENTATION = [
"doc",
"by",
"license",
"see",
"throws",
"tagged"
];
const SUBST = {
className: 'subst',
excludeBegin: true,
excludeEnd: true,
begin: /``/,
end: /``/,
keywords: KEYWORDS,
relevance: 10
};
const EXPRESSIONS = [
{
// verbatim string
className: 'string',
begin: '"""',
end: '"""',
relevance: 10
},
{
// string literal or template
className: 'string',
begin: '"',
end: '"',
contains: [ SUBST ]
},
{
// character literal
className: 'string',
begin: "'",
end: "'"
},
{
// numeric literal
className: 'number',
begin: '#[0-9a-fA-F_]+|\\$[01_]+|[0-9_]+(?:\\.[0-9_](?:[eE][+-]?\\d+)?)?[kMGTPmunpf]?',
relevance: 0
}
];
SUBST.contains = EXPRESSIONS;
return {
name: 'Ceylon',
keywords: {
keyword: KEYWORDS.concat(DECLARATION_MODIFIERS),
meta: DOCUMENTATION
},
illegal: '\\$[^01]|#[^0-9a-fA-F]',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT('/\\*', '\\*/', { contains: [ 'self' ] }),
{
// compiler annotation
className: 'meta',
begin: '@[a-z]\\w*(?::"[^"]*")?'
}
].concat(EXPRESSIONS)
};
}
var ceylon_1 = ceylon;
/*
Language: Clean
Author: Camil Staps <info@camilstaps.nl>
Category: functional
Website: http://clean.cs.ru.nl
*/
/** @type LanguageFn */
function clean(hljs) {
const KEYWORDS = [
"if",
"let",
"in",
"with",
"where",
"case",
"of",
"class",
"instance",
"otherwise",
"implementation",
"definition",
"system",
"module",
"from",
"import",
"qualified",
"as",
"special",
"code",
"inline",
"foreign",
"export",
"ccall",
"stdcall",
"generic",
"derive",
"infix",
"infixl",
"infixr"
];
return {
name: 'Clean',
aliases: [
'icl',
'dcl'
],
keywords: {
keyword: KEYWORDS,
built_in:
'Int Real Char Bool',
literal:
'True False'
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
{ // relevance booster
begin: '->|<-[|:]?|#!?|>>=|\\{\\||\\|\\}|:==|=:|<>' }
]
};
}
var clean_1 = clean;
/*
Language: Clojure
Description: Clojure syntax (based on lisp.js)
Author: mfornos
Website: https://clojure.org
Category: lisp
*/
/** @type LanguageFn */
function clojure(hljs) {
const SYMBOLSTART = 'a-zA-Z_\\-!.?+*=<>&\'';
const SYMBOL_RE = '[#]?[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:$#]*';
const globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';
const keywords = {
$pattern: SYMBOL_RE,
built_in:
// Clojure keywords
globals + ' '
+ 'cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem '
+ 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? '
+ 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? '
+ 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? '
+ 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . '
+ 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last '
+ 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate '
+ 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext '
+ 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends '
+ 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler '
+ 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter '
+ 'monitor-exit macroexpand macroexpand-1 for dosync and or '
+ 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert '
+ 'peek pop doto proxy first rest cons cast coll last butlast '
+ 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import '
+ 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! '
+ 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger '
+ 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline '
+ 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking '
+ 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! '
+ 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! '
+ 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty '
+ 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list '
+ 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer '
+ 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate '
+ 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta '
+ 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'
};
const SYMBOL = {
begin: SYMBOL_RE,
relevance: 0
};
const NUMBER = {
scope: 'number',
relevance: 0,
variants: [
{ match: /[-+]?0[xX][0-9a-fA-F]+N?/ }, // hexadecimal // 0x2a
{ match: /[-+]?0[0-7]+N?/ }, // octal // 052
{ match: /[-+]?[1-9][0-9]?[rR][0-9a-zA-Z]+N?/ }, // variable radix from 2 to 36 // 2r101010, 8r52, 36r16
{ match: /[-+]?[0-9]+\/[0-9]+N?/ }, // ratio // 1/2
{ match: /[-+]?[0-9]+((\.[0-9]*([eE][+-]?[0-9]+)?M?)|([eE][+-]?[0-9]+M?|M))/ }, // float // 0.42 4.2E-1M 42E1 42M
{ match: /[-+]?([1-9][0-9]*|0)N?/ }, // int (don't match leading 0) // 42 42N
]
};
const CHARACTER = {
scope: 'character',
variants: [
{ match: /\\o[0-3]?[0-7]{1,2}/ }, // Unicode Octal 0 - 377
{ match: /\\u[0-9a-fA-F]{4}/ }, // Unicode Hex 0000 - FFFF
{ match: /\\(newline|space|tab|formfeed|backspace|return)/ }, // special characters
{
match: /\\\S/,
relevance: 0
} // any non-whitespace char
]
};
const REGEX = {
scope: 'regex',
begin: /#"/,
end: /"/,
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null });
const COMMA = {
scope: 'punctuation',
match: /,/,
relevance: 0
};
const COMMENT = hljs.COMMENT(
';',
'$',
{ relevance: 0 }
);
const LITERAL = {
className: 'literal',
begin: /\b(true|false|nil)\b/
};
const COLLECTION = {
begin: "\\[|(#::?" + SYMBOL_RE + ")?\\{",
end: '[\\]\\}]',
relevance: 0
};
const KEY = {
className: 'symbol',
begin: '[:]{1,2}' + SYMBOL_RE
};
const LIST = {
begin: '\\(',
end: '\\)'
};
const BODY = {
endsWithParent: true,
relevance: 0
};
const NAME = {
keywords: keywords,
className: 'name',
begin: SYMBOL_RE,
relevance: 0,
starts: BODY
};
const DEFAULT_CONTAINS = [
COMMA,
LIST,
CHARACTER,
REGEX,
STRING,
COMMENT,
KEY,
COLLECTION,
NUMBER,
LITERAL,
SYMBOL
];
const GLOBAL = {
beginKeywords: globals,
keywords: {
$pattern: SYMBOL_RE,
keyword: globals
},
end: '(\\[|#|\\d|"|:|\\{|\\)|\\(|$)',
contains: [
{
className: 'title',
begin: SYMBOL_RE,
relevance: 0,
excludeEnd: true,
// we can only have a single title
endsParent: true
}
].concat(DEFAULT_CONTAINS)
};
LIST.contains = [
GLOBAL,
NAME,
BODY
];
BODY.contains = DEFAULT_CONTAINS;
COLLECTION.contains = DEFAULT_CONTAINS;
return {
name: 'Clojure',
aliases: [
'clj',
'edn'
],
illegal: /\S/,
contains: [
COMMA,
LIST,
CHARACTER,
REGEX,
STRING,
COMMENT,
KEY,
COLLECTION,
NUMBER,
LITERAL
]
};
}
var clojure_1 = clojure;
/*
Language: Clojure REPL
Description: Clojure REPL sessions
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Requires: clojure.js
Website: https://clojure.org
Category: lisp
*/
/** @type LanguageFn */
function clojureRepl(hljs) {
return {
name: 'Clojure REPL',
contains: [
{
className: 'meta.prompt',
begin: /^([\w.-]+|\s*#_)?=>/,
starts: {
end: /$/,
subLanguage: 'clojure'
}
}
]
};
}
var clojureRepl_1 = clojureRepl;
/*
Language: CMake
Description: CMake is an open-source cross-platform system for build automation.
Author: Igor Kalnitsky <igor@kalnitsky.org>
Website: https://cmake.org
*/
/** @type LanguageFn */
function cmake(hljs) {
return {
name: 'CMake',
aliases: [ 'cmake.in' ],
case_insensitive: true,
keywords: { keyword:
// scripting commands
'break cmake_host_system_information cmake_minimum_required cmake_parse_arguments '
+ 'cmake_policy configure_file continue elseif else endforeach endfunction endif endmacro '
+ 'endwhile execute_process file find_file find_library find_package find_path '
+ 'find_program foreach function get_cmake_property get_directory_property '
+ 'get_filename_component get_property if include include_guard list macro '
+ 'mark_as_advanced math message option return separate_arguments '
+ 'set_directory_properties set_property set site_name string unset variable_watch while '
// project commands
+ 'add_compile_definitions add_compile_options add_custom_command add_custom_target '
+ 'add_definitions add_dependencies add_executable add_library add_link_options '
+ 'add_subdirectory add_test aux_source_directory build_command create_test_sourcelist '
+ 'define_property enable_language enable_testing export fltk_wrap_ui '
+ 'get_source_file_property get_target_property get_test_property include_directories '
+ 'include_external_msproject include_regular_expression install link_directories '
+ 'link_libraries load_cache project qt_wrap_cpp qt_wrap_ui remove_definitions '
+ 'set_source_files_properties set_target_properties set_tests_properties source_group '
+ 'target_compile_definitions target_compile_features target_compile_options '
+ 'target_include_directories target_link_directories target_link_libraries '
+ 'target_link_options target_sources try_compile try_run '
// CTest commands
+ 'ctest_build ctest_configure ctest_coverage ctest_empty_binary_directory ctest_memcheck '
+ 'ctest_read_custom_files ctest_run_script ctest_sleep ctest_start ctest_submit '
+ 'ctest_test ctest_update ctest_upload '
// deprecated commands
+ 'build_name exec_program export_library_dependencies install_files install_programs '
+ 'install_targets load_command make_directory output_required_files remove '
+ 'subdir_depends subdirs use_mangled_mesa utility_source variable_requires write_file '
+ 'qt5_use_modules qt5_use_package qt5_wrap_cpp '
// core keywords
+ 'on off true false and or not command policy target test exists is_newer_than '
+ 'is_directory is_symlink is_absolute matches less greater equal less_equal '
+ 'greater_equal strless strgreater strequal strless_equal strgreater_equal version_less '
+ 'version_greater version_equal version_less_equal version_greater_equal in_list defined' },
contains: [
{
className: 'variable',
begin: /\$\{/,
end: /\}/
},
hljs.COMMENT(/#\[\[/, /]]/),
hljs.HASH_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE
]
};
}
var cmake_1 = cmake;
const KEYWORDS$3 = [
"as", // for exports
"in",
"of",
"if",
"for",
"while",
"finally",
"var",
"new",
"function",
"do",
"return",
"void",
"else",
"break",
"catch",
"instanceof",
"with",
"throw",
"case",
"default",
"try",
"switch",
"continue",
"typeof",
"delete",
"let",
"yield",
"const",
"class",
// JS handles these with a special rule
// "get",
// "set",
"debugger",
"async",
"await",
"static",
"import",
"from",
"export",
"extends"
];
const LITERALS$3 = [
"true",
"false",
"null",
"undefined",
"NaN",
"Infinity"
];
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
const TYPES$3 = [
// Fundamental objects
"Object",
"Function",
"Boolean",
"Symbol",
// numbers and dates
"Math",
"Date",
"Number",
"BigInt",
// text
"String",
"RegExp",
// Indexed collections
"Array",
"Float32Array",
"Float64Array",
"Int8Array",
"Uint8Array",
"Uint8ClampedArray",
"Int16Array",
"Int32Array",
"Uint16Array",
"Uint32Array",
"BigInt64Array",
"BigUint64Array",
// Keyed collections
"Set",
"Map",
"WeakSet",
"WeakMap",
// Structured data
"ArrayBuffer",
"SharedArrayBuffer",
"Atomics",
"DataView",
"JSON",
// Control abstraction objects
"Promise",
"Generator",
"GeneratorFunction",
"AsyncFunction",
// Reflection
"Reflect",
"Proxy",
// Internationalization
"Intl",
// WebAssembly
"WebAssembly"
];
const ERROR_TYPES$3 = [
"Error",
"EvalError",
"InternalError",
"RangeError",
"ReferenceError",
"SyntaxError",
"TypeError",
"URIError"
];
const BUILT_IN_GLOBALS$3 = [
"setInterval",
"setTimeout",
"clearInterval",
"clearTimeout",
"require",
"exports",
"eval",
"isFinite",
"isNaN",
"parseFloat",
"parseInt",
"decodeURI",
"decodeURIComponent",
"encodeURI",
"encodeURIComponent",
"escape",
"unescape"
];
const BUILT_INS$3 = [].concat(
BUILT_IN_GLOBALS$3,
TYPES$3,
ERROR_TYPES$3
);
/*
Language: CoffeeScript
Author: Dmytrii Nagirniak <dnagir@gmail.com>
Contributors: Oleg Efimov <efimovov@gmail.com>, Cédric Néhémie <cedric.nehemie@gmail.com>
Description: CoffeeScript is a programming language that transcompiles to JavaScript. For info about language see http://coffeescript.org/
Category: scripting
Website: https://coffeescript.org
*/
/** @type LanguageFn */
function coffeescript(hljs) {
const COFFEE_BUILT_INS = [
'npm',
'print'
];
const COFFEE_LITERALS = [
'yes',
'no',
'on',
'off'
];
const COFFEE_KEYWORDS = [
'then',
'unless',
'until',
'loop',
'by',
'when',
'and',
'or',
'is',
'isnt',
'not'
];
const NOT_VALID_KEYWORDS = [
"var",
"const",
"let",
"function",
"static"
];
const excluding = (list) =>
(kw) => !list.includes(kw);
const KEYWORDS$1 = {
keyword: KEYWORDS$3.concat(COFFEE_KEYWORDS).filter(excluding(NOT_VALID_KEYWORDS)),
literal: LITERALS$3.concat(COFFEE_LITERALS),
built_in: BUILT_INS$3.concat(COFFEE_BUILT_INS)
};
const JS_IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: KEYWORDS$1
};
const EXPRESSIONS = [
hljs.BINARY_NUMBER_MODE,
hljs.inherit(hljs.C_NUMBER_MODE, { starts: {
end: '(\\s*/)?',
relevance: 0
} }), // a number tries to eat the following slash to prevent treating it as a regexp
{
className: 'string',
variants: [
{
begin: /'''/,
end: /'''/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /'/,
end: /'/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /"""/,
end: /"""/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
},
{
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
}
]
},
{
className: 'regexp',
variants: [
{
begin: '///',
end: '///',
contains: [
SUBST,
hljs.HASH_COMMENT_MODE
]
},
{
begin: '//[gim]{0,3}(?=\\W)',
relevance: 0
},
{
// regex can't start with space to parse x / 2 / 3 as two divisions
// regex can't start with *, and it supports an "illegal" in the main mode
begin: /\/(?![ *]).*?(?![\\]).\/[gim]{0,3}(?=\W)/ }
]
},
{ begin: '@' + JS_IDENT_RE // relevance booster
},
{
subLanguage: 'javascript',
excludeBegin: true,
excludeEnd: true,
variants: [
{
begin: '```',
end: '```'
},
{
begin: '`',
end: '`'
}
]
}
];
SUBST.contains = EXPRESSIONS;
const TITLE = hljs.inherit(hljs.TITLE_MODE, { begin: JS_IDENT_RE });
const POSSIBLE_PARAMS_RE = '(\\(.*\\)\\s*)?\\B[-=]>';
const PARAMS = {
className: 'params',
begin: '\\([^\\(]',
returnBegin: true,
/* We need another contained nameless mode to not have every nested
pair of parens to be called "params" */
contains: [
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS$1,
contains: [ 'self' ].concat(EXPRESSIONS)
}
]
};
const CLASS_DEFINITION = {
variants: [
{ match: [
/class\s+/,
JS_IDENT_RE,
/\s+extends\s+/,
JS_IDENT_RE
] },
{ match: [
/class\s+/,
JS_IDENT_RE
] }
],
scope: {
2: "title.class",
4: "title.class.inherited"
},
keywords: KEYWORDS$1
};
return {
name: 'CoffeeScript',
aliases: [
'coffee',
'cson',
'iced'
],
keywords: KEYWORDS$1,
illegal: /\/\*/,
contains: [
...EXPRESSIONS,
hljs.COMMENT('###', '###'),
hljs.HASH_COMMENT_MODE,
{
className: 'function',
begin: '^\\s*' + JS_IDENT_RE + '\\s*=\\s*' + POSSIBLE_PARAMS_RE,
end: '[-=]>',
returnBegin: true,
contains: [
TITLE,
PARAMS
]
},
{
// anonymous function start
begin: /[:\(,=]\s*/,
relevance: 0,
contains: [
{
className: 'function',
begin: POSSIBLE_PARAMS_RE,
end: '[-=]>',
returnBegin: true,
contains: [ PARAMS ]
}
]
},
CLASS_DEFINITION,
{
begin: JS_IDENT_RE + ':',
end: ':',
returnBegin: true,
returnEnd: true,
relevance: 0
}
]
};
}
var coffeescript_1 = coffeescript;
/*
Language: Coq
Author: Stephan Boyer <stephan@stephanboyer.com>
Category: functional
Website: https://coq.inria.fr
*/
/** @type LanguageFn */
function coq(hljs) {
const KEYWORDS = [
"_|0",
"as",
"at",
"cofix",
"else",
"end",
"exists",
"exists2",
"fix",
"for",
"forall",
"fun",
"if",
"IF",
"in",
"let",
"match",
"mod",
"Prop",
"return",
"Set",
"then",
"Type",
"using",
"where",
"with",
"Abort",
"About",
"Add",
"Admit",
"Admitted",
"All",
"Arguments",
"Assumptions",
"Axiom",
"Back",
"BackTo",
"Backtrack",
"Bind",
"Blacklist",
"Canonical",
"Cd",
"Check",
"Class",
"Classes",
"Close",
"Coercion",
"Coercions",
"CoFixpoint",
"CoInductive",
"Collection",
"Combined",
"Compute",
"Conjecture",
"Conjectures",
"Constant",
"constr",
"Constraint",
"Constructors",
"Context",
"Corollary",
"CreateHintDb",
"Cut",
"Declare",
"Defined",
"Definition",
"Delimit",
"Dependencies",
"Dependent",
"Derive",
"Drop",
"eauto",
"End",
"Equality",
"Eval",
"Example",
"Existential",
"Existentials",
"Existing",
"Export",
"exporting",
"Extern",
"Extract",
"Extraction",
"Fact",
"Field",
"Fields",
"File",
"Fixpoint",
"Focus",
"for",
"From",
"Function",
"Functional",
"Generalizable",
"Global",
"Goal",
"Grab",
"Grammar",
"Graph",
"Guarded",
"Heap",
"Hint",
"HintDb",
"Hints",
"Hypotheses",
"Hypothesis",
"ident",
"Identity",
"If",
"Immediate",
"Implicit",
"Import",
"Include",
"Inductive",
"Infix",
"Info",
"Initial",
"Inline",
"Inspect",
"Instance",
"Instances",
"Intro",
"Intros",
"Inversion",
"Inversion_clear",
"Language",
"Left",
"Lemma",
"Let",
"Libraries",
"Library",
"Load",
"LoadPath",
"Local",
"Locate",
"Ltac",
"ML",
"Mode",
"Module",
"Modules",
"Monomorphic",
"Morphism",
"Next",
"NoInline",
"Notation",
"Obligation",
"Obligations",
"Opaque",
"Open",
"Optimize",
"Options",
"Parameter",
"Parameters",
"Parametric",
"Path",
"Paths",
"pattern",
"Polymorphic",
"Preterm",
"Print",
"Printing",
"Program",
"Projections",
"Proof",
"Proposition",
"Pwd",
"Qed",
"Quit",
"Rec",
"Record",
"Recursive",
"Redirect",
"Relation",
"Remark",
"Remove",
"Require",
"Reserved",
"Reset",
"Resolve",
"Restart",
"Rewrite",
"Right",
"Ring",
"Rings",
"Save",
"Scheme",
"Scope",
"Scopes",
"Script",
"Search",
"SearchAbout",
"SearchHead",
"SearchPattern",
"SearchRewrite",
"Section",
"Separate",
"Set",
"Setoid",
"Show",
"Solve",
"Sorted",
"Step",
"Strategies",
"Strategy",
"Structure",
"SubClass",
"Table",
"Tables",
"Tactic",
"Term",
"Test",
"Theorem",
"Time",
"Timeout",
"Transparent",
"Type",
"Typeclasses",
"Types",
"Undelimit",
"Undo",
"Unfocus",
"Unfocused",
"Unfold",
"Universe",
"Universes",
"Unset",
"Unshelve",
"using",
"Variable",
"Variables",
"Variant",
"Verbose",
"Visibility",
"where",
"with"
];
const BUILT_INS = [
"abstract",
"absurd",
"admit",
"after",
"apply",
"as",
"assert",
"assumption",
"at",
"auto",
"autorewrite",
"autounfold",
"before",
"bottom",
"btauto",
"by",
"case",
"case_eq",
"cbn",
"cbv",
"change",
"classical_left",
"classical_right",
"clear",
"clearbody",
"cofix",
"compare",
"compute",
"congruence",
"constr_eq",
"constructor",
"contradict",
"contradiction",
"cut",
"cutrewrite",
"cycle",
"decide",
"decompose",
"dependent",
"destruct",
"destruction",
"dintuition",
"discriminate",
"discrR",
"do",
"double",
"dtauto",
"eapply",
"eassumption",
"eauto",
"ecase",
"econstructor",
"edestruct",
"ediscriminate",
"eelim",
"eexact",
"eexists",
"einduction",
"einjection",
"eleft",
"elim",
"elimtype",
"enough",
"equality",
"erewrite",
"eright",
"esimplify_eq",
"esplit",
"evar",
"exact",
"exactly_once",
"exfalso",
"exists",
"f_equal",
"fail",
"field",
"field_simplify",
"field_simplify_eq",
"first",
"firstorder",
"fix",
"fold",
"fourier",
"functional",
"generalize",
"generalizing",
"gfail",
"give_up",
"has_evar",
"hnf",
"idtac",
"in",
"induction",
"injection",
"instantiate",
"intro",
"intro_pattern",
"intros",
"intuition",
"inversion",
"inversion_clear",
"is_evar",
"is_var",
"lapply",
"lazy",
"left",
"lia",
"lra",
"move",
"native_compute",
"nia",
"nsatz",
"omega",
"once",
"pattern",
"pose",
"progress",
"proof",
"psatz",
"quote",
"record",
"red",
"refine",
"reflexivity",
"remember",
"rename",
"repeat",
"replace",
"revert",
"revgoals",
"rewrite",
"rewrite_strat",
"right",
"ring",
"ring_simplify",
"rtauto",
"set",
"setoid_reflexivity",
"setoid_replace",
"setoid_rewrite",
"setoid_symmetry",
"setoid_transitivity",
"shelve",
"shelve_unifiable",
"simpl",
"simple",
"simplify_eq",
"solve",
"specialize",
"split",
"split_Rabs",
"split_Rmult",
"stepl",
"stepr",
"subst",
"sum",
"swap",
"symmetry",
"tactic",
"tauto",
"time",
"timeout",
"top",
"transitivity",
"trivial",
"try",
"tryif",
"unfold",
"unify",
"until",
"using",
"vm_compute",
"with"
];
return {
name: 'Coq',
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS
},
contains: [
hljs.QUOTE_STRING_MODE,
hljs.COMMENT('\\(\\*', '\\*\\)'),
hljs.C_NUMBER_MODE,
{
className: 'type',
excludeBegin: true,
begin: '\\|\\s*',
end: '\\w+'
},
{ // relevance booster
begin: /[-=]>/ }
]
};
}
var coq_1 = coq;
/*
Language: Caché Object Script
Author: Nikita Savchenko <zitros.lab@gmail.com>
Category: enterprise, scripting
Website: https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls
*/
/** @type LanguageFn */
function cos(hljs) {
const STRINGS = {
className: 'string',
variants: [
{
begin: '"',
end: '"',
contains: [
{ // escaped
begin: "\"\"",
relevance: 0
}
]
}
]
};
const NUMBERS = {
className: "number",
begin: "\\b(\\d+(\\.\\d*)?|\\.\\d+)",
relevance: 0
};
const COS_KEYWORDS =
'property parameter class classmethod clientmethod extends as break '
+ 'catch close continue do d|0 else elseif for goto halt hang h|0 if job '
+ 'j|0 kill k|0 lock l|0 merge new open quit q|0 read r|0 return set s|0 '
+ 'tcommit throw trollback try tstart use view while write w|0 xecute x|0 '
+ 'zkill znspace zn ztrap zwrite zw zzdump zzwrite print zbreak zinsert '
+ 'zload zprint zremove zsave zzprint mv mvcall mvcrt mvdim mvprint zquit '
+ 'zsync ascii';
// registered function - no need in them due to all functions are highlighted,
// but I'll just leave this here.
// "$bit", "$bitcount",
// "$bitfind", "$bitlogic", "$case", "$char", "$classmethod", "$classname",
// "$compile", "$data", "$decimal", "$double", "$extract", "$factor",
// "$find", "$fnumber", "$get", "$increment", "$inumber", "$isobject",
// "$isvaliddouble", "$isvalidnum", "$justify", "$length", "$list",
// "$listbuild", "$listdata", "$listfind", "$listfromstring", "$listget",
// "$listlength", "$listnext", "$listsame", "$listtostring", "$listvalid",
// "$locate", "$match", "$method", "$name", "$nconvert", "$next",
// "$normalize", "$now", "$number", "$order", "$parameter", "$piece",
// "$prefetchoff", "$prefetchon", "$property", "$qlength", "$qsubscript",
// "$query", "$random", "$replace", "$reverse", "$sconvert", "$select",
// "$sortbegin", "$sortend", "$stack", "$text", "$translate", "$view",
// "$wascii", "$wchar", "$wextract", "$wfind", "$wiswide", "$wlength",
// "$wreverse", "$xecute", "$zabs", "$zarccos", "$zarcsin", "$zarctan",
// "$zcos", "$zcot", "$zcsc", "$zdate", "$zdateh", "$zdatetime",
// "$zdatetimeh", "$zexp", "$zhex", "$zln", "$zlog", "$zpower", "$zsec",
// "$zsin", "$zsqr", "$ztan", "$ztime", "$ztimeh", "$zboolean",
// "$zconvert", "$zcrc", "$zcyc", "$zdascii", "$zdchar", "$zf",
// "$ziswide", "$zlascii", "$zlchar", "$zname", "$zposition", "$zqascii",
// "$zqchar", "$zsearch", "$zseek", "$zstrip", "$zwascii", "$zwchar",
// "$zwidth", "$zwpack", "$zwbpack", "$zwunpack", "$zwbunpack", "$zzenkaku",
// "$change", "$mv", "$mvat", "$mvfmt", "$mvfmts", "$mviconv",
// "$mviconvs", "$mvinmat", "$mvlover", "$mvoconv", "$mvoconvs", "$mvraise",
// "$mvtrans", "$mvv", "$mvname", "$zbitand", "$zbitcount", "$zbitfind",
// "$zbitget", "$zbitlen", "$zbitnot", "$zbitor", "$zbitset", "$zbitstr",
// "$zbitxor", "$zincrement", "$znext", "$zorder", "$zprevious", "$zsort",
// "device", "$ecode", "$estack", "$etrap", "$halt", "$horolog",
// "$io", "$job", "$key", "$namespace", "$principal", "$quit", "$roles",
// "$storage", "$system", "$test", "$this", "$tlevel", "$username",
// "$x", "$y", "$za", "$zb", "$zchild", "$zeof", "$zeos", "$zerror",
// "$zhorolog", "$zio", "$zjob", "$zmode", "$znspace", "$zparent", "$zpi",
// "$zpos", "$zreference", "$zstorage", "$ztimestamp", "$ztimezone",
// "$ztrap", "$zversion"
return {
name: 'Caché Object Script',
case_insensitive: true,
aliases: [ "cls" ],
keywords: COS_KEYWORDS,
contains: [
NUMBERS,
STRINGS,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: "comment",
begin: /;/,
end: "$",
relevance: 0
},
{ // Functions and user-defined functions: write $ztime(60*60*3), $$myFunc(10), $$^Val(1)
className: "built_in",
begin: /(?:\$\$?|\.\.)\^?[a-zA-Z]+/
},
{ // Macro command: quit $$$OK
className: "built_in",
begin: /\$\$\$[a-zA-Z]+/
},
{ // Special (global) variables: write %request.Content; Built-in classes: %Library.Integer
className: "built_in",
begin: /%[a-z]+(?:\.[a-z]+)*/
},
{ // Global variable: set ^globalName = 12 write ^globalName
className: "symbol",
begin: /\^%?[a-zA-Z][\w]*/
},
{ // Some control constructions: do ##class(Package.ClassName).Method(), ##super()
className: "keyword",
begin: /##class|##super|#define|#dim/
},
// sub-languages: are not fully supported by hljs by 11/15/2015
// left for the future implementation.
{
begin: /&sql\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
subLanguage: "sql"
},
{
begin: /&(js|jscript|javascript)</,
end: />/,
excludeBegin: true,
excludeEnd: true,
subLanguage: "javascript"
},
{
// this brakes first and last tag, but this is the only way to embed a valid html
begin: /&html<\s*</,
end: />\s*>/,
subLanguage: "xml"
}
]
};
}
var cos_1 = cos;
/*
Language: C++
Category: common, system
Website: https://isocpp.org
*/
/** @type LanguageFn */
function cpp(hljs) {
const regex = hljs.regex;
// added for historic reasons because `hljs.C_LINE_COMMENT_MODE` does
// not include such support nor can we be sure all the grammars depending
// on it would desire this behavior
const C_LINE_COMMENT_MODE = hljs.COMMENT('//', '$', { contains: [ { begin: /\\\n/ } ] });
const DECLTYPE_AUTO_RE = 'decltype\\(auto\\)';
const NAMESPACE_RE = '[a-zA-Z_]\\w*::';
const TEMPLATE_ARGUMENT_RE = '<[^<>]+>';
const FUNCTION_TYPE_RE = '(?!struct)('
+ DECLTYPE_AUTO_RE + '|'
+ regex.optional(NAMESPACE_RE)
+ '[a-zA-Z_]\\w*' + regex.optional(TEMPLATE_ARGUMENT_RE)
+ ')';
const CPP_PRIMITIVE_TYPES = {
className: 'type',
begin: '\\b[a-z\\d_]*_t\\b'
};
// https://en.cppreference.com/w/cpp/language/escape
// \\ \x \xFF \u2837 \u00323747 \374
const CHARACTER_ESCAPES = '\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)';
const STRINGS = {
className: 'string',
variants: [
{
begin: '(u8?|U|L)?"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '(u8?|U|L)?\'(' + CHARACTER_ESCAPES + '|.)',
end: '\'',
illegal: '.'
},
hljs.END_SAME_AS_BEGIN({
begin: /(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,
end: /\)([^()\\ ]{0,16})"/
})
]
};
const NUMBERS = {
className: 'number',
variants: [
{ begin: '\\b(0b[01\']+)' },
{ begin: '(-?)\\b([\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)' },
{ begin: '(-?)(\\b0[xX][a-fA-F0-9\']+|(\\b[\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)([eE][-+]?[\\d\']+)?)' }
],
relevance: 0
};
const PREPROCESSOR = {
className: 'meta',
begin: /#\s*[a-z]+\b/,
end: /$/,
keywords: { keyword:
'if else elif endif define undef warning error line '
+ 'pragma _Pragma ifdef ifndef include' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
hljs.inherit(STRINGS, { className: 'string' }),
{
className: 'string',
begin: /<.*?>/
},
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
const TITLE_MODE = {
className: 'title',
begin: regex.optional(NAMESPACE_RE) + hljs.IDENT_RE,
relevance: 0
};
const FUNCTION_TITLE = regex.optional(NAMESPACE_RE) + hljs.IDENT_RE + '\\s*\\(';
// https://en.cppreference.com/w/cpp/keyword
const RESERVED_KEYWORDS = [
'alignas',
'alignof',
'and',
'and_eq',
'asm',
'atomic_cancel',
'atomic_commit',
'atomic_noexcept',
'auto',
'bitand',
'bitor',
'break',
'case',
'catch',
'class',
'co_await',
'co_return',
'co_yield',
'compl',
'concept',
'const_cast|10',
'consteval',
'constexpr',
'constinit',
'continue',
'decltype',
'default',
'delete',
'do',
'dynamic_cast|10',
'else',
'enum',
'explicit',
'export',
'extern',
'false',
'final',
'for',
'friend',
'goto',
'if',
'import',
'inline',
'module',
'mutable',
'namespace',
'new',
'noexcept',
'not',
'not_eq',
'nullptr',
'operator',
'or',
'or_eq',
'override',
'private',
'protected',
'public',
'reflexpr',
'register',
'reinterpret_cast|10',
'requires',
'return',
'sizeof',
'static_assert',
'static_cast|10',
'struct',
'switch',
'synchronized',
'template',
'this',
'thread_local',
'throw',
'transaction_safe',
'transaction_safe_dynamic',
'true',
'try',
'typedef',
'typeid',
'typename',
'union',
'using',
'virtual',
'volatile',
'while',
'xor',
'xor_eq'
];
// https://en.cppreference.com/w/cpp/keyword
const RESERVED_TYPES = [
'bool',
'char',
'char16_t',
'char32_t',
'char8_t',
'double',
'float',
'int',
'long',
'short',
'void',
'wchar_t',
'unsigned',
'signed',
'const',
'static'
];
const TYPE_HINTS = [
'any',
'auto_ptr',
'barrier',
'binary_semaphore',
'bitset',
'complex',
'condition_variable',
'condition_variable_any',
'counting_semaphore',
'deque',
'false_type',
'future',
'imaginary',
'initializer_list',
'istringstream',
'jthread',
'latch',
'lock_guard',
'multimap',
'multiset',
'mutex',
'optional',
'ostringstream',
'packaged_task',
'pair',
'promise',
'priority_queue',
'queue',
'recursive_mutex',
'recursive_timed_mutex',
'scoped_lock',
'set',
'shared_future',
'shared_lock',
'shared_mutex',
'shared_timed_mutex',
'shared_ptr',
'stack',
'string_view',
'stringstream',
'timed_mutex',
'thread',
'true_type',
'tuple',
'unique_lock',
'unique_ptr',
'unordered_map',
'unordered_multimap',
'unordered_multiset',
'unordered_set',
'variant',
'vector',
'weak_ptr',
'wstring',
'wstring_view'
];
const FUNCTION_HINTS = [
'abort',
'abs',
'acos',
'apply',
'as_const',
'asin',
'atan',
'atan2',
'calloc',
'ceil',
'cerr',
'cin',
'clog',
'cos',
'cosh',
'cout',
'declval',
'endl',
'exchange',
'exit',
'exp',
'fabs',
'floor',
'fmod',
'forward',
'fprintf',
'fputs',
'free',
'frexp',
'fscanf',
'future',
'invoke',
'isalnum',
'isalpha',
'iscntrl',
'isdigit',
'isgraph',
'islower',
'isprint',
'ispunct',
'isspace',
'isupper',
'isxdigit',
'labs',
'launder',
'ldexp',
'log',
'log10',
'make_pair',
'make_shared',
'make_shared_for_overwrite',
'make_tuple',
'make_unique',
'malloc',
'memchr',
'memcmp',
'memcpy',
'memset',
'modf',
'move',
'pow',
'printf',
'putchar',
'puts',
'realloc',
'scanf',
'sin',
'sinh',
'snprintf',
'sprintf',
'sqrt',
'sscanf',
'std',
'stderr',
'stdin',
'stdout',
'strcat',
'strchr',
'strcmp',
'strcpy',
'strcspn',
'strlen',
'strncat',
'strncmp',
'strncpy',
'strpbrk',
'strrchr',
'strspn',
'strstr',
'swap',
'tan',
'tanh',
'terminate',
'to_underlying',
'tolower',
'toupper',
'vfprintf',
'visit',
'vprintf',
'vsprintf'
];
const LITERALS = [
'NULL',
'false',
'nullopt',
'nullptr',
'true'
];
// https://en.cppreference.com/w/cpp/keyword
const BUILT_IN = [ '_Pragma' ];
const CPP_KEYWORDS = {
type: RESERVED_TYPES,
keyword: RESERVED_KEYWORDS,
literal: LITERALS,
built_in: BUILT_IN,
_type_hints: TYPE_HINTS
};
const FUNCTION_DISPATCH = {
className: 'function.dispatch',
relevance: 0,
keywords: {
// Only for relevance, not highlighting.
_hint: FUNCTION_HINTS },
begin: regex.concat(
/\b/,
/(?!decltype)/,
/(?!if)/,
/(?!for)/,
/(?!switch)/,
/(?!while)/,
hljs.IDENT_RE,
regex.lookahead(/(<[^<>]+>|)\s*\(/))
};
const EXPRESSION_CONTAINS = [
FUNCTION_DISPATCH,
PREPROCESSOR,
CPP_PRIMITIVE_TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
NUMBERS,
STRINGS
];
const EXPRESSION_CONTEXT = {
// This mode covers expression context where we can't expect a function
// definition and shouldn't highlight anything that looks like one:
// `return some()`, `else if()`, `(x*sum(1, 2))`
variants: [
{
begin: /=/,
end: /;/
},
{
begin: /\(/,
end: /\)/
},
{
beginKeywords: 'new throw return else',
end: /;/
}
],
keywords: CPP_KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([
{
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
contains: EXPRESSION_CONTAINS.concat([ 'self' ]),
relevance: 0
}
]),
relevance: 0
};
const FUNCTION_DECLARATION = {
className: 'function',
begin: '(' + FUNCTION_TYPE_RE + '[\\*&\\s]+)+' + FUNCTION_TITLE,
returnBegin: true,
end: /[{;=]/,
excludeEnd: true,
keywords: CPP_KEYWORDS,
illegal: /[^\w\s\*&:<>.]/,
contains: [
{ // to prevent it from being confused as the function title
begin: DECLTYPE_AUTO_RE,
keywords: CPP_KEYWORDS,
relevance: 0
},
{
begin: FUNCTION_TITLE,
returnBegin: true,
contains: [ TITLE_MODE ],
relevance: 0
},
// needed because we do not have look-behind on the below rule
// to prevent it from grabbing the final : in a :: pair
{
begin: /::/,
relevance: 0
},
// initializers
{
begin: /:/,
endsWithParent: true,
contains: [
STRINGS,
NUMBERS
]
},
// allow for multiple declarations, e.g.:
// extern void f(int), g(char);
{
relevance: 0,
match: /,/
},
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
relevance: 0,
contains: [
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
CPP_PRIMITIVE_TYPES,
// Count matching parentheses.
{
begin: /\(/,
end: /\)/,
keywords: CPP_KEYWORDS,
relevance: 0,
contains: [
'self',
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRINGS,
NUMBERS,
CPP_PRIMITIVE_TYPES
]
}
]
},
CPP_PRIMITIVE_TYPES,
C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
PREPROCESSOR
]
};
return {
name: 'C++',
aliases: [
'cc',
'c++',
'h++',
'hpp',
'hh',
'hxx',
'cxx'
],
keywords: CPP_KEYWORDS,
illegal: '</',
classNameAliases: { 'function.dispatch': 'built_in' },
contains: [].concat(
EXPRESSION_CONTEXT,
FUNCTION_DECLARATION,
FUNCTION_DISPATCH,
EXPRESSION_CONTAINS,
[
PREPROCESSOR,
{ // containers: ie, `vector <int> rooms (9);`
begin: '\\b(deque|list|queue|priority_queue|pair|stack|vector|map|set|bitset|multiset|multimap|unordered_map|unordered_set|unordered_multiset|unordered_multimap|array|tuple|optional|variant|function)\\s*<(?!<)',
end: '>',
keywords: CPP_KEYWORDS,
contains: [
'self',
CPP_PRIMITIVE_TYPES
]
},
{
begin: hljs.IDENT_RE + '::',
keywords: CPP_KEYWORDS
},
{
match: [
// extra complexity to deal with `enum class` and `enum struct`
/\b(?:enum(?:\s+(?:class|struct))?|class|struct|union)/,
/\s+/,
/\w+/
],
className: {
1: 'keyword',
3: 'title.class'
}
}
])
};
}
var cpp_1 = cpp;
/*
Language: crmsh
Author: Kristoffer Gronlund <kgronlund@suse.com>
Website: http://crmsh.github.io
Description: Syntax Highlighting for the crmsh DSL
Category: config
*/
/** @type LanguageFn */
function crmsh(hljs) {
const RESOURCES = 'primitive rsc_template';
const COMMANDS = 'group clone ms master location colocation order fencing_topology '
+ 'rsc_ticket acl_target acl_group user role '
+ 'tag xml';
const PROPERTY_SETS = 'property rsc_defaults op_defaults';
const KEYWORDS = 'params meta operations op rule attributes utilization';
const OPERATORS = 'read write deny defined not_defined in_range date spec in '
+ 'ref reference attribute type xpath version and or lt gt tag '
+ 'lte gte eq ne \\';
const TYPES = 'number string';
const LITERALS = 'Master Started Slave Stopped start promote demote stop monitor true false';
return {
name: 'crmsh',
aliases: [
'crm',
'pcmk'
],
case_insensitive: true,
keywords: {
keyword: KEYWORDS + ' ' + OPERATORS + ' ' + TYPES,
literal: LITERALS
},
contains: [
hljs.HASH_COMMENT_MODE,
{
beginKeywords: 'node',
starts: {
end: '\\s*([\\w_-]+:)?',
starts: {
className: 'title',
end: '\\s*[\\$\\w_][\\w_-]*'
}
}
},
{
beginKeywords: RESOURCES,
starts: {
className: 'title',
end: '\\s*[\\$\\w_][\\w_-]*',
starts: { end: '\\s*@?[\\w_][\\w_\\.:-]*' }
}
},
{
begin: '\\b(' + COMMANDS.split(' ').join('|') + ')\\s+',
keywords: COMMANDS,
starts: {
className: 'title',
end: '[\\$\\w_][\\w_-]*'
}
},
{
beginKeywords: PROPERTY_SETS,
starts: {
className: 'title',
end: '\\s*([\\w_-]+:)?'
}
},
hljs.QUOTE_STRING_MODE,
{
className: 'meta',
begin: '(ocf|systemd|service|lsb):[\\w_:-]+',
relevance: 0
},
{
className: 'number',
begin: '\\b\\d+(\\.\\d+)?(ms|s|h|m)?',
relevance: 0
},
{
className: 'literal',
begin: '[-]?(infinity|inf)',
relevance: 0
},
{
className: 'attr',
begin: /([A-Za-z$_#][\w_-]+)=/,
relevance: 0
},
{
className: 'tag',
begin: '</?',
end: '/?>',
relevance: 0
}
]
};
}
var crmsh_1 = crmsh;
/*
Language: Crystal
Author: TSUYUSATO Kitsune <make.just.on@gmail.com>
Website: https://crystal-lang.org
*/
/** @type LanguageFn */
function crystal(hljs) {
const INT_SUFFIX = '(_?[ui](8|16|32|64|128))?';
const FLOAT_SUFFIX = '(_?f(32|64))?';
const CRYSTAL_IDENT_RE = '[a-zA-Z_]\\w*[!?=]?';
const CRYSTAL_METHOD_RE = '[a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|[=!]~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~|]|//|//=|&[-+*]=?|&\\*\\*|\\[\\][=?]?';
const CRYSTAL_PATH_RE = '[A-Za-z_]\\w*(::\\w+)*(\\?|!)?';
const CRYSTAL_KEYWORDS = {
$pattern: CRYSTAL_IDENT_RE,
keyword:
'abstract alias annotation as as? asm begin break case class def do else elsif end ensure enum extend for fun if '
+ 'include instance_sizeof is_a? lib macro module next nil? of out pointerof private protected rescue responds_to? '
+ 'return require select self sizeof struct super then type typeof union uninitialized unless until verbatim when while with yield '
+ '__DIR__ __END_LINE__ __FILE__ __LINE__',
literal: 'false nil true'
};
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: CRYSTAL_KEYWORDS
};
// borrowed from Ruby
const VARIABLE = {
// negative-look forward attemps to prevent false matches like:
// @ident@ or $ident$ that might indicate this is not ruby at all
className: "variable",
begin: '(\\$\\W)|((\\$|@@?)(\\w+))(?=[^@$?])' + `(?![A-Za-z])(?![@$?'])`
};
const EXPANSION = {
className: 'template-variable',
variants: [
{
begin: '\\{\\{',
end: '\\}\\}'
},
{
begin: '\\{%',
end: '%\\}'
}
],
keywords: CRYSTAL_KEYWORDS
};
function recursiveParen(begin, end) {
const
contains = [
{
begin: begin,
end: end
}
];
contains[0].contains = contains;
return contains;
}
const STRING = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
},
{
begin: /`/,
end: /`/
},
{
begin: '%[Qwi]?\\(',
end: '\\)',
contains: recursiveParen('\\(', '\\)')
},
{
begin: '%[Qwi]?\\[',
end: '\\]',
contains: recursiveParen('\\[', '\\]')
},
{
begin: '%[Qwi]?\\{',
end: /\}/,
contains: recursiveParen(/\{/, /\}/)
},
{
begin: '%[Qwi]?<',
end: '>',
contains: recursiveParen('<', '>')
},
{
begin: '%[Qwi]?\\|',
end: '\\|'
},
{
begin: /<<-\w+$/,
end: /^\s*\w+$/
}
],
relevance: 0
};
const Q_STRING = {
className: 'string',
variants: [
{
begin: '%q\\(',
end: '\\)',
contains: recursiveParen('\\(', '\\)')
},
{
begin: '%q\\[',
end: '\\]',
contains: recursiveParen('\\[', '\\]')
},
{
begin: '%q\\{',
end: /\}/,
contains: recursiveParen(/\{/, /\}/)
},
{
begin: '%q<',
end: '>',
contains: recursiveParen('<', '>')
},
{
begin: '%q\\|',
end: '\\|'
},
{
begin: /<<-'\w+'$/,
end: /^\s*\w+$/
}
],
relevance: 0
};
const REGEXP = {
begin: '(?!%\\})(' + hljs.RE_STARTERS_RE + '|\\n|\\b(case|if|select|unless|until|when|while)\\b)\\s*',
keywords: 'case if select unless until when while',
contains: [
{
className: 'regexp',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
variants: [
{
begin: '//[a-z]*',
relevance: 0
},
{
begin: '/(?!\\/)',
end: '/[a-z]*'
}
]
}
],
relevance: 0
};
const REGEXP2 = {
className: 'regexp',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
variants: [
{
begin: '%r\\(',
end: '\\)',
contains: recursiveParen('\\(', '\\)')
},
{
begin: '%r\\[',
end: '\\]',
contains: recursiveParen('\\[', '\\]')
},
{
begin: '%r\\{',
end: /\}/,
contains: recursiveParen(/\{/, /\}/)
},
{
begin: '%r<',
end: '>',
contains: recursiveParen('<', '>')
},
{
begin: '%r\\|',
end: '\\|'
}
],
relevance: 0
};
const ATTRIBUTE = {
className: 'meta',
begin: '@\\[',
end: '\\]',
contains: [ hljs.inherit(hljs.QUOTE_STRING_MODE, { className: 'string' }) ]
};
const CRYSTAL_DEFAULT_CONTAINS = [
EXPANSION,
STRING,
Q_STRING,
REGEXP2,
REGEXP,
ATTRIBUTE,
VARIABLE,
hljs.HASH_COMMENT_MODE,
{
className: 'class',
beginKeywords: 'class module struct',
end: '$|;',
illegal: /=/,
contains: [
hljs.HASH_COMMENT_MODE,
hljs.inherit(hljs.TITLE_MODE, { begin: CRYSTAL_PATH_RE }),
{ // relevance booster for inheritance
begin: '<' }
]
},
{
className: 'class',
beginKeywords: 'lib enum union',
end: '$|;',
illegal: /=/,
contains: [
hljs.HASH_COMMENT_MODE,
hljs.inherit(hljs.TITLE_MODE, { begin: CRYSTAL_PATH_RE })
]
},
{
beginKeywords: 'annotation',
end: '$|;',
illegal: /=/,
contains: [
hljs.HASH_COMMENT_MODE,
hljs.inherit(hljs.TITLE_MODE, { begin: CRYSTAL_PATH_RE })
],
relevance: 2
},
{
className: 'function',
beginKeywords: 'def',
end: /\B\b/,
contains: [
hljs.inherit(hljs.TITLE_MODE, {
begin: CRYSTAL_METHOD_RE,
endsParent: true
})
]
},
{
className: 'function',
beginKeywords: 'fun macro',
end: /\B\b/,
contains: [
hljs.inherit(hljs.TITLE_MODE, {
begin: CRYSTAL_METHOD_RE,
endsParent: true
})
],
relevance: 2
},
{
className: 'symbol',
begin: hljs.UNDERSCORE_IDENT_RE + '(!|\\?)?:',
relevance: 0
},
{
className: 'symbol',
begin: ':',
contains: [
STRING,
{ begin: CRYSTAL_METHOD_RE }
],
relevance: 0
},
{
className: 'number',
variants: [
{ begin: '\\b0b([01_]+)' + INT_SUFFIX },
{ begin: '\\b0o([0-7_]+)' + INT_SUFFIX },
{ begin: '\\b0x([A-Fa-f0-9_]+)' + INT_SUFFIX },
{ begin: '\\b([1-9][0-9_]*[0-9]|[0-9])(\\.[0-9][0-9_]*)?([eE]_?[-+]?[0-9_]*)?' + FLOAT_SUFFIX + '(?!_)' },
{ begin: '\\b([1-9][0-9_]*|0)' + INT_SUFFIX }
],
relevance: 0
}
];
SUBST.contains = CRYSTAL_DEFAULT_CONTAINS;
EXPANSION.contains = CRYSTAL_DEFAULT_CONTAINS.slice(1); // without EXPANSION
return {
name: 'Crystal',
aliases: [ 'cr' ],
keywords: CRYSTAL_KEYWORDS,
contains: CRYSTAL_DEFAULT_CONTAINS
};
}
var crystal_1 = crystal;
/*
Language: C#
Author: Jason Diamond <jason@diamond.name>
Contributor: Nicolas LLOBERA <nllobera@gmail.com>, Pieter Vantorre <pietervantorre@gmail.com>, David Pine <david.pine@microsoft.com>
Website: https://docs.microsoft.com/dotnet/csharp/
Category: common
*/
/** @type LanguageFn */
function csharp(hljs) {
const BUILT_IN_KEYWORDS = [
'bool',
'byte',
'char',
'decimal',
'delegate',
'double',
'dynamic',
'enum',
'float',
'int',
'long',
'nint',
'nuint',
'object',
'sbyte',
'short',
'string',
'ulong',
'uint',
'ushort'
];
const FUNCTION_MODIFIERS = [
'public',
'private',
'protected',
'static',
'internal',
'protected',
'abstract',
'async',
'extern',
'override',
'unsafe',
'virtual',
'new',
'sealed',
'partial'
];
const LITERAL_KEYWORDS = [
'default',
'false',
'null',
'true'
];
const NORMAL_KEYWORDS = [
'abstract',
'as',
'base',
'break',
'case',
'catch',
'class',
'const',
'continue',
'do',
'else',
'event',
'explicit',
'extern',
'finally',
'fixed',
'for',
'foreach',
'goto',
'if',
'implicit',
'in',
'interface',
'internal',
'is',
'lock',
'namespace',
'new',
'operator',
'out',
'override',
'params',
'private',
'protected',
'public',
'readonly',
'record',
'ref',
'return',
'scoped',
'sealed',
'sizeof',
'stackalloc',
'static',
'struct',
'switch',
'this',
'throw',
'try',
'typeof',
'unchecked',
'unsafe',
'using',
'virtual',
'void',
'volatile',
'while'
];
const CONTEXTUAL_KEYWORDS = [
'add',
'alias',
'and',
'ascending',
'async',
'await',
'by',
'descending',
'equals',
'from',
'get',
'global',
'group',
'init',
'into',
'join',
'let',
'nameof',
'not',
'notnull',
'on',
'or',
'orderby',
'partial',
'remove',
'select',
'set',
'unmanaged',
'value|0',
'var',
'when',
'where',
'with',
'yield'
];
const KEYWORDS = {
keyword: NORMAL_KEYWORDS.concat(CONTEXTUAL_KEYWORDS),
built_in: BUILT_IN_KEYWORDS,
literal: LITERAL_KEYWORDS
};
const TITLE_MODE = hljs.inherit(hljs.TITLE_MODE, { begin: '[a-zA-Z](\\.?\\w)*' });
const NUMBERS = {
className: 'number',
variants: [
{ begin: '\\b(0b[01\']+)' },
{ begin: '(-?)\\b([\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)(u|U|l|L|ul|UL|f|F|b|B)' },
{ begin: '(-?)(\\b0[xX][a-fA-F0-9\']+|(\\b[\\d\']+(\\.[\\d\']*)?|\\.[\\d\']+)([eE][-+]?[\\d\']+)?)' }
],
relevance: 0
};
const VERBATIM_STRING = {
className: 'string',
begin: '@"',
end: '"',
contains: [ { begin: '""' } ]
};
const VERBATIM_STRING_NO_LF = hljs.inherit(VERBATIM_STRING, { illegal: /\n/ });
const SUBST = {
className: 'subst',
begin: /\{/,
end: /\}/,
keywords: KEYWORDS
};
const SUBST_NO_LF = hljs.inherit(SUBST, { illegal: /\n/ });
const INTERPOLATED_STRING = {
className: 'string',
begin: /\$"/,
end: '"',
illegal: /\n/,
contains: [
{ begin: /\{\{/ },
{ begin: /\}\}/ },
hljs.BACKSLASH_ESCAPE,
SUBST_NO_LF
]
};
const INTERPOLATED_VERBATIM_STRING = {
className: 'string',
begin: /\$@"/,
end: '"',
contains: [
{ begin: /\{\{/ },
{ begin: /\}\}/ },
{ begin: '""' },
SUBST
]
};
const INTERPOLATED_VERBATIM_STRING_NO_LF = hljs.inherit(INTERPOLATED_VERBATIM_STRING, {
illegal: /\n/,
contains: [
{ begin: /\{\{/ },
{ begin: /\}\}/ },
{ begin: '""' },
SUBST_NO_LF
]
});
SUBST.contains = [
INTERPOLATED_VERBATIM_STRING,
INTERPOLATED_STRING,
VERBATIM_STRING,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
NUMBERS,
hljs.C_BLOCK_COMMENT_MODE
];
SUBST_NO_LF.contains = [
INTERPOLATED_VERBATIM_STRING_NO_LF,
INTERPOLATED_STRING,
VERBATIM_STRING_NO_LF,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
NUMBERS,
hljs.inherit(hljs.C_BLOCK_COMMENT_MODE, { illegal: /\n/ })
];
const STRING = { variants: [
INTERPOLATED_VERBATIM_STRING,
INTERPOLATED_STRING,
VERBATIM_STRING,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
] };
const GENERIC_MODIFIER = {
begin: "<",
end: ">",
contains: [
{ beginKeywords: "in out" },
TITLE_MODE
]
};
const TYPE_IDENT_RE = hljs.IDENT_RE + '(<' + hljs.IDENT_RE + '(\\s*,\\s*' + hljs.IDENT_RE + ')*>)?(\\[\\])?';
const AT_IDENTIFIER = {
// prevents expressions like `@class` from incorrect flagging
// `class` as a keyword
begin: "@" + hljs.IDENT_RE,
relevance: 0
};
return {
name: 'C#',
aliases: [
'cs',
'c#'
],
keywords: KEYWORDS,
illegal: /::/,
contains: [
hljs.COMMENT(
'///',
'$',
{
returnBegin: true,
contains: [
{
className: 'doctag',
variants: [
{
begin: '///',
relevance: 0
},
{ begin: '<!--|-->' },
{
begin: '</?',
end: '>'
}
]
}
]
}
),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'meta',
begin: '#',
end: '$',
keywords: { keyword: 'if else elif endif define undef warning error line region endregion pragma checksum' }
},
STRING,
NUMBERS,
{
beginKeywords: 'class interface',
relevance: 0,
end: /[{;=]/,
illegal: /[^\s:,]/,
contains: [
{ beginKeywords: "where class" },
TITLE_MODE,
GENERIC_MODIFIER,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
beginKeywords: 'namespace',
relevance: 0,
end: /[{;=]/,
illegal: /[^\s:]/,
contains: [
TITLE_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
beginKeywords: 'record',
relevance: 0,
end: /[{;=]/,
illegal: /[^\s:]/,
contains: [
TITLE_MODE,
GENERIC_MODIFIER,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
// [Attributes("")]
className: 'meta',
begin: '^\\s*\\[(?=[\\w])',
excludeBegin: true,
end: '\\]',
excludeEnd: true,
contains: [
{
className: 'string',
begin: /"/,
end: /"/
}
]
},
{
// Expression keywords prevent 'keyword Name(...)' from being
// recognized as a function definition
beginKeywords: 'new return throw await else',
relevance: 0
},
{
className: 'function',
begin: '(' + TYPE_IDENT_RE + '\\s+)+' + hljs.IDENT_RE + '\\s*(<[^=]+>\\s*)?\\(',
returnBegin: true,
end: /\s*[{;=]/,
excludeEnd: true,
keywords: KEYWORDS,
contains: [
// prevents these from being highlighted `title`
{
beginKeywords: FUNCTION_MODIFIERS.join(" "),
relevance: 0
},
{
begin: hljs.IDENT_RE + '\\s*(<[^=]+>\\s*)?\\(',
returnBegin: true,
contains: [
hljs.TITLE_MODE,
GENERIC_MODIFIER
],
relevance: 0
},
{ match: /\(\)/ },
{
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS,
relevance: 0,
contains: [
STRING,
NUMBERS,
hljs.C_BLOCK_COMMENT_MODE
]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
AT_IDENTIFIER
]
};
}
var csharp_1 = csharp;
/*
Language: CSP
Description: Content Security Policy definition highlighting
Author: Taras <oxdef@oxdef.info>
Website: https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP
vim: ts=2 sw=2 st=2
*/
/** @type LanguageFn */
function csp(hljs) {
const KEYWORDS = [
"base-uri",
"child-src",
"connect-src",
"default-src",
"font-src",
"form-action",
"frame-ancestors",
"frame-src",
"img-src",
"manifest-src",
"media-src",
"object-src",
"plugin-types",
"report-uri",
"sandbox",
"script-src",
"style-src",
"trusted-types",
"unsafe-hashes",
"worker-src"
];
return {
name: 'CSP',
case_insensitive: false,
keywords: {
$pattern: '[a-zA-Z][a-zA-Z0-9_-]*',
keyword: KEYWORDS
},
contains: [
{
className: 'string',
begin: "'",
end: "'"
},
{
className: 'attribute',
begin: '^Content',
end: ':',
excludeEnd: true
}
]
};
}
var csp_1 = csp;
const MODES$3 = (hljs) => {
return {
IMPORTANT: {
scope: 'meta',
begin: '!important'
},
BLOCK_COMMENT: hljs.C_BLOCK_COMMENT_MODE,
HEXCOLOR: {
scope: 'number',
begin: /#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/
},
FUNCTION_DISPATCH: {
className: "built_in",
begin: /[\w-]+(?=\()/
},
ATTRIBUTE_SELECTOR_MODE: {
scope: 'selector-attr',
begin: /\[/,
end: /\]/,
illegal: '$',
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
},
CSS_NUMBER_MODE: {
scope: 'number',
begin: hljs.NUMBER_RE + '(' +
'%|em|ex|ch|rem' +
'|vw|vh|vmin|vmax' +
'|cm|mm|in|pt|pc|px' +
'|deg|grad|rad|turn' +
'|s|ms' +
'|Hz|kHz' +
'|dpi|dpcm|dppx' +
')?',
relevance: 0
},
CSS_VARIABLE: {
className: "attr",
begin: /--[A-Za-z_][A-Za-z0-9_-]*/
}
};
};
const TAGS$3 = [
'a',
'abbr',
'address',
'article',
'aside',
'audio',
'b',
'blockquote',
'body',
'button',
'canvas',
'caption',
'cite',
'code',
'dd',
'del',
'details',
'dfn',
'div',
'dl',
'dt',
'em',
'fieldset',
'figcaption',
'figure',
'footer',
'form',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'header',
'hgroup',
'html',
'i',
'iframe',
'img',
'input',
'ins',
'kbd',
'label',
'legend',
'li',
'main',
'mark',
'menu',
'nav',
'object',
'ol',
'p',
'q',
'quote',
'samp',
'section',
'span',
'strong',
'summary',
'sup',
'table',
'tbody',
'td',
'textarea',
'tfoot',
'th',
'thead',
'time',
'tr',
'ul',
'var',
'video'
];
const MEDIA_FEATURES$3 = [
'any-hover',
'any-pointer',
'aspect-ratio',
'color',
'color-gamut',
'color-index',
'device-aspect-ratio',
'device-height',
'device-width',
'display-mode',
'forced-colors',
'grid',
'height',
'hover',
'inverted-colors',
'monochrome',
'orientation',
'overflow-block',
'overflow-inline',
'pointer',
'prefers-color-scheme',
'prefers-contrast',
'prefers-reduced-motion',
'prefers-reduced-transparency',
'resolution',
'scan',
'scripting',
'update',
'width',
// TODO: find a better solution?
'min-width',
'max-width',
'min-height',
'max-height'
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-classes
const PSEUDO_CLASSES$3 = [
'active',
'any-link',
'blank',
'checked',
'current',
'default',
'defined',
'dir', // dir()
'disabled',
'drop',
'empty',
'enabled',
'first',
'first-child',
'first-of-type',
'fullscreen',
'future',
'focus',
'focus-visible',
'focus-within',
'has', // has()
'host', // host or host()
'host-context', // host-context()
'hover',
'indeterminate',
'in-range',
'invalid',
'is', // is()
'lang', // lang()
'last-child',
'last-of-type',
'left',
'link',
'local-link',
'not', // not()
'nth-child', // nth-child()
'nth-col', // nth-col()
'nth-last-child', // nth-last-child()
'nth-last-col', // nth-last-col()
'nth-last-of-type', //nth-last-of-type()
'nth-of-type', //nth-of-type()
'only-child',
'only-of-type',
'optional',
'out-of-range',
'past',
'placeholder-shown',
'read-only',
'read-write',
'required',
'right',
'root',
'scope',
'target',
'target-within',
'user-invalid',
'valid',
'visited',
'where' // where()
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-elements
const PSEUDO_ELEMENTS$3 = [
'after',
'backdrop',
'before',
'cue',
'cue-region',
'first-letter',
'first-line',
'grammar-error',
'marker',
'part',
'placeholder',
'selection',
'slotted',
'spelling-error'
];
const ATTRIBUTES$3 = [
'align-content',
'align-items',
'align-self',
'all',
'animation',
'animation-delay',
'animation-direction',
'animation-duration',
'animation-fill-mode',
'animation-iteration-count',
'animation-name',
'animation-play-state',
'animation-timing-function',
'backface-visibility',
'background',
'background-attachment',
'background-blend-mode',
'background-clip',
'background-color',
'background-image',
'background-origin',
'background-position',
'background-repeat',
'background-size',
'block-size',
'border',
'border-block',
'border-block-color',
'border-block-end',
'border-block-end-color',
'border-block-end-style',
'border-block-end-width',
'border-block-start',
'border-block-start-color',
'border-block-start-style',
'border-block-start-width',
'border-block-style',
'border-block-width',
'border-bottom',
'border-bottom-color',
'border-bottom-left-radius',
'border-bottom-right-radius',
'border-bottom-style',
'border-bottom-width',
'border-collapse',
'border-color',
'border-image',
'border-image-outset',
'border-image-repeat',
'border-image-slice',
'border-image-source',
'border-image-width',
'border-inline',
'border-inline-color',
'border-inline-end',
'border-inline-end-color',
'border-inline-end-style',
'border-inline-end-width',
'border-inline-start',
'border-inline-start-color',
'border-inline-start-style',
'border-inline-start-width',
'border-inline-style',
'border-inline-width',
'border-left',
'border-left-color',
'border-left-style',
'border-left-width',
'border-radius',
'border-right',
'border-right-color',
'border-right-style',
'border-right-width',
'border-spacing',
'border-style',
'border-top',
'border-top-color',
'border-top-left-radius',
'border-top-right-radius',
'border-top-style',
'border-top-width',
'border-width',
'bottom',
'box-decoration-break',
'box-shadow',
'box-sizing',
'break-after',
'break-before',
'break-inside',
'caption-side',
'caret-color',
'clear',
'clip',
'clip-path',
'clip-rule',
'color',
'column-count',
'column-fill',
'column-gap',
'column-rule',
'column-rule-color',
'column-rule-style',
'column-rule-width',
'column-span',
'column-width',
'columns',
'contain',
'content',
'content-visibility',
'counter-increment',
'counter-reset',
'cue',
'cue-after',
'cue-before',
'cursor',
'direction',
'display',
'empty-cells',
'filter',
'flex',
'flex-basis',
'flex-direction',
'flex-flow',
'flex-grow',
'flex-shrink',
'flex-wrap',
'float',
'flow',
'font',
'font-display',
'font-family',
'font-feature-settings',
'font-kerning',
'font-language-override',
'font-size',
'font-size-adjust',
'font-smoothing',
'font-stretch',
'font-style',
'font-synthesis',
'font-variant',
'font-variant-caps',
'font-variant-east-asian',
'font-variant-ligatures',
'font-variant-numeric',
'font-variant-position',
'font-variation-settings',
'font-weight',
'gap',
'glyph-orientation-vertical',
'grid',
'grid-area',
'grid-auto-columns',
'grid-auto-flow',
'grid-auto-rows',
'grid-column',
'grid-column-end',
'grid-column-start',
'grid-gap',
'grid-row',
'grid-row-end',
'grid-row-start',
'grid-template',
'grid-template-areas',
'grid-template-columns',
'grid-template-rows',
'hanging-punctuation',
'height',
'hyphens',
'icon',
'image-orientation',
'image-rendering',
'image-resolution',
'ime-mode',
'inline-size',
'isolation',
'justify-content',
'left',
'letter-spacing',
'line-break',
'line-height',
'list-style',
'list-style-image',
'list-style-position',
'list-style-type',
'margin',
'margin-block',
'margin-block-end',
'margin-block-start',
'margin-bottom',
'margin-inline',
'margin-inline-end',
'margin-inline-start',
'margin-left',
'margin-right',
'margin-top',
'marks',
'mask',
'mask-border',
'mask-border-mode',
'mask-border-outset',
'mask-border-repeat',
'mask-border-slice',
'mask-border-source',
'mask-border-width',
'mask-clip',
'mask-composite',
'mask-image',
'mask-mode',
'mask-origin',
'mask-position',
'mask-repeat',
'mask-size',
'mask-type',
'max-block-size',
'max-height',
'max-inline-size',
'max-width',
'min-block-size',
'min-height',
'min-inline-size',
'min-width',
'mix-blend-mode',
'nav-down',
'nav-index',
'nav-left',
'nav-right',
'nav-up',
'none',
'normal',
'object-fit',
'object-position',
'opacity',
'order',
'orphans',
'outline',
'outline-color',
'outline-offset',
'outline-style',
'outline-width',
'overflow',
'overflow-wrap',
'overflow-x',
'overflow-y',
'padding',
'padding-block',
'padding-block-end',
'padding-block-start',
'padding-bottom',
'padding-inline',
'padding-inline-end',
'padding-inline-start',
'padding-left',
'padding-right',
'padding-top',
'page-break-after',
'page-break-before',
'page-break-inside',
'pause',
'pause-after',
'pause-before',
'perspective',
'perspective-origin',
'pointer-events',
'position',
'quotes',
'resize',
'rest',
'rest-after',
'rest-before',
'right',
'row-gap',
'scroll-margin',
'scroll-margin-block',
'scroll-margin-block-end',
'scroll-margin-block-start',
'scroll-margin-bottom',
'scroll-margin-inline',
'scroll-margin-inline-end',
'scroll-margin-inline-start',
'scroll-margin-left',
'scroll-margin-right',
'scroll-margin-top',
'scroll-padding',
'scroll-padding-block',
'scroll-padding-block-end',
'scroll-padding-block-start',
'scroll-padding-bottom',
'scroll-padding-inline',
'scroll-padding-inline-end',
'scroll-padding-inline-start',
'scroll-padding-left',
'scroll-padding-right',
'scroll-padding-top',
'scroll-snap-align',
'scroll-snap-stop',
'scroll-snap-type',
'scrollbar-color',
'scrollbar-gutter',
'scrollbar-width',
'shape-image-threshold',
'shape-margin',
'shape-outside',
'speak',
'speak-as',
'src', // @font-face
'tab-size',
'table-layout',
'text-align',
'text-align-all',
'text-align-last',
'text-combine-upright',
'text-decoration',
'text-decoration-color',
'text-decoration-line',
'text-decoration-style',
'text-emphasis',
'text-emphasis-color',
'text-emphasis-position',
'text-emphasis-style',
'text-indent',
'text-justify',
'text-orientation',
'text-overflow',
'text-rendering',
'text-shadow',
'text-transform',
'text-underline-position',
'top',
'transform',
'transform-box',
'transform-origin',
'transform-style',
'transition',
'transition-delay',
'transition-duration',
'transition-property',
'transition-timing-function',
'unicode-bidi',
'vertical-align',
'visibility',
'voice-balance',
'voice-duration',
'voice-family',
'voice-pitch',
'voice-range',
'voice-rate',
'voice-stress',
'voice-volume',
'white-space',
'widows',
'width',
'will-change',
'word-break',
'word-spacing',
'word-wrap',
'writing-mode',
'z-index'
// reverse makes sure longer attributes `font-weight` are matched fully
// instead of getting false positives on say `font`
].reverse();
/*
Language: CSS
Category: common, css, web
Website: https://developer.mozilla.org/en-US/docs/Web/CSS
*/
/** @type LanguageFn */
function css(hljs) {
const regex = hljs.regex;
const modes = MODES$3(hljs);
const VENDOR_PREFIX = { begin: /-(webkit|moz|ms|o)-(?=[a-z])/ };
const AT_MODIFIERS = "and or not only";
const AT_PROPERTY_RE = /@-?\w[\w]*(-\w+)*/; // @-webkit-keyframes
const IDENT_RE = '[a-zA-Z-][a-zA-Z0-9_-]*';
const STRINGS = [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
];
return {
name: 'CSS',
case_insensitive: true,
illegal: /[=|'\$]/,
keywords: { keyframePosition: "from to" },
classNameAliases: {
// for visual continuity with `tag {}` and because we
// don't have a great class for this?
keyframePosition: "selector-tag" },
contains: [
modes.BLOCK_COMMENT,
VENDOR_PREFIX,
// to recognize keyframe 40% etc which are outside the scope of our
// attribute value mode
modes.CSS_NUMBER_MODE,
{
className: 'selector-id',
begin: /#[A-Za-z0-9_-]+/,
relevance: 0
},
{
className: 'selector-class',
begin: '\\.' + IDENT_RE,
relevance: 0
},
modes.ATTRIBUTE_SELECTOR_MODE,
{
className: 'selector-pseudo',
variants: [
{ begin: ':(' + PSEUDO_CLASSES$3.join('|') + ')' },
{ begin: ':(:)?(' + PSEUDO_ELEMENTS$3.join('|') + ')' }
]
},
// we may actually need this (12/2020)
// { // pseudo-selector params
// begin: /\(/,
// end: /\)/,
// contains: [ hljs.CSS_NUMBER_MODE ]
// },
modes.CSS_VARIABLE,
{
className: 'attribute',
begin: '\\b(' + ATTRIBUTES$3.join('|') + ')\\b'
},
// attribute values
{
begin: /:/,
end: /[;}{]/,
contains: [
modes.BLOCK_COMMENT,
modes.HEXCOLOR,
modes.IMPORTANT,
modes.CSS_NUMBER_MODE,
...STRINGS,
// needed to highlight these as strings and to avoid issues with
// illegal characters that might be inside urls that would tigger the
// languages illegal stack
{
begin: /(url|data-uri)\(/,
end: /\)/,
relevance: 0, // from keywords
keywords: { built_in: "url data-uri" },
contains: [
...STRINGS,
{
className: "string",
// any character other than `)` as in `url()` will be the start
// of a string, which ends with `)` (from the parent mode)
begin: /[^)]/,
endsWithParent: true,
excludeEnd: true
}
]
},
modes.FUNCTION_DISPATCH
]
},
{
begin: regex.lookahead(/@/),
end: '[{;]',
relevance: 0,
illegal: /:/, // break on Less variables @var: ...
contains: [
{
className: 'keyword',
begin: AT_PROPERTY_RE
},
{
begin: /\s/,
endsWithParent: true,
excludeEnd: true,
relevance: 0,
keywords: {
$pattern: /[a-z-]+/,
keyword: AT_MODIFIERS,
attribute: MEDIA_FEATURES$3.join(" ")
},
contains: [
{
begin: /[a-z-]+(?=:)/,
className: "attribute"
},
...STRINGS,
modes.CSS_NUMBER_MODE
]
}
]
},
{
className: 'selector-tag',
begin: '\\b(' + TAGS$3.join('|') + ')\\b'
}
]
};
}
var css_1 = css;
/*
Language: D
Author: Aleksandar Ruzicic <aleksandar@ruzicic.info>
Description: D is a language with C-like syntax and static typing. It pragmatically combines efficiency, control, and modeling power, with safety and programmer productivity.
Version: 1.0a
Website: https://dlang.org
Date: 2012-04-08
*/
/**
* Known issues:
*
* - invalid hex string literals will be recognized as a double quoted strings
* but 'x' at the beginning of string will not be matched
*
* - delimited string literals are not checked for matching end delimiter
* (not possible to do with js regexp)
*
* - content of token string is colored as a string (i.e. no keyword coloring inside a token string)
* also, content of token string is not validated to contain only valid D tokens
*
* - special token sequence rule is not strictly following D grammar (anything following #line
* up to the end of line is matched as special token sequence)
*/
/** @type LanguageFn */
function d(hljs) {
/**
* Language keywords
*
* @type {Object}
*/
const D_KEYWORDS = {
$pattern: hljs.UNDERSCORE_IDENT_RE,
keyword:
'abstract alias align asm assert auto body break byte case cast catch class '
+ 'const continue debug default delete deprecated do else enum export extern final '
+ 'finally for foreach foreach_reverse|10 goto if immutable import in inout int '
+ 'interface invariant is lazy macro mixin module new nothrow out override package '
+ 'pragma private protected public pure ref return scope shared static struct '
+ 'super switch synchronized template this throw try typedef typeid typeof union '
+ 'unittest version void volatile while with __FILE__ __LINE__ __gshared|10 '
+ '__thread __traits __DATE__ __EOF__ __TIME__ __TIMESTAMP__ __VENDOR__ __VERSION__',
built_in:
'bool cdouble cent cfloat char creal dchar delegate double dstring float function '
+ 'idouble ifloat ireal long real short string ubyte ucent uint ulong ushort wchar '
+ 'wstring',
literal:
'false null true'
};
/**
* Number literal regexps
*
* @type {String}
*/
const decimal_integer_re = '(0|[1-9][\\d_]*)';
const decimal_integer_nosus_re = '(0|[1-9][\\d_]*|\\d[\\d_]*|[\\d_]+?\\d)';
const binary_integer_re = '0[bB][01_]+';
const hexadecimal_digits_re = '([\\da-fA-F][\\da-fA-F_]*|_[\\da-fA-F][\\da-fA-F_]*)';
const hexadecimal_integer_re = '0[xX]' + hexadecimal_digits_re;
const decimal_exponent_re = '([eE][+-]?' + decimal_integer_nosus_re + ')';
const decimal_float_re = '(' + decimal_integer_nosus_re + '(\\.\\d*|' + decimal_exponent_re + ')|'
+ '\\d+\\.' + decimal_integer_nosus_re + '|'
+ '\\.' + decimal_integer_re + decimal_exponent_re + '?'
+ ')';
const hexadecimal_float_re = '(0[xX]('
+ hexadecimal_digits_re + '\\.' + hexadecimal_digits_re + '|'
+ '\\.?' + hexadecimal_digits_re
+ ')[pP][+-]?' + decimal_integer_nosus_re + ')';
const integer_re = '('
+ decimal_integer_re + '|'
+ binary_integer_re + '|'
+ hexadecimal_integer_re
+ ')';
const float_re = '('
+ hexadecimal_float_re + '|'
+ decimal_float_re
+ ')';
/**
* Escape sequence supported in D string and character literals
*
* @type {String}
*/
const escape_sequence_re = '\\\\('
+ '[\'"\\?\\\\abfnrtv]|' // common escapes
+ 'u[\\dA-Fa-f]{4}|' // four hex digit unicode codepoint
+ '[0-7]{1,3}|' // one to three octal digit ascii char code
+ 'x[\\dA-Fa-f]{2}|' // two hex digit ascii char code
+ 'U[\\dA-Fa-f]{8}' // eight hex digit unicode codepoint
+ ')|'
+ '&[a-zA-Z\\d]{2,};'; // named character entity
/**
* D integer number literals
*
* @type {Object}
*/
const D_INTEGER_MODE = {
className: 'number',
begin: '\\b' + integer_re + '(L|u|U|Lu|LU|uL|UL)?',
relevance: 0
};
/**
* [D_FLOAT_MODE description]
* @type {Object}
*/
const D_FLOAT_MODE = {
className: 'number',
begin: '\\b('
+ float_re + '([fF]|L|i|[fF]i|Li)?|'
+ integer_re + '(i|[fF]i|Li)'
+ ')',
relevance: 0
};
/**
* D character literal
*
* @type {Object}
*/
const D_CHARACTER_MODE = {
className: 'string',
begin: '\'(' + escape_sequence_re + '|.)',
end: '\'',
illegal: '.'
};
/**
* D string escape sequence
*
* @type {Object}
*/
const D_ESCAPE_SEQUENCE = {
begin: escape_sequence_re,
relevance: 0
};
/**
* D double quoted string literal
*
* @type {Object}
*/
const D_STRING_MODE = {
className: 'string',
begin: '"',
contains: [ D_ESCAPE_SEQUENCE ],
end: '"[cwd]?'
};
/**
* D wysiwyg and delimited string literals
*
* @type {Object}
*/
const D_WYSIWYG_DELIMITED_STRING_MODE = {
className: 'string',
begin: '[rq]"',
end: '"[cwd]?',
relevance: 5
};
/**
* D alternate wysiwyg string literal
*
* @type {Object}
*/
const D_ALTERNATE_WYSIWYG_STRING_MODE = {
className: 'string',
begin: '`',
end: '`[cwd]?'
};
/**
* D hexadecimal string literal
*
* @type {Object}
*/
const D_HEX_STRING_MODE = {
className: 'string',
begin: 'x"[\\da-fA-F\\s\\n\\r]*"[cwd]?',
relevance: 10
};
/**
* D delimited string literal
*
* @type {Object}
*/
const D_TOKEN_STRING_MODE = {
className: 'string',
begin: 'q"\\{',
end: '\\}"'
};
/**
* Hashbang support
*
* @type {Object}
*/
const D_HASHBANG_MODE = {
className: 'meta',
begin: '^#!',
end: '$',
relevance: 5
};
/**
* D special token sequence
*
* @type {Object}
*/
const D_SPECIAL_TOKEN_SEQUENCE_MODE = {
className: 'meta',
begin: '#(line)',
end: '$',
relevance: 5
};
/**
* D attributes
*
* @type {Object}
*/
const D_ATTRIBUTE_MODE = {
className: 'keyword',
begin: '@[a-zA-Z_][a-zA-Z_\\d]*'
};
/**
* D nesting comment
*
* @type {Object}
*/
const D_NESTING_COMMENT_MODE = hljs.COMMENT(
'\\/\\+',
'\\+\\/',
{
contains: [ 'self' ],
relevance: 10
}
);
return {
name: 'D',
keywords: D_KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
D_NESTING_COMMENT_MODE,
D_HEX_STRING_MODE,
D_STRING_MODE,
D_WYSIWYG_DELIMITED_STRING_MODE,
D_ALTERNATE_WYSIWYG_STRING_MODE,
D_TOKEN_STRING_MODE,
D_FLOAT_MODE,
D_INTEGER_MODE,
D_CHARACTER_MODE,
D_HASHBANG_MODE,
D_SPECIAL_TOKEN_SEQUENCE_MODE,
D_ATTRIBUTE_MODE
]
};
}
var d_1 = d;
/*
Language: Markdown
Requires: xml.js
Author: John Crepezzi <john.crepezzi@gmail.com>
Website: https://daringfireball.net/projects/markdown/
Category: common, markup
*/
function markdown(hljs) {
const regex = hljs.regex;
const INLINE_HTML = {
begin: /<\/?[A-Za-z_]/,
end: '>',
subLanguage: 'xml',
relevance: 0
};
const HORIZONTAL_RULE = {
begin: '^[-\\*]{3,}',
end: '$'
};
const CODE = {
className: 'code',
variants: [
// TODO: fix to allow these to work with sublanguage also
{ begin: '(`{3,})[^`](.|\\n)*?\\1`*[ ]*' },
{ begin: '(~{3,})[^~](.|\\n)*?\\1~*[ ]*' },
// needed to allow markdown as a sublanguage to work
{
begin: '```',
end: '```+[ ]*$'
},
{
begin: '~~~',
end: '~~~+[ ]*$'
},
{ begin: '`.+?`' },
{
begin: '(?=^( {4}|\\t))',
// use contains to gobble up multiple lines to allow the block to be whatever size
// but only have a single open/close tag vs one per line
contains: [
{
begin: '^( {4}|\\t)',
end: '(\\n)$'
}
],
relevance: 0
}
]
};
const LIST = {
className: 'bullet',
begin: '^[ \t]*([*+-]|(\\d+\\.))(?=\\s+)',
end: '\\s+',
excludeEnd: true
};
const LINK_REFERENCE = {
begin: /^\[[^\n]+\]:/,
returnBegin: true,
contains: [
{
className: 'symbol',
begin: /\[/,
end: /\]/,
excludeBegin: true,
excludeEnd: true
},
{
className: 'link',
begin: /:\s*/,
end: /$/,
excludeBegin: true
}
]
};
const URL_SCHEME = /[A-Za-z][A-Za-z0-9+.-]*/;
const LINK = {
variants: [
// too much like nested array access in so many languages
// to have any real relevance
{
begin: /\[.+?\]\[.*?\]/,
relevance: 0
},
// popular internet URLs
{
begin: /\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,
relevance: 2
},
{
begin: regex.concat(/\[.+?\]\(/, URL_SCHEME, /:\/\/.*?\)/),
relevance: 2
},
// relative urls
{
begin: /\[.+?\]\([./?&#].*?\)/,
relevance: 1
},
// whatever else, lower relevance (might not be a link at all)
{
begin: /\[.*?\]\(.*?\)/,
relevance: 0
}
],
returnBegin: true,
contains: [
{
// empty strings for alt or link text
match: /\[(?=\])/ },
{
className: 'string',
relevance: 0,
begin: '\\[',
end: '\\]',
excludeBegin: true,
returnEnd: true
},
{
className: 'link',
relevance: 0,
begin: '\\]\\(',
end: '\\)',
excludeBegin: true,
excludeEnd: true
},
{
className: 'symbol',
relevance: 0,
begin: '\\]\\[',
end: '\\]',
excludeBegin: true,
excludeEnd: true
}
]
};
const BOLD = {
className: 'strong',
contains: [], // defined later
variants: [
{
begin: /_{2}(?!\s)/,
end: /_{2}/
},
{
begin: /\*{2}(?!\s)/,
end: /\*{2}/
}
]
};
const ITALIC = {
className: 'emphasis',
contains: [], // defined later
variants: [
{
begin: /\*(?![*\s])/,
end: /\*/
},
{
begin: /_(?![_\s])/,
end: /_/,
relevance: 0
}
]
};
// 3 level deep nesting is not allowed because it would create confusion
// in cases like `***testing***` because where we don't know if the last
// `***` is starting a new bold/italic or finishing the last one
const BOLD_WITHOUT_ITALIC = hljs.inherit(BOLD, { contains: [] });
const ITALIC_WITHOUT_BOLD = hljs.inherit(ITALIC, { contains: [] });
BOLD.contains.push(ITALIC_WITHOUT_BOLD);
ITALIC.contains.push(BOLD_WITHOUT_ITALIC);
let CONTAINABLE = [
INLINE_HTML,
LINK
];
[
BOLD,
ITALIC,
BOLD_WITHOUT_ITALIC,
ITALIC_WITHOUT_BOLD
].forEach(m => {
m.contains = m.contains.concat(CONTAINABLE);
});
CONTAINABLE = CONTAINABLE.concat(BOLD, ITALIC);
const HEADER = {
className: 'section',
variants: [
{
begin: '^#{1,6}',
end: '$',
contains: CONTAINABLE
},
{
begin: '(?=^.+?\\n[=-]{2,}$)',
contains: [
{ begin: '^[=-]*$' },
{
begin: '^',
end: "\\n",
contains: CONTAINABLE
}
]
}
]
};
const BLOCKQUOTE = {
className: 'quote',
begin: '^>\\s+',
contains: CONTAINABLE,
end: '$'
};
return {
name: 'Markdown',
aliases: [
'md',
'mkdown',
'mkd'
],
contains: [
HEADER,
INLINE_HTML,
LIST,
BOLD,
ITALIC,
BLOCKQUOTE,
CODE,
HORIZONTAL_RULE,
LINK,
LINK_REFERENCE
]
};
}
var markdown_1 = markdown;
/*
Language: Dart
Requires: markdown.js
Author: Maxim Dikun <dikmax@gmail.com>
Description: Dart a modern, object-oriented language developed by Google. For more information see https://www.dartlang.org/
Website: https://dart.dev
Category: scripting
*/
/** @type LanguageFn */
function dart(hljs) {
const SUBST = {
className: 'subst',
variants: [ { begin: '\\$[A-Za-z0-9_]+' } ]
};
const BRACED_SUBST = {
className: 'subst',
variants: [
{
begin: /\$\{/,
end: /\}/
}
],
keywords: 'true false null this is new super'
};
const STRING = {
className: 'string',
variants: [
{
begin: 'r\'\'\'',
end: '\'\'\''
},
{
begin: 'r"""',
end: '"""'
},
{
begin: 'r\'',
end: '\'',
illegal: '\\n'
},
{
begin: 'r"',
end: '"',
illegal: '\\n'
},
{
begin: '\'\'\'',
end: '\'\'\'',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
BRACED_SUBST
]
},
{
begin: '"""',
end: '"""',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
BRACED_SUBST
]
},
{
begin: '\'',
end: '\'',
illegal: '\\n',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
BRACED_SUBST
]
},
{
begin: '"',
end: '"',
illegal: '\\n',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
BRACED_SUBST
]
}
]
};
BRACED_SUBST.contains = [
hljs.C_NUMBER_MODE,
STRING
];
const BUILT_IN_TYPES = [
// dart:core
'Comparable',
'DateTime',
'Duration',
'Function',
'Iterable',
'Iterator',
'List',
'Map',
'Match',
'Object',
'Pattern',
'RegExp',
'Set',
'Stopwatch',
'String',
'StringBuffer',
'StringSink',
'Symbol',
'Type',
'Uri',
'bool',
'double',
'int',
'num',
// dart:html
'Element',
'ElementList'
];
const NULLABLE_BUILT_IN_TYPES = BUILT_IN_TYPES.map((e) => `${e}?`);
const BASIC_KEYWORDS = [
"abstract",
"as",
"assert",
"async",
"await",
"base",
"break",
"case",
"catch",
"class",
"const",
"continue",
"covariant",
"default",
"deferred",
"do",
"dynamic",
"else",
"enum",
"export",
"extends",
"extension",
"external",
"factory",
"false",
"final",
"finally",
"for",
"Function",
"get",
"hide",
"if",
"implements",
"import",
"in",
"interface",
"is",
"late",
"library",
"mixin",
"new",
"null",
"on",
"operator",
"part",
"required",
"rethrow",
"return",
"sealed",
"set",
"show",
"static",
"super",
"switch",
"sync",
"this",
"throw",
"true",
"try",
"typedef",
"var",
"void",
"when",
"while",
"with",
"yield"
];
const KEYWORDS = {
keyword: BASIC_KEYWORDS,
built_in:
BUILT_IN_TYPES
.concat(NULLABLE_BUILT_IN_TYPES)
.concat([
// dart:core
'Never',
'Null',
'dynamic',
'print',
// dart:html
'document',
'querySelector',
'querySelectorAll',
'window'
]),
$pattern: /[A-Za-z][A-Za-z0-9_]*\??/
};
return {
name: 'Dart',
keywords: KEYWORDS,
contains: [
STRING,
hljs.COMMENT(
/\/\*\*(?!\/)/,
/\*\//,
{
subLanguage: 'markdown',
relevance: 0
}
),
hljs.COMMENT(
/\/{3,} ?/,
/$/, { contains: [
{
subLanguage: 'markdown',
begin: '.',
end: '$',
relevance: 0
}
] }
),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'class',
beginKeywords: 'class interface',
end: /\{/,
excludeEnd: true,
contains: [
{ beginKeywords: 'extends implements' },
hljs.UNDERSCORE_TITLE_MODE
]
},
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '@[A-Za-z]+'
},
{ begin: '=>' // No markup, just a relevance booster
}
]
};
}
var dart_1 = dart;
/*
Language: Delphi
Website: https://www.embarcadero.com/products/delphi
*/
/** @type LanguageFn */
function delphi(hljs) {
const KEYWORDS = [
"exports",
"register",
"file",
"shl",
"array",
"record",
"property",
"for",
"mod",
"while",
"set",
"ally",
"label",
"uses",
"raise",
"not",
"stored",
"class",
"safecall",
"var",
"interface",
"or",
"private",
"static",
"exit",
"index",
"inherited",
"to",
"else",
"stdcall",
"override",
"shr",
"asm",
"far",
"resourcestring",
"finalization",
"packed",
"virtual",
"out",
"and",
"protected",
"library",
"do",
"xorwrite",
"goto",
"near",
"function",
"end",
"div",
"overload",
"object",
"unit",
"begin",
"string",
"on",
"inline",
"repeat",
"until",
"destructor",
"write",
"message",
"program",
"with",
"read",
"initialization",
"except",
"default",
"nil",
"if",
"case",
"cdecl",
"in",
"downto",
"threadvar",
"of",
"try",
"pascal",
"const",
"external",
"constructor",
"type",
"public",
"then",
"implementation",
"finally",
"published",
"procedure",
"absolute",
"reintroduce",
"operator",
"as",
"is",
"abstract",
"alias",
"assembler",
"bitpacked",
"break",
"continue",
"cppdecl",
"cvar",
"enumerator",
"experimental",
"platform",
"deprecated",
"unimplemented",
"dynamic",
"export",
"far16",
"forward",
"generic",
"helper",
"implements",
"interrupt",
"iochecks",
"local",
"name",
"nodefault",
"noreturn",
"nostackframe",
"oldfpccall",
"otherwise",
"saveregisters",
"softfloat",
"specialize",
"strict",
"unaligned",
"varargs"
];
const COMMENT_MODES = [
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT(/\{/, /\}/, { relevance: 0 }),
hljs.COMMENT(/\(\*/, /\*\)/, { relevance: 10 })
];
const DIRECTIVE = {
className: 'meta',
variants: [
{
begin: /\{\$/,
end: /\}/
},
{
begin: /\(\*\$/,
end: /\*\)/
}
]
};
const STRING = {
className: 'string',
begin: /'/,
end: /'/,
contains: [ { begin: /''/ } ]
};
const NUMBER = {
className: 'number',
relevance: 0,
// Source: https://www.freepascal.org/docs-html/ref/refse6.html
variants: [
{
// Hexadecimal notation, e.g., $7F.
begin: '\\$[0-9A-Fa-f]+' },
{
// Octal notation, e.g., &42.
begin: '&[0-7]+' },
{
// Binary notation, e.g., %1010.
begin: '%[01]+' }
]
};
const CHAR_STRING = {
className: 'string',
begin: /(#\d+)+/
};
const CLASS = {
begin: hljs.IDENT_RE + '\\s*=\\s*class\\s*\\(',
returnBegin: true,
contains: [ hljs.TITLE_MODE ]
};
const FUNCTION = {
className: 'function',
beginKeywords: 'function constructor destructor procedure',
end: /[:;]/,
keywords: 'function constructor|10 destructor|10 procedure|10',
contains: [
hljs.TITLE_MODE,
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [
STRING,
CHAR_STRING,
DIRECTIVE
].concat(COMMENT_MODES)
},
DIRECTIVE
].concat(COMMENT_MODES)
};
return {
name: 'Delphi',
aliases: [
'dpr',
'dfm',
'pas',
'pascal'
],
case_insensitive: true,
keywords: KEYWORDS,
illegal: /"|\$[G-Zg-z]|\/\*|<\/|\|/,
contains: [
STRING,
CHAR_STRING,
hljs.NUMBER_MODE,
NUMBER,
CLASS,
FUNCTION,
DIRECTIVE
].concat(COMMENT_MODES)
};
}
var delphi_1 = delphi;
/*
Language: Diff
Description: Unified and context diff
Author: Vasily Polovnyov <vast@whiteants.net>
Website: https://www.gnu.org/software/diffutils/
Category: common
*/
/** @type LanguageFn */
function diff(hljs) {
const regex = hljs.regex;
return {
name: 'Diff',
aliases: [ 'patch' ],
contains: [
{
className: 'meta',
relevance: 10,
match: regex.either(
/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,
/^\*\*\* +\d+,\d+ +\*\*\*\*$/,
/^--- +\d+,\d+ +----$/
)
},
{
className: 'comment',
variants: [
{
begin: regex.either(
/Index: /,
/^index/,
/={3,}/,
/^-{3}/,
/^\*{3} /,
/^\+{3}/,
/^diff --git/
),
end: /$/
},
{ match: /^\*{15}$/ }
]
},
{
className: 'addition',
begin: /^\+/,
end: /$/
},
{
className: 'deletion',
begin: /^-/,
end: /$/
},
{
className: 'addition',
begin: /^!/,
end: /$/
}
]
};
}
var diff_1 = diff;
/*
Language: Django
Description: Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
Requires: xml.js
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Contributors: Ilya Baryshev <baryshev@gmail.com>
Website: https://www.djangoproject.com
Category: template
*/
/** @type LanguageFn */
function django(hljs) {
const FILTER = {
begin: /\|[A-Za-z]+:?/,
keywords: { name:
'truncatewords removetags linebreaksbr yesno get_digit timesince random striptags '
+ 'filesizeformat escape linebreaks length_is ljust rjust cut urlize fix_ampersands '
+ 'title floatformat capfirst pprint divisibleby add make_list unordered_list urlencode '
+ 'timeuntil urlizetrunc wordcount stringformat linenumbers slice date dictsort '
+ 'dictsortreversed default_if_none pluralize lower join center default '
+ 'truncatewords_html upper length phone2numeric wordwrap time addslashes slugify first '
+ 'escapejs force_escape iriencode last safe safeseq truncatechars localize unlocalize '
+ 'localtime utc timezone' },
contains: [
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE
]
};
return {
name: 'Django',
aliases: [ 'jinja' ],
case_insensitive: true,
subLanguage: 'xml',
contains: [
hljs.COMMENT(/\{%\s*comment\s*%\}/, /\{%\s*endcomment\s*%\}/),
hljs.COMMENT(/\{#/, /#\}/),
{
className: 'template-tag',
begin: /\{%/,
end: /%\}/,
contains: [
{
className: 'name',
begin: /\w+/,
keywords: { name:
'comment endcomment load templatetag ifchanged endifchanged if endif firstof for '
+ 'endfor ifnotequal endifnotequal widthratio extends include spaceless '
+ 'endspaceless regroup ifequal endifequal ssi now with cycle url filter '
+ 'endfilter debug block endblock else autoescape endautoescape csrf_token empty elif '
+ 'endwith static trans blocktrans endblocktrans get_static_prefix get_media_prefix '
+ 'plural get_current_language language get_available_languages '
+ 'get_current_language_bidi get_language_info get_language_info_list localize '
+ 'endlocalize localtime endlocaltime timezone endtimezone get_current_timezone '
+ 'verbatim' },
starts: {
endsWithParent: true,
keywords: 'in by as',
contains: [ FILTER ],
relevance: 0
}
}
]
},
{
className: 'template-variable',
begin: /\{\{/,
end: /\}\}/,
contains: [ FILTER ]
}
]
};
}
var django_1 = django;
/*
Language: DNS Zone
Author: Tim Schumacher <tim@datenknoten.me>
Category: config
Website: https://en.wikipedia.org/wiki/Zone_file
*/
/** @type LanguageFn */
function dns(hljs) {
const KEYWORDS = [
"IN",
"A",
"AAAA",
"AFSDB",
"APL",
"CAA",
"CDNSKEY",
"CDS",
"CERT",
"CNAME",
"DHCID",
"DLV",
"DNAME",
"DNSKEY",
"DS",
"HIP",
"IPSECKEY",
"KEY",
"KX",
"LOC",
"MX",
"NAPTR",
"NS",
"NSEC",
"NSEC3",
"NSEC3PARAM",
"PTR",
"RRSIG",
"RP",
"SIG",
"SOA",
"SRV",
"SSHFP",
"TA",
"TKEY",
"TLSA",
"TSIG",
"TXT"
];
return {
name: 'DNS Zone',
aliases: [
'bind',
'zone'
],
keywords: KEYWORDS,
contains: [
hljs.COMMENT(';', '$', { relevance: 0 }),
{
className: 'meta',
begin: /^\$(TTL|GENERATE|INCLUDE|ORIGIN)\b/
},
// IPv6
{
className: 'number',
begin: '((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))\\b'
},
// IPv4
{
className: 'number',
begin: '((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\b'
},
hljs.inherit(hljs.NUMBER_MODE, { begin: /\b\d+[dhwm]?/ })
]
};
}
var dns_1 = dns;
/*
Language: Dockerfile
Requires: bash.js
Author: Alexis Hénaut <alexis@henaut.net>
Description: language definition for Dockerfile files
Website: https://docs.docker.com/engine/reference/builder/
Category: config
*/
/** @type LanguageFn */
function dockerfile(hljs) {
const KEYWORDS = [
"from",
"maintainer",
"expose",
"env",
"arg",
"user",
"onbuild",
"stopsignal"
];
return {
name: 'Dockerfile',
aliases: [ 'docker' ],
case_insensitive: true,
keywords: KEYWORDS,
contains: [
hljs.HASH_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
{
beginKeywords: 'run cmd entrypoint volume add copy workdir label healthcheck shell',
starts: {
end: /[^\\]$/,
subLanguage: 'bash'
}
}
],
illegal: '</'
};
}
var dockerfile_1 = dockerfile;
/*
Language: Batch file (DOS)
Author: Alexander Makarov <sam@rmcreative.ru>
Contributors: Anton Kochkov <anton.kochkov@gmail.com>
Website: https://en.wikipedia.org/wiki/Batch_file
*/
/** @type LanguageFn */
function dos(hljs) {
const COMMENT = hljs.COMMENT(
/^\s*@?rem\b/, /$/,
{ relevance: 10 }
);
const LABEL = {
className: 'symbol',
begin: '^\\s*[A-Za-z._?][A-Za-z0-9_$#@~.?]*(:|\\s+label)',
relevance: 0
};
const KEYWORDS = [
"if",
"else",
"goto",
"for",
"in",
"do",
"call",
"exit",
"not",
"exist",
"errorlevel",
"defined",
"equ",
"neq",
"lss",
"leq",
"gtr",
"geq"
];
const BUILT_INS = [
"prn",
"nul",
"lpt3",
"lpt2",
"lpt1",
"con",
"com4",
"com3",
"com2",
"com1",
"aux",
"shift",
"cd",
"dir",
"echo",
"setlocal",
"endlocal",
"set",
"pause",
"copy",
"append",
"assoc",
"at",
"attrib",
"break",
"cacls",
"cd",
"chcp",
"chdir",
"chkdsk",
"chkntfs",
"cls",
"cmd",
"color",
"comp",
"compact",
"convert",
"date",
"dir",
"diskcomp",
"diskcopy",
"doskey",
"erase",
"fs",
"find",
"findstr",
"format",
"ftype",
"graftabl",
"help",
"keyb",
"label",
"md",
"mkdir",
"mode",
"more",
"move",
"path",
"pause",
"print",
"popd",
"pushd",
"promt",
"rd",
"recover",
"rem",
"rename",
"replace",
"restore",
"rmdir",
"shift",
"sort",
"start",
"subst",
"time",
"title",
"tree",
"type",
"ver",
"verify",
"vol",
// winutils
"ping",
"net",
"ipconfig",
"taskkill",
"xcopy",
"ren",
"del"
];
return {
name: 'Batch file (DOS)',
aliases: [
'bat',
'cmd'
],
case_insensitive: true,
illegal: /\/\*/,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS
},
contains: [
{
className: 'variable',
begin: /%%[^ ]|%[^ ]+?%|![^ ]+?!/
},
{
className: 'function',
begin: LABEL.begin,
end: 'goto:eof',
contains: [
hljs.inherit(hljs.TITLE_MODE, { begin: '([_a-zA-Z]\\w*\\.)*([_a-zA-Z]\\w*:)?[_a-zA-Z]\\w*' }),
COMMENT
]
},
{
className: 'number',
begin: '\\b\\d+',
relevance: 0
},
COMMENT
]
};
}
var dos_1 = dos;
/*
Language: dsconfig
Description: dsconfig batch configuration language for LDAP directory servers
Contributors: Jacob Childress <jacobc@gmail.com>
Category: enterprise, config
*/
/** @type LanguageFn */
function dsconfig(hljs) {
const QUOTED_PROPERTY = {
className: 'string',
begin: /"/,
end: /"/
};
const APOS_PROPERTY = {
className: 'string',
begin: /'/,
end: /'/
};
const UNQUOTED_PROPERTY = {
className: 'string',
begin: /[\w\-?]+:\w+/,
end: /\W/,
relevance: 0
};
const VALUELESS_PROPERTY = {
className: 'string',
begin: /\w+(\-\w+)*/,
end: /(?=\W)/,
relevance: 0
};
return {
keywords: 'dsconfig',
contains: [
{
className: 'keyword',
begin: '^dsconfig',
end: /\s/,
excludeEnd: true,
relevance: 10
},
{
className: 'built_in',
begin: /(list|create|get|set|delete)-(\w+)/,
end: /\s/,
excludeEnd: true,
illegal: '!@#$%^&*()',
relevance: 10
},
{
className: 'built_in',
begin: /--(\w+)/,
end: /\s/,
excludeEnd: true
},
QUOTED_PROPERTY,
APOS_PROPERTY,
UNQUOTED_PROPERTY,
VALUELESS_PROPERTY,
hljs.HASH_COMMENT_MODE
]
};
}
var dsconfig_1 = dsconfig;
/*
Language: Device Tree
Description: *.dts files used in the Linux kernel
Author: Martin Braun <martin.braun@ettus.com>, Moritz Fischer <moritz.fischer@ettus.com>
Website: https://elinux.org/Device_Tree_Reference
Category: config
*/
/** @type LanguageFn */
function dts(hljs) {
const STRINGS = {
className: 'string',
variants: [
hljs.inherit(hljs.QUOTE_STRING_MODE, { begin: '((u8?|U)|L)?"' }),
{
begin: '(u8?|U)?R"',
end: '"',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '\'\\\\?.',
end: '\'',
illegal: '.'
}
]
};
const NUMBERS = {
className: 'number',
variants: [
{ begin: '\\b(\\d+(\\.\\d*)?|\\.\\d+)(u|U|l|L|ul|UL|f|F)' },
{ begin: hljs.C_NUMBER_RE }
],
relevance: 0
};
const PREPROCESSOR = {
className: 'meta',
begin: '#',
end: '$',
keywords: { keyword: 'if else elif endif define undef ifdef ifndef' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
{
beginKeywords: 'include',
end: '$',
keywords: { keyword: 'include' },
contains: [
hljs.inherit(STRINGS, { className: 'string' }),
{
className: 'string',
begin: '<',
end: '>',
illegal: '\\n'
}
]
},
STRINGS,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
const REFERENCE = {
className: 'variable',
begin: /&[a-z\d_]*\b/
};
const KEYWORD = {
className: 'keyword',
begin: '/[a-z][a-z\\d-]*/'
};
const LABEL = {
className: 'symbol',
begin: '^\\s*[a-zA-Z_][a-zA-Z\\d_]*:'
};
const CELL_PROPERTY = {
className: 'params',
relevance: 0,
begin: '<',
end: '>',
contains: [
NUMBERS,
REFERENCE
]
};
const NODE = {
className: 'title.class',
begin: /[a-zA-Z_][a-zA-Z\d_@-]*(?=\s\{)/,
relevance: 0.2
};
const ROOT_NODE = {
className: 'title.class',
begin: /^\/(?=\s*\{)/,
relevance: 10
};
// TODO: `attribute` might be the right scope here, unsure
// I'm not sure if all these key names have semantic meaning or not
const ATTR_NO_VALUE = {
match: /[a-z][a-z-,]+(?=;)/,
relevance: 0,
scope: "attr"
};
const ATTR = {
relevance: 0,
match: [
/[a-z][a-z-,]+/,
/\s*/,
/=/
],
scope: {
1: "attr",
3: "operator"
}
};
const PUNC = {
scope: "punctuation",
relevance: 0,
// `};` combined is just to avoid tons of useless punctuation nodes
match: /\};|[;{}]/
};
return {
name: 'Device Tree',
contains: [
ROOT_NODE,
REFERENCE,
KEYWORD,
LABEL,
NODE,
ATTR,
ATTR_NO_VALUE,
CELL_PROPERTY,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
NUMBERS,
STRINGS,
PREPROCESSOR,
PUNC,
{
begin: hljs.IDENT_RE + '::',
keywords: ""
}
]
};
}
var dts_1 = dts;
/*
Language: Dust
Requires: xml.js
Author: Michael Allen <michael.allen@benefitfocus.com>
Description: Matcher for dust.js templates.
Website: https://www.dustjs.com
Category: template
*/
/** @type LanguageFn */
function dust(hljs) {
const EXPRESSION_KEYWORDS = 'if eq ne lt lte gt gte select default math sep';
return {
name: 'Dust',
aliases: [ 'dst' ],
case_insensitive: true,
subLanguage: 'xml',
contains: [
{
className: 'template-tag',
begin: /\{[#\/]/,
end: /\}/,
illegal: /;/,
contains: [
{
className: 'name',
begin: /[a-zA-Z\.-]+/,
starts: {
endsWithParent: true,
relevance: 0,
contains: [ hljs.QUOTE_STRING_MODE ]
}
}
]
},
{
className: 'template-variable',
begin: /\{/,
end: /\}/,
illegal: /;/,
keywords: EXPRESSION_KEYWORDS
}
]
};
}
var dust_1 = dust;
/*
Language: Extended Backus-Naur Form
Author: Alex McKibben <alex@nullscope.net>
Website: https://en.wikipedia.org/wiki/Extended_BackusNaur_form
*/
/** @type LanguageFn */
function ebnf(hljs) {
const commentMode = hljs.COMMENT(/\(\*/, /\*\)/);
const nonTerminalMode = {
className: "attribute",
begin: /^[ ]*[a-zA-Z]+([\s_-]+[a-zA-Z]+)*/
};
const specialSequenceMode = {
className: "meta",
begin: /\?.*\?/
};
const ruleBodyMode = {
begin: /=/,
end: /[.;]/,
contains: [
commentMode,
specialSequenceMode,
{
// terminals
className: 'string',
variants: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
begin: '`',
end: '`'
}
]
}
]
};
return {
name: 'Extended Backus-Naur Form',
illegal: /\S/,
contains: [
commentMode,
nonTerminalMode,
ruleBodyMode
]
};
}
var ebnf_1 = ebnf;
/*
Language: Elixir
Author: Josh Adams <josh@isotope11.com>
Description: language definition for Elixir source code files (.ex and .exs). Based on ruby language support.
Category: functional
Website: https://elixir-lang.org
*/
/** @type LanguageFn */
function elixir(hljs) {
const regex = hljs.regex;
const ELIXIR_IDENT_RE = '[a-zA-Z_][a-zA-Z0-9_.]*(!|\\?)?';
const ELIXIR_METHOD_RE = '[a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?';
const KEYWORDS = [
"after",
"alias",
"and",
"case",
"catch",
"cond",
"defstruct",
"defguard",
"do",
"else",
"end",
"fn",
"for",
"if",
"import",
"in",
"not",
"or",
"quote",
"raise",
"receive",
"require",
"reraise",
"rescue",
"try",
"unless",
"unquote",
"unquote_splicing",
"use",
"when",
"with|0"
];
const LITERALS = [
"false",
"nil",
"true"
];
const KWS = {
$pattern: ELIXIR_IDENT_RE,
keyword: KEYWORDS,
literal: LITERALS
};
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: KWS
};
const NUMBER = {
className: 'number',
begin: '(\\b0o[0-7_]+)|(\\b0b[01_]+)|(\\b0x[0-9a-fA-F_]+)|(-?\\b[0-9][0-9_]*(\\.[0-9_]+([eE][-+]?[0-9]+)?)?)',
relevance: 0
};
// TODO: could be tightened
// https://elixir-lang.readthedocs.io/en/latest/intro/18.html
// but you also need to include closing delemeters in the escape list per
// individual sigil mode from what I can tell,
// ie: \} might or might not be an escape depending on the sigil used
const ESCAPES_RE = /\\[\s\S]/;
// const ESCAPES_RE = /\\["'\\abdefnrstv0]/;
const BACKSLASH_ESCAPE = {
match: ESCAPES_RE,
scope: "char.escape",
relevance: 0
};
const SIGIL_DELIMITERS = '[/|([{<"\']';
const SIGIL_DELIMITER_MODES = [
{
begin: /"/,
end: /"/
},
{
begin: /'/,
end: /'/
},
{
begin: /\//,
end: /\//
},
{
begin: /\|/,
end: /\|/
},
{
begin: /\(/,
end: /\)/
},
{
begin: /\[/,
end: /\]/
},
{
begin: /\{/,
end: /\}/
},
{
begin: /</,
end: />/
}
];
const escapeSigilEnd = (end) => {
return {
scope: "char.escape",
begin: regex.concat(/\\/, end),
relevance: 0
};
};
const LOWERCASE_SIGIL = {
className: 'string',
begin: '~[a-z]' + '(?=' + SIGIL_DELIMITERS + ')',
contains: SIGIL_DELIMITER_MODES.map(x => hljs.inherit(x,
{ contains: [
escapeSigilEnd(x.end),
BACKSLASH_ESCAPE,
SUBST
] }
))
};
const UPCASE_SIGIL = {
className: 'string',
begin: '~[A-Z]' + '(?=' + SIGIL_DELIMITERS + ')',
contains: SIGIL_DELIMITER_MODES.map(x => hljs.inherit(x,
{ contains: [ escapeSigilEnd(x.end) ] }
))
};
const REGEX_SIGIL = {
className: 'regex',
variants: [
{
begin: '~r' + '(?=' + SIGIL_DELIMITERS + ')',
contains: SIGIL_DELIMITER_MODES.map(x => hljs.inherit(x,
{
end: regex.concat(x.end, /[uismxfU]{0,7}/),
contains: [
escapeSigilEnd(x.end),
BACKSLASH_ESCAPE,
SUBST
]
}
))
},
{
begin: '~R' + '(?=' + SIGIL_DELIMITERS + ')',
contains: SIGIL_DELIMITER_MODES.map(x => hljs.inherit(x,
{
end: regex.concat(x.end, /[uismxfU]{0,7}/),
contains: [ escapeSigilEnd(x.end) ]
})
)
}
]
};
const STRING = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
variants: [
{
begin: /"""/,
end: /"""/
},
{
begin: /'''/,
end: /'''/
},
{
begin: /~S"""/,
end: /"""/,
contains: [] // override default
},
{
begin: /~S"/,
end: /"/,
contains: [] // override default
},
{
begin: /~S'''/,
end: /'''/,
contains: [] // override default
},
{
begin: /~S'/,
end: /'/,
contains: [] // override default
},
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
}
]
};
const FUNCTION = {
className: 'function',
beginKeywords: 'def defp defmacro defmacrop',
end: /\B\b/, // the mode is ended by the title
contains: [
hljs.inherit(hljs.TITLE_MODE, {
begin: ELIXIR_IDENT_RE,
endsParent: true
})
]
};
const CLASS = hljs.inherit(FUNCTION, {
className: 'class',
beginKeywords: 'defimpl defmodule defprotocol defrecord',
end: /\bdo\b|$|;/
});
const ELIXIR_DEFAULT_CONTAINS = [
STRING,
REGEX_SIGIL,
UPCASE_SIGIL,
LOWERCASE_SIGIL,
hljs.HASH_COMMENT_MODE,
CLASS,
FUNCTION,
{ begin: '::' },
{
className: 'symbol',
begin: ':(?![\\s:])',
contains: [
STRING,
{ begin: ELIXIR_METHOD_RE }
],
relevance: 0
},
{
className: 'symbol',
begin: ELIXIR_IDENT_RE + ':(?!:)',
relevance: 0
},
{ // Usage of a module, struct, etc.
className: 'title.class',
begin: /(\b[A-Z][a-zA-Z0-9_]+)/,
relevance: 0
},
NUMBER,
{
className: 'variable',
begin: '(\\$\\W)|((\\$|@@?)(\\w+))'
}
// -> has been removed, capnproto always uses this grammar construct
];
SUBST.contains = ELIXIR_DEFAULT_CONTAINS;
return {
name: 'Elixir',
aliases: [
'ex',
'exs'
],
keywords: KWS,
contains: ELIXIR_DEFAULT_CONTAINS
};
}
var elixir_1 = elixir;
/*
Language: Elm
Author: Janis Voigtlaender <janis.voigtlaender@gmail.com>
Website: https://elm-lang.org
Category: functional
*/
/** @type LanguageFn */
function elm(hljs) {
const COMMENT = { variants: [
hljs.COMMENT('--', '$'),
hljs.COMMENT(
/\{-/,
/-\}/,
{ contains: [ 'self' ] }
)
] };
const CONSTRUCTOR = {
className: 'type',
begin: '\\b[A-Z][\\w\']*', // TODO: other constructors (built-in, infix).
relevance: 0
};
const LIST = {
begin: '\\(',
end: '\\)',
illegal: '"',
contains: [
{
className: 'type',
begin: '\\b[A-Z][\\w]*(\\((\\.\\.|,|\\w+)\\))?'
},
COMMENT
]
};
const RECORD = {
begin: /\{/,
end: /\}/,
contains: LIST.contains
};
const CHARACTER = {
className: 'string',
begin: '\'\\\\?.',
end: '\'',
illegal: '.'
};
const KEYWORDS = [
"let",
"in",
"if",
"then",
"else",
"case",
"of",
"where",
"module",
"import",
"exposing",
"type",
"alias",
"as",
"infix",
"infixl",
"infixr",
"port",
"effect",
"command",
"subscription"
];
return {
name: 'Elm',
keywords: KEYWORDS,
contains: [
// Top-level constructions.
{
beginKeywords: 'port effect module',
end: 'exposing',
keywords: 'port effect module where command subscription exposing',
contains: [
LIST,
COMMENT
],
illegal: '\\W\\.|;'
},
{
begin: 'import',
end: '$',
keywords: 'import as exposing',
contains: [
LIST,
COMMENT
],
illegal: '\\W\\.|;'
},
{
begin: 'type',
end: '$',
keywords: 'type alias',
contains: [
CONSTRUCTOR,
LIST,
RECORD,
COMMENT
]
},
{
beginKeywords: 'infix infixl infixr',
end: '$',
contains: [
hljs.C_NUMBER_MODE,
COMMENT
]
},
{
begin: 'port',
end: '$',
keywords: 'port',
contains: [ COMMENT ]
},
// Literals and names.
CHARACTER,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
CONSTRUCTOR,
hljs.inherit(hljs.TITLE_MODE, { begin: '^[_a-z][\\w\']*' }),
COMMENT,
{ // No markup, relevance booster
begin: '->|<-' }
],
illegal: /;/
};
}
var elm_1 = elm;
/*
Language: Ruby
Description: Ruby is a dynamic, open source programming language with a focus on simplicity and productivity.
Website: https://www.ruby-lang.org/
Author: Anton Kovalyov <anton@kovalyov.net>
Contributors: Peter Leonov <gojpeg@yandex.ru>, Vasily Polovnyov <vast@whiteants.net>, Loren Segal <lsegal@soen.ca>, Pascal Hurni <phi@ruby-reactive.org>, Cedric Sohrauer <sohrauer@googlemail.com>
Category: common
*/
function ruby(hljs) {
const regex = hljs.regex;
const RUBY_METHOD_RE = '([a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?)';
// TODO: move concepts like CAMEL_CASE into `modes.js`
const CLASS_NAME_RE = regex.either(
/\b([A-Z]+[a-z0-9]+)+/,
// ends in caps
/\b([A-Z]+[a-z0-9]+)+[A-Z]+/,
)
;
const CLASS_NAME_WITH_NAMESPACE_RE = regex.concat(CLASS_NAME_RE, /(::\w+)*/);
// very popular ruby built-ins that one might even assume
// are actual keywords (despite that not being the case)
const PSEUDO_KWS = [
"include",
"extend",
"prepend",
"public",
"private",
"protected",
"raise",
"throw"
];
const RUBY_KEYWORDS = {
"variable.constant": [
"__FILE__",
"__LINE__",
"__ENCODING__"
],
"variable.language": [
"self",
"super",
],
keyword: [
"alias",
"and",
"begin",
"BEGIN",
"break",
"case",
"class",
"defined",
"do",
"else",
"elsif",
"end",
"END",
"ensure",
"for",
"if",
"in",
"module",
"next",
"not",
"or",
"redo",
"require",
"rescue",
"retry",
"return",
"then",
"undef",
"unless",
"until",
"when",
"while",
"yield",
...PSEUDO_KWS
],
built_in: [
"proc",
"lambda",
"attr_accessor",
"attr_reader",
"attr_writer",
"define_method",
"private_constant",
"module_function"
],
literal: [
"true",
"false",
"nil"
]
};
const YARDOCTAG = {
className: 'doctag',
begin: '@[A-Za-z]+'
};
const IRB_OBJECT = {
begin: '#<',
end: '>'
};
const COMMENT_MODES = [
hljs.COMMENT(
'#',
'$',
{ contains: [ YARDOCTAG ] }
),
hljs.COMMENT(
'^=begin',
'^=end',
{
contains: [ YARDOCTAG ],
relevance: 10
}
),
hljs.COMMENT('^__END__', hljs.MATCH_NOTHING_RE)
];
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: RUBY_KEYWORDS
};
const STRING = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
},
{
begin: /`/,
end: /`/
},
{
begin: /%[qQwWx]?\(/,
end: /\)/
},
{
begin: /%[qQwWx]?\[/,
end: /\]/
},
{
begin: /%[qQwWx]?\{/,
end: /\}/
},
{
begin: /%[qQwWx]?</,
end: />/
},
{
begin: /%[qQwWx]?\//,
end: /\//
},
{
begin: /%[qQwWx]?%/,
end: /%/
},
{
begin: /%[qQwWx]?-/,
end: /-/
},
{
begin: /%[qQwWx]?\|/,
end: /\|/
},
// in the following expressions, \B in the beginning suppresses recognition of ?-sequences
// where ? is the last character of a preceding identifier, as in: `func?4`
{ begin: /\B\?(\\\d{1,3})/ },
{ begin: /\B\?(\\x[A-Fa-f0-9]{1,2})/ },
{ begin: /\B\?(\\u\{?[A-Fa-f0-9]{1,6}\}?)/ },
{ begin: /\B\?(\\M-\\C-|\\M-\\c|\\c\\M-|\\M-|\\C-\\M-)[\x20-\x7e]/ },
{ begin: /\B\?\\(c|C-)[\x20-\x7e]/ },
{ begin: /\B\?\\?\S/ },
// heredocs
{
// this guard makes sure that we have an entire heredoc and not a false
// positive (auto-detect, etc.)
begin: regex.concat(
/<<[-~]?'?/,
regex.lookahead(/(\w+)(?=\W)[^\n]*\n(?:[^\n]*\n)*?\s*\1\b/)
),
contains: [
hljs.END_SAME_AS_BEGIN({
begin: /(\w+)/,
end: /(\w+)/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
})
]
}
]
};
// Ruby syntax is underdocumented, but this grammar seems to be accurate
// as of version 2.7.2 (confirmed with (irb and `Ripper.sexp(...)`)
// https://docs.ruby-lang.org/en/2.7.0/doc/syntax/literals_rdoc.html#label-Numbers
const decimal = '[1-9](_?[0-9])*|0';
const digits = '[0-9](_?[0-9])*';
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
// decimal integer/float, optionally exponential or rational, optionally imaginary
{ begin: `\\b(${decimal})(\\.(${digits}))?([eE][+-]?(${digits})|r)?i?\\b` },
// explicit decimal/binary/octal/hexadecimal integer,
// optionally rational and/or imaginary
{ begin: "\\b0[dD][0-9](_?[0-9])*r?i?\\b" },
{ begin: "\\b0[bB][0-1](_?[0-1])*r?i?\\b" },
{ begin: "\\b0[oO][0-7](_?[0-7])*r?i?\\b" },
{ begin: "\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*r?i?\\b" },
// 0-prefixed implicit octal integer, optionally rational and/or imaginary
{ begin: "\\b0(_?[0-7])+r?i?\\b" }
]
};
const PARAMS = {
variants: [
{
match: /\(\)/,
},
{
className: 'params',
begin: /\(/,
end: /(?=\))/,
excludeBegin: true,
endsParent: true,
keywords: RUBY_KEYWORDS,
}
]
};
const INCLUDE_EXTEND = {
match: [
/(include|extend)\s+/,
CLASS_NAME_WITH_NAMESPACE_RE
],
scope: {
2: "title.class"
},
keywords: RUBY_KEYWORDS
};
const CLASS_DEFINITION = {
variants: [
{
match: [
/class\s+/,
CLASS_NAME_WITH_NAMESPACE_RE,
/\s+<\s+/,
CLASS_NAME_WITH_NAMESPACE_RE
]
},
{
match: [
/\b(class|module)\s+/,
CLASS_NAME_WITH_NAMESPACE_RE
]
}
],
scope: {
2: "title.class",
4: "title.class.inherited"
},
keywords: RUBY_KEYWORDS
};
const UPPER_CASE_CONSTANT = {
relevance: 0,
match: /\b[A-Z][A-Z_0-9]+\b/,
className: "variable.constant"
};
const METHOD_DEFINITION = {
match: [
/def/, /\s+/,
RUBY_METHOD_RE
],
scope: {
1: "keyword",
3: "title.function"
},
contains: [
PARAMS
]
};
const OBJECT_CREATION = {
relevance: 0,
match: [
CLASS_NAME_WITH_NAMESPACE_RE,
/\.new[. (]/
],
scope: {
1: "title.class"
}
};
// CamelCase
const CLASS_REFERENCE = {
relevance: 0,
match: CLASS_NAME_RE,
scope: "title.class"
};
const RUBY_DEFAULT_CONTAINS = [
STRING,
CLASS_DEFINITION,
INCLUDE_EXTEND,
OBJECT_CREATION,
UPPER_CASE_CONSTANT,
CLASS_REFERENCE,
METHOD_DEFINITION,
{
// swallow namespace qualifiers before symbols
begin: hljs.IDENT_RE + '::' },
{
className: 'symbol',
begin: hljs.UNDERSCORE_IDENT_RE + '(!|\\?)?:',
relevance: 0
},
{
className: 'symbol',
begin: ':(?!\\s)',
contains: [
STRING,
{ begin: RUBY_METHOD_RE }
],
relevance: 0
},
NUMBER,
{
// negative-look forward attempts to prevent false matches like:
// @ident@ or $ident$ that might indicate this is not ruby at all
className: "variable",
begin: '(\\$\\W)|((\\$|@@?)(\\w+))(?=[^@$?])' + `(?![A-Za-z])(?![@$?'])`
},
{
className: 'params',
begin: /\|/,
end: /\|/,
excludeBegin: true,
excludeEnd: true,
relevance: 0, // this could be a lot of things (in other languages) other than params
keywords: RUBY_KEYWORDS
},
{ // regexp container
begin: '(' + hljs.RE_STARTERS_RE + '|unless)\\s*',
keywords: 'unless',
contains: [
{
className: 'regexp',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
illegal: /\n/,
variants: [
{
begin: '/',
end: '/[a-z]*'
},
{
begin: /%r\{/,
end: /\}[a-z]*/
},
{
begin: '%r\\(',
end: '\\)[a-z]*'
},
{
begin: '%r!',
end: '![a-z]*'
},
{
begin: '%r\\[',
end: '\\][a-z]*'
}
]
}
].concat(IRB_OBJECT, COMMENT_MODES),
relevance: 0
}
].concat(IRB_OBJECT, COMMENT_MODES);
SUBST.contains = RUBY_DEFAULT_CONTAINS;
PARAMS.contains = RUBY_DEFAULT_CONTAINS;
// >>
// ?>
const SIMPLE_PROMPT = "[>?]>";
// irb(main):001:0>
const DEFAULT_PROMPT = "[\\w#]+\\(\\w+\\):\\d+:\\d+[>*]";
const RVM_PROMPT = "(\\w+-)?\\d+\\.\\d+\\.\\d+(p\\d+)?[^\\d][^>]+>";
const IRB_DEFAULT = [
{
begin: /^\s*=>/,
starts: {
end: '$',
contains: RUBY_DEFAULT_CONTAINS
}
},
{
className: 'meta.prompt',
begin: '^(' + SIMPLE_PROMPT + "|" + DEFAULT_PROMPT + '|' + RVM_PROMPT + ')(?=[ ])',
starts: {
end: '$',
keywords: RUBY_KEYWORDS,
contains: RUBY_DEFAULT_CONTAINS
}
}
];
COMMENT_MODES.unshift(IRB_OBJECT);
return {
name: 'Ruby',
aliases: [
'rb',
'gemspec',
'podspec',
'thor',
'irb'
],
keywords: RUBY_KEYWORDS,
illegal: /\/\*/,
contains: [ hljs.SHEBANG({ binary: "ruby" }) ]
.concat(IRB_DEFAULT)
.concat(COMMENT_MODES)
.concat(RUBY_DEFAULT_CONTAINS)
};
}
var ruby_1 = ruby;
/*
Language: ERB (Embedded Ruby)
Requires: xml.js, ruby.js
Author: Lucas Mazza <lucastmazza@gmail.com>
Contributors: Kassio Borges <kassioborgesm@gmail.com>
Description: "Bridge" language defining fragments of Ruby in HTML within <% .. %>
Website: https://ruby-doc.org/stdlib-2.6.5/libdoc/erb/rdoc/ERB.html
Category: template
*/
/** @type LanguageFn */
function erb(hljs) {
return {
name: 'ERB',
subLanguage: 'xml',
contains: [
hljs.COMMENT('<%#', '%>'),
{
begin: '<%[%=-]?',
end: '[%-]?%>',
subLanguage: 'ruby',
excludeBegin: true,
excludeEnd: true
}
]
};
}
var erb_1 = erb;
/*
Language: Erlang REPL
Author: Sergey Ignatov <sergey@ignatov.spb.su>
Website: https://www.erlang.org
Category: functional
*/
/** @type LanguageFn */
function erlangRepl(hljs) {
const regex = hljs.regex;
return {
name: 'Erlang REPL',
keywords: {
built_in:
'spawn spawn_link self',
keyword:
'after and andalso|10 band begin bnot bor bsl bsr bxor case catch cond div end fun if '
+ 'let not of or orelse|10 query receive rem try when xor'
},
contains: [
{
className: 'meta.prompt',
begin: '^[0-9]+> ',
relevance: 10
},
hljs.COMMENT('%', '$'),
{
className: 'number',
begin: '\\b(\\d+(_\\d+)*#[a-fA-F0-9]+(_[a-fA-F0-9]+)*|\\d+(_\\d+)*(\\.\\d+(_\\d+)*)?([eE][-+]?\\d+)?)',
relevance: 0
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{ begin: regex.concat(
/\?(::)?/,
/([A-Z]\w*)/, // at least one identifier
/((::)[A-Z]\w*)*/ // perhaps more
) },
{ begin: '->' },
{ begin: 'ok' },
{ begin: '!' },
{
begin: '(\\b[a-z\'][a-zA-Z0-9_\']*:[a-z\'][a-zA-Z0-9_\']*)|(\\b[a-z\'][a-zA-Z0-9_\']*)',
relevance: 0
},
{
begin: '[A-Z][a-zA-Z0-9_\']*',
relevance: 0
}
]
};
}
var erlangRepl_1 = erlangRepl;
/*
Language: Erlang
Description: Erlang is a general-purpose functional language, with strict evaluation, single assignment, and dynamic typing.
Author: Nikolay Zakharov <nikolay.desh@gmail.com>, Dmitry Kovega <arhibot@gmail.com>
Website: https://www.erlang.org
Category: functional
*/
/** @type LanguageFn */
function erlang(hljs) {
const BASIC_ATOM_RE = '[a-z\'][a-zA-Z0-9_\']*';
const FUNCTION_NAME_RE = '(' + BASIC_ATOM_RE + ':' + BASIC_ATOM_RE + '|' + BASIC_ATOM_RE + ')';
const ERLANG_RESERVED = {
keyword:
'after and andalso|10 band begin bnot bor bsl bzr bxor case catch cond div end fun if '
+ 'let not of orelse|10 query receive rem try when xor',
literal:
'false true'
};
const COMMENT = hljs.COMMENT('%', '$');
const NUMBER = {
className: 'number',
begin: '\\b(\\d+(_\\d+)*#[a-fA-F0-9]+(_[a-fA-F0-9]+)*|\\d+(_\\d+)*(\\.\\d+(_\\d+)*)?([eE][-+]?\\d+)?)',
relevance: 0
};
const NAMED_FUN = { begin: 'fun\\s+' + BASIC_ATOM_RE + '/\\d+' };
const FUNCTION_CALL = {
begin: FUNCTION_NAME_RE + '\\(',
end: '\\)',
returnBegin: true,
relevance: 0,
contains: [
{
begin: FUNCTION_NAME_RE,
relevance: 0
},
{
begin: '\\(',
end: '\\)',
endsWithParent: true,
returnEnd: true,
relevance: 0
// "contains" defined later
}
]
};
const TUPLE = {
begin: /\{/,
end: /\}/,
relevance: 0
// "contains" defined later
};
const VAR1 = {
begin: '\\b_([A-Z][A-Za-z0-9_]*)?',
relevance: 0
};
const VAR2 = {
begin: '[A-Z][a-zA-Z0-9_]*',
relevance: 0
};
const RECORD_ACCESS = {
begin: '#' + hljs.UNDERSCORE_IDENT_RE,
relevance: 0,
returnBegin: true,
contains: [
{
begin: '#' + hljs.UNDERSCORE_IDENT_RE,
relevance: 0
},
{
begin: /\{/,
end: /\}/,
relevance: 0
// "contains" defined later
}
]
};
const BLOCK_STATEMENTS = {
beginKeywords: 'fun receive if try case',
end: 'end',
keywords: ERLANG_RESERVED
};
BLOCK_STATEMENTS.contains = [
COMMENT,
NAMED_FUN,
hljs.inherit(hljs.APOS_STRING_MODE, { className: '' }),
BLOCK_STATEMENTS,
FUNCTION_CALL,
hljs.QUOTE_STRING_MODE,
NUMBER,
TUPLE,
VAR1,
VAR2,
RECORD_ACCESS
];
const BASIC_MODES = [
COMMENT,
NAMED_FUN,
BLOCK_STATEMENTS,
FUNCTION_CALL,
hljs.QUOTE_STRING_MODE,
NUMBER,
TUPLE,
VAR1,
VAR2,
RECORD_ACCESS
];
FUNCTION_CALL.contains[1].contains = BASIC_MODES;
TUPLE.contains = BASIC_MODES;
RECORD_ACCESS.contains[1].contains = BASIC_MODES;
const DIRECTIVES = [
"-module",
"-record",
"-undef",
"-export",
"-ifdef",
"-ifndef",
"-author",
"-copyright",
"-doc",
"-vsn",
"-import",
"-include",
"-include_lib",
"-compile",
"-define",
"-else",
"-endif",
"-file",
"-behaviour",
"-behavior",
"-spec"
];
const PARAMS = {
className: 'params',
begin: '\\(',
end: '\\)',
contains: BASIC_MODES
};
return {
name: 'Erlang',
aliases: [ 'erl' ],
keywords: ERLANG_RESERVED,
illegal: '(</|\\*=|\\+=|-=|/\\*|\\*/|\\(\\*|\\*\\))',
contains: [
{
className: 'function',
begin: '^' + BASIC_ATOM_RE + '\\s*\\(',
end: '->',
returnBegin: true,
illegal: '\\(|#|//|/\\*|\\\\|:|;',
contains: [
PARAMS,
hljs.inherit(hljs.TITLE_MODE, { begin: BASIC_ATOM_RE })
],
starts: {
end: ';|\\.',
keywords: ERLANG_RESERVED,
contains: BASIC_MODES
}
},
COMMENT,
{
begin: '^-',
end: '\\.',
relevance: 0,
excludeEnd: true,
returnBegin: true,
keywords: {
$pattern: '-' + hljs.IDENT_RE,
keyword: DIRECTIVES.map(x => `${x}|1.5`).join(" ")
},
contains: [ PARAMS ]
},
NUMBER,
hljs.QUOTE_STRING_MODE,
RECORD_ACCESS,
VAR1,
VAR2,
TUPLE,
{ begin: /\.$/ } // relevance booster
]
};
}
var erlang_1 = erlang;
/*
Language: Excel formulae
Author: Victor Zhou <OiCMudkips@users.noreply.github.com>
Description: Excel formulae
Website: https://products.office.com/en-us/excel/
*/
/** @type LanguageFn */
function excel(hljs) {
// built-in functions imported from https://web.archive.org/web/20160513042710/https://support.office.com/en-us/article/Excel-functions-alphabetical-b3944572-255d-4efb-bb96-c6d90033e188
const BUILT_INS = [
"ABS",
"ACCRINT",
"ACCRINTM",
"ACOS",
"ACOSH",
"ACOT",
"ACOTH",
"AGGREGATE",
"ADDRESS",
"AMORDEGRC",
"AMORLINC",
"AND",
"ARABIC",
"AREAS",
"ASC",
"ASIN",
"ASINH",
"ATAN",
"ATAN2",
"ATANH",
"AVEDEV",
"AVERAGE",
"AVERAGEA",
"AVERAGEIF",
"AVERAGEIFS",
"BAHTTEXT",
"BASE",
"BESSELI",
"BESSELJ",
"BESSELK",
"BESSELY",
"BETADIST",
"BETA.DIST",
"BETAINV",
"BETA.INV",
"BIN2DEC",
"BIN2HEX",
"BIN2OCT",
"BINOMDIST",
"BINOM.DIST",
"BINOM.DIST.RANGE",
"BINOM.INV",
"BITAND",
"BITLSHIFT",
"BITOR",
"BITRSHIFT",
"BITXOR",
"CALL",
"CEILING",
"CEILING.MATH",
"CEILING.PRECISE",
"CELL",
"CHAR",
"CHIDIST",
"CHIINV",
"CHITEST",
"CHISQ.DIST",
"CHISQ.DIST.RT",
"CHISQ.INV",
"CHISQ.INV.RT",
"CHISQ.TEST",
"CHOOSE",
"CLEAN",
"CODE",
"COLUMN",
"COLUMNS",
"COMBIN",
"COMBINA",
"COMPLEX",
"CONCAT",
"CONCATENATE",
"CONFIDENCE",
"CONFIDENCE.NORM",
"CONFIDENCE.T",
"CONVERT",
"CORREL",
"COS",
"COSH",
"COT",
"COTH",
"COUNT",
"COUNTA",
"COUNTBLANK",
"COUNTIF",
"COUNTIFS",
"COUPDAYBS",
"COUPDAYS",
"COUPDAYSNC",
"COUPNCD",
"COUPNUM",
"COUPPCD",
"COVAR",
"COVARIANCE.P",
"COVARIANCE.S",
"CRITBINOM",
"CSC",
"CSCH",
"CUBEKPIMEMBER",
"CUBEMEMBER",
"CUBEMEMBERPROPERTY",
"CUBERANKEDMEMBER",
"CUBESET",
"CUBESETCOUNT",
"CUBEVALUE",
"CUMIPMT",
"CUMPRINC",
"DATE",
"DATEDIF",
"DATEVALUE",
"DAVERAGE",
"DAY",
"DAYS",
"DAYS360",
"DB",
"DBCS",
"DCOUNT",
"DCOUNTA",
"DDB",
"DEC2BIN",
"DEC2HEX",
"DEC2OCT",
"DECIMAL",
"DEGREES",
"DELTA",
"DEVSQ",
"DGET",
"DISC",
"DMAX",
"DMIN",
"DOLLAR",
"DOLLARDE",
"DOLLARFR",
"DPRODUCT",
"DSTDEV",
"DSTDEVP",
"DSUM",
"DURATION",
"DVAR",
"DVARP",
"EDATE",
"EFFECT",
"ENCODEURL",
"EOMONTH",
"ERF",
"ERF.PRECISE",
"ERFC",
"ERFC.PRECISE",
"ERROR.TYPE",
"EUROCONVERT",
"EVEN",
"EXACT",
"EXP",
"EXPON.DIST",
"EXPONDIST",
"FACT",
"FACTDOUBLE",
"FALSE|0",
"F.DIST",
"FDIST",
"F.DIST.RT",
"FILTERXML",
"FIND",
"FINDB",
"F.INV",
"F.INV.RT",
"FINV",
"FISHER",
"FISHERINV",
"FIXED",
"FLOOR",
"FLOOR.MATH",
"FLOOR.PRECISE",
"FORECAST",
"FORECAST.ETS",
"FORECAST.ETS.CONFINT",
"FORECAST.ETS.SEASONALITY",
"FORECAST.ETS.STAT",
"FORECAST.LINEAR",
"FORMULATEXT",
"FREQUENCY",
"F.TEST",
"FTEST",
"FV",
"FVSCHEDULE",
"GAMMA",
"GAMMA.DIST",
"GAMMADIST",
"GAMMA.INV",
"GAMMAINV",
"GAMMALN",
"GAMMALN.PRECISE",
"GAUSS",
"GCD",
"GEOMEAN",
"GESTEP",
"GETPIVOTDATA",
"GROWTH",
"HARMEAN",
"HEX2BIN",
"HEX2DEC",
"HEX2OCT",
"HLOOKUP",
"HOUR",
"HYPERLINK",
"HYPGEOM.DIST",
"HYPGEOMDIST",
"IF",
"IFERROR",
"IFNA",
"IFS",
"IMABS",
"IMAGINARY",
"IMARGUMENT",
"IMCONJUGATE",
"IMCOS",
"IMCOSH",
"IMCOT",
"IMCSC",
"IMCSCH",
"IMDIV",
"IMEXP",
"IMLN",
"IMLOG10",
"IMLOG2",
"IMPOWER",
"IMPRODUCT",
"IMREAL",
"IMSEC",
"IMSECH",
"IMSIN",
"IMSINH",
"IMSQRT",
"IMSUB",
"IMSUM",
"IMTAN",
"INDEX",
"INDIRECT",
"INFO",
"INT",
"INTERCEPT",
"INTRATE",
"IPMT",
"IRR",
"ISBLANK",
"ISERR",
"ISERROR",
"ISEVEN",
"ISFORMULA",
"ISLOGICAL",
"ISNA",
"ISNONTEXT",
"ISNUMBER",
"ISODD",
"ISREF",
"ISTEXT",
"ISO.CEILING",
"ISOWEEKNUM",
"ISPMT",
"JIS",
"KURT",
"LARGE",
"LCM",
"LEFT",
"LEFTB",
"LEN",
"LENB",
"LINEST",
"LN",
"LOG",
"LOG10",
"LOGEST",
"LOGINV",
"LOGNORM.DIST",
"LOGNORMDIST",
"LOGNORM.INV",
"LOOKUP",
"LOWER",
"MATCH",
"MAX",
"MAXA",
"MAXIFS",
"MDETERM",
"MDURATION",
"MEDIAN",
"MID",
"MIDBs",
"MIN",
"MINIFS",
"MINA",
"MINUTE",
"MINVERSE",
"MIRR",
"MMULT",
"MOD",
"MODE",
"MODE.MULT",
"MODE.SNGL",
"MONTH",
"MROUND",
"MULTINOMIAL",
"MUNIT",
"N",
"NA",
"NEGBINOM.DIST",
"NEGBINOMDIST",
"NETWORKDAYS",
"NETWORKDAYS.INTL",
"NOMINAL",
"NORM.DIST",
"NORMDIST",
"NORMINV",
"NORM.INV",
"NORM.S.DIST",
"NORMSDIST",
"NORM.S.INV",
"NORMSINV",
"NOT",
"NOW",
"NPER",
"NPV",
"NUMBERVALUE",
"OCT2BIN",
"OCT2DEC",
"OCT2HEX",
"ODD",
"ODDFPRICE",
"ODDFYIELD",
"ODDLPRICE",
"ODDLYIELD",
"OFFSET",
"OR",
"PDURATION",
"PEARSON",
"PERCENTILE.EXC",
"PERCENTILE.INC",
"PERCENTILE",
"PERCENTRANK.EXC",
"PERCENTRANK.INC",
"PERCENTRANK",
"PERMUT",
"PERMUTATIONA",
"PHI",
"PHONETIC",
"PI",
"PMT",
"POISSON.DIST",
"POISSON",
"POWER",
"PPMT",
"PRICE",
"PRICEDISC",
"PRICEMAT",
"PROB",
"PRODUCT",
"PROPER",
"PV",
"QUARTILE",
"QUARTILE.EXC",
"QUARTILE.INC",
"QUOTIENT",
"RADIANS",
"RAND",
"RANDBETWEEN",
"RANK.AVG",
"RANK.EQ",
"RANK",
"RATE",
"RECEIVED",
"REGISTER.ID",
"REPLACE",
"REPLACEB",
"REPT",
"RIGHT",
"RIGHTB",
"ROMAN",
"ROUND",
"ROUNDDOWN",
"ROUNDUP",
"ROW",
"ROWS",
"RRI",
"RSQ",
"RTD",
"SEARCH",
"SEARCHB",
"SEC",
"SECH",
"SECOND",
"SERIESSUM",
"SHEET",
"SHEETS",
"SIGN",
"SIN",
"SINH",
"SKEW",
"SKEW.P",
"SLN",
"SLOPE",
"SMALL",
"SQL.REQUEST",
"SQRT",
"SQRTPI",
"STANDARDIZE",
"STDEV",
"STDEV.P",
"STDEV.S",
"STDEVA",
"STDEVP",
"STDEVPA",
"STEYX",
"SUBSTITUTE",
"SUBTOTAL",
"SUM",
"SUMIF",
"SUMIFS",
"SUMPRODUCT",
"SUMSQ",
"SUMX2MY2",
"SUMX2PY2",
"SUMXMY2",
"SWITCH",
"SYD",
"T",
"TAN",
"TANH",
"TBILLEQ",
"TBILLPRICE",
"TBILLYIELD",
"T.DIST",
"T.DIST.2T",
"T.DIST.RT",
"TDIST",
"TEXT",
"TEXTJOIN",
"TIME",
"TIMEVALUE",
"T.INV",
"T.INV.2T",
"TINV",
"TODAY",
"TRANSPOSE",
"TREND",
"TRIM",
"TRIMMEAN",
"TRUE|0",
"TRUNC",
"T.TEST",
"TTEST",
"TYPE",
"UNICHAR",
"UNICODE",
"UPPER",
"VALUE",
"VAR",
"VAR.P",
"VAR.S",
"VARA",
"VARP",
"VARPA",
"VDB",
"VLOOKUP",
"WEBSERVICE",
"WEEKDAY",
"WEEKNUM",
"WEIBULL",
"WEIBULL.DIST",
"WORKDAY",
"WORKDAY.INTL",
"XIRR",
"XNPV",
"XOR",
"YEAR",
"YEARFRAC",
"YIELD",
"YIELDDISC",
"YIELDMAT",
"Z.TEST",
"ZTEST"
];
return {
name: 'Excel formulae',
aliases: [
'xlsx',
'xls'
],
case_insensitive: true,
keywords: {
$pattern: /[a-zA-Z][\w\.]*/,
built_in: BUILT_INS
},
contains: [
{
/* matches a beginning equal sign found in Excel formula examples */
begin: /^=/,
end: /[^=]/,
returnEnd: true,
illegal: /=/, /* only allow single equal sign at front of line */
relevance: 10
},
/* technically, there can be more than 2 letters in column names, but this prevents conflict with some keywords */
{
/* matches a reference to a single cell */
className: 'symbol',
begin: /\b[A-Z]{1,2}\d+\b/,
end: /[^\d]/,
excludeEnd: true,
relevance: 0
},
{
/* matches a reference to a range of cells */
className: 'symbol',
begin: /[A-Z]{0,2}\d*:[A-Z]{0,2}\d*/,
relevance: 0
},
hljs.BACKSLASH_ESCAPE,
hljs.QUOTE_STRING_MODE,
{
className: 'number',
begin: hljs.NUMBER_RE + '(%)?',
relevance: 0
},
/* Excel formula comments are done by putting the comment in a function call to N() */
hljs.COMMENT(/\bN\(/, /\)/,
{
excludeBegin: true,
excludeEnd: true,
illegal: /\n/
})
]
};
}
var excel_1 = excel;
/*
Language: FIX
Author: Brent Bradbury <brent@brentium.com>
*/
/** @type LanguageFn */
function fix(hljs) {
return {
name: 'FIX',
contains: [
{
begin: /[^\u2401\u0001]+/,
end: /[\u2401\u0001]/,
excludeEnd: true,
returnBegin: true,
returnEnd: false,
contains: [
{
begin: /([^\u2401\u0001=]+)/,
end: /=([^\u2401\u0001=]+)/,
returnEnd: true,
returnBegin: false,
className: 'attr'
},
{
begin: /=/,
end: /([\u2401\u0001])/,
excludeEnd: true,
excludeBegin: true,
className: 'string'
}
]
}
],
case_insensitive: true
};
}
var fix_1 = fix;
/*
Language: Flix
Category: functional
Author: Magnus Madsen <mmadsen@uwaterloo.ca>
Website: https://flix.dev/
*/
/** @type LanguageFn */
function flix(hljs) {
const CHAR = {
className: 'string',
begin: /'(.|\\[xXuU][a-zA-Z0-9]+)'/
};
const STRING = {
className: 'string',
variants: [
{
begin: '"',
end: '"'
}
]
};
const NAME = {
className: 'title',
relevance: 0,
begin: /[^0-9\n\t "'(),.`{}\[\]:;][^\n\t "'(),.`{}\[\]:;]+|[^0-9\n\t "'(),.`{}\[\]:;=]/
};
const METHOD = {
className: 'function',
beginKeywords: 'def',
end: /[:={\[(\n;]/,
excludeEnd: true,
contains: [ NAME ]
};
return {
name: 'Flix',
keywords: {
keyword: [
"case",
"class",
"def",
"else",
"enum",
"if",
"impl",
"import",
"in",
"lat",
"rel",
"index",
"let",
"match",
"namespace",
"switch",
"type",
"yield",
"with"
],
literal: [
"true",
"false"
]
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
CHAR,
STRING,
METHOD,
hljs.C_NUMBER_MODE
]
};
}
var flix_1 = flix;
/*
Language: Fortran
Author: Anthony Scemama <scemama@irsamc.ups-tlse.fr>
Website: https://en.wikipedia.org/wiki/Fortran
Category: scientific
*/
/** @type LanguageFn */
function fortran(hljs) {
const regex = hljs.regex;
const PARAMS = {
className: 'params',
begin: '\\(',
end: '\\)'
};
const COMMENT = { variants: [
hljs.COMMENT('!', '$', { relevance: 0 }),
// allow FORTRAN 77 style comments
hljs.COMMENT('^C[ ]', '$', { relevance: 0 }),
hljs.COMMENT('^C$', '$', { relevance: 0 })
] };
// regex in both fortran and irpf90 should match
const OPTIONAL_NUMBER_SUFFIX = /(_[a-z_\d]+)?/;
const OPTIONAL_NUMBER_EXP = /([de][+-]?\d+)?/;
const NUMBER = {
className: 'number',
variants: [
{ begin: regex.concat(/\b\d+/, /\.(\d*)/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) },
{ begin: regex.concat(/\b\d+/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) },
{ begin: regex.concat(/\.\d+/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) }
],
relevance: 0
};
const FUNCTION_DEF = {
className: 'function',
beginKeywords: 'subroutine function program',
illegal: '[${=\\n]',
contains: [
hljs.UNDERSCORE_TITLE_MODE,
PARAMS
]
};
const STRING = {
className: 'string',
relevance: 0,
variants: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
};
const KEYWORDS = [
"kind",
"do",
"concurrent",
"local",
"shared",
"while",
"private",
"call",
"intrinsic",
"where",
"elsewhere",
"type",
"endtype",
"endmodule",
"endselect",
"endinterface",
"end",
"enddo",
"endif",
"if",
"forall",
"endforall",
"only",
"contains",
"default",
"return",
"stop",
"then",
"block",
"endblock",
"endassociate",
"public",
"subroutine|10",
"function",
"program",
".and.",
".or.",
".not.",
".le.",
".eq.",
".ge.",
".gt.",
".lt.",
"goto",
"save",
"else",
"use",
"module",
"select",
"case",
"access",
"blank",
"direct",
"exist",
"file",
"fmt",
"form",
"formatted",
"iostat",
"name",
"named",
"nextrec",
"number",
"opened",
"rec",
"recl",
"sequential",
"status",
"unformatted",
"unit",
"continue",
"format",
"pause",
"cycle",
"exit",
"c_null_char",
"c_alert",
"c_backspace",
"c_form_feed",
"flush",
"wait",
"decimal",
"round",
"iomsg",
"synchronous",
"nopass",
"non_overridable",
"pass",
"protected",
"volatile",
"abstract",
"extends",
"import",
"non_intrinsic",
"value",
"deferred",
"generic",
"final",
"enumerator",
"class",
"associate",
"bind",
"enum",
"c_int",
"c_short",
"c_long",
"c_long_long",
"c_signed_char",
"c_size_t",
"c_int8_t",
"c_int16_t",
"c_int32_t",
"c_int64_t",
"c_int_least8_t",
"c_int_least16_t",
"c_int_least32_t",
"c_int_least64_t",
"c_int_fast8_t",
"c_int_fast16_t",
"c_int_fast32_t",
"c_int_fast64_t",
"c_intmax_t",
"C_intptr_t",
"c_float",
"c_double",
"c_long_double",
"c_float_complex",
"c_double_complex",
"c_long_double_complex",
"c_bool",
"c_char",
"c_null_ptr",
"c_null_funptr",
"c_new_line",
"c_carriage_return",
"c_horizontal_tab",
"c_vertical_tab",
"iso_c_binding",
"c_loc",
"c_funloc",
"c_associated",
"c_f_pointer",
"c_ptr",
"c_funptr",
"iso_fortran_env",
"character_storage_size",
"error_unit",
"file_storage_size",
"input_unit",
"iostat_end",
"iostat_eor",
"numeric_storage_size",
"output_unit",
"c_f_procpointer",
"ieee_arithmetic",
"ieee_support_underflow_control",
"ieee_get_underflow_mode",
"ieee_set_underflow_mode",
"newunit",
"contiguous",
"recursive",
"pad",
"position",
"action",
"delim",
"readwrite",
"eor",
"advance",
"nml",
"interface",
"procedure",
"namelist",
"include",
"sequence",
"elemental",
"pure",
"impure",
"integer",
"real",
"character",
"complex",
"logical",
"codimension",
"dimension",
"allocatable|10",
"parameter",
"external",
"implicit|10",
"none",
"double",
"precision",
"assign",
"intent",
"optional",
"pointer",
"target",
"in",
"out",
"common",
"equivalence",
"data"
];
const LITERALS = [
".False.",
".True."
];
const BUILT_INS = [
"alog",
"alog10",
"amax0",
"amax1",
"amin0",
"amin1",
"amod",
"cabs",
"ccos",
"cexp",
"clog",
"csin",
"csqrt",
"dabs",
"dacos",
"dasin",
"datan",
"datan2",
"dcos",
"dcosh",
"ddim",
"dexp",
"dint",
"dlog",
"dlog10",
"dmax1",
"dmin1",
"dmod",
"dnint",
"dsign",
"dsin",
"dsinh",
"dsqrt",
"dtan",
"dtanh",
"float",
"iabs",
"idim",
"idint",
"idnint",
"ifix",
"isign",
"max0",
"max1",
"min0",
"min1",
"sngl",
"algama",
"cdabs",
"cdcos",
"cdexp",
"cdlog",
"cdsin",
"cdsqrt",
"cqabs",
"cqcos",
"cqexp",
"cqlog",
"cqsin",
"cqsqrt",
"dcmplx",
"dconjg",
"derf",
"derfc",
"dfloat",
"dgamma",
"dimag",
"dlgama",
"iqint",
"qabs",
"qacos",
"qasin",
"qatan",
"qatan2",
"qcmplx",
"qconjg",
"qcos",
"qcosh",
"qdim",
"qerf",
"qerfc",
"qexp",
"qgamma",
"qimag",
"qlgama",
"qlog",
"qlog10",
"qmax1",
"qmin1",
"qmod",
"qnint",
"qsign",
"qsin",
"qsinh",
"qsqrt",
"qtan",
"qtanh",
"abs",
"acos",
"aimag",
"aint",
"anint",
"asin",
"atan",
"atan2",
"char",
"cmplx",
"conjg",
"cos",
"cosh",
"exp",
"ichar",
"index",
"int",
"log",
"log10",
"max",
"min",
"nint",
"sign",
"sin",
"sinh",
"sqrt",
"tan",
"tanh",
"print",
"write",
"dim",
"lge",
"lgt",
"lle",
"llt",
"mod",
"nullify",
"allocate",
"deallocate",
"adjustl",
"adjustr",
"all",
"allocated",
"any",
"associated",
"bit_size",
"btest",
"ceiling",
"count",
"cshift",
"date_and_time",
"digits",
"dot_product",
"eoshift",
"epsilon",
"exponent",
"floor",
"fraction",
"huge",
"iand",
"ibclr",
"ibits",
"ibset",
"ieor",
"ior",
"ishft",
"ishftc",
"lbound",
"len_trim",
"matmul",
"maxexponent",
"maxloc",
"maxval",
"merge",
"minexponent",
"minloc",
"minval",
"modulo",
"mvbits",
"nearest",
"pack",
"present",
"product",
"radix",
"random_number",
"random_seed",
"range",
"repeat",
"reshape",
"rrspacing",
"scale",
"scan",
"selected_int_kind",
"selected_real_kind",
"set_exponent",
"shape",
"size",
"spacing",
"spread",
"sum",
"system_clock",
"tiny",
"transpose",
"trim",
"ubound",
"unpack",
"verify",
"achar",
"iachar",
"transfer",
"dble",
"entry",
"dprod",
"cpu_time",
"command_argument_count",
"get_command",
"get_command_argument",
"get_environment_variable",
"is_iostat_end",
"ieee_arithmetic",
"ieee_support_underflow_control",
"ieee_get_underflow_mode",
"ieee_set_underflow_mode",
"is_iostat_eor",
"move_alloc",
"new_line",
"selected_char_kind",
"same_type_as",
"extends_type_of",
"acosh",
"asinh",
"atanh",
"bessel_j0",
"bessel_j1",
"bessel_jn",
"bessel_y0",
"bessel_y1",
"bessel_yn",
"erf",
"erfc",
"erfc_scaled",
"gamma",
"log_gamma",
"hypot",
"norm2",
"atomic_define",
"atomic_ref",
"execute_command_line",
"leadz",
"trailz",
"storage_size",
"merge_bits",
"bge",
"bgt",
"ble",
"blt",
"dshiftl",
"dshiftr",
"findloc",
"iall",
"iany",
"iparity",
"image_index",
"lcobound",
"ucobound",
"maskl",
"maskr",
"num_images",
"parity",
"popcnt",
"poppar",
"shifta",
"shiftl",
"shiftr",
"this_image",
"sync",
"change",
"team",
"co_broadcast",
"co_max",
"co_min",
"co_sum",
"co_reduce"
];
return {
name: 'Fortran',
case_insensitive: true,
aliases: [
'f90',
'f95'
],
keywords: {
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILT_INS
},
illegal: /\/\*/,
contains: [
STRING,
FUNCTION_DEF,
// allow `C = value` for assignments so they aren't misdetected
// as Fortran 77 style comments
{
begin: /^C\s*=(?!=)/,
relevance: 0
},
COMMENT,
NUMBER
]
};
}
var fortran_1 = fortran;
/**
* @param {string} value
* @returns {RegExp}
* */
function escape$1(value) {
return new RegExp(value.replace(/[-/\\^$*+?.()|[\]{}]/g, '\\$&'), 'm');
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function source$1(re) {
if (!re) return null;
if (typeof re === "string") return re;
return re.source;
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function lookahead$1(re) {
return concat$1('(?=', re, ')');
}
/**
* @param {...(RegExp | string) } args
* @returns {string}
*/
function concat$1(...args) {
const joined = args.map((x) => source$1(x)).join("");
return joined;
}
/**
* @param { Array<string | RegExp | Object> } args
* @returns {object}
*/
function stripOptionsFromArgs$1(args) {
const opts = args[args.length - 1];
if (typeof opts === 'object' && opts.constructor === Object) {
args.splice(args.length - 1, 1);
return opts;
} else {
return {};
}
}
/** @typedef { {capture?: boolean} } RegexEitherOptions */
/**
* Any of the passed expresssions may match
*
* Creates a huge this | this | that | that match
* @param {(RegExp | string)[] | [...(RegExp | string)[], RegexEitherOptions]} args
* @returns {string}
*/
function either$1(...args) {
/** @type { object & {capture?: boolean} } */
const opts = stripOptionsFromArgs$1(args);
const joined = '('
+ (opts.capture ? "" : "?:")
+ args.map((x) => source$1(x)).join("|") + ")";
return joined;
}
/*
Language: F#
Author: Jonas Follesø <jonas@follesoe.no>
Contributors: Troy Kershaw <hello@troykershaw.com>, Henrik Feldt <henrik@haf.se>, Melvyn Laïly <melvyn.laily@gmail.com>
Website: https://docs.microsoft.com/en-us/dotnet/fsharp/
Category: functional
*/
/** @type LanguageFn */
function fsharp(hljs) {
const KEYWORDS = [
"abstract",
"and",
"as",
"assert",
"base",
"begin",
"class",
"default",
"delegate",
"do",
"done",
"downcast",
"downto",
"elif",
"else",
"end",
"exception",
"extern",
// "false", // literal
"finally",
"fixed",
"for",
"fun",
"function",
"global",
"if",
"in",
"inherit",
"inline",
"interface",
"internal",
"lazy",
"let",
"match",
"member",
"module",
"mutable",
"namespace",
"new",
// "not", // built_in
// "null", // literal
"of",
"open",
"or",
"override",
"private",
"public",
"rec",
"return",
"static",
"struct",
"then",
"to",
// "true", // literal
"try",
"type",
"upcast",
"use",
"val",
"void",
"when",
"while",
"with",
"yield"
];
const BANG_KEYWORD_MODE = {
// monad builder keywords (matches before non-bang keywords)
scope: 'keyword',
match: /\b(yield|return|let|do|match|use)!/
};
const PREPROCESSOR_KEYWORDS = [
"if",
"else",
"endif",
"line",
"nowarn",
"light",
"r",
"i",
"I",
"load",
"time",
"help",
"quit"
];
const LITERALS = [
"true",
"false",
"null",
"Some",
"None",
"Ok",
"Error",
"infinity",
"infinityf",
"nan",
"nanf"
];
const SPECIAL_IDENTIFIERS = [
"__LINE__",
"__SOURCE_DIRECTORY__",
"__SOURCE_FILE__"
];
// Since it's possible to re-bind/shadow names (e.g. let char = 'c'),
// these builtin types should only be matched when a type name is expected.
const KNOWN_TYPES = [
// basic types
"bool",
"byte",
"sbyte",
"int8",
"int16",
"int32",
"uint8",
"uint16",
"uint32",
"int",
"uint",
"int64",
"uint64",
"nativeint",
"unativeint",
"decimal",
"float",
"double",
"float32",
"single",
"char",
"string",
"unit",
"bigint",
// other native types or lowercase aliases
"option",
"voption",
"list",
"array",
"seq",
"byref",
"exn",
"inref",
"nativeptr",
"obj",
"outref",
"voidptr",
// other important FSharp types
"Result"
];
const BUILTINS = [
// Somewhat arbitrary list of builtin functions and values.
// Most of them are declared in Microsoft.FSharp.Core
// I tried to stay relevant by adding only the most idiomatic
// and most used symbols that are not already declared as types.
"not",
"ref",
"raise",
"reraise",
"dict",
"readOnlyDict",
"set",
"get",
"enum",
"sizeof",
"typeof",
"typedefof",
"nameof",
"nullArg",
"invalidArg",
"invalidOp",
"id",
"fst",
"snd",
"ignore",
"lock",
"using",
"box",
"unbox",
"tryUnbox",
"printf",
"printfn",
"sprintf",
"eprintf",
"eprintfn",
"fprintf",
"fprintfn",
"failwith",
"failwithf"
];
const ALL_KEYWORDS = {
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILTINS,
'variable.constant': SPECIAL_IDENTIFIERS
};
// (* potentially multi-line Meta Language style comment *)
const ML_COMMENT =
hljs.COMMENT(/\(\*(?!\))/, /\*\)/, {
contains: ["self"]
});
// Either a multi-line (* Meta Language style comment *) or a single line // C style comment.
const COMMENT = {
variants: [
ML_COMMENT,
hljs.C_LINE_COMMENT_MODE,
]
};
// Most identifiers can contain apostrophes
const IDENTIFIER_RE = /[a-zA-Z_](\w|')*/;
const QUOTED_IDENTIFIER = {
scope: 'variable',
begin: /``/,
end: /``/
};
// 'a or ^a where a can be a ``quoted identifier``
const BEGIN_GENERIC_TYPE_SYMBOL_RE = /\B('|\^)/;
const GENERIC_TYPE_SYMBOL = {
scope: 'symbol',
variants: [
// the type name is a quoted identifier:
{ match: concat$1(BEGIN_GENERIC_TYPE_SYMBOL_RE, /``.*?``/) },
// the type name is a normal identifier (we don't use IDENTIFIER_RE because there cannot be another apostrophe here):
{ match: concat$1(BEGIN_GENERIC_TYPE_SYMBOL_RE, hljs.UNDERSCORE_IDENT_RE) }
],
relevance: 0
};
const makeOperatorMode = function({ includeEqual }) {
// List or symbolic operator characters from the FSharp Spec 4.1, minus the dot, and with `?` added, used for nullable operators.
let allOperatorChars;
if (includeEqual)
allOperatorChars = "!%&*+-/<=>@^|~?";
else
allOperatorChars = "!%&*+-/<>@^|~?";
const OPERATOR_CHARS = Array.from(allOperatorChars);
const OPERATOR_CHAR_RE = concat$1('[', ...OPERATOR_CHARS.map(escape$1), ']');
// The lone dot operator is special. It cannot be redefined, and we don't want to highlight it. It can be used as part of a multi-chars operator though.
const OPERATOR_CHAR_OR_DOT_RE = either$1(OPERATOR_CHAR_RE, /\./);
// When a dot is present, it must be followed by another operator char:
const OPERATOR_FIRST_CHAR_OF_MULTIPLE_RE = concat$1(OPERATOR_CHAR_OR_DOT_RE, lookahead$1(OPERATOR_CHAR_OR_DOT_RE));
const SYMBOLIC_OPERATOR_RE = either$1(
concat$1(OPERATOR_FIRST_CHAR_OF_MULTIPLE_RE, OPERATOR_CHAR_OR_DOT_RE, '*'), // Matches at least 2 chars operators
concat$1(OPERATOR_CHAR_RE, '+'), // Matches at least one char operators
);
return {
scope: 'operator',
match: either$1(
// symbolic operators:
SYMBOLIC_OPERATOR_RE,
// other symbolic keywords:
// Type casting and conversion operators:
/:\?>/,
/:\?/,
/:>/,
/:=/, // Reference cell assignment
/::?/, // : or ::
/\$/), // A single $ can be used as an operator
relevance: 0
};
};
const OPERATOR = makeOperatorMode({ includeEqual: true });
// This variant is used when matching '=' should end a parent mode:
const OPERATOR_WITHOUT_EQUAL = makeOperatorMode({ includeEqual: false });
const makeTypeAnnotationMode = function(prefix, prefixScope) {
return {
begin: concat$1( // a type annotation is a
prefix, // should be a colon or the 'of' keyword
lookahead$1( // that has to be followed by
concat$1(
/\s*/, // optional space
either$1( // then either of:
/\w/, // word
/'/, // generic type name
/\^/, // generic type name
/#/, // flexible type name
/``/, // quoted type name
/\(/, // parens type expression
/{\|/, // anonymous type annotation
)))),
beginScope: prefixScope,
// BUG: because ending with \n is necessary for some cases, multi-line type annotations are not properly supported.
// Examples where \n is required at the end:
// - abstract member definitions in classes: abstract Property : int * string
// - return type annotations: let f f' = f' () : returnTypeAnnotation
// - record fields definitions: { A : int \n B : string }
end: lookahead$1(
either$1(
/\n/,
/=/)),
relevance: 0,
// we need the known types, and we need the type constraint keywords and literals. e.g.: when 'a : null
keywords: hljs.inherit(ALL_KEYWORDS, { type: KNOWN_TYPES }),
contains: [
COMMENT,
GENERIC_TYPE_SYMBOL,
hljs.inherit(QUOTED_IDENTIFIER, { scope: null }), // match to avoid strange patterns inside that may break the parsing
OPERATOR_WITHOUT_EQUAL
]
};
};
const TYPE_ANNOTATION = makeTypeAnnotationMode(/:/, 'operator');
const DISCRIMINATED_UNION_TYPE_ANNOTATION = makeTypeAnnotationMode(/\bof\b/, 'keyword');
// type MyType<'a> = ...
const TYPE_DECLARATION = {
begin: [
/(^|\s+)/, // prevents matching the following: `match s.stype with`
/type/,
/\s+/,
IDENTIFIER_RE
],
beginScope: {
2: 'keyword',
4: 'title.class'
},
end: lookahead$1(/\(|=|$/),
keywords: ALL_KEYWORDS, // match keywords in type constraints. e.g.: when 'a : null
contains: [
COMMENT,
hljs.inherit(QUOTED_IDENTIFIER, { scope: null }), // match to avoid strange patterns inside that may break the parsing
GENERIC_TYPE_SYMBOL,
{
// For visual consistency, highlight type brackets as operators.
scope: 'operator',
match: /<|>/
},
TYPE_ANNOTATION // generic types can have constraints, which are type annotations. e.g. type MyType<'T when 'T : delegate<obj * string>> =
]
};
const COMPUTATION_EXPRESSION = {
// computation expressions:
scope: 'computation-expression',
// BUG: might conflict with record deconstruction. e.g. let f { Name = name } = name // will highlight f
match: /\b[_a-z]\w*(?=\s*\{)/
};
const PREPROCESSOR = {
// preprocessor directives and fsi commands:
begin: [
/^\s*/,
concat$1(/#/, either$1(...PREPROCESSOR_KEYWORDS)),
/\b/
],
beginScope: { 2: 'meta' },
end: lookahead$1(/\s|$/)
};
// TODO: this definition is missing support for type suffixes and octal notation.
// BUG: range operator without any space is wrongly interpreted as a single number (e.g. 1..10 )
const NUMBER = {
variants: [
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE
]
};
// All the following string definitions are potentially multi-line.
// BUG: these definitions are missing support for byte strings (suffixed with B)
// "..."
const QUOTED_STRING = {
scope: 'string',
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE
]
};
// @"..."
const VERBATIM_STRING = {
scope: 'string',
begin: /@"/,
end: /"/,
contains: [
{
match: /""/ // escaped "
},
hljs.BACKSLASH_ESCAPE
]
};
// """..."""
const TRIPLE_QUOTED_STRING = {
scope: 'string',
begin: /"""/,
end: /"""/,
relevance: 2
};
const SUBST = {
scope: 'subst',
begin: /\{/,
end: /\}/,
keywords: ALL_KEYWORDS
};
// $"...{1+1}..."
const INTERPOLATED_STRING = {
scope: 'string',
begin: /\$"/,
end: /"/,
contains: [
{
match: /\{\{/ // escaped {
},
{
match: /\}\}/ // escaped }
},
hljs.BACKSLASH_ESCAPE,
SUBST
]
};
// $@"...{1+1}..."
const INTERPOLATED_VERBATIM_STRING = {
scope: 'string',
begin: /(\$@|@\$)"/,
end: /"/,
contains: [
{
match: /\{\{/ // escaped {
},
{
match: /\}\}/ // escaped }
},
{
match: /""/
},
hljs.BACKSLASH_ESCAPE,
SUBST
]
};
// $"""...{1+1}..."""
const INTERPOLATED_TRIPLE_QUOTED_STRING = {
scope: 'string',
begin: /\$"""/,
end: /"""/,
contains: [
{
match: /\{\{/ // escaped {
},
{
match: /\}\}/ // escaped }
},
SUBST
],
relevance: 2
};
// '.'
const CHAR_LITERAL = {
scope: 'string',
match: concat$1(
/'/,
either$1(
/[^\\']/, // either a single non escaped char...
/\\(?:.|\d{3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}|U[a-fA-F\d]{8})/ // ...or an escape sequence
),
/'/
)
};
// F# allows a lot of things inside string placeholders.
// Things that don't currently seem allowed by the compiler: types definition, attributes usage.
// (Strictly speaking, some of the followings are only allowed inside triple quoted interpolated strings...)
SUBST.contains = [
INTERPOLATED_VERBATIM_STRING,
INTERPOLATED_STRING,
VERBATIM_STRING,
QUOTED_STRING,
CHAR_LITERAL,
BANG_KEYWORD_MODE,
COMMENT,
QUOTED_IDENTIFIER,
TYPE_ANNOTATION,
COMPUTATION_EXPRESSION,
PREPROCESSOR,
NUMBER,
GENERIC_TYPE_SYMBOL,
OPERATOR
];
const STRING = {
variants: [
INTERPOLATED_TRIPLE_QUOTED_STRING,
INTERPOLATED_VERBATIM_STRING,
INTERPOLATED_STRING,
TRIPLE_QUOTED_STRING,
VERBATIM_STRING,
QUOTED_STRING,
CHAR_LITERAL
]
};
return {
name: 'F#',
aliases: [
'fs',
'f#'
],
keywords: ALL_KEYWORDS,
illegal: /\/\*/,
classNameAliases: {
'computation-expression': 'keyword'
},
contains: [
BANG_KEYWORD_MODE,
STRING,
COMMENT,
QUOTED_IDENTIFIER,
TYPE_DECLARATION,
{
// e.g. [<Attributes("")>] or [<``module``: MyCustomAttributeThatWorksOnModules>]
// or [<Sealed; NoEquality; NoComparison; CompiledName("FSharpAsync`1")>]
scope: 'meta',
begin: /\[</,
end: />\]/,
relevance: 2,
contains: [
QUOTED_IDENTIFIER,
// can contain any constant value
TRIPLE_QUOTED_STRING,
VERBATIM_STRING,
QUOTED_STRING,
CHAR_LITERAL,
NUMBER
]
},
DISCRIMINATED_UNION_TYPE_ANNOTATION,
TYPE_ANNOTATION,
COMPUTATION_EXPRESSION,
PREPROCESSOR,
NUMBER,
GENERIC_TYPE_SYMBOL,
OPERATOR
]
};
}
var fsharp_1 = fsharp;
/*
Language: GAMS
Author: Stefan Bechert <stefan.bechert@gmx.net>
Contributors: Oleg Efimov <efimovov@gmail.com>, Mikko Kouhia <mikko.kouhia@iki.fi>
Description: The General Algebraic Modeling System language
Website: https://www.gams.com
Category: scientific
*/
/** @type LanguageFn */
function gams(hljs) {
const regex = hljs.regex;
const KEYWORDS = {
keyword:
'abort acronym acronyms alias all and assign binary card diag display '
+ 'else eq file files for free ge gt if integer le loop lt maximizing '
+ 'minimizing model models ne negative no not option options or ord '
+ 'positive prod put putpage puttl repeat sameas semicont semiint smax '
+ 'smin solve sos1 sos2 sum system table then until using while xor yes',
literal:
'eps inf na',
built_in:
'abs arccos arcsin arctan arctan2 Beta betaReg binomial ceil centropy '
+ 'cos cosh cvPower div div0 eDist entropy errorf execSeed exp fact '
+ 'floor frac gamma gammaReg log logBeta logGamma log10 log2 mapVal max '
+ 'min mod ncpCM ncpF ncpVUpow ncpVUsin normal pi poly power '
+ 'randBinomial randLinear randTriangle round rPower sigmoid sign '
+ 'signPower sin sinh slexp sllog10 slrec sqexp sqlog10 sqr sqrec sqrt '
+ 'tan tanh trunc uniform uniformInt vcPower bool_and bool_eqv bool_imp '
+ 'bool_not bool_or bool_xor ifThen rel_eq rel_ge rel_gt rel_le rel_lt '
+ 'rel_ne gday gdow ghour gleap gmillisec gminute gmonth gsecond gyear '
+ 'jdate jnow jstart jtime errorLevel execError gamsRelease gamsVersion '
+ 'handleCollect handleDelete handleStatus handleSubmit heapFree '
+ 'heapLimit heapSize jobHandle jobKill jobStatus jobTerminate '
+ 'licenseLevel licenseStatus maxExecError sleep timeClose timeComp '
+ 'timeElapsed timeExec timeStart'
};
const PARAMS = {
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true
};
const SYMBOLS = {
className: 'symbol',
variants: [
{ begin: /=[lgenxc]=/ },
{ begin: /\$/ }
]
};
const QSTR = { // One-line quoted comment string
className: 'comment',
variants: [
{
begin: '\'',
end: '\''
},
{
begin: '"',
end: '"'
}
],
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const ASSIGNMENT = {
begin: '/',
end: '/',
keywords: KEYWORDS,
contains: [
QSTR,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_NUMBER_MODE
]
};
const COMMENT_WORD = /[a-z0-9&#*=?@\\><:,()$[\]_.{}!+%^-]+/;
const DESCTEXT = { // Parameter/set/variable description text
begin: /[a-z][a-z0-9_]*(\([a-z0-9_, ]*\))?[ \t]+/,
excludeBegin: true,
end: '$',
endsWithParent: true,
contains: [
QSTR,
ASSIGNMENT,
{
className: 'comment',
// one comment word, then possibly more
begin: regex.concat(
COMMENT_WORD,
// [ ] because \s would be too broad (matching newlines)
regex.anyNumberOfTimes(regex.concat(/[ ]+/, COMMENT_WORD))
),
relevance: 0
}
]
};
return {
name: 'GAMS',
aliases: [ 'gms' ],
case_insensitive: true,
keywords: KEYWORDS,
contains: [
hljs.COMMENT(/^\$ontext/, /^\$offtext/),
{
className: 'meta',
begin: '^\\$[a-z0-9]+',
end: '$',
returnBegin: true,
contains: [
{
className: 'keyword',
begin: '^\\$[a-z0-9]+'
}
]
},
hljs.COMMENT('^\\*', '$'),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
// Declarations
{
beginKeywords:
'set sets parameter parameters variable variables '
+ 'scalar scalars equation equations',
end: ';',
contains: [
hljs.COMMENT('^\\*', '$'),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
ASSIGNMENT,
DESCTEXT
]
},
{ // table environment
beginKeywords: 'table',
end: ';',
returnBegin: true,
contains: [
{ // table header row
beginKeywords: 'table',
end: '$',
contains: [ DESCTEXT ]
},
hljs.COMMENT('^\\*', '$'),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_NUMBER_MODE
// Table does not contain DESCTEXT or ASSIGNMENT
]
},
// Function definitions
{
className: 'function',
begin: /^[a-z][a-z0-9_,\-+' ()$]+\.{2}/,
returnBegin: true,
contains: [
{ // Function title
className: 'title',
begin: /^[a-z0-9_]+/
},
PARAMS,
SYMBOLS
]
},
hljs.C_NUMBER_MODE,
SYMBOLS
]
};
}
var gams_1 = gams;
/*
Language: GAUSS
Author: Matt Evans <matt@aptech.com>
Description: GAUSS Mathematical and Statistical language
Website: https://www.aptech.com
Category: scientific
*/
function gauss(hljs) {
const KEYWORDS = {
keyword: 'bool break call callexe checkinterrupt clear clearg closeall cls comlog compile '
+ 'continue create debug declare delete disable dlibrary dllcall do dos ed edit else '
+ 'elseif enable end endfor endif endp endo errorlog errorlogat expr external fn '
+ 'for format goto gosub graph if keyword let lib library line load loadarray loadexe '
+ 'loadf loadk loadm loadp loads loadx local locate loopnextindex lprint lpwidth lshow '
+ 'matrix msym ndpclex new open output outwidth plot plotsym pop prcsn print '
+ 'printdos proc push retp return rndcon rndmod rndmult rndseed run save saveall screen '
+ 'scroll setarray show sparse stop string struct system trace trap threadfor '
+ 'threadendfor threadbegin threadjoin threadstat threadend until use while winprint '
+ 'ne ge le gt lt and xor or not eq eqv',
built_in: 'abs acf aconcat aeye amax amean AmericanBinomCall AmericanBinomCall_Greeks AmericanBinomCall_ImpVol '
+ 'AmericanBinomPut AmericanBinomPut_Greeks AmericanBinomPut_ImpVol AmericanBSCall AmericanBSCall_Greeks '
+ 'AmericanBSCall_ImpVol AmericanBSPut AmericanBSPut_Greeks AmericanBSPut_ImpVol amin amult annotationGetDefaults '
+ 'annotationSetBkd annotationSetFont annotationSetLineColor annotationSetLineStyle annotationSetLineThickness '
+ 'annualTradingDays arccos arcsin areshape arrayalloc arrayindex arrayinit arraytomat asciiload asclabel astd '
+ 'astds asum atan atan2 atranspose axmargin balance band bandchol bandcholsol bandltsol bandrv bandsolpd bar '
+ 'base10 begwind besselj bessely beta box boxcox cdfBeta cdfBetaInv cdfBinomial cdfBinomialInv cdfBvn cdfBvn2 '
+ 'cdfBvn2e cdfCauchy cdfCauchyInv cdfChic cdfChii cdfChinc cdfChincInv cdfExp cdfExpInv cdfFc cdfFnc cdfFncInv '
+ 'cdfGam cdfGenPareto cdfHyperGeo cdfLaplace cdfLaplaceInv cdfLogistic cdfLogisticInv cdfmControlCreate cdfMvn '
+ 'cdfMvn2e cdfMvnce cdfMvne cdfMvt2e cdfMvtce cdfMvte cdfN cdfN2 cdfNc cdfNegBinomial cdfNegBinomialInv cdfNi '
+ 'cdfPoisson cdfPoissonInv cdfRayleigh cdfRayleighInv cdfTc cdfTci cdfTnc cdfTvn cdfWeibull cdfWeibullInv cdir '
+ 'ceil ChangeDir chdir chiBarSquare chol choldn cholsol cholup chrs close code cols colsf combinate combinated '
+ 'complex con cond conj cons ConScore contour conv convertsatostr convertstrtosa corrm corrms corrvc corrx corrxs '
+ 'cos cosh counts countwts crossprd crout croutp csrcol csrlin csvReadM csvReadSA cumprodc cumsumc curve cvtos '
+ 'datacreate datacreatecomplex datalist dataload dataloop dataopen datasave date datestr datestring datestrymd '
+ 'dayinyr dayofweek dbAddDatabase dbClose dbCommit dbCreateQuery dbExecQuery dbGetConnectOptions dbGetDatabaseName '
+ 'dbGetDriverName dbGetDrivers dbGetHostName dbGetLastErrorNum dbGetLastErrorText dbGetNumericalPrecPolicy '
+ 'dbGetPassword dbGetPort dbGetTableHeaders dbGetTables dbGetUserName dbHasFeature dbIsDriverAvailable dbIsOpen '
+ 'dbIsOpenError dbOpen dbQueryBindValue dbQueryClear dbQueryCols dbQueryExecPrepared dbQueryFetchAllM dbQueryFetchAllSA '
+ 'dbQueryFetchOneM dbQueryFetchOneSA dbQueryFinish dbQueryGetBoundValue dbQueryGetBoundValues dbQueryGetField '
+ 'dbQueryGetLastErrorNum dbQueryGetLastErrorText dbQueryGetLastInsertID dbQueryGetLastQuery dbQueryGetPosition '
+ 'dbQueryIsActive dbQueryIsForwardOnly dbQueryIsNull dbQueryIsSelect dbQueryIsValid dbQueryPrepare dbQueryRows '
+ 'dbQuerySeek dbQuerySeekFirst dbQuerySeekLast dbQuerySeekNext dbQuerySeekPrevious dbQuerySetForwardOnly '
+ 'dbRemoveDatabase dbRollback dbSetConnectOptions dbSetDatabaseName dbSetHostName dbSetNumericalPrecPolicy '
+ 'dbSetPort dbSetUserName dbTransaction DeleteFile delif delrows denseToSp denseToSpRE denToZero design det detl '
+ 'dfft dffti diag diagrv digamma doswin DOSWinCloseall DOSWinOpen dotfeq dotfeqmt dotfge dotfgemt dotfgt dotfgtmt '
+ 'dotfle dotflemt dotflt dotfltmt dotfne dotfnemt draw drop dsCreate dstat dstatmt dstatmtControlCreate dtdate dtday '
+ 'dttime dttodtv dttostr dttoutc dtvnormal dtvtodt dtvtoutc dummy dummybr dummydn eig eigh eighv eigv elapsedTradingDays '
+ 'endwind envget eof eqSolve eqSolvemt eqSolvemtControlCreate eqSolvemtOutCreate eqSolveset erf erfc erfccplx erfcplx error '
+ 'etdays ethsec etstr EuropeanBinomCall EuropeanBinomCall_Greeks EuropeanBinomCall_ImpVol EuropeanBinomPut '
+ 'EuropeanBinomPut_Greeks EuropeanBinomPut_ImpVol EuropeanBSCall EuropeanBSCall_Greeks EuropeanBSCall_ImpVol '
+ 'EuropeanBSPut EuropeanBSPut_Greeks EuropeanBSPut_ImpVol exctsmpl exec execbg exp extern eye fcheckerr fclearerr feq '
+ 'feqmt fflush fft ffti fftm fftmi fftn fge fgemt fgets fgetsa fgetsat fgetst fgt fgtmt fileinfo filesa fle flemt '
+ 'floor flt fltmt fmod fne fnemt fonts fopen formatcv formatnv fputs fputst fseek fstrerror ftell ftocv ftos ftostrC '
+ 'gamma gammacplx gammaii gausset gdaAppend gdaCreate gdaDStat gdaDStatMat gdaGetIndex gdaGetName gdaGetNames gdaGetOrders '
+ 'gdaGetType gdaGetTypes gdaGetVarInfo gdaIsCplx gdaLoad gdaPack gdaRead gdaReadByIndex gdaReadSome gdaReadSparse '
+ 'gdaReadStruct gdaReportVarInfo gdaSave gdaUpdate gdaUpdateAndPack gdaVars gdaWrite gdaWrite32 gdaWriteSome getarray '
+ 'getdims getf getGAUSShome getmatrix getmatrix4D getname getnamef getNextTradingDay getNextWeekDay getnr getorders '
+ 'getpath getPreviousTradingDay getPreviousWeekDay getRow getscalar3D getscalar4D getTrRow getwind glm gradcplx gradMT '
+ 'gradMTm gradMTT gradMTTm gradp graphprt graphset hasimag header headermt hess hessMT hessMTg hessMTgw hessMTm '
+ 'hessMTmw hessMTT hessMTTg hessMTTgw hessMTTm hessMTw hessp hist histf histp hsec imag indcv indexcat indices indices2 '
+ 'indicesf indicesfn indnv indsav integrate1d integrateControlCreate intgrat2 intgrat3 inthp1 inthp2 inthp3 inthp4 '
+ 'inthpControlCreate intquad1 intquad2 intquad3 intrleav intrleavsa intrsect intsimp inv invpd invswp iscplx iscplxf '
+ 'isden isinfnanmiss ismiss key keyav keyw lag lag1 lagn lapEighb lapEighi lapEighvb lapEighvi lapgEig lapgEigh lapgEighv '
+ 'lapgEigv lapgSchur lapgSvdcst lapgSvds lapgSvdst lapSvdcusv lapSvds lapSvdusv ldlp ldlsol linSolve listwise ln lncdfbvn '
+ 'lncdfbvn2 lncdfmvn lncdfn lncdfn2 lncdfnc lnfact lngammacplx lnpdfmvn lnpdfmvt lnpdfn lnpdft loadd loadstruct loadwind '
+ 'loess loessmt loessmtControlCreate log loglog logx logy lower lowmat lowmat1 ltrisol lu lusol machEpsilon make makevars '
+ 'makewind margin matalloc matinit mattoarray maxbytes maxc maxindc maxv maxvec mbesselei mbesselei0 mbesselei1 mbesseli '
+ 'mbesseli0 mbesseli1 meanc median mergeby mergevar minc minindc minv miss missex missrv moment momentd movingave '
+ 'movingaveExpwgt movingaveWgt nextindex nextn nextnevn nextwind ntos null null1 numCombinations ols olsmt olsmtControlCreate '
+ 'olsqr olsqr2 olsqrmt ones optn optnevn orth outtyp pacf packedToSp packr parse pause pdfCauchy pdfChi pdfExp pdfGenPareto '
+ 'pdfHyperGeo pdfLaplace pdfLogistic pdfn pdfPoisson pdfRayleigh pdfWeibull pi pinv pinvmt plotAddArrow plotAddBar plotAddBox '
+ 'plotAddHist plotAddHistF plotAddHistP plotAddPolar plotAddScatter plotAddShape plotAddTextbox plotAddTS plotAddXY plotArea '
+ 'plotBar plotBox plotClearLayout plotContour plotCustomLayout plotGetDefaults plotHist plotHistF plotHistP plotLayout '
+ 'plotLogLog plotLogX plotLogY plotOpenWindow plotPolar plotSave plotScatter plotSetAxesPen plotSetBar plotSetBarFill '
+ 'plotSetBarStacked plotSetBkdColor plotSetFill plotSetGrid plotSetLegend plotSetLineColor plotSetLineStyle plotSetLineSymbol '
+ 'plotSetLineThickness plotSetNewWindow plotSetTitle plotSetWhichYAxis plotSetXAxisShow plotSetXLabel plotSetXRange '
+ 'plotSetXTicInterval plotSetXTicLabel plotSetYAxisShow plotSetYLabel plotSetYRange plotSetZAxisShow plotSetZLabel '
+ 'plotSurface plotTS plotXY polar polychar polyeval polygamma polyint polymake polymat polymroot polymult polyroot '
+ 'pqgwin previousindex princomp printfm printfmt prodc psi putarray putf putvals pvCreate pvGetIndex pvGetParNames '
+ 'pvGetParVector pvLength pvList pvPack pvPacki pvPackm pvPackmi pvPacks pvPacksi pvPacksm pvPacksmi pvPutParVector '
+ 'pvTest pvUnpack QNewton QNewtonmt QNewtonmtControlCreate QNewtonmtOutCreate QNewtonSet QProg QProgmt QProgmtInCreate '
+ 'qqr qqre qqrep qr qre qrep qrsol qrtsol qtyr qtyre qtyrep quantile quantiled qyr qyre qyrep qz rank rankindx readr '
+ 'real reclassify reclassifyCuts recode recserar recsercp recserrc rerun rescale reshape rets rev rfft rffti rfftip rfftn '
+ 'rfftnp rfftp rndBernoulli rndBeta rndBinomial rndCauchy rndChiSquare rndCon rndCreateState rndExp rndGamma rndGeo rndGumbel '
+ 'rndHyperGeo rndi rndKMbeta rndKMgam rndKMi rndKMn rndKMnb rndKMp rndKMu rndKMvm rndLaplace rndLCbeta rndLCgam rndLCi rndLCn '
+ 'rndLCnb rndLCp rndLCu rndLCvm rndLogNorm rndMTu rndMVn rndMVt rndn rndnb rndNegBinomial rndp rndPoisson rndRayleigh '
+ 'rndStateSkip rndu rndvm rndWeibull rndWishart rotater round rows rowsf rref sampleData satostrC saved saveStruct savewind '
+ 'scale scale3d scalerr scalinfnanmiss scalmiss schtoc schur searchsourcepath seekr select selif seqa seqm setdif setdifsa '
+ 'setvars setvwrmode setwind shell shiftr sin singleindex sinh sleep solpd sortc sortcc sortd sorthc sorthcc sortind '
+ 'sortindc sortmc sortr sortrc spBiconjGradSol spChol spConjGradSol spCreate spDenseSubmat spDiagRvMat spEigv spEye spLDL '
+ 'spline spLU spNumNZE spOnes spreadSheetReadM spreadSheetReadSA spreadSheetWrite spScale spSubmat spToDense spTrTDense '
+ 'spTScalar spZeros sqpSolve sqpSolveMT sqpSolveMTControlCreate sqpSolveMTlagrangeCreate sqpSolveMToutCreate sqpSolveSet '
+ 'sqrt statements stdc stdsc stocv stof strcombine strindx strlen strput strrindx strsect strsplit strsplitPad strtodt '
+ 'strtof strtofcplx strtriml strtrimr strtrunc strtruncl strtruncpad strtruncr submat subscat substute subvec sumc sumr '
+ 'surface svd svd1 svd2 svdcusv svds svdusv sysstate tab tan tanh tempname '
+ 'time timedt timestr timeutc title tkf2eps tkf2ps tocart todaydt toeplitz token topolar trapchk '
+ 'trigamma trimr trunc type typecv typef union unionsa uniqindx uniqindxsa unique uniquesa upmat upmat1 upper utctodt '
+ 'utctodtv utrisol vals varCovMS varCovXS varget vargetl varmall varmares varput varputl vartypef vcm vcms vcx vcxs '
+ 'vec vech vecr vector vget view viewxyz vlist vnamecv volume vput vread vtypecv wait waitc walkindex where window '
+ 'writer xlabel xlsGetSheetCount xlsGetSheetSize xlsGetSheetTypes xlsMakeRange xlsReadM xlsReadSA xlsWrite xlsWriteM '
+ 'xlsWriteSA xpnd xtics xy xyz ylabel ytics zeros zeta zlabel ztics cdfEmpirical dot h5create h5open h5read h5readAttribute '
+ 'h5write h5writeAttribute ldl plotAddErrorBar plotAddSurface plotCDFEmpirical plotSetColormap plotSetContourLabels '
+ 'plotSetLegendFont plotSetTextInterpreter plotSetXTicCount plotSetYTicCount plotSetZLevels powerm strjoin sylvester '
+ 'strtrim',
literal: 'DB_AFTER_LAST_ROW DB_ALL_TABLES DB_BATCH_OPERATIONS DB_BEFORE_FIRST_ROW DB_BLOB DB_EVENT_NOTIFICATIONS '
+ 'DB_FINISH_QUERY DB_HIGH_PRECISION DB_LAST_INSERT_ID DB_LOW_PRECISION_DOUBLE DB_LOW_PRECISION_INT32 '
+ 'DB_LOW_PRECISION_INT64 DB_LOW_PRECISION_NUMBERS DB_MULTIPLE_RESULT_SETS DB_NAMED_PLACEHOLDERS '
+ 'DB_POSITIONAL_PLACEHOLDERS DB_PREPARED_QUERIES DB_QUERY_SIZE DB_SIMPLE_LOCKING DB_SYSTEM_TABLES DB_TABLES '
+ 'DB_TRANSACTIONS DB_UNICODE DB_VIEWS __STDIN __STDOUT __STDERR __FILE_DIR'
};
const AT_COMMENT_MODE = hljs.COMMENT('@', '@');
const PREPROCESSOR =
{
className: 'meta',
begin: '#',
end: '$',
keywords: { keyword: 'define definecs|10 undef ifdef ifndef iflight ifdllcall ifmac ifos2win ifunix else endif lineson linesoff srcfile srcline' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
{
beginKeywords: 'include',
end: '$',
keywords: { keyword: 'include' },
contains: [
{
className: 'string',
begin: '"',
end: '"',
illegal: '\\n'
}
]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AT_COMMENT_MODE
]
};
const STRUCT_TYPE =
{
begin: /\bstruct\s+/,
end: /\s/,
keywords: "struct",
contains: [
{
className: "type",
begin: hljs.UNDERSCORE_IDENT_RE,
relevance: 0
}
]
};
// only for definitions
const PARSE_PARAMS = [
{
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
endsWithParent: true,
relevance: 0,
contains: [
{ // dots
className: 'literal',
begin: /\.\.\./
},
hljs.C_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AT_COMMENT_MODE,
STRUCT_TYPE
]
}
];
const FUNCTION_DEF =
{
className: "title",
begin: hljs.UNDERSCORE_IDENT_RE,
relevance: 0
};
const DEFINITION = function(beginKeywords, end, inherits) {
const mode = hljs.inherit(
{
className: "function",
beginKeywords: beginKeywords,
end: end,
excludeEnd: true,
contains: [].concat(PARSE_PARAMS)
},
inherits || {}
);
mode.contains.push(FUNCTION_DEF);
mode.contains.push(hljs.C_NUMBER_MODE);
mode.contains.push(hljs.C_BLOCK_COMMENT_MODE);
mode.contains.push(AT_COMMENT_MODE);
return mode;
};
const BUILT_IN_REF =
{ // these are explicitly named internal function calls
className: 'built_in',
begin: '\\b(' + KEYWORDS.built_in.split(' ').join('|') + ')\\b'
};
const STRING_REF =
{
className: 'string',
begin: '"',
end: '"',
contains: [ hljs.BACKSLASH_ESCAPE ],
relevance: 0
};
const FUNCTION_REF =
{
// className: "fn_ref",
begin: hljs.UNDERSCORE_IDENT_RE + '\\s*\\(',
returnBegin: true,
keywords: KEYWORDS,
relevance: 0,
contains: [
{ beginKeywords: KEYWORDS.keyword },
BUILT_IN_REF,
{ // ambiguously named function calls get a relevance of 0
className: 'built_in',
begin: hljs.UNDERSCORE_IDENT_RE,
relevance: 0
}
]
};
const FUNCTION_REF_PARAMS =
{
// className: "fn_ref_params",
begin: /\(/,
end: /\)/,
relevance: 0,
keywords: {
built_in: KEYWORDS.built_in,
literal: KEYWORDS.literal
},
contains: [
hljs.C_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AT_COMMENT_MODE,
BUILT_IN_REF,
FUNCTION_REF,
STRING_REF,
'self'
]
};
FUNCTION_REF.contains.push(FUNCTION_REF_PARAMS);
return {
name: 'GAUSS',
aliases: [ 'gss' ],
case_insensitive: true, // language is case-insensitive
keywords: KEYWORDS,
illegal: /(\{[%#]|[%#]\}| <- )/,
contains: [
hljs.C_NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AT_COMMENT_MODE,
STRING_REF,
PREPROCESSOR,
{
className: 'keyword',
begin: /\bexternal (matrix|string|array|sparse matrix|struct|proc|keyword|fn)/
},
DEFINITION('proc keyword', ';'),
DEFINITION('fn', '='),
{
beginKeywords: 'for threadfor',
end: /;/,
// end: /\(/,
relevance: 0,
contains: [
hljs.C_BLOCK_COMMENT_MODE,
AT_COMMENT_MODE,
FUNCTION_REF_PARAMS
]
},
{ // custom method guard
// excludes method names from keyword processing
variants: [
{ begin: hljs.UNDERSCORE_IDENT_RE + '\\.' + hljs.UNDERSCORE_IDENT_RE },
{ begin: hljs.UNDERSCORE_IDENT_RE + '\\s*=' }
],
relevance: 0
},
FUNCTION_REF,
STRUCT_TYPE
]
};
}
var gauss_1 = gauss;
/*
Language: G-code (ISO 6983)
Contributors: Adam Joseph Cook <adam.joseph.cook@gmail.com>
Description: G-code syntax highlighter for Fanuc and other common CNC machine tool controls.
Website: https://www.sis.se/api/document/preview/911952/
*/
function gcode(hljs) {
const GCODE_IDENT_RE = '[A-Z_][A-Z0-9_.]*';
const GCODE_CLOSE_RE = '%';
const GCODE_KEYWORDS = {
$pattern: GCODE_IDENT_RE,
keyword: 'IF DO WHILE ENDWHILE CALL ENDIF SUB ENDSUB GOTO REPEAT ENDREPEAT '
+ 'EQ LT GT NE GE LE OR XOR'
};
const GCODE_START = {
className: 'meta',
begin: '([O])([0-9]+)'
};
const NUMBER = hljs.inherit(hljs.C_NUMBER_MODE, { begin: '([-+]?((\\.\\d+)|(\\d+)(\\.\\d*)?))|' + hljs.C_NUMBER_RE });
const GCODE_CODE = [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.COMMENT(/\(/, /\)/),
NUMBER,
hljs.inherit(hljs.APOS_STRING_MODE, { illegal: null }),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
className: 'name',
begin: '([G])([0-9]+\\.?[0-9]?)'
},
{
className: 'name',
begin: '([M])([0-9]+\\.?[0-9]?)'
},
{
className: 'attr',
begin: '(VC|VS|#)',
end: '(\\d+)'
},
{
className: 'attr',
begin: '(VZOFX|VZOFY|VZOFZ)'
},
{
className: 'built_in',
begin: '(ATAN|ABS|ACOS|ASIN|SIN|COS|EXP|FIX|FUP|ROUND|LN|TAN)(\\[)',
contains: [ NUMBER ],
end: '\\]'
},
{
className: 'symbol',
variants: [
{
begin: 'N',
end: '\\d+',
illegal: '\\W'
}
]
}
];
return {
name: 'G-code (ISO 6983)',
aliases: [ 'nc' ],
// Some implementations (CNC controls) of G-code are interoperable with uppercase and lowercase letters seamlessly.
// However, most prefer all uppercase and uppercase is customary.
case_insensitive: true,
keywords: GCODE_KEYWORDS,
contains: [
{
className: 'meta',
begin: GCODE_CLOSE_RE
},
GCODE_START
].concat(GCODE_CODE)
};
}
var gcode_1 = gcode;
/*
Language: Gherkin
Author: Sam Pikesley (@pikesley) <sam.pikesley@theodi.org>
Description: Gherkin is the format for cucumber specifications. It is a domain specific language which helps you to describe business behavior without the need to go into detail of implementation.
Website: https://cucumber.io/docs/gherkin/
*/
function gherkin(hljs) {
return {
name: 'Gherkin',
aliases: [ 'feature' ],
keywords: 'Feature Background Ability Business\ Need Scenario Scenarios Scenario\ Outline Scenario\ Template Examples Given And Then But When',
contains: [
{
className: 'symbol',
begin: '\\*',
relevance: 0
},
{
className: 'meta',
begin: '@[^@\\s]+'
},
{
begin: '\\|',
end: '\\|\\w*$',
contains: [
{
className: 'string',
begin: '[^|]+'
}
]
},
{
className: 'variable',
begin: '<',
end: '>'
},
hljs.HASH_COMMENT_MODE,
{
className: 'string',
begin: '"""',
end: '"""'
},
hljs.QUOTE_STRING_MODE
]
};
}
var gherkin_1 = gherkin;
/*
Language: GLSL
Description: OpenGL Shading Language
Author: Sergey Tikhomirov <sergey@tikhomirov.io>
Website: https://en.wikipedia.org/wiki/OpenGL_Shading_Language
Category: graphics
*/
function glsl(hljs) {
return {
name: 'GLSL',
keywords: {
keyword:
// Statements
'break continue discard do else for if return while switch case default '
// Qualifiers
+ 'attribute binding buffer ccw centroid centroid varying coherent column_major const cw '
+ 'depth_any depth_greater depth_less depth_unchanged early_fragment_tests equal_spacing '
+ 'flat fractional_even_spacing fractional_odd_spacing highp in index inout invariant '
+ 'invocations isolines layout line_strip lines lines_adjacency local_size_x local_size_y '
+ 'local_size_z location lowp max_vertices mediump noperspective offset origin_upper_left '
+ 'out packed patch pixel_center_integer point_mode points precise precision quads r11f_g11f_b10f '
+ 'r16 r16_snorm r16f r16i r16ui r32f r32i r32ui r8 r8_snorm r8i r8ui readonly restrict '
+ 'rg16 rg16_snorm rg16f rg16i rg16ui rg32f rg32i rg32ui rg8 rg8_snorm rg8i rg8ui rgb10_a2 '
+ 'rgb10_a2ui rgba16 rgba16_snorm rgba16f rgba16i rgba16ui rgba32f rgba32i rgba32ui rgba8 '
+ 'rgba8_snorm rgba8i rgba8ui row_major sample shared smooth std140 std430 stream triangle_strip '
+ 'triangles triangles_adjacency uniform varying vertices volatile writeonly',
type:
'atomic_uint bool bvec2 bvec3 bvec4 dmat2 dmat2x2 dmat2x3 dmat2x4 dmat3 dmat3x2 dmat3x3 '
+ 'dmat3x4 dmat4 dmat4x2 dmat4x3 dmat4x4 double dvec2 dvec3 dvec4 float iimage1D iimage1DArray '
+ 'iimage2D iimage2DArray iimage2DMS iimage2DMSArray iimage2DRect iimage3D iimageBuffer '
+ 'iimageCube iimageCubeArray image1D image1DArray image2D image2DArray image2DMS image2DMSArray '
+ 'image2DRect image3D imageBuffer imageCube imageCubeArray int isampler1D isampler1DArray '
+ 'isampler2D isampler2DArray isampler2DMS isampler2DMSArray isampler2DRect isampler3D '
+ 'isamplerBuffer isamplerCube isamplerCubeArray ivec2 ivec3 ivec4 mat2 mat2x2 mat2x3 '
+ 'mat2x4 mat3 mat3x2 mat3x3 mat3x4 mat4 mat4x2 mat4x3 mat4x4 sampler1D sampler1DArray '
+ 'sampler1DArrayShadow sampler1DShadow sampler2D sampler2DArray sampler2DArrayShadow '
+ 'sampler2DMS sampler2DMSArray sampler2DRect sampler2DRectShadow sampler2DShadow sampler3D '
+ 'samplerBuffer samplerCube samplerCubeArray samplerCubeArrayShadow samplerCubeShadow '
+ 'image1D uimage1DArray uimage2D uimage2DArray uimage2DMS uimage2DMSArray uimage2DRect '
+ 'uimage3D uimageBuffer uimageCube uimageCubeArray uint usampler1D usampler1DArray '
+ 'usampler2D usampler2DArray usampler2DMS usampler2DMSArray usampler2DRect usampler3D '
+ 'samplerBuffer usamplerCube usamplerCubeArray uvec2 uvec3 uvec4 vec2 vec3 vec4 void',
built_in:
// Constants
'gl_MaxAtomicCounterBindings gl_MaxAtomicCounterBufferSize gl_MaxClipDistances gl_MaxClipPlanes '
+ 'gl_MaxCombinedAtomicCounterBuffers gl_MaxCombinedAtomicCounters gl_MaxCombinedImageUniforms '
+ 'gl_MaxCombinedImageUnitsAndFragmentOutputs gl_MaxCombinedTextureImageUnits gl_MaxComputeAtomicCounterBuffers '
+ 'gl_MaxComputeAtomicCounters gl_MaxComputeImageUniforms gl_MaxComputeTextureImageUnits '
+ 'gl_MaxComputeUniformComponents gl_MaxComputeWorkGroupCount gl_MaxComputeWorkGroupSize '
+ 'gl_MaxDrawBuffers gl_MaxFragmentAtomicCounterBuffers gl_MaxFragmentAtomicCounters '
+ 'gl_MaxFragmentImageUniforms gl_MaxFragmentInputComponents gl_MaxFragmentInputVectors '
+ 'gl_MaxFragmentUniformComponents gl_MaxFragmentUniformVectors gl_MaxGeometryAtomicCounterBuffers '
+ 'gl_MaxGeometryAtomicCounters gl_MaxGeometryImageUniforms gl_MaxGeometryInputComponents '
+ 'gl_MaxGeometryOutputComponents gl_MaxGeometryOutputVertices gl_MaxGeometryTextureImageUnits '
+ 'gl_MaxGeometryTotalOutputComponents gl_MaxGeometryUniformComponents gl_MaxGeometryVaryingComponents '
+ 'gl_MaxImageSamples gl_MaxImageUnits gl_MaxLights gl_MaxPatchVertices gl_MaxProgramTexelOffset '
+ 'gl_MaxTessControlAtomicCounterBuffers gl_MaxTessControlAtomicCounters gl_MaxTessControlImageUniforms '
+ 'gl_MaxTessControlInputComponents gl_MaxTessControlOutputComponents gl_MaxTessControlTextureImageUnits '
+ 'gl_MaxTessControlTotalOutputComponents gl_MaxTessControlUniformComponents '
+ 'gl_MaxTessEvaluationAtomicCounterBuffers gl_MaxTessEvaluationAtomicCounters '
+ 'gl_MaxTessEvaluationImageUniforms gl_MaxTessEvaluationInputComponents gl_MaxTessEvaluationOutputComponents '
+ 'gl_MaxTessEvaluationTextureImageUnits gl_MaxTessEvaluationUniformComponents '
+ 'gl_MaxTessGenLevel gl_MaxTessPatchComponents gl_MaxTextureCoords gl_MaxTextureImageUnits '
+ 'gl_MaxTextureUnits gl_MaxVaryingComponents gl_MaxVaryingFloats gl_MaxVaryingVectors '
+ 'gl_MaxVertexAtomicCounterBuffers gl_MaxVertexAtomicCounters gl_MaxVertexAttribs gl_MaxVertexImageUniforms '
+ 'gl_MaxVertexOutputComponents gl_MaxVertexOutputVectors gl_MaxVertexTextureImageUnits '
+ 'gl_MaxVertexUniformComponents gl_MaxVertexUniformVectors gl_MaxViewports gl_MinProgramTexelOffset '
// Variables
+ 'gl_BackColor gl_BackLightModelProduct gl_BackLightProduct gl_BackMaterial '
+ 'gl_BackSecondaryColor gl_ClipDistance gl_ClipPlane gl_ClipVertex gl_Color '
+ 'gl_DepthRange gl_EyePlaneQ gl_EyePlaneR gl_EyePlaneS gl_EyePlaneT gl_Fog gl_FogCoord '
+ 'gl_FogFragCoord gl_FragColor gl_FragCoord gl_FragData gl_FragDepth gl_FrontColor '
+ 'gl_FrontFacing gl_FrontLightModelProduct gl_FrontLightProduct gl_FrontMaterial '
+ 'gl_FrontSecondaryColor gl_GlobalInvocationID gl_InstanceID gl_InvocationID gl_Layer gl_LightModel '
+ 'gl_LightSource gl_LocalInvocationID gl_LocalInvocationIndex gl_ModelViewMatrix '
+ 'gl_ModelViewMatrixInverse gl_ModelViewMatrixInverseTranspose gl_ModelViewMatrixTranspose '
+ 'gl_ModelViewProjectionMatrix gl_ModelViewProjectionMatrixInverse gl_ModelViewProjectionMatrixInverseTranspose '
+ 'gl_ModelViewProjectionMatrixTranspose gl_MultiTexCoord0 gl_MultiTexCoord1 gl_MultiTexCoord2 '
+ 'gl_MultiTexCoord3 gl_MultiTexCoord4 gl_MultiTexCoord5 gl_MultiTexCoord6 gl_MultiTexCoord7 '
+ 'gl_Normal gl_NormalMatrix gl_NormalScale gl_NumSamples gl_NumWorkGroups gl_ObjectPlaneQ '
+ 'gl_ObjectPlaneR gl_ObjectPlaneS gl_ObjectPlaneT gl_PatchVerticesIn gl_Point gl_PointCoord '
+ 'gl_PointSize gl_Position gl_PrimitiveID gl_PrimitiveIDIn gl_ProjectionMatrix gl_ProjectionMatrixInverse '
+ 'gl_ProjectionMatrixInverseTranspose gl_ProjectionMatrixTranspose gl_SampleID gl_SampleMask '
+ 'gl_SampleMaskIn gl_SamplePosition gl_SecondaryColor gl_TessCoord gl_TessLevelInner gl_TessLevelOuter '
+ 'gl_TexCoord gl_TextureEnvColor gl_TextureMatrix gl_TextureMatrixInverse gl_TextureMatrixInverseTranspose '
+ 'gl_TextureMatrixTranspose gl_Vertex gl_VertexID gl_ViewportIndex gl_WorkGroupID gl_WorkGroupSize gl_in gl_out '
// Functions
+ 'EmitStreamVertex EmitVertex EndPrimitive EndStreamPrimitive abs acos acosh all any asin '
+ 'asinh atan atanh atomicAdd atomicAnd atomicCompSwap atomicCounter atomicCounterDecrement '
+ 'atomicCounterIncrement atomicExchange atomicMax atomicMin atomicOr atomicXor barrier '
+ 'bitCount bitfieldExtract bitfieldInsert bitfieldReverse ceil clamp cos cosh cross '
+ 'dFdx dFdy degrees determinant distance dot equal exp exp2 faceforward findLSB findMSB '
+ 'floatBitsToInt floatBitsToUint floor fma fract frexp ftransform fwidth greaterThan '
+ 'greaterThanEqual groupMemoryBarrier imageAtomicAdd imageAtomicAnd imageAtomicCompSwap '
+ 'imageAtomicExchange imageAtomicMax imageAtomicMin imageAtomicOr imageAtomicXor imageLoad '
+ 'imageSize imageStore imulExtended intBitsToFloat interpolateAtCentroid interpolateAtOffset '
+ 'interpolateAtSample inverse inversesqrt isinf isnan ldexp length lessThan lessThanEqual log '
+ 'log2 matrixCompMult max memoryBarrier memoryBarrierAtomicCounter memoryBarrierBuffer '
+ 'memoryBarrierImage memoryBarrierShared min mix mod modf noise1 noise2 noise3 noise4 '
+ 'normalize not notEqual outerProduct packDouble2x32 packHalf2x16 packSnorm2x16 packSnorm4x8 '
+ 'packUnorm2x16 packUnorm4x8 pow radians reflect refract round roundEven shadow1D shadow1DLod '
+ 'shadow1DProj shadow1DProjLod shadow2D shadow2DLod shadow2DProj shadow2DProjLod sign sin sinh '
+ 'smoothstep sqrt step tan tanh texelFetch texelFetchOffset texture texture1D texture1DLod '
+ 'texture1DProj texture1DProjLod texture2D texture2DLod texture2DProj texture2DProjLod '
+ 'texture3D texture3DLod texture3DProj texture3DProjLod textureCube textureCubeLod '
+ 'textureGather textureGatherOffset textureGatherOffsets textureGrad textureGradOffset '
+ 'textureLod textureLodOffset textureOffset textureProj textureProjGrad textureProjGradOffset '
+ 'textureProjLod textureProjLodOffset textureProjOffset textureQueryLevels textureQueryLod '
+ 'textureSize transpose trunc uaddCarry uintBitsToFloat umulExtended unpackDouble2x32 '
+ 'unpackHalf2x16 unpackSnorm2x16 unpackSnorm4x8 unpackUnorm2x16 unpackUnorm4x8 usubBorrow',
literal: 'true false'
},
illegal: '"',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '#',
end: '$'
}
]
};
}
var glsl_1 = glsl;
/*
Language: GML
Author: Meseta <meseta@gmail.com>
Description: Game Maker Language for GameMaker Studio 2
Website: https://docs2.yoyogames.com
Category: scripting
*/
function gml(hljs) {
const KEYWORDS = [
"#endregion",
"#macro",
"#region",
"and",
"begin",
"break",
"case",
"constructor",
"continue",
"default",
"delete",
"div",
"do",
"else",
"end",
"enum",
"exit",
"for",
"function",
"globalvar",
"if",
"mod",
"not",
"or",
"repeat",
"return",
"switch",
"then",
"until",
"var",
"while",
"with",
"xor"
];
const BUILT_INS = [
"abs",
"achievement_available",
"achievement_event",
"achievement_get_challenges",
"achievement_get_info",
"achievement_get_pic",
"achievement_increment",
"achievement_load_friends",
"achievement_load_leaderboard",
"achievement_load_progress",
"achievement_login",
"achievement_login_status",
"achievement_logout",
"achievement_post",
"achievement_post_score",
"achievement_reset",
"achievement_send_challenge",
"achievement_show",
"achievement_show_achievements",
"achievement_show_challenge_notifications",
"achievement_show_leaderboards",
"action_inherited",
"action_kill_object",
"ads_disable",
"ads_enable",
"ads_engagement_active",
"ads_engagement_available",
"ads_engagement_launch",
"ads_event",
"ads_event_preload",
"ads_get_display_height",
"ads_get_display_width",
"ads_interstitial_available",
"ads_interstitial_display",
"ads_move",
"ads_set_reward_callback",
"ads_setup",
"alarm_get",
"alarm_set",
"analytics_event",
"analytics_event_ext",
"angle_difference",
"ansi_char",
"application_get_position",
"application_surface_draw_enable",
"application_surface_enable",
"application_surface_is_enabled",
"arccos",
"arcsin",
"arctan",
"arctan2",
"array_copy",
"array_create",
"array_delete",
"array_equals",
"array_height_2d",
"array_insert",
"array_length",
"array_length_1d",
"array_length_2d",
"array_pop",
"array_push",
"array_resize",
"array_sort",
"asset_get_index",
"asset_get_type",
"audio_channel_num",
"audio_create_buffer_sound",
"audio_create_play_queue",
"audio_create_stream",
"audio_create_sync_group",
"audio_debug",
"audio_destroy_stream",
"audio_destroy_sync_group",
"audio_emitter_create",
"audio_emitter_exists",
"audio_emitter_falloff",
"audio_emitter_free",
"audio_emitter_gain",
"audio_emitter_get_gain",
"audio_emitter_get_listener_mask",
"audio_emitter_get_pitch",
"audio_emitter_get_vx",
"audio_emitter_get_vy",
"audio_emitter_get_vz",
"audio_emitter_get_x",
"audio_emitter_get_y",
"audio_emitter_get_z",
"audio_emitter_pitch",
"audio_emitter_position",
"audio_emitter_set_listener_mask",
"audio_emitter_velocity",
"audio_exists",
"audio_falloff_set_model",
"audio_free_buffer_sound",
"audio_free_play_queue",
"audio_get_listener_count",
"audio_get_listener_info",
"audio_get_listener_mask",
"audio_get_master_gain",
"audio_get_name",
"audio_get_recorder_count",
"audio_get_recorder_info",
"audio_get_type",
"audio_group_is_loaded",
"audio_group_load",
"audio_group_load_progress",
"audio_group_name",
"audio_group_set_gain",
"audio_group_stop_all",
"audio_group_unload",
"audio_is_paused",
"audio_is_playing",
"audio_listener_get_data",
"audio_listener_orientation",
"audio_listener_position",
"audio_listener_set_orientation",
"audio_listener_set_position",
"audio_listener_set_velocity",
"audio_listener_velocity",
"audio_master_gain",
"audio_music_gain",
"audio_music_is_playing",
"audio_pause_all",
"audio_pause_music",
"audio_pause_sound",
"audio_pause_sync_group",
"audio_play_in_sync_group",
"audio_play_music",
"audio_play_sound",
"audio_play_sound_at",
"audio_play_sound_on",
"audio_queue_sound",
"audio_resume_all",
"audio_resume_music",
"audio_resume_sound",
"audio_resume_sync_group",
"audio_set_listener_mask",
"audio_set_master_gain",
"audio_sound_gain",
"audio_sound_get_gain",
"audio_sound_get_listener_mask",
"audio_sound_get_pitch",
"audio_sound_get_track_position",
"audio_sound_length",
"audio_sound_pitch",
"audio_sound_set_listener_mask",
"audio_sound_set_track_position",
"audio_start_recording",
"audio_start_sync_group",
"audio_stop_all",
"audio_stop_music",
"audio_stop_recording",
"audio_stop_sound",
"audio_stop_sync_group",
"audio_sync_group_debug",
"audio_sync_group_get_track_pos",
"audio_sync_group_is_playing",
"audio_system",
"background_get_height",
"background_get_width",
"base64_decode",
"base64_encode",
"browser_input_capture",
"buffer_async_group_begin",
"buffer_async_group_end",
"buffer_async_group_option",
"buffer_base64_decode",
"buffer_base64_decode_ext",
"buffer_base64_encode",
"buffer_copy",
"buffer_copy_from_vertex_buffer",
"buffer_create",
"buffer_create_from_vertex_buffer",
"buffer_create_from_vertex_buffer_ext",
"buffer_delete",
"buffer_exists",
"buffer_fill",
"buffer_get_address",
"buffer_get_alignment",
"buffer_get_size",
"buffer_get_surface",
"buffer_get_type",
"buffer_load",
"buffer_load_async",
"buffer_load_ext",
"buffer_load_partial",
"buffer_md5",
"buffer_peek",
"buffer_poke",
"buffer_read",
"buffer_resize",
"buffer_save",
"buffer_save_async",
"buffer_save_ext",
"buffer_seek",
"buffer_set_surface",
"buffer_sha1",
"buffer_sizeof",
"buffer_tell",
"buffer_write",
"camera_apply",
"camera_create",
"camera_create_view",
"camera_destroy",
"camera_get_active",
"camera_get_begin_script",
"camera_get_default",
"camera_get_end_script",
"camera_get_proj_mat",
"camera_get_update_script",
"camera_get_view_angle",
"camera_get_view_border_x",
"camera_get_view_border_y",
"camera_get_view_height",
"camera_get_view_mat",
"camera_get_view_speed_x",
"camera_get_view_speed_y",
"camera_get_view_target",
"camera_get_view_width",
"camera_get_view_x",
"camera_get_view_y",
"camera_set_begin_script",
"camera_set_default",
"camera_set_end_script",
"camera_set_proj_mat",
"camera_set_update_script",
"camera_set_view_angle",
"camera_set_view_border",
"camera_set_view_mat",
"camera_set_view_pos",
"camera_set_view_size",
"camera_set_view_speed",
"camera_set_view_target",
"ceil",
"choose",
"chr",
"clamp",
"clickable_add",
"clickable_add_ext",
"clickable_change",
"clickable_change_ext",
"clickable_delete",
"clickable_exists",
"clickable_set_style",
"clipboard_get_text",
"clipboard_has_text",
"clipboard_set_text",
"cloud_file_save",
"cloud_string_save",
"cloud_synchronise",
"code_is_compiled",
"collision_circle",
"collision_circle_list",
"collision_ellipse",
"collision_ellipse_list",
"collision_line",
"collision_line_list",
"collision_point",
"collision_point_list",
"collision_rectangle",
"collision_rectangle_list",
"color_get_blue",
"color_get_green",
"color_get_hue",
"color_get_red",
"color_get_saturation",
"color_get_value",
"colour_get_blue",
"colour_get_green",
"colour_get_hue",
"colour_get_red",
"colour_get_saturation",
"colour_get_value",
"cos",
"darccos",
"darcsin",
"darctan",
"darctan2",
"date_compare_date",
"date_compare_datetime",
"date_compare_time",
"date_create_datetime",
"date_current_datetime",
"date_date_of",
"date_date_string",
"date_datetime_string",
"date_day_span",
"date_days_in_month",
"date_days_in_year",
"date_get_day",
"date_get_day_of_year",
"date_get_hour",
"date_get_hour_of_year",
"date_get_minute",
"date_get_minute_of_year",
"date_get_month",
"date_get_second",
"date_get_second_of_year",
"date_get_timezone",
"date_get_week",
"date_get_weekday",
"date_get_year",
"date_hour_span",
"date_inc_day",
"date_inc_hour",
"date_inc_minute",
"date_inc_month",
"date_inc_second",
"date_inc_week",
"date_inc_year",
"date_is_today",
"date_leap_year",
"date_minute_span",
"date_month_span",
"date_second_span",
"date_set_timezone",
"date_time_of",
"date_time_string",
"date_valid_datetime",
"date_week_span",
"date_year_span",
"dcos",
"debug_event",
"debug_get_callstack",
"degtorad",
"device_get_tilt_x",
"device_get_tilt_y",
"device_get_tilt_z",
"device_is_keypad_open",
"device_mouse_check_button",
"device_mouse_check_button_pressed",
"device_mouse_check_button_released",
"device_mouse_dbclick_enable",
"device_mouse_raw_x",
"device_mouse_raw_y",
"device_mouse_x",
"device_mouse_x_to_gui",
"device_mouse_y",
"device_mouse_y_to_gui",
"directory_create",
"directory_destroy",
"directory_exists",
"display_get_dpi_x",
"display_get_dpi_y",
"display_get_gui_height",
"display_get_gui_width",
"display_get_height",
"display_get_orientation",
"display_get_sleep_margin",
"display_get_timing_method",
"display_get_width",
"display_mouse_get_x",
"display_mouse_get_y",
"display_mouse_set",
"display_reset",
"display_set_gui_maximise",
"display_set_gui_maximize",
"display_set_gui_size",
"display_set_sleep_margin",
"display_set_timing_method",
"display_set_ui_visibility",
"distance_to_object",
"distance_to_point",
"dot_product",
"dot_product_3d",
"dot_product_3d_normalised",
"dot_product_3d_normalized",
"dot_product_normalised",
"dot_product_normalized",
"draw_arrow",
"draw_background",
"draw_background_ext",
"draw_background_part_ext",
"draw_background_tiled",
"draw_button",
"draw_circle",
"draw_circle_color",
"draw_circle_colour",
"draw_clear",
"draw_clear_alpha",
"draw_ellipse",
"draw_ellipse_color",
"draw_ellipse_colour",
"draw_enable_alphablend",
"draw_enable_drawevent",
"draw_enable_swf_aa",
"draw_flush",
"draw_get_alpha",
"draw_get_color",
"draw_get_colour",
"draw_get_lighting",
"draw_get_swf_aa_level",
"draw_getpixel",
"draw_getpixel_ext",
"draw_healthbar",
"draw_highscore",
"draw_light_define_ambient",
"draw_light_define_direction",
"draw_light_define_point",
"draw_light_enable",
"draw_light_get",
"draw_light_get_ambient",
"draw_line",
"draw_line_color",
"draw_line_colour",
"draw_line_width",
"draw_line_width_color",
"draw_line_width_colour",
"draw_path",
"draw_point",
"draw_point_color",
"draw_point_colour",
"draw_primitive_begin",
"draw_primitive_begin_texture",
"draw_primitive_end",
"draw_rectangle",
"draw_rectangle_color",
"draw_rectangle_colour",
"draw_roundrect",
"draw_roundrect_color",
"draw_roundrect_color_ext",
"draw_roundrect_colour",
"draw_roundrect_colour_ext",
"draw_roundrect_ext",
"draw_self",
"draw_set_alpha",
"draw_set_alpha_test",
"draw_set_alpha_test_ref_value",
"draw_set_blend_mode",
"draw_set_blend_mode_ext",
"draw_set_circle_precision",
"draw_set_color",
"draw_set_color_write_enable",
"draw_set_colour",
"draw_set_font",
"draw_set_halign",
"draw_set_lighting",
"draw_set_swf_aa_level",
"draw_set_valign",
"draw_skeleton",
"draw_skeleton_collision",
"draw_skeleton_instance",
"draw_skeleton_time",
"draw_sprite",
"draw_sprite_ext",
"draw_sprite_general",
"draw_sprite_part",
"draw_sprite_part_ext",
"draw_sprite_pos",
"draw_sprite_stretched",
"draw_sprite_stretched_ext",
"draw_sprite_tiled",
"draw_sprite_tiled_ext",
"draw_surface",
"draw_surface_ext",
"draw_surface_general",
"draw_surface_part",
"draw_surface_part_ext",
"draw_surface_stretched",
"draw_surface_stretched_ext",
"draw_surface_tiled",
"draw_surface_tiled_ext",
"draw_text",
"draw_text_color",
"draw_text_colour",
"draw_text_ext",
"draw_text_ext_color",
"draw_text_ext_colour",
"draw_text_ext_transformed",
"draw_text_ext_transformed_color",
"draw_text_ext_transformed_colour",
"draw_text_transformed",
"draw_text_transformed_color",
"draw_text_transformed_colour",
"draw_texture_flush",
"draw_tile",
"draw_tilemap",
"draw_triangle",
"draw_triangle_color",
"draw_triangle_colour",
"draw_vertex",
"draw_vertex_color",
"draw_vertex_colour",
"draw_vertex_texture",
"draw_vertex_texture_color",
"draw_vertex_texture_colour",
"ds_exists",
"ds_grid_add",
"ds_grid_add_disk",
"ds_grid_add_grid_region",
"ds_grid_add_region",
"ds_grid_clear",
"ds_grid_copy",
"ds_grid_create",
"ds_grid_destroy",
"ds_grid_get",
"ds_grid_get_disk_max",
"ds_grid_get_disk_mean",
"ds_grid_get_disk_min",
"ds_grid_get_disk_sum",
"ds_grid_get_max",
"ds_grid_get_mean",
"ds_grid_get_min",
"ds_grid_get_sum",
"ds_grid_height",
"ds_grid_multiply",
"ds_grid_multiply_disk",
"ds_grid_multiply_grid_region",
"ds_grid_multiply_region",
"ds_grid_read",
"ds_grid_resize",
"ds_grid_set",
"ds_grid_set_disk",
"ds_grid_set_grid_region",
"ds_grid_set_region",
"ds_grid_shuffle",
"ds_grid_sort",
"ds_grid_value_disk_exists",
"ds_grid_value_disk_x",
"ds_grid_value_disk_y",
"ds_grid_value_exists",
"ds_grid_value_x",
"ds_grid_value_y",
"ds_grid_width",
"ds_grid_write",
"ds_list_add",
"ds_list_clear",
"ds_list_copy",
"ds_list_create",
"ds_list_delete",
"ds_list_destroy",
"ds_list_empty",
"ds_list_find_index",
"ds_list_find_value",
"ds_list_insert",
"ds_list_mark_as_list",
"ds_list_mark_as_map",
"ds_list_read",
"ds_list_replace",
"ds_list_set",
"ds_list_shuffle",
"ds_list_size",
"ds_list_sort",
"ds_list_write",
"ds_map_add",
"ds_map_add_list",
"ds_map_add_map",
"ds_map_clear",
"ds_map_copy",
"ds_map_create",
"ds_map_delete",
"ds_map_destroy",
"ds_map_empty",
"ds_map_exists",
"ds_map_find_first",
"ds_map_find_last",
"ds_map_find_next",
"ds_map_find_previous",
"ds_map_find_value",
"ds_map_read",
"ds_map_replace",
"ds_map_replace_list",
"ds_map_replace_map",
"ds_map_secure_load",
"ds_map_secure_load_buffer",
"ds_map_secure_save",
"ds_map_secure_save_buffer",
"ds_map_set",
"ds_map_size",
"ds_map_write",
"ds_priority_add",
"ds_priority_change_priority",
"ds_priority_clear",
"ds_priority_copy",
"ds_priority_create",
"ds_priority_delete_max",
"ds_priority_delete_min",
"ds_priority_delete_value",
"ds_priority_destroy",
"ds_priority_empty",
"ds_priority_find_max",
"ds_priority_find_min",
"ds_priority_find_priority",
"ds_priority_read",
"ds_priority_size",
"ds_priority_write",
"ds_queue_clear",
"ds_queue_copy",
"ds_queue_create",
"ds_queue_dequeue",
"ds_queue_destroy",
"ds_queue_empty",
"ds_queue_enqueue",
"ds_queue_head",
"ds_queue_read",
"ds_queue_size",
"ds_queue_tail",
"ds_queue_write",
"ds_set_precision",
"ds_stack_clear",
"ds_stack_copy",
"ds_stack_create",
"ds_stack_destroy",
"ds_stack_empty",
"ds_stack_pop",
"ds_stack_push",
"ds_stack_read",
"ds_stack_size",
"ds_stack_top",
"ds_stack_write",
"dsin",
"dtan",
"effect_clear",
"effect_create_above",
"effect_create_below",
"environment_get_variable",
"event_inherited",
"event_perform",
"event_perform_object",
"event_user",
"exp",
"external_call",
"external_define",
"external_free",
"facebook_accesstoken",
"facebook_check_permission",
"facebook_dialog",
"facebook_graph_request",
"facebook_init",
"facebook_launch_offerwall",
"facebook_login",
"facebook_logout",
"facebook_post_message",
"facebook_request_publish_permissions",
"facebook_request_read_permissions",
"facebook_send_invite",
"facebook_status",
"facebook_user_id",
"file_attributes",
"file_bin_close",
"file_bin_open",
"file_bin_position",
"file_bin_read_byte",
"file_bin_rewrite",
"file_bin_seek",
"file_bin_size",
"file_bin_write_byte",
"file_copy",
"file_delete",
"file_exists",
"file_find_close",
"file_find_first",
"file_find_next",
"file_rename",
"file_text_close",
"file_text_eof",
"file_text_eoln",
"file_text_open_append",
"file_text_open_from_string",
"file_text_open_read",
"file_text_open_write",
"file_text_read_real",
"file_text_read_string",
"file_text_readln",
"file_text_write_real",
"file_text_write_string",
"file_text_writeln",
"filename_change_ext",
"filename_dir",
"filename_drive",
"filename_ext",
"filename_name",
"filename_path",
"floor",
"font_add",
"font_add_enable_aa",
"font_add_get_enable_aa",
"font_add_sprite",
"font_add_sprite_ext",
"font_delete",
"font_exists",
"font_get_bold",
"font_get_first",
"font_get_fontname",
"font_get_italic",
"font_get_last",
"font_get_name",
"font_get_size",
"font_get_texture",
"font_get_uvs",
"font_replace",
"font_replace_sprite",
"font_replace_sprite_ext",
"font_set_cache_size",
"font_texture_page_size",
"frac",
"game_end",
"game_get_speed",
"game_load",
"game_load_buffer",
"game_restart",
"game_save",
"game_save_buffer",
"game_set_speed",
"gamepad_axis_count",
"gamepad_axis_value",
"gamepad_button_check",
"gamepad_button_check_pressed",
"gamepad_button_check_released",
"gamepad_button_count",
"gamepad_button_value",
"gamepad_get_axis_deadzone",
"gamepad_get_button_threshold",
"gamepad_get_description",
"gamepad_get_device_count",
"gamepad_is_connected",
"gamepad_is_supported",
"gamepad_set_axis_deadzone",
"gamepad_set_button_threshold",
"gamepad_set_color",
"gamepad_set_colour",
"gamepad_set_vibration",
"gesture_double_tap_distance",
"gesture_double_tap_time",
"gesture_drag_distance",
"gesture_drag_time",
"gesture_flick_speed",
"gesture_get_double_tap_distance",
"gesture_get_double_tap_time",
"gesture_get_drag_distance",
"gesture_get_drag_time",
"gesture_get_flick_speed",
"gesture_get_pinch_angle_away",
"gesture_get_pinch_angle_towards",
"gesture_get_pinch_distance",
"gesture_get_rotate_angle",
"gesture_get_rotate_time",
"gesture_get_tap_count",
"gesture_pinch_angle_away",
"gesture_pinch_angle_towards",
"gesture_pinch_distance",
"gesture_rotate_angle",
"gesture_rotate_time",
"gesture_tap_count",
"get_integer",
"get_integer_async",
"get_login_async",
"get_open_filename",
"get_open_filename_ext",
"get_save_filename",
"get_save_filename_ext",
"get_string",
"get_string_async",
"get_timer",
"gml_pragma",
"gml_release_mode",
"gpu_get_alphatestenable",
"gpu_get_alphatestfunc",
"gpu_get_alphatestref",
"gpu_get_blendenable",
"gpu_get_blendmode",
"gpu_get_blendmode_dest",
"gpu_get_blendmode_destalpha",
"gpu_get_blendmode_ext",
"gpu_get_blendmode_ext_sepalpha",
"gpu_get_blendmode_src",
"gpu_get_blendmode_srcalpha",
"gpu_get_colorwriteenable",
"gpu_get_colourwriteenable",
"gpu_get_cullmode",
"gpu_get_fog",
"gpu_get_lightingenable",
"gpu_get_state",
"gpu_get_tex_filter",
"gpu_get_tex_filter_ext",
"gpu_get_tex_max_aniso",
"gpu_get_tex_max_aniso_ext",
"gpu_get_tex_max_mip",
"gpu_get_tex_max_mip_ext",
"gpu_get_tex_min_mip",
"gpu_get_tex_min_mip_ext",
"gpu_get_tex_mip_bias",
"gpu_get_tex_mip_bias_ext",
"gpu_get_tex_mip_enable",
"gpu_get_tex_mip_enable_ext",
"gpu_get_tex_mip_filter",
"gpu_get_tex_mip_filter_ext",
"gpu_get_tex_repeat",
"gpu_get_tex_repeat_ext",
"gpu_get_texfilter",
"gpu_get_texfilter_ext",
"gpu_get_texrepeat",
"gpu_get_texrepeat_ext",
"gpu_get_zfunc",
"gpu_get_ztestenable",
"gpu_get_zwriteenable",
"gpu_pop_state",
"gpu_push_state",
"gpu_set_alphatestenable",
"gpu_set_alphatestfunc",
"gpu_set_alphatestref",
"gpu_set_blendenable",
"gpu_set_blendmode",
"gpu_set_blendmode_ext",
"gpu_set_blendmode_ext_sepalpha",
"gpu_set_colorwriteenable",
"gpu_set_colourwriteenable",
"gpu_set_cullmode",
"gpu_set_fog",
"gpu_set_lightingenable",
"gpu_set_state",
"gpu_set_tex_filter",
"gpu_set_tex_filter_ext",
"gpu_set_tex_max_aniso",
"gpu_set_tex_max_aniso_ext",
"gpu_set_tex_max_mip",
"gpu_set_tex_max_mip_ext",
"gpu_set_tex_min_mip",
"gpu_set_tex_min_mip_ext",
"gpu_set_tex_mip_bias",
"gpu_set_tex_mip_bias_ext",
"gpu_set_tex_mip_enable",
"gpu_set_tex_mip_enable_ext",
"gpu_set_tex_mip_filter",
"gpu_set_tex_mip_filter_ext",
"gpu_set_tex_repeat",
"gpu_set_tex_repeat_ext",
"gpu_set_texfilter",
"gpu_set_texfilter_ext",
"gpu_set_texrepeat",
"gpu_set_texrepeat_ext",
"gpu_set_zfunc",
"gpu_set_ztestenable",
"gpu_set_zwriteenable",
"highscore_add",
"highscore_clear",
"highscore_name",
"highscore_value",
"http_get",
"http_get_file",
"http_post_string",
"http_request",
"iap_acquire",
"iap_activate",
"iap_consume",
"iap_enumerate_products",
"iap_product_details",
"iap_purchase_details",
"iap_restore_all",
"iap_status",
"ini_close",
"ini_key_delete",
"ini_key_exists",
"ini_open",
"ini_open_from_string",
"ini_read_real",
"ini_read_string",
"ini_section_delete",
"ini_section_exists",
"ini_write_real",
"ini_write_string",
"instance_activate_all",
"instance_activate_layer",
"instance_activate_object",
"instance_activate_region",
"instance_change",
"instance_copy",
"instance_create",
"instance_create_depth",
"instance_create_layer",
"instance_deactivate_all",
"instance_deactivate_layer",
"instance_deactivate_object",
"instance_deactivate_region",
"instance_destroy",
"instance_exists",
"instance_find",
"instance_furthest",
"instance_id_get",
"instance_nearest",
"instance_number",
"instance_place",
"instance_place_list",
"instance_position",
"instance_position_list",
"int64",
"io_clear",
"irandom",
"irandom_range",
"is_array",
"is_bool",
"is_infinity",
"is_int32",
"is_int64",
"is_matrix",
"is_method",
"is_nan",
"is_numeric",
"is_ptr",
"is_real",
"is_string",
"is_struct",
"is_undefined",
"is_vec3",
"is_vec4",
"json_decode",
"json_encode",
"keyboard_check",
"keyboard_check_direct",
"keyboard_check_pressed",
"keyboard_check_released",
"keyboard_clear",
"keyboard_get_map",
"keyboard_get_numlock",
"keyboard_key_press",
"keyboard_key_release",
"keyboard_set_map",
"keyboard_set_numlock",
"keyboard_unset_map",
"keyboard_virtual_height",
"keyboard_virtual_hide",
"keyboard_virtual_show",
"keyboard_virtual_status",
"layer_add_instance",
"layer_background_alpha",
"layer_background_blend",
"layer_background_change",
"layer_background_create",
"layer_background_destroy",
"layer_background_exists",
"layer_background_get_alpha",
"layer_background_get_blend",
"layer_background_get_htiled",
"layer_background_get_id",
"layer_background_get_index",
"layer_background_get_speed",
"layer_background_get_sprite",
"layer_background_get_stretch",
"layer_background_get_visible",
"layer_background_get_vtiled",
"layer_background_get_xscale",
"layer_background_get_yscale",
"layer_background_htiled",
"layer_background_index",
"layer_background_speed",
"layer_background_sprite",
"layer_background_stretch",
"layer_background_visible",
"layer_background_vtiled",
"layer_background_xscale",
"layer_background_yscale",
"layer_create",
"layer_depth",
"layer_destroy",
"layer_destroy_instances",
"layer_element_move",
"layer_exists",
"layer_force_draw_depth",
"layer_get_all",
"layer_get_all_elements",
"layer_get_depth",
"layer_get_element_layer",
"layer_get_element_type",
"layer_get_forced_depth",
"layer_get_hspeed",
"layer_get_id",
"layer_get_id_at_depth",
"layer_get_name",
"layer_get_script_begin",
"layer_get_script_end",
"layer_get_shader",
"layer_get_target_room",
"layer_get_visible",
"layer_get_vspeed",
"layer_get_x",
"layer_get_y",
"layer_has_instance",
"layer_hspeed",
"layer_instance_get_instance",
"layer_is_draw_depth_forced",
"layer_reset_target_room",
"layer_script_begin",
"layer_script_end",
"layer_set_target_room",
"layer_set_visible",
"layer_shader",
"layer_sprite_alpha",
"layer_sprite_angle",
"layer_sprite_blend",
"layer_sprite_change",
"layer_sprite_create",
"layer_sprite_destroy",
"layer_sprite_exists",
"layer_sprite_get_alpha",
"layer_sprite_get_angle",
"layer_sprite_get_blend",
"layer_sprite_get_id",
"layer_sprite_get_index",
"layer_sprite_get_speed",
"layer_sprite_get_sprite",
"layer_sprite_get_x",
"layer_sprite_get_xscale",
"layer_sprite_get_y",
"layer_sprite_get_yscale",
"layer_sprite_index",
"layer_sprite_speed",
"layer_sprite_x",
"layer_sprite_xscale",
"layer_sprite_y",
"layer_sprite_yscale",
"layer_tile_alpha",
"layer_tile_blend",
"layer_tile_change",
"layer_tile_create",
"layer_tile_destroy",
"layer_tile_exists",
"layer_tile_get_alpha",
"layer_tile_get_blend",
"layer_tile_get_region",
"layer_tile_get_sprite",
"layer_tile_get_visible",
"layer_tile_get_x",
"layer_tile_get_xscale",
"layer_tile_get_y",
"layer_tile_get_yscale",
"layer_tile_region",
"layer_tile_visible",
"layer_tile_x",
"layer_tile_xscale",
"layer_tile_y",
"layer_tile_yscale",
"layer_tilemap_create",
"layer_tilemap_destroy",
"layer_tilemap_exists",
"layer_tilemap_get_id",
"layer_vspeed",
"layer_x",
"layer_y",
"lengthdir_x",
"lengthdir_y",
"lerp",
"ln",
"load_csv",
"log10",
"log2",
"logn",
"make_color_hsv",
"make_color_rgb",
"make_colour_hsv",
"make_colour_rgb",
"math_get_epsilon",
"math_set_epsilon",
"matrix_build",
"matrix_build_identity",
"matrix_build_lookat",
"matrix_build_projection_ortho",
"matrix_build_projection_perspective",
"matrix_build_projection_perspective_fov",
"matrix_get",
"matrix_multiply",
"matrix_set",
"matrix_stack_clear",
"matrix_stack_is_empty",
"matrix_stack_multiply",
"matrix_stack_pop",
"matrix_stack_push",
"matrix_stack_set",
"matrix_stack_top",
"matrix_transform_vertex",
"max",
"md5_file",
"md5_string_unicode",
"md5_string_utf8",
"mean",
"median",
"merge_color",
"merge_colour",
"min",
"motion_add",
"motion_set",
"mouse_check_button",
"mouse_check_button_pressed",
"mouse_check_button_released",
"mouse_clear",
"mouse_wheel_down",
"mouse_wheel_up",
"move_bounce_all",
"move_bounce_solid",
"move_contact_all",
"move_contact_solid",
"move_outside_all",
"move_outside_solid",
"move_random",
"move_snap",
"move_towards_point",
"move_wrap",
"mp_grid_add_cell",
"mp_grid_add_instances",
"mp_grid_add_rectangle",
"mp_grid_clear_all",
"mp_grid_clear_cell",
"mp_grid_clear_rectangle",
"mp_grid_create",
"mp_grid_destroy",
"mp_grid_draw",
"mp_grid_get_cell",
"mp_grid_path",
"mp_grid_to_ds_grid",
"mp_linear_path",
"mp_linear_path_object",
"mp_linear_step",
"mp_linear_step_object",
"mp_potential_path",
"mp_potential_path_object",
"mp_potential_settings",
"mp_potential_step",
"mp_potential_step_object",
"network_connect",
"network_connect_raw",
"network_create_server",
"network_create_server_raw",
"network_create_socket",
"network_create_socket_ext",
"network_destroy",
"network_resolve",
"network_send_broadcast",
"network_send_packet",
"network_send_raw",
"network_send_udp",
"network_send_udp_raw",
"network_set_config",
"network_set_timeout",
"object_exists",
"object_get_depth",
"object_get_mask",
"object_get_name",
"object_get_parent",
"object_get_persistent",
"object_get_physics",
"object_get_solid",
"object_get_sprite",
"object_get_visible",
"object_is_ancestor",
"object_set_mask",
"object_set_persistent",
"object_set_solid",
"object_set_sprite",
"object_set_visible",
"ord",
"os_get_config",
"os_get_info",
"os_get_language",
"os_get_region",
"os_is_network_connected",
"os_is_paused",
"os_lock_orientation",
"os_powersave_enable",
"parameter_count",
"parameter_string",
"part_emitter_burst",
"part_emitter_clear",
"part_emitter_create",
"part_emitter_destroy",
"part_emitter_destroy_all",
"part_emitter_exists",
"part_emitter_region",
"part_emitter_stream",
"part_particles_clear",
"part_particles_count",
"part_particles_create",
"part_particles_create_color",
"part_particles_create_colour",
"part_system_automatic_draw",
"part_system_automatic_update",
"part_system_clear",
"part_system_create",
"part_system_create_layer",
"part_system_depth",
"part_system_destroy",
"part_system_draw_order",
"part_system_drawit",
"part_system_exists",
"part_system_get_layer",
"part_system_layer",
"part_system_position",
"part_system_update",
"part_type_alpha1",
"part_type_alpha2",
"part_type_alpha3",
"part_type_blend",
"part_type_clear",
"part_type_color1",
"part_type_color2",
"part_type_color3",
"part_type_color_hsv",
"part_type_color_mix",
"part_type_color_rgb",
"part_type_colour1",
"part_type_colour2",
"part_type_colour3",
"part_type_colour_hsv",
"part_type_colour_mix",
"part_type_colour_rgb",
"part_type_create",
"part_type_death",
"part_type_destroy",
"part_type_direction",
"part_type_exists",
"part_type_gravity",
"part_type_life",
"part_type_orientation",
"part_type_scale",
"part_type_shape",
"part_type_size",
"part_type_speed",
"part_type_sprite",
"part_type_step",
"path_add",
"path_add_point",
"path_append",
"path_assign",
"path_change_point",
"path_clear_points",
"path_delete",
"path_delete_point",
"path_duplicate",
"path_end",
"path_exists",
"path_flip",
"path_get_closed",
"path_get_kind",
"path_get_length",
"path_get_name",
"path_get_number",
"path_get_point_speed",
"path_get_point_x",
"path_get_point_y",
"path_get_precision",
"path_get_speed",
"path_get_time",
"path_get_x",
"path_get_y",
"path_insert_point",
"path_mirror",
"path_rescale",
"path_reverse",
"path_rotate",
"path_set_closed",
"path_set_kind",
"path_set_precision",
"path_shift",
"path_start",
"physics_apply_angular_impulse",
"physics_apply_force",
"physics_apply_impulse",
"physics_apply_local_force",
"physics_apply_local_impulse",
"physics_apply_torque",
"physics_draw_debug",
"physics_fixture_add_point",
"physics_fixture_bind",
"physics_fixture_bind_ext",
"physics_fixture_create",
"physics_fixture_delete",
"physics_fixture_set_angular_damping",
"physics_fixture_set_awake",
"physics_fixture_set_box_shape",
"physics_fixture_set_chain_shape",
"physics_fixture_set_circle_shape",
"physics_fixture_set_collision_group",
"physics_fixture_set_density",
"physics_fixture_set_edge_shape",
"physics_fixture_set_friction",
"physics_fixture_set_kinematic",
"physics_fixture_set_linear_damping",
"physics_fixture_set_polygon_shape",
"physics_fixture_set_restitution",
"physics_fixture_set_sensor",
"physics_get_density",
"physics_get_friction",
"physics_get_restitution",
"physics_joint_delete",
"physics_joint_distance_create",
"physics_joint_enable_motor",
"physics_joint_friction_create",
"physics_joint_gear_create",
"physics_joint_get_value",
"physics_joint_prismatic_create",
"physics_joint_pulley_create",
"physics_joint_revolute_create",
"physics_joint_rope_create",
"physics_joint_set_value",
"physics_joint_weld_create",
"physics_joint_wheel_create",
"physics_mass_properties",
"physics_particle_count",
"physics_particle_create",
"physics_particle_delete",
"physics_particle_delete_region_box",
"physics_particle_delete_region_circle",
"physics_particle_delete_region_poly",
"physics_particle_draw",
"physics_particle_draw_ext",
"physics_particle_get_damping",
"physics_particle_get_data",
"physics_particle_get_data_particle",
"physics_particle_get_density",
"physics_particle_get_gravity_scale",
"physics_particle_get_group_flags",
"physics_particle_get_max_count",
"physics_particle_get_radius",
"physics_particle_group_add_point",
"physics_particle_group_begin",
"physics_particle_group_box",
"physics_particle_group_circle",
"physics_particle_group_count",
"physics_particle_group_delete",
"physics_particle_group_end",
"physics_particle_group_get_ang_vel",
"physics_particle_group_get_angle",
"physics_particle_group_get_centre_x",
"physics_particle_group_get_centre_y",
"physics_particle_group_get_data",
"physics_particle_group_get_inertia",
"physics_particle_group_get_mass",
"physics_particle_group_get_vel_x",
"physics_particle_group_get_vel_y",
"physics_particle_group_get_x",
"physics_particle_group_get_y",
"physics_particle_group_join",
"physics_particle_group_polygon",
"physics_particle_set_category_flags",
"physics_particle_set_damping",
"physics_particle_set_density",
"physics_particle_set_flags",
"physics_particle_set_gravity_scale",
"physics_particle_set_group_flags",
"physics_particle_set_max_count",
"physics_particle_set_radius",
"physics_pause_enable",
"physics_remove_fixture",
"physics_set_density",
"physics_set_friction",
"physics_set_restitution",
"physics_test_overlap",
"physics_world_create",
"physics_world_draw_debug",
"physics_world_gravity",
"physics_world_update_iterations",
"physics_world_update_speed",
"place_empty",
"place_free",
"place_meeting",
"place_snapped",
"point_direction",
"point_distance",
"point_distance_3d",
"point_in_circle",
"point_in_rectangle",
"point_in_triangle",
"position_change",
"position_destroy",
"position_empty",
"position_meeting",
"power",
"ptr",
"push_cancel_local_notification",
"push_get_first_local_notification",
"push_get_next_local_notification",
"push_local_notification",
"radtodeg",
"random",
"random_get_seed",
"random_range",
"random_set_seed",
"randomise",
"randomize",
"real",
"rectangle_in_circle",
"rectangle_in_rectangle",
"rectangle_in_triangle",
"room_add",
"room_assign",
"room_duplicate",
"room_exists",
"room_get_camera",
"room_get_name",
"room_get_viewport",
"room_goto",
"room_goto_next",
"room_goto_previous",
"room_instance_add",
"room_instance_clear",
"room_next",
"room_previous",
"room_restart",
"room_set_background_color",
"room_set_background_colour",
"room_set_camera",
"room_set_height",
"room_set_persistent",
"room_set_view",
"room_set_view_enabled",
"room_set_viewport",
"room_set_width",
"round",
"screen_save",
"screen_save_part",
"script_execute",
"script_exists",
"script_get_name",
"sha1_file",
"sha1_string_unicode",
"sha1_string_utf8",
"shader_current",
"shader_enable_corner_id",
"shader_get_name",
"shader_get_sampler_index",
"shader_get_uniform",
"shader_is_compiled",
"shader_reset",
"shader_set",
"shader_set_uniform_f",
"shader_set_uniform_f_array",
"shader_set_uniform_i",
"shader_set_uniform_i_array",
"shader_set_uniform_matrix",
"shader_set_uniform_matrix_array",
"shaders_are_supported",
"shop_leave_rating",
"show_debug_message",
"show_debug_overlay",
"show_error",
"show_message",
"show_message_async",
"show_question",
"show_question_async",
"sign",
"sin",
"skeleton_animation_clear",
"skeleton_animation_get",
"skeleton_animation_get_duration",
"skeleton_animation_get_ext",
"skeleton_animation_get_frame",
"skeleton_animation_get_frames",
"skeleton_animation_list",
"skeleton_animation_mix",
"skeleton_animation_set",
"skeleton_animation_set_ext",
"skeleton_animation_set_frame",
"skeleton_attachment_create",
"skeleton_attachment_get",
"skeleton_attachment_set",
"skeleton_bone_data_get",
"skeleton_bone_data_set",
"skeleton_bone_state_get",
"skeleton_bone_state_set",
"skeleton_collision_draw_set",
"skeleton_get_bounds",
"skeleton_get_minmax",
"skeleton_get_num_bounds",
"skeleton_skin_get",
"skeleton_skin_list",
"skeleton_skin_set",
"skeleton_slot_data",
"sprite_add",
"sprite_add_from_surface",
"sprite_assign",
"sprite_collision_mask",
"sprite_create_from_surface",
"sprite_delete",
"sprite_duplicate",
"sprite_exists",
"sprite_flush",
"sprite_flush_multi",
"sprite_get_bbox_bottom",
"sprite_get_bbox_left",
"sprite_get_bbox_right",
"sprite_get_bbox_top",
"sprite_get_height",
"sprite_get_name",
"sprite_get_number",
"sprite_get_speed",
"sprite_get_speed_type",
"sprite_get_texture",
"sprite_get_tpe",
"sprite_get_uvs",
"sprite_get_width",
"sprite_get_xoffset",
"sprite_get_yoffset",
"sprite_merge",
"sprite_prefetch",
"sprite_prefetch_multi",
"sprite_replace",
"sprite_save",
"sprite_save_strip",
"sprite_set_alpha_from_sprite",
"sprite_set_cache_size",
"sprite_set_cache_size_ext",
"sprite_set_offset",
"sprite_set_speed",
"sqr",
"sqrt",
"steam_activate_overlay",
"steam_activate_overlay_browser",
"steam_activate_overlay_store",
"steam_activate_overlay_user",
"steam_available_languages",
"steam_clear_achievement",
"steam_create_leaderboard",
"steam_current_game_language",
"steam_download_friends_scores",
"steam_download_scores",
"steam_download_scores_around_user",
"steam_file_delete",
"steam_file_exists",
"steam_file_persisted",
"steam_file_read",
"steam_file_share",
"steam_file_size",
"steam_file_write",
"steam_file_write_file",
"steam_get_achievement",
"steam_get_app_id",
"steam_get_persona_name",
"steam_get_quota_free",
"steam_get_quota_total",
"steam_get_stat_avg_rate",
"steam_get_stat_float",
"steam_get_stat_int",
"steam_get_user_account_id",
"steam_get_user_persona_name",
"steam_get_user_steam_id",
"steam_initialised",
"steam_is_cloud_enabled_for_account",
"steam_is_cloud_enabled_for_app",
"steam_is_overlay_activated",
"steam_is_overlay_enabled",
"steam_is_screenshot_requested",
"steam_is_user_logged_on",
"steam_reset_all_stats",
"steam_reset_all_stats_achievements",
"steam_send_screenshot",
"steam_set_achievement",
"steam_set_stat_avg_rate",
"steam_set_stat_float",
"steam_set_stat_int",
"steam_stats_ready",
"steam_ugc_create_item",
"steam_ugc_create_query_all",
"steam_ugc_create_query_all_ex",
"steam_ugc_create_query_user",
"steam_ugc_create_query_user_ex",
"steam_ugc_download",
"steam_ugc_get_item_install_info",
"steam_ugc_get_item_update_info",
"steam_ugc_get_item_update_progress",
"steam_ugc_get_subscribed_items",
"steam_ugc_num_subscribed_items",
"steam_ugc_query_add_excluded_tag",
"steam_ugc_query_add_required_tag",
"steam_ugc_query_set_allow_cached_response",
"steam_ugc_query_set_cloud_filename_filter",
"steam_ugc_query_set_match_any_tag",
"steam_ugc_query_set_ranked_by_trend_days",
"steam_ugc_query_set_return_long_description",
"steam_ugc_query_set_return_total_only",
"steam_ugc_query_set_search_text",
"steam_ugc_request_item_details",
"steam_ugc_send_query",
"steam_ugc_set_item_content",
"steam_ugc_set_item_description",
"steam_ugc_set_item_preview",
"steam_ugc_set_item_tags",
"steam_ugc_set_item_title",
"steam_ugc_set_item_visibility",
"steam_ugc_start_item_update",
"steam_ugc_submit_item_update",
"steam_ugc_subscribe_item",
"steam_ugc_unsubscribe_item",
"steam_upload_score",
"steam_upload_score_buffer",
"steam_upload_score_buffer_ext",
"steam_upload_score_ext",
"steam_user_installed_dlc",
"steam_user_owns_dlc",
"string",
"string_byte_at",
"string_byte_length",
"string_char_at",
"string_copy",
"string_count",
"string_delete",
"string_digits",
"string_format",
"string_hash_to_newline",
"string_height",
"string_height_ext",
"string_insert",
"string_length",
"string_letters",
"string_lettersdigits",
"string_lower",
"string_ord_at",
"string_pos",
"string_repeat",
"string_replace",
"string_replace_all",
"string_set_byte_at",
"string_upper",
"string_width",
"string_width_ext",
"surface_copy",
"surface_copy_part",
"surface_create",
"surface_create_ext",
"surface_depth_disable",
"surface_exists",
"surface_free",
"surface_get_depth_disable",
"surface_get_height",
"surface_get_texture",
"surface_get_width",
"surface_getpixel",
"surface_getpixel_ext",
"surface_reset_target",
"surface_resize",
"surface_save",
"surface_save_part",
"surface_set_target",
"surface_set_target_ext",
"tan",
"texture_get_height",
"texture_get_texel_height",
"texture_get_texel_width",
"texture_get_uvs",
"texture_get_width",
"texture_global_scale",
"texture_set_stage",
"tile_get_empty",
"tile_get_flip",
"tile_get_index",
"tile_get_mirror",
"tile_get_rotate",
"tile_set_empty",
"tile_set_flip",
"tile_set_index",
"tile_set_mirror",
"tile_set_rotate",
"tilemap_clear",
"tilemap_get",
"tilemap_get_at_pixel",
"tilemap_get_cell_x_at_pixel",
"tilemap_get_cell_y_at_pixel",
"tilemap_get_frame",
"tilemap_get_global_mask",
"tilemap_get_height",
"tilemap_get_mask",
"tilemap_get_tile_height",
"tilemap_get_tile_width",
"tilemap_get_tileset",
"tilemap_get_width",
"tilemap_get_x",
"tilemap_get_y",
"tilemap_set",
"tilemap_set_at_pixel",
"tilemap_set_global_mask",
"tilemap_set_mask",
"tilemap_tileset",
"tilemap_x",
"tilemap_y",
"timeline_add",
"timeline_clear",
"timeline_delete",
"timeline_exists",
"timeline_get_name",
"timeline_max_moment",
"timeline_moment_add_script",
"timeline_moment_clear",
"timeline_size",
"typeof",
"url_get_domain",
"url_open",
"url_open_ext",
"url_open_full",
"variable_global_exists",
"variable_global_get",
"variable_global_set",
"variable_instance_exists",
"variable_instance_get",
"variable_instance_get_names",
"variable_instance_set",
"variable_struct_exists",
"variable_struct_get",
"variable_struct_get_names",
"variable_struct_names_count",
"variable_struct_remove",
"variable_struct_set",
"vertex_argb",
"vertex_begin",
"vertex_color",
"vertex_colour",
"vertex_create_buffer",
"vertex_create_buffer_ext",
"vertex_create_buffer_from_buffer",
"vertex_create_buffer_from_buffer_ext",
"vertex_delete_buffer",
"vertex_end",
"vertex_float1",
"vertex_float2",
"vertex_float3",
"vertex_float4",
"vertex_format_add_color",
"vertex_format_add_colour",
"vertex_format_add_custom",
"vertex_format_add_normal",
"vertex_format_add_position",
"vertex_format_add_position_3d",
"vertex_format_add_texcoord",
"vertex_format_add_textcoord",
"vertex_format_begin",
"vertex_format_delete",
"vertex_format_end",
"vertex_freeze",
"vertex_get_buffer_size",
"vertex_get_number",
"vertex_normal",
"vertex_position",
"vertex_position_3d",
"vertex_submit",
"vertex_texcoord",
"vertex_ubyte4",
"view_get_camera",
"view_get_hport",
"view_get_surface_id",
"view_get_visible",
"view_get_wport",
"view_get_xport",
"view_get_yport",
"view_set_camera",
"view_set_hport",
"view_set_surface_id",
"view_set_visible",
"view_set_wport",
"view_set_xport",
"view_set_yport",
"virtual_key_add",
"virtual_key_delete",
"virtual_key_hide",
"virtual_key_show",
"win8_appbar_add_element",
"win8_appbar_enable",
"win8_appbar_remove_element",
"win8_device_touchscreen_available",
"win8_license_initialize_sandbox",
"win8_license_trial_version",
"win8_livetile_badge_clear",
"win8_livetile_badge_notification",
"win8_livetile_notification_begin",
"win8_livetile_notification_end",
"win8_livetile_notification_expiry",
"win8_livetile_notification_image_add",
"win8_livetile_notification_secondary_begin",
"win8_livetile_notification_tag",
"win8_livetile_notification_text_add",
"win8_livetile_queue_enable",
"win8_livetile_tile_clear",
"win8_livetile_tile_notification",
"win8_search_add_suggestions",
"win8_search_disable",
"win8_search_enable",
"win8_secondarytile_badge_notification",
"win8_secondarytile_delete",
"win8_secondarytile_pin",
"win8_settingscharm_add_entry",
"win8_settingscharm_add_html_entry",
"win8_settingscharm_add_xaml_entry",
"win8_settingscharm_get_xaml_property",
"win8_settingscharm_remove_entry",
"win8_settingscharm_set_xaml_property",
"win8_share_file",
"win8_share_image",
"win8_share_screenshot",
"win8_share_text",
"win8_share_url",
"window_center",
"window_device",
"window_get_caption",
"window_get_color",
"window_get_colour",
"window_get_cursor",
"window_get_fullscreen",
"window_get_height",
"window_get_visible_rects",
"window_get_width",
"window_get_x",
"window_get_y",
"window_handle",
"window_has_focus",
"window_mouse_get_x",
"window_mouse_get_y",
"window_mouse_set",
"window_set_caption",
"window_set_color",
"window_set_colour",
"window_set_cursor",
"window_set_fullscreen",
"window_set_max_height",
"window_set_max_width",
"window_set_min_height",
"window_set_min_width",
"window_set_position",
"window_set_rectangle",
"window_set_size",
"window_view_mouse_get_x",
"window_view_mouse_get_y",
"window_views_mouse_get_x",
"window_views_mouse_get_y",
"winphone_license_trial_version",
"winphone_tile_back_content",
"winphone_tile_back_content_wide",
"winphone_tile_back_image",
"winphone_tile_back_image_wide",
"winphone_tile_back_title",
"winphone_tile_background_color",
"winphone_tile_background_colour",
"winphone_tile_count",
"winphone_tile_cycle_images",
"winphone_tile_front_image",
"winphone_tile_front_image_small",
"winphone_tile_front_image_wide",
"winphone_tile_icon_image",
"winphone_tile_small_background_image",
"winphone_tile_small_icon_image",
"winphone_tile_title",
"winphone_tile_wide_content",
"zip_unzip"
];
const LITERALS = [
"all",
"false",
"noone",
"pointer_invalid",
"pointer_null",
"true",
"undefined"
];
// many of these look like enumerables to me (see comments below)
const SYMBOLS = [
"ANSI_CHARSET",
"ARABIC_CHARSET",
"BALTIC_CHARSET",
"CHINESEBIG5_CHARSET",
"DEFAULT_CHARSET",
"EASTEUROPE_CHARSET",
"GB2312_CHARSET",
"GM_build_date",
"GM_runtime_version",
"GM_version",
"GREEK_CHARSET",
"HANGEUL_CHARSET",
"HEBREW_CHARSET",
"JOHAB_CHARSET",
"MAC_CHARSET",
"OEM_CHARSET",
"RUSSIAN_CHARSET",
"SHIFTJIS_CHARSET",
"SYMBOL_CHARSET",
"THAI_CHARSET",
"TURKISH_CHARSET",
"VIETNAMESE_CHARSET",
"achievement_achievement_info",
"achievement_filter_all_players",
"achievement_filter_favorites_only",
"achievement_filter_friends_only",
"achievement_friends_info",
"achievement_leaderboard_info",
"achievement_our_info",
"achievement_pic_loaded",
"achievement_show_achievement",
"achievement_show_bank",
"achievement_show_friend_picker",
"achievement_show_leaderboard",
"achievement_show_profile",
"achievement_show_purchase_prompt",
"achievement_show_ui",
"achievement_type_achievement_challenge",
"achievement_type_score_challenge",
"asset_font",
"asset_object",
"asset_path",
"asset_room",
"asset_script",
"asset_shader",
"asset_sound",
"asset_sprite",
"asset_tiles",
"asset_timeline",
"asset_unknown",
"audio_3d",
"audio_falloff_exponent_distance",
"audio_falloff_exponent_distance_clamped",
"audio_falloff_inverse_distance",
"audio_falloff_inverse_distance_clamped",
"audio_falloff_linear_distance",
"audio_falloff_linear_distance_clamped",
"audio_falloff_none",
"audio_mono",
"audio_new_system",
"audio_old_system",
"audio_stereo",
"bm_add",
"bm_complex",
"bm_dest_alpha",
"bm_dest_color",
"bm_dest_colour",
"bm_inv_dest_alpha",
"bm_inv_dest_color",
"bm_inv_dest_colour",
"bm_inv_src_alpha",
"bm_inv_src_color",
"bm_inv_src_colour",
"bm_max",
"bm_normal",
"bm_one",
"bm_src_alpha",
"bm_src_alpha_sat",
"bm_src_color",
"bm_src_colour",
"bm_subtract",
"bm_zero",
"browser_chrome",
"browser_edge",
"browser_firefox",
"browser_ie",
"browser_ie_mobile",
"browser_not_a_browser",
"browser_opera",
"browser_safari",
"browser_safari_mobile",
"browser_tizen",
"browser_unknown",
"browser_windows_store",
"buffer_bool",
"buffer_f16",
"buffer_f32",
"buffer_f64",
"buffer_fast",
"buffer_fixed",
"buffer_generalerror",
"buffer_grow",
"buffer_invalidtype",
"buffer_network",
"buffer_outofbounds",
"buffer_outofspace",
"buffer_s16",
"buffer_s32",
"buffer_s8",
"buffer_seek_end",
"buffer_seek_relative",
"buffer_seek_start",
"buffer_string",
"buffer_surface_copy",
"buffer_text",
"buffer_u16",
"buffer_u32",
"buffer_u64",
"buffer_u8",
"buffer_vbuffer",
"buffer_wrap",
"button_type",
"c_aqua",
"c_black",
"c_blue",
"c_dkgray",
"c_fuchsia",
"c_gray",
"c_green",
"c_lime",
"c_ltgray",
"c_maroon",
"c_navy",
"c_olive",
"c_orange",
"c_purple",
"c_red",
"c_silver",
"c_teal",
"c_white",
"c_yellow",
"cmpfunc_always",
"cmpfunc_equal",
"cmpfunc_greater",
"cmpfunc_greaterequal",
"cmpfunc_less",
"cmpfunc_lessequal",
"cmpfunc_never",
"cmpfunc_notequal",
"cr_appstart",
"cr_arrow",
"cr_beam",
"cr_cross",
"cr_default",
"cr_drag",
"cr_handpoint",
"cr_hourglass",
"cr_none",
"cr_size_all",
"cr_size_nesw",
"cr_size_ns",
"cr_size_nwse",
"cr_size_we",
"cr_uparrow",
"cull_clockwise",
"cull_counterclockwise",
"cull_noculling",
"device_emulator",
"device_ios_ipad",
"device_ios_ipad_retina",
"device_ios_iphone",
"device_ios_iphone5",
"device_ios_iphone6",
"device_ios_iphone6plus",
"device_ios_iphone_retina",
"device_ios_unknown",
"device_tablet",
"display_landscape",
"display_landscape_flipped",
"display_portrait",
"display_portrait_flipped",
"dll_cdecl",
"dll_stdcall",
"ds_type_grid",
"ds_type_list",
"ds_type_map",
"ds_type_priority",
"ds_type_queue",
"ds_type_stack",
"ef_cloud",
"ef_ellipse",
"ef_explosion",
"ef_firework",
"ef_flare",
"ef_rain",
"ef_ring",
"ef_smoke",
"ef_smokeup",
"ef_snow",
"ef_spark",
"ef_star",
// for example ev_ are types of events
"ev_alarm",
"ev_animation_end",
"ev_boundary",
"ev_cleanup",
"ev_close_button",
"ev_collision",
"ev_create",
"ev_destroy",
"ev_draw",
"ev_draw_begin",
"ev_draw_end",
"ev_draw_post",
"ev_draw_pre",
"ev_end_of_path",
"ev_game_end",
"ev_game_start",
"ev_gesture",
"ev_gesture_double_tap",
"ev_gesture_drag_end",
"ev_gesture_drag_start",
"ev_gesture_dragging",
"ev_gesture_flick",
"ev_gesture_pinch_end",
"ev_gesture_pinch_in",
"ev_gesture_pinch_out",
"ev_gesture_pinch_start",
"ev_gesture_rotate_end",
"ev_gesture_rotate_start",
"ev_gesture_rotating",
"ev_gesture_tap",
"ev_global_gesture_double_tap",
"ev_global_gesture_drag_end",
"ev_global_gesture_drag_start",
"ev_global_gesture_dragging",
"ev_global_gesture_flick",
"ev_global_gesture_pinch_end",
"ev_global_gesture_pinch_in",
"ev_global_gesture_pinch_out",
"ev_global_gesture_pinch_start",
"ev_global_gesture_rotate_end",
"ev_global_gesture_rotate_start",
"ev_global_gesture_rotating",
"ev_global_gesture_tap",
"ev_global_left_button",
"ev_global_left_press",
"ev_global_left_release",
"ev_global_middle_button",
"ev_global_middle_press",
"ev_global_middle_release",
"ev_global_right_button",
"ev_global_right_press",
"ev_global_right_release",
"ev_gui",
"ev_gui_begin",
"ev_gui_end",
"ev_joystick1_button1",
"ev_joystick1_button2",
"ev_joystick1_button3",
"ev_joystick1_button4",
"ev_joystick1_button5",
"ev_joystick1_button6",
"ev_joystick1_button7",
"ev_joystick1_button8",
"ev_joystick1_down",
"ev_joystick1_left",
"ev_joystick1_right",
"ev_joystick1_up",
"ev_joystick2_button1",
"ev_joystick2_button2",
"ev_joystick2_button3",
"ev_joystick2_button4",
"ev_joystick2_button5",
"ev_joystick2_button6",
"ev_joystick2_button7",
"ev_joystick2_button8",
"ev_joystick2_down",
"ev_joystick2_left",
"ev_joystick2_right",
"ev_joystick2_up",
"ev_keyboard",
"ev_keypress",
"ev_keyrelease",
"ev_left_button",
"ev_left_press",
"ev_left_release",
"ev_middle_button",
"ev_middle_press",
"ev_middle_release",
"ev_mouse",
"ev_mouse_enter",
"ev_mouse_leave",
"ev_mouse_wheel_down",
"ev_mouse_wheel_up",
"ev_no_button",
"ev_no_more_health",
"ev_no_more_lives",
"ev_other",
"ev_outside",
"ev_right_button",
"ev_right_press",
"ev_right_release",
"ev_room_end",
"ev_room_start",
"ev_step",
"ev_step_begin",
"ev_step_end",
"ev_step_normal",
"ev_trigger",
"ev_user0",
"ev_user1",
"ev_user2",
"ev_user3",
"ev_user4",
"ev_user5",
"ev_user6",
"ev_user7",
"ev_user8",
"ev_user9",
"ev_user10",
"ev_user11",
"ev_user12",
"ev_user13",
"ev_user14",
"ev_user15",
"fa_archive",
"fa_bottom",
"fa_center",
"fa_directory",
"fa_hidden",
"fa_left",
"fa_middle",
"fa_readonly",
"fa_right",
"fa_sysfile",
"fa_top",
"fa_volumeid",
"fb_login_default",
"fb_login_fallback_to_webview",
"fb_login_forcing_safari",
"fb_login_forcing_webview",
"fb_login_no_fallback_to_webview",
"fb_login_use_system_account",
"gamespeed_fps",
"gamespeed_microseconds",
"ge_lose",
"global",
"gp_axislh",
"gp_axislv",
"gp_axisrh",
"gp_axisrv",
"gp_face1",
"gp_face2",
"gp_face3",
"gp_face4",
"gp_padd",
"gp_padl",
"gp_padr",
"gp_padu",
"gp_select",
"gp_shoulderl",
"gp_shoulderlb",
"gp_shoulderr",
"gp_shoulderrb",
"gp_start",
"gp_stickl",
"gp_stickr",
"iap_available",
"iap_canceled",
"iap_ev_consume",
"iap_ev_product",
"iap_ev_purchase",
"iap_ev_restore",
"iap_ev_storeload",
"iap_failed",
"iap_purchased",
"iap_refunded",
"iap_status_available",
"iap_status_loading",
"iap_status_processing",
"iap_status_restoring",
"iap_status_unavailable",
"iap_status_uninitialised",
"iap_storeload_failed",
"iap_storeload_ok",
"iap_unavailable",
"input_type",
"kbv_autocapitalize_characters",
"kbv_autocapitalize_none",
"kbv_autocapitalize_sentences",
"kbv_autocapitalize_words",
"kbv_returnkey_continue",
"kbv_returnkey_default",
"kbv_returnkey_done",
"kbv_returnkey_emergency",
"kbv_returnkey_go",
"kbv_returnkey_google",
"kbv_returnkey_join",
"kbv_returnkey_next",
"kbv_returnkey_route",
"kbv_returnkey_search",
"kbv_returnkey_send",
"kbv_returnkey_yahoo",
"kbv_type_ascii",
"kbv_type_default",
"kbv_type_email",
"kbv_type_numbers",
"kbv_type_phone",
"kbv_type_phone_name",
"kbv_type_url",
"layerelementtype_background",
"layerelementtype_instance",
"layerelementtype_oldtilemap",
"layerelementtype_particlesystem",
"layerelementtype_sprite",
"layerelementtype_tile",
"layerelementtype_tilemap",
"layerelementtype_undefined",
"lb_disp_none",
"lb_disp_numeric",
"lb_disp_time_ms",
"lb_disp_time_sec",
"lb_sort_ascending",
"lb_sort_descending",
"lb_sort_none",
"leaderboard_type_number",
"leaderboard_type_time_mins_secs",
"lighttype_dir",
"lighttype_point",
"local",
"matrix_projection",
"matrix_view",
"matrix_world",
"mb_any",
"mb_left",
"mb_middle",
"mb_none",
"mb_right",
"mip_markedonly",
"mip_off",
"mip_on",
"network_config_connect_timeout",
"network_config_disable_reliable_udp",
"network_config_enable_reliable_udp",
"network_config_use_non_blocking_socket",
"network_socket_bluetooth",
"network_socket_tcp",
"network_socket_udp",
"network_type_connect",
"network_type_data",
"network_type_disconnect",
"network_type_non_blocking_connect",
"of_challen",
"of_challenge_tie",
"of_challenge_win",
"os_3ds",
"os_android",
"os_bb10",
"os_ios",
"os_linux",
"os_macosx",
"os_ps3",
"os_ps4",
"os_psvita",
"os_switch",
"os_symbian",
"os_tizen",
"os_tvos",
"os_unknown",
"os_uwp",
"os_wiiu",
"os_win32",
"os_win8native",
"os_windows",
"os_winphone",
"os_xbox360",
"os_xboxone",
"other",
"ov_achievements",
"ov_community",
"ov_friends",
"ov_gamegroup",
"ov_players",
"ov_settings",
"path_action_continue",
"path_action_restart",
"path_action_reverse",
"path_action_stop",
"phy_debug_render_aabb",
"phy_debug_render_collision_pairs",
"phy_debug_render_coms",
"phy_debug_render_core_shapes",
"phy_debug_render_joints",
"phy_debug_render_obb",
"phy_debug_render_shapes",
"phy_joint_anchor_1_x",
"phy_joint_anchor_1_y",
"phy_joint_anchor_2_x",
"phy_joint_anchor_2_y",
"phy_joint_angle",
"phy_joint_angle_limits",
"phy_joint_damping_ratio",
"phy_joint_frequency",
"phy_joint_length_1",
"phy_joint_length_2",
"phy_joint_lower_angle_limit",
"phy_joint_max_force",
"phy_joint_max_length",
"phy_joint_max_motor_force",
"phy_joint_max_motor_torque",
"phy_joint_max_torque",
"phy_joint_motor_force",
"phy_joint_motor_speed",
"phy_joint_motor_torque",
"phy_joint_reaction_force_x",
"phy_joint_reaction_force_y",
"phy_joint_reaction_torque",
"phy_joint_speed",
"phy_joint_translation",
"phy_joint_upper_angle_limit",
"phy_particle_data_flag_category",
"phy_particle_data_flag_color",
"phy_particle_data_flag_colour",
"phy_particle_data_flag_position",
"phy_particle_data_flag_typeflags",
"phy_particle_data_flag_velocity",
"phy_particle_flag_colormixing",
"phy_particle_flag_colourmixing",
"phy_particle_flag_elastic",
"phy_particle_flag_powder",
"phy_particle_flag_spring",
"phy_particle_flag_tensile",
"phy_particle_flag_viscous",
"phy_particle_flag_wall",
"phy_particle_flag_water",
"phy_particle_flag_zombie",
"phy_particle_group_flag_rigid",
"phy_particle_group_flag_solid",
"pi",
"pr_linelist",
"pr_linestrip",
"pr_pointlist",
"pr_trianglefan",
"pr_trianglelist",
"pr_trianglestrip",
"ps_distr_gaussian",
"ps_distr_invgaussian",
"ps_distr_linear",
"ps_shape_diamond",
"ps_shape_ellipse",
"ps_shape_line",
"ps_shape_rectangle",
"pt_shape_circle",
"pt_shape_cloud",
"pt_shape_disk",
"pt_shape_explosion",
"pt_shape_flare",
"pt_shape_line",
"pt_shape_pixel",
"pt_shape_ring",
"pt_shape_smoke",
"pt_shape_snow",
"pt_shape_spark",
"pt_shape_sphere",
"pt_shape_square",
"pt_shape_star",
"spritespeed_framespergameframe",
"spritespeed_framespersecond",
"text_type",
"tf_anisotropic",
"tf_linear",
"tf_point",
"tile_flip",
"tile_index_mask",
"tile_mirror",
"tile_rotate",
"timezone_local",
"timezone_utc",
"tm_countvsyncs",
"tm_sleep",
"ty_real",
"ty_string",
"ugc_filetype_community",
"ugc_filetype_microtrans",
"ugc_list_Favorited",
"ugc_list_Followed",
"ugc_list_Published",
"ugc_list_Subscribed",
"ugc_list_UsedOrPlayed",
"ugc_list_VotedDown",
"ugc_list_VotedOn",
"ugc_list_VotedUp",
"ugc_list_WillVoteLater",
"ugc_match_AllGuides",
"ugc_match_Artwork",
"ugc_match_Collections",
"ugc_match_ControllerBindings",
"ugc_match_IntegratedGuides",
"ugc_match_Items",
"ugc_match_Items_Mtx",
"ugc_match_Items_ReadyToUse",
"ugc_match_Screenshots",
"ugc_match_UsableInGame",
"ugc_match_Videos",
"ugc_match_WebGuides",
"ugc_query_AcceptedForGameRankedByAcceptanceDate",
"ugc_query_CreatedByFollowedUsersRankedByPublicationDate",
"ugc_query_CreatedByFriendsRankedByPublicationDate",
"ugc_query_FavoritedByFriendsRankedByPublicationDate",
"ugc_query_NotYetRated",
"ugc_query_RankedByNumTimesReported",
"ugc_query_RankedByPublicationDate",
"ugc_query_RankedByTextSearch",
"ugc_query_RankedByTotalVotesAsc",
"ugc_query_RankedByTrend",
"ugc_query_RankedByVote",
"ugc_query_RankedByVotesUp",
"ugc_result_success",
"ugc_sortorder_CreationOrderAsc",
"ugc_sortorder_CreationOrderDesc",
"ugc_sortorder_ForModeration",
"ugc_sortorder_LastUpdatedDesc",
"ugc_sortorder_SubscriptionDateDesc",
"ugc_sortorder_TitleAsc",
"ugc_sortorder_VoteScoreDesc",
"ugc_visibility_friends_only",
"ugc_visibility_private",
"ugc_visibility_public",
"vertex_type_color",
"vertex_type_colour",
"vertex_type_float1",
"vertex_type_float2",
"vertex_type_float3",
"vertex_type_float4",
"vertex_type_ubyte4",
"vertex_usage_binormal",
"vertex_usage_blendindices",
"vertex_usage_blendweight",
"vertex_usage_color",
"vertex_usage_colour",
"vertex_usage_depth",
"vertex_usage_fog",
"vertex_usage_normal",
"vertex_usage_position",
"vertex_usage_psize",
"vertex_usage_sample",
"vertex_usage_tangent",
"vertex_usage_texcoord",
"vertex_usage_textcoord",
"vk_add",
"vk_alt",
"vk_anykey",
"vk_backspace",
"vk_control",
"vk_decimal",
"vk_delete",
"vk_divide",
"vk_down",
"vk_end",
"vk_enter",
"vk_escape",
"vk_f1",
"vk_f2",
"vk_f3",
"vk_f4",
"vk_f5",
"vk_f6",
"vk_f7",
"vk_f8",
"vk_f9",
"vk_f10",
"vk_f11",
"vk_f12",
"vk_home",
"vk_insert",
"vk_lalt",
"vk_lcontrol",
"vk_left",
"vk_lshift",
"vk_multiply",
"vk_nokey",
"vk_numpad0",
"vk_numpad1",
"vk_numpad2",
"vk_numpad3",
"vk_numpad4",
"vk_numpad5",
"vk_numpad6",
"vk_numpad7",
"vk_numpad8",
"vk_numpad9",
"vk_pagedown",
"vk_pageup",
"vk_pause",
"vk_printscreen",
"vk_ralt",
"vk_rcontrol",
"vk_return",
"vk_right",
"vk_rshift",
"vk_shift",
"vk_space",
"vk_subtract",
"vk_tab",
"vk_up"
];
const LANGUAGE_VARIABLES = [
"alarm",
"application_surface",
"argument",
"argument0",
"argument1",
"argument2",
"argument3",
"argument4",
"argument5",
"argument6",
"argument7",
"argument8",
"argument9",
"argument10",
"argument11",
"argument12",
"argument13",
"argument14",
"argument15",
"argument_count",
"argument_relative",
"async_load",
"background_color",
"background_colour",
"background_showcolor",
"background_showcolour",
"bbox_bottom",
"bbox_left",
"bbox_right",
"bbox_top",
"browser_height",
"browser_width",
"caption_health",
"caption_lives",
"caption_score",
"current_day",
"current_hour",
"current_minute",
"current_month",
"current_second",
"current_time",
"current_weekday",
"current_year",
"cursor_sprite",
"debug_mode",
"delta_time",
"depth",
"direction",
"display_aa",
"error_last",
"error_occurred",
"event_action",
"event_data",
"event_number",
"event_object",
"event_type",
"fps",
"fps_real",
"friction",
"game_display_name",
"game_id",
"game_project_name",
"game_save_id",
"gamemaker_pro",
"gamemaker_registered",
"gamemaker_version",
"gravity",
"gravity_direction",
"health",
"hspeed",
"iap_data",
"id|0",
"image_alpha",
"image_angle",
"image_blend",
"image_index",
"image_number",
"image_speed",
"image_xscale",
"image_yscale",
"instance_count",
"instance_id",
"keyboard_key",
"keyboard_lastchar",
"keyboard_lastkey",
"keyboard_string",
"layer",
"lives",
"mask_index",
"mouse_button",
"mouse_lastbutton",
"mouse_x",
"mouse_y",
"object_index",
"os_browser",
"os_device",
"os_type",
"os_version",
"path_endaction",
"path_index",
"path_orientation",
"path_position",
"path_positionprevious",
"path_scale",
"path_speed",
"persistent",
"phy_active",
"phy_angular_damping",
"phy_angular_velocity",
"phy_bullet",
"phy_col_normal_x",
"phy_col_normal_y",
"phy_collision_points",
"phy_collision_x",
"phy_collision_y",
"phy_com_x",
"phy_com_y",
"phy_dynamic",
"phy_fixed_rotation",
"phy_inertia",
"phy_kinematic",
"phy_linear_damping",
"phy_linear_velocity_x",
"phy_linear_velocity_y",
"phy_mass",
"phy_position_x",
"phy_position_xprevious",
"phy_position_y",
"phy_position_yprevious",
"phy_rotation",
"phy_sleeping",
"phy_speed",
"phy_speed_x",
"phy_speed_y",
"program_directory",
"room",
"room_caption",
"room_first",
"room_height",
"room_last",
"room_persistent",
"room_speed",
"room_width",
"score",
"self",
"show_health",
"show_lives",
"show_score",
"solid",
"speed",
"sprite_height",
"sprite_index",
"sprite_width",
"sprite_xoffset",
"sprite_yoffset",
"temp_directory",
"timeline_index",
"timeline_loop",
"timeline_position",
"timeline_running",
"timeline_speed",
"view_angle",
"view_camera",
"view_current",
"view_enabled",
"view_hborder",
"view_hport",
"view_hspeed",
"view_hview",
"view_object",
"view_surface_id",
"view_vborder",
"view_visible",
"view_vspeed",
"view_wport",
"view_wview",
"view_xport",
"view_xview",
"view_yport",
"view_yview",
"visible",
"vspeed",
"webgl_enabled",
"working_directory",
"xprevious",
"xstart",
"x|0",
"yprevious",
"ystart",
"y|0"
];
return {
name: 'GML',
case_insensitive: false, // language is case-insensitive
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS,
literal: LITERALS,
symbol: SYMBOLS,
"variable.language": LANGUAGE_VARIABLES
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE
]
};
}
var gml_1 = gml;
/*
Language: Go
Author: Stephan Kountso aka StepLg <steplg@gmail.com>
Contributors: Evgeny Stepanischev <imbolk@gmail.com>
Description: Google go language (golang). For info about language
Website: http://golang.org/
Category: common, system
*/
function go(hljs) {
const LITERALS = [
"true",
"false",
"iota",
"nil"
];
const BUILT_INS = [
"append",
"cap",
"close",
"complex",
"copy",
"imag",
"len",
"make",
"new",
"panic",
"print",
"println",
"real",
"recover",
"delete"
];
const TYPES = [
"bool",
"byte",
"complex64",
"complex128",
"error",
"float32",
"float64",
"int8",
"int16",
"int32",
"int64",
"string",
"uint8",
"uint16",
"uint32",
"uint64",
"int",
"uint",
"uintptr",
"rune"
];
const KWS = [
"break",
"case",
"chan",
"const",
"continue",
"default",
"defer",
"else",
"fallthrough",
"for",
"func",
"go",
"goto",
"if",
"import",
"interface",
"map",
"package",
"range",
"return",
"select",
"struct",
"switch",
"type",
"var",
];
const KEYWORDS = {
keyword: KWS,
type: TYPES,
literal: LITERALS,
built_in: BUILT_INS
};
return {
name: 'Go',
aliases: [ 'golang' ],
keywords: KEYWORDS,
illegal: '</',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'string',
variants: [
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
{
begin: '`',
end: '`'
}
]
},
{
className: 'number',
variants: [
{
begin: hljs.C_NUMBER_RE + '[i]',
relevance: 1
},
hljs.C_NUMBER_MODE
]
},
{ begin: /:=/ // relevance booster
},
{
className: 'function',
beginKeywords: 'func',
end: '\\s*(\\{|$)',
excludeEnd: true,
contains: [
hljs.TITLE_MODE,
{
className: 'params',
begin: /\(/,
end: /\)/,
endsParent: true,
keywords: KEYWORDS,
illegal: /["']/
}
]
}
]
};
}
var go_1 = go;
/*
Language: Golo
Author: Philippe Charriere <ph.charriere@gmail.com>
Description: a lightweight dynamic language for the JVM
Website: http://golo-lang.org/
*/
function golo(hljs) {
const KEYWORDS = [
"println",
"readln",
"print",
"import",
"module",
"function",
"local",
"return",
"let",
"var",
"while",
"for",
"foreach",
"times",
"in",
"case",
"when",
"match",
"with",
"break",
"continue",
"augment",
"augmentation",
"each",
"find",
"filter",
"reduce",
"if",
"then",
"else",
"otherwise",
"try",
"catch",
"finally",
"raise",
"throw",
"orIfNull",
"DynamicObject|10",
"DynamicVariable",
"struct",
"Observable",
"map",
"set",
"vector",
"list",
"array"
];
return {
name: 'Golo',
keywords: {
keyword: KEYWORDS,
literal: [
"true",
"false",
"null"
]
},
contains: [
hljs.HASH_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '@[A-Za-z]+'
}
]
};
}
var golo_1 = golo;
/*
Language: Gradle
Description: Gradle is an open-source build automation tool focused on flexibility and performance.
Website: https://gradle.org
Author: Damian Mee <mee.damian@gmail.com>
*/
function gradle(hljs) {
const KEYWORDS = [
"task",
"project",
"allprojects",
"subprojects",
"artifacts",
"buildscript",
"configurations",
"dependencies",
"repositories",
"sourceSets",
"description",
"delete",
"from",
"into",
"include",
"exclude",
"source",
"classpath",
"destinationDir",
"includes",
"options",
"sourceCompatibility",
"targetCompatibility",
"group",
"flatDir",
"doLast",
"doFirst",
"flatten",
"todir",
"fromdir",
"ant",
"def",
"abstract",
"break",
"case",
"catch",
"continue",
"default",
"do",
"else",
"extends",
"final",
"finally",
"for",
"if",
"implements",
"instanceof",
"native",
"new",
"private",
"protected",
"public",
"return",
"static",
"switch",
"synchronized",
"throw",
"throws",
"transient",
"try",
"volatile",
"while",
"strictfp",
"package",
"import",
"false",
"null",
"super",
"this",
"true",
"antlrtask",
"checkstyle",
"codenarc",
"copy",
"boolean",
"byte",
"char",
"class",
"double",
"float",
"int",
"interface",
"long",
"short",
"void",
"compile",
"runTime",
"file",
"fileTree",
"abs",
"any",
"append",
"asList",
"asWritable",
"call",
"collect",
"compareTo",
"count",
"div",
"dump",
"each",
"eachByte",
"eachFile",
"eachLine",
"every",
"find",
"findAll",
"flatten",
"getAt",
"getErr",
"getIn",
"getOut",
"getText",
"grep",
"immutable",
"inject",
"inspect",
"intersect",
"invokeMethods",
"isCase",
"join",
"leftShift",
"minus",
"multiply",
"newInputStream",
"newOutputStream",
"newPrintWriter",
"newReader",
"newWriter",
"next",
"plus",
"pop",
"power",
"previous",
"print",
"println",
"push",
"putAt",
"read",
"readBytes",
"readLines",
"reverse",
"reverseEach",
"round",
"size",
"sort",
"splitEachLine",
"step",
"subMap",
"times",
"toInteger",
"toList",
"tokenize",
"upto",
"waitForOrKill",
"withPrintWriter",
"withReader",
"withStream",
"withWriter",
"withWriterAppend",
"write",
"writeLine"
];
return {
name: 'Gradle',
case_insensitive: true,
keywords: KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
hljs.REGEXP_MODE
]
};
}
var gradle_1 = gradle;
/*
Language: GraphQL
Author: John Foster (GH jf990), and others
Description: GraphQL is a query language for APIs
Category: web, common
*/
/** @type LanguageFn */
function graphql(hljs) {
const regex = hljs.regex;
const GQL_NAME = /[_A-Za-z][_0-9A-Za-z]*/;
return {
name: "GraphQL",
aliases: [ "gql" ],
case_insensitive: true,
disableAutodetect: false,
keywords: {
keyword: [
"query",
"mutation",
"subscription",
"type",
"input",
"schema",
"directive",
"interface",
"union",
"scalar",
"fragment",
"enum",
"on"
],
literal: [
"true",
"false",
"null"
]
},
contains: [
hljs.HASH_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
{
scope: "punctuation",
match: /[.]{3}/,
relevance: 0
},
{
scope: "punctuation",
begin: /[\!\(\)\:\=\[\]\{\|\}]{1}/,
relevance: 0
},
{
scope: "variable",
begin: /\$/,
end: /\W/,
excludeEnd: true,
relevance: 0
},
{
scope: "meta",
match: /@\w+/,
excludeEnd: true
},
{
scope: "symbol",
begin: regex.concat(GQL_NAME, regex.lookahead(/\s*:/)),
relevance: 0
}
],
illegal: [
/[;<']/,
/BEGIN/
]
};
}
var graphql_1 = graphql;
/*
Language: Groovy
Author: Guillaume Laforge <glaforge@gmail.com>
Description: Groovy programming language implementation inspired from Vsevolod's Java mode
Website: https://groovy-lang.org
*/
function variants(variants, obj = {}) {
obj.variants = variants;
return obj;
}
function groovy(hljs) {
const regex = hljs.regex;
const IDENT_RE = '[A-Za-z0-9_$]+';
const COMMENT = variants([
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.COMMENT(
'/\\*\\*',
'\\*/',
{
relevance: 0,
contains: [
{
// eat up @'s in emails to prevent them to be recognized as doctags
begin: /\w+@/,
relevance: 0
},
{
className: 'doctag',
begin: '@[A-Za-z]+'
}
]
}
)
]);
const REGEXP = {
className: 'regexp',
begin: /~?\/[^\/\n]+\//,
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const NUMBER = variants([
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE
]);
const STRING = variants([
{
begin: /"""/,
end: /"""/
},
{
begin: /'''/,
end: /'''/
},
{
begin: "\\$/",
end: "/\\$",
relevance: 10
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
],
{ className: "string" }
);
const CLASS_DEFINITION = {
match: [
/(class|interface|trait|enum|record|extends|implements)/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE
],
scope: {
1: "keyword",
3: "title.class",
}
};
const TYPES = [
"byte",
"short",
"char",
"int",
"long",
"boolean",
"float",
"double",
"void"
];
const KEYWORDS = [
// groovy specific keywords
"def",
"as",
"in",
"assert",
"trait",
// common keywords with Java
"abstract",
"static",
"volatile",
"transient",
"public",
"private",
"protected",
"synchronized",
"final",
"class",
"interface",
"enum",
"if",
"else",
"for",
"while",
"switch",
"case",
"break",
"default",
"continue",
"throw",
"throws",
"try",
"catch",
"finally",
"implements",
"extends",
"new",
"import",
"package",
"return",
"instanceof",
"var"
];
return {
name: 'Groovy',
keywords: {
"variable.language": 'this super',
literal: 'true false null',
type: TYPES,
keyword: KEYWORDS
},
contains: [
hljs.SHEBANG({
binary: "groovy",
relevance: 10
}),
COMMENT,
STRING,
REGEXP,
NUMBER,
CLASS_DEFINITION,
{
className: 'meta',
begin: '@[A-Za-z]+',
relevance: 0
},
{
// highlight map keys and named parameters as attrs
className: 'attr',
begin: IDENT_RE + '[ \t]*:',
relevance: 0
},
{
// catch middle element of the ternary operator
// to avoid highlight it as a label, named parameter, or map key
begin: /\?/,
end: /:/,
relevance: 0,
contains: [
COMMENT,
STRING,
REGEXP,
NUMBER,
'self'
]
},
{
// highlight labeled statements
className: 'symbol',
begin: '^[ \t]*' + regex.lookahead(IDENT_RE + ':'),
excludeBegin: true,
end: IDENT_RE + ':',
relevance: 0
}
],
illegal: /#|<\//
};
}
var groovy_1 = groovy;
/*
Language: HAML
Requires: ruby.js
Author: Dan Allen <dan.j.allen@gmail.com>
Website: http://haml.info
Category: template
*/
// TODO support filter tags like :javascript, support inline HTML
function haml(hljs) {
return {
name: 'HAML',
case_insensitive: true,
contains: [
{
className: 'meta',
begin: '^!!!( (5|1\\.1|Strict|Frameset|Basic|Mobile|RDFa|XML\\b.*))?$',
relevance: 10
},
// FIXME these comments should be allowed to span indented lines
hljs.COMMENT(
'^\\s*(!=#|=#|-#|/).*$',
null,
{ relevance: 0 }
),
{
begin: '^\\s*(-|=|!=)(?!#)',
end: /$/,
subLanguage: 'ruby',
excludeBegin: true,
excludeEnd: true
},
{
className: 'tag',
begin: '^\\s*%',
contains: [
{
className: 'selector-tag',
begin: '\\w+'
},
{
className: 'selector-id',
begin: '#[\\w-]+'
},
{
className: 'selector-class',
begin: '\\.[\\w-]+'
},
{
begin: /\{\s*/,
end: /\s*\}/,
contains: [
{
begin: ':\\w+\\s*=>',
end: ',\\s+',
returnBegin: true,
endsWithParent: true,
contains: [
{
className: 'attr',
begin: ':\\w+'
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
begin: '\\w+',
relevance: 0
}
]
}
]
},
{
begin: '\\(\\s*',
end: '\\s*\\)',
excludeEnd: true,
contains: [
{
begin: '\\w+\\s*=',
end: '\\s+',
returnBegin: true,
endsWithParent: true,
contains: [
{
className: 'attr',
begin: '\\w+',
relevance: 0
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
begin: '\\w+',
relevance: 0
}
]
}
]
}
]
},
{ begin: '^\\s*[=~]\\s*' },
{
begin: /#\{/,
end: /\}/,
subLanguage: 'ruby',
excludeBegin: true,
excludeEnd: true
}
]
};
}
var haml_1 = haml;
/*
Language: Handlebars
Requires: xml.js
Author: Robin Ward <robin.ward@gmail.com>
Description: Matcher for Handlebars as well as EmberJS additions.
Website: https://handlebarsjs.com
Category: template
*/
function handlebars(hljs) {
const regex = hljs.regex;
const BUILT_INS = {
$pattern: /[\w.\/]+/,
built_in: [
'action',
'bindattr',
'collection',
'component',
'concat',
'debugger',
'each',
'each-in',
'get',
'hash',
'if',
'in',
'input',
'link-to',
'loc',
'log',
'lookup',
'mut',
'outlet',
'partial',
'query-params',
'render',
'template',
'textarea',
'unbound',
'unless',
'view',
'with',
'yield'
]
};
const LITERALS = {
$pattern: /[\w.\/]+/,
literal: [
'true',
'false',
'undefined',
'null'
]
};
// as defined in https://handlebarsjs.com/guide/expressions.html#literal-segments
// this regex matches literal segments like ' abc ' or [ abc ] as well as helpers and paths
// like a/b, ./abc/cde, and abc.bcd
const DOUBLE_QUOTED_ID_REGEX = /""|"[^"]+"/;
const SINGLE_QUOTED_ID_REGEX = /''|'[^']+'/;
const BRACKET_QUOTED_ID_REGEX = /\[\]|\[[^\]]+\]/;
const PLAIN_ID_REGEX = /[^\s!"#%&'()*+,.\/;<=>@\[\\\]^`{|}~]+/;
const PATH_DELIMITER_REGEX = /(\.|\/)/;
const ANY_ID = regex.either(
DOUBLE_QUOTED_ID_REGEX,
SINGLE_QUOTED_ID_REGEX,
BRACKET_QUOTED_ID_REGEX,
PLAIN_ID_REGEX
);
const IDENTIFIER_REGEX = regex.concat(
regex.optional(/\.|\.\/|\//), // relative or absolute path
ANY_ID,
regex.anyNumberOfTimes(regex.concat(
PATH_DELIMITER_REGEX,
ANY_ID
))
);
// identifier followed by a equal-sign (without the equal sign)
const HASH_PARAM_REGEX = regex.concat(
'(',
BRACKET_QUOTED_ID_REGEX, '|',
PLAIN_ID_REGEX,
')(?==)'
);
const HELPER_NAME_OR_PATH_EXPRESSION = { begin: IDENTIFIER_REGEX };
const HELPER_PARAMETER = hljs.inherit(HELPER_NAME_OR_PATH_EXPRESSION, { keywords: LITERALS });
const SUB_EXPRESSION = {
begin: /\(/,
end: /\)/
// the "contains" is added below when all necessary sub-modes are defined
};
const HASH = {
// fka "attribute-assignment", parameters of the form 'key=value'
className: 'attr',
begin: HASH_PARAM_REGEX,
relevance: 0,
starts: {
begin: /=/,
end: /=/,
starts: { contains: [
hljs.NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
HELPER_PARAMETER,
SUB_EXPRESSION
] }
}
};
const BLOCK_PARAMS = {
// parameters of the form '{{#with x as | y |}}...{{/with}}'
begin: /as\s+\|/,
keywords: { keyword: 'as' },
end: /\|/,
contains: [
{
// define sub-mode in order to prevent highlighting of block-parameter named "as"
begin: /\w+/ }
]
};
const HELPER_PARAMETERS = {
contains: [
hljs.NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
BLOCK_PARAMS,
HASH,
HELPER_PARAMETER,
SUB_EXPRESSION
],
returnEnd: true
// the property "end" is defined through inheritance when the mode is used. If depends
// on the surrounding mode, but "endsWithParent" does not work here (i.e. it includes the
// end-token of the surrounding mode)
};
const SUB_EXPRESSION_CONTENTS = hljs.inherit(HELPER_NAME_OR_PATH_EXPRESSION, {
className: 'name',
keywords: BUILT_INS,
starts: hljs.inherit(HELPER_PARAMETERS, { end: /\)/ })
});
SUB_EXPRESSION.contains = [ SUB_EXPRESSION_CONTENTS ];
const OPENING_BLOCK_MUSTACHE_CONTENTS = hljs.inherit(HELPER_NAME_OR_PATH_EXPRESSION, {
keywords: BUILT_INS,
className: 'name',
starts: hljs.inherit(HELPER_PARAMETERS, { end: /\}\}/ })
});
const CLOSING_BLOCK_MUSTACHE_CONTENTS = hljs.inherit(HELPER_NAME_OR_PATH_EXPRESSION, {
keywords: BUILT_INS,
className: 'name'
});
const BASIC_MUSTACHE_CONTENTS = hljs.inherit(HELPER_NAME_OR_PATH_EXPRESSION, {
className: 'name',
keywords: BUILT_INS,
starts: hljs.inherit(HELPER_PARAMETERS, { end: /\}\}/ })
});
const ESCAPE_MUSTACHE_WITH_PRECEEDING_BACKSLASH = {
begin: /\\\{\{/,
skip: true
};
const PREVENT_ESCAPE_WITH_ANOTHER_PRECEEDING_BACKSLASH = {
begin: /\\\\(?=\{\{)/,
skip: true
};
return {
name: 'Handlebars',
aliases: [
'hbs',
'html.hbs',
'html.handlebars',
'htmlbars'
],
case_insensitive: true,
subLanguage: 'xml',
contains: [
ESCAPE_MUSTACHE_WITH_PRECEEDING_BACKSLASH,
PREVENT_ESCAPE_WITH_ANOTHER_PRECEEDING_BACKSLASH,
hljs.COMMENT(/\{\{!--/, /--\}\}/),
hljs.COMMENT(/\{\{!/, /\}\}/),
{
// open raw block "{{{{raw}}}} content not evaluated {{{{/raw}}}}"
className: 'template-tag',
begin: /\{\{\{\{(?!\/)/,
end: /\}\}\}\}/,
contains: [ OPENING_BLOCK_MUSTACHE_CONTENTS ],
starts: {
end: /\{\{\{\{\//,
returnEnd: true,
subLanguage: 'xml'
}
},
{
// close raw block
className: 'template-tag',
begin: /\{\{\{\{\//,
end: /\}\}\}\}/,
contains: [ CLOSING_BLOCK_MUSTACHE_CONTENTS ]
},
{
// open block statement
className: 'template-tag',
begin: /\{\{#/,
end: /\}\}/,
contains: [ OPENING_BLOCK_MUSTACHE_CONTENTS ]
},
{
className: 'template-tag',
begin: /\{\{(?=else\}\})/,
end: /\}\}/,
keywords: 'else'
},
{
className: 'template-tag',
begin: /\{\{(?=else if)/,
end: /\}\}/,
keywords: 'else if'
},
{
// closing block statement
className: 'template-tag',
begin: /\{\{\//,
end: /\}\}/,
contains: [ CLOSING_BLOCK_MUSTACHE_CONTENTS ]
},
{
// template variable or helper-call that is NOT html-escaped
className: 'template-variable',
begin: /\{\{\{/,
end: /\}\}\}/,
contains: [ BASIC_MUSTACHE_CONTENTS ]
},
{
// template variable or helper-call that is html-escaped
className: 'template-variable',
begin: /\{\{/,
end: /\}\}/,
contains: [ BASIC_MUSTACHE_CONTENTS ]
}
]
};
}
var handlebars_1 = handlebars;
/*
Language: Haskell
Author: Jeremy Hull <sourdrums@gmail.com>
Contributors: Zena Treep <zena.treep@gmail.com>
Website: https://www.haskell.org
Category: functional
*/
function haskell(hljs) {
/* See:
- https://www.haskell.org/onlinereport/lexemes.html
- https://downloads.haskell.org/ghc/9.0.1/docs/html/users_guide/exts/binary_literals.html
- https://downloads.haskell.org/ghc/9.0.1/docs/html/users_guide/exts/numeric_underscores.html
- https://downloads.haskell.org/ghc/9.0.1/docs/html/users_guide/exts/hex_float_literals.html
*/
const decimalDigits = '([0-9]_*)+';
const hexDigits = '([0-9a-fA-F]_*)+';
const binaryDigits = '([01]_*)+';
const octalDigits = '([0-7]_*)+';
const ascSymbol = '[!#$%&*+.\\/<=>?@\\\\^~-]';
const uniSymbol = '(\\p{S}|\\p{P})'; // Symbol or Punctuation
const special = '[(),;\\[\\]`|{}]';
const symbol = `(${ascSymbol}|(?!(${special}|[_:"']))${uniSymbol})`;
const COMMENT = { variants: [
// Double dash forms a valid comment only if it's not part of legal lexeme.
// See: Haskell 98 report: https://www.haskell.org/onlinereport/lexemes.html
//
// The commented code does the job, but we can't use negative lookbehind,
// due to poor support by Safari browser.
// > hljs.COMMENT(`(?<!${symbol})--+(?!${symbol})`, '$'),
// So instead, we'll add a no-markup rule before the COMMENT rule in the rules list
// to match the problematic infix operators that contain double dash.
hljs.COMMENT('--+', '$'),
hljs.COMMENT(
/\{-/,
/-\}/,
{ contains: [ 'self' ] }
)
] };
const PRAGMA = {
className: 'meta',
begin: /\{-#/,
end: /#-\}/
};
const PREPROCESSOR = {
className: 'meta',
begin: '^#',
end: '$'
};
const CONSTRUCTOR = {
className: 'type',
begin: '\\b[A-Z][\\w\']*', // TODO: other constructors (build-in, infix).
relevance: 0
};
const LIST = {
begin: '\\(',
end: '\\)',
illegal: '"',
contains: [
PRAGMA,
PREPROCESSOR,
{
className: 'type',
begin: '\\b[A-Z][\\w]*(\\((\\.\\.|,|\\w+)\\))?'
},
hljs.inherit(hljs.TITLE_MODE, { begin: '[_a-z][\\w\']*' }),
COMMENT
]
};
const RECORD = {
begin: /\{/,
end: /\}/,
contains: LIST.contains
};
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
// decimal floating-point-literal (subsumes decimal-literal)
{ match: `\\b(${decimalDigits})(\\.(${decimalDigits}))?` + `([eE][+-]?(${decimalDigits}))?\\b` },
// hexadecimal floating-point-literal (subsumes hexadecimal-literal)
{ match: `\\b0[xX]_*(${hexDigits})(\\.(${hexDigits}))?` + `([pP][+-]?(${decimalDigits}))?\\b` },
// octal-literal
{ match: `\\b0[oO](${octalDigits})\\b` },
// binary-literal
{ match: `\\b0[bB](${binaryDigits})\\b` }
]
};
return {
name: 'Haskell',
aliases: [ 'hs' ],
keywords:
'let in if then else case of where do module import hiding '
+ 'qualified type data newtype deriving class instance as default '
+ 'infix infixl infixr foreign export ccall stdcall cplusplus '
+ 'jvm dotnet safe unsafe family forall mdo proc rec',
unicodeRegex: true,
contains: [
// Top-level constructions.
{
beginKeywords: 'module',
end: 'where',
keywords: 'module where',
contains: [
LIST,
COMMENT
],
illegal: '\\W\\.|;'
},
{
begin: '\\bimport\\b',
end: '$',
keywords: 'import qualified as hiding',
contains: [
LIST,
COMMENT
],
illegal: '\\W\\.|;'
},
{
className: 'class',
begin: '^(\\s*)?(class|instance)\\b',
end: 'where',
keywords: 'class family instance where',
contains: [
CONSTRUCTOR,
LIST,
COMMENT
]
},
{
className: 'class',
begin: '\\b(data|(new)?type)\\b',
end: '$',
keywords: 'data family type newtype deriving',
contains: [
PRAGMA,
CONSTRUCTOR,
LIST,
RECORD,
COMMENT
]
},
{
beginKeywords: 'default',
end: '$',
contains: [
CONSTRUCTOR,
LIST,
COMMENT
]
},
{
beginKeywords: 'infix infixl infixr',
end: '$',
contains: [
hljs.C_NUMBER_MODE,
COMMENT
]
},
{
begin: '\\bforeign\\b',
end: '$',
keywords: 'foreign import export ccall stdcall cplusplus jvm '
+ 'dotnet safe unsafe',
contains: [
CONSTRUCTOR,
hljs.QUOTE_STRING_MODE,
COMMENT
]
},
{
className: 'meta',
begin: '#!\\/usr\\/bin\\/env\ runhaskell',
end: '$'
},
// "Whitespaces".
PRAGMA,
PREPROCESSOR,
// Literals and names.
// Single characters.
{
scope: 'string',
begin: /'(?=\\?.')/,
end: /'/,
contains: [
{
scope: 'char.escape',
match: /\\./,
},
]
},
hljs.QUOTE_STRING_MODE,
NUMBER,
CONSTRUCTOR,
hljs.inherit(hljs.TITLE_MODE, { begin: '^[_a-z][\\w\']*' }),
// No markup, prevents infix operators from being recognized as comments.
{ begin: `(?!-)${symbol}--+|--+(?!-)${symbol}`},
COMMENT,
{ // No markup, relevance booster
begin: '->|<-' }
]
};
}
var haskell_1 = haskell;
/*
Language: Haxe
Description: Haxe is an open source toolkit based on a modern, high level, strictly typed programming language.
Author: Christopher Kaster <ikasoki@gmail.com> (Based on the actionscript.js language file by Alexander Myadzel)
Contributors: Kenton Hamaluik <kentonh@gmail.com>
Website: https://haxe.org
*/
function haxe(hljs) {
const IDENT_RE = '[a-zA-Z_$][a-zA-Z0-9_$]*';
// C_NUMBER_RE with underscores and literal suffixes
const HAXE_NUMBER_RE = /(-?)(\b0[xX][a-fA-F0-9_]+|(\b\d+(\.[\d_]*)?|\.[\d_]+)(([eE][-+]?\d+)|i32|u32|i64|f64)?)/;
const HAXE_BASIC_TYPES = 'Int Float String Bool Dynamic Void Array ';
return {
name: 'Haxe',
aliases: [ 'hx' ],
keywords: {
keyword: 'abstract break case cast catch continue default do dynamic else enum extern '
+ 'final for function here if import in inline is macro never new override package private get set '
+ 'public return static super switch this throw trace try typedef untyped using var while '
+ HAXE_BASIC_TYPES,
built_in:
'trace this',
literal:
'true false null _'
},
contains: [
{
className: 'string', // interpolate-able strings
begin: '\'',
end: '\'',
contains: [
hljs.BACKSLASH_ESCAPE,
{
className: 'subst', // interpolation
begin: /\$\{/,
end: /\}/
},
{
className: 'subst', // interpolation
begin: /\$/,
end: /\W\}/
}
]
},
hljs.QUOTE_STRING_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'number',
begin: HAXE_NUMBER_RE,
relevance: 0
},
{
className: 'variable',
begin: "\\$" + IDENT_RE,
},
{
className: 'meta', // compiler meta
begin: /@:?/,
end: /\(|$/,
excludeEnd: true,
},
{
className: 'meta', // compiler conditionals
begin: '#',
end: '$',
keywords: { keyword: 'if else elseif end error' }
},
{
className: 'type', // function types
begin: /:[ \t]*/,
end: /[^A-Za-z0-9_ \t\->]/,
excludeBegin: true,
excludeEnd: true,
relevance: 0
},
{
className: 'type', // types
begin: /:[ \t]*/,
end: /\W/,
excludeBegin: true,
excludeEnd: true
},
{
className: 'type', // instantiation
begin: /new */,
end: /\W/,
excludeBegin: true,
excludeEnd: true
},
{
className: 'title.class', // enums
beginKeywords: 'enum',
end: /\{/,
contains: [ hljs.TITLE_MODE ]
},
{
className: 'title.class', // abstracts
begin: '\\babstract\\b(?=\\s*' + hljs.IDENT_RE + '\\s*\\()',
end: /[\{$]/,
contains: [
{
className: 'type',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true
},
{
className: 'type',
begin: /from +/,
end: /\W/,
excludeBegin: true,
excludeEnd: true
},
{
className: 'type',
begin: /to +/,
end: /\W/,
excludeBegin: true,
excludeEnd: true
},
hljs.TITLE_MODE
],
keywords: { keyword: 'abstract from to' }
},
{
className: 'title.class', // classes
begin: /\b(class|interface) +/,
end: /[\{$]/,
excludeEnd: true,
keywords: 'class interface',
contains: [
{
className: 'keyword',
begin: /\b(extends|implements) +/,
keywords: 'extends implements',
contains: [
{
className: 'type',
begin: hljs.IDENT_RE,
relevance: 0
}
]
},
hljs.TITLE_MODE
]
},
{
className: 'title.function',
beginKeywords: 'function',
end: /\(/,
excludeEnd: true,
illegal: /\S/,
contains: [ hljs.TITLE_MODE ]
}
],
illegal: /<\//
};
}
var haxe_1 = haxe;
/*
Language: HSP
Author: prince <MC.prince.0203@gmail.com>
Website: https://en.wikipedia.org/wiki/Hot_Soup_Processor
Category: scripting
*/
function hsp(hljs) {
return {
name: 'HSP',
case_insensitive: true,
keywords: {
$pattern: /[\w._]+/,
keyword: 'goto gosub return break repeat loop continue wait await dim sdim foreach dimtype dup dupptr end stop newmod delmod mref run exgoto on mcall assert logmes newlab resume yield onexit onerror onkey onclick oncmd exist delete mkdir chdir dirlist bload bsave bcopy memfile if else poke wpoke lpoke getstr chdpm memexpand memcpy memset notesel noteadd notedel noteload notesave randomize noteunsel noteget split strrep setease button chgdisp exec dialog mmload mmplay mmstop mci pset pget syscolor mes print title pos circle cls font sysfont objsize picload color palcolor palette redraw width gsel gcopy gzoom gmode bmpsave hsvcolor getkey listbox chkbox combox input mesbox buffer screen bgscr mouse objsel groll line clrobj boxf objprm objmode stick grect grotate gsquare gradf objimage objskip objenable celload celdiv celput newcom querycom delcom cnvstow comres axobj winobj sendmsg comevent comevarg sarrayconv callfunc cnvwtos comevdisp libptr system hspstat hspver stat cnt err strsize looplev sublev iparam wparam lparam refstr refdval int rnd strlen length length2 length3 length4 vartype gettime peek wpeek lpeek varptr varuse noteinfo instr abs limit getease str strmid strf getpath strtrim sin cos tan atan sqrt double absf expf logf limitf powf geteasef mousex mousey mousew hwnd hinstance hdc ginfo objinfo dirinfo sysinfo thismod __hspver__ __hsp30__ __date__ __time__ __line__ __file__ _debug __hspdef__ and or xor not screen_normal screen_palette screen_hide screen_fixedsize screen_tool screen_frame gmode_gdi gmode_mem gmode_rgb0 gmode_alpha gmode_rgb0alpha gmode_add gmode_sub gmode_pixela ginfo_mx ginfo_my ginfo_act ginfo_sel ginfo_wx1 ginfo_wy1 ginfo_wx2 ginfo_wy2 ginfo_vx ginfo_vy ginfo_sizex ginfo_sizey ginfo_winx ginfo_winy ginfo_mesx ginfo_mesy ginfo_r ginfo_g ginfo_b ginfo_paluse ginfo_dispx ginfo_dispy ginfo_cx ginfo_cy ginfo_intid ginfo_newid ginfo_sx ginfo_sy objinfo_mode objinfo_bmscr objinfo_hwnd notemax notesize dir_cur dir_exe dir_win dir_sys dir_cmdline dir_desktop dir_mydoc dir_tv font_normal font_bold font_italic font_underline font_strikeout font_antialias objmode_normal objmode_guifont objmode_usefont gsquare_grad msgothic msmincho do until while wend for next _break _continue switch case default swbreak swend ddim ldim alloc m_pi rad2deg deg2rad ease_linear ease_quad_in ease_quad_out ease_quad_inout ease_cubic_in ease_cubic_out ease_cubic_inout ease_quartic_in ease_quartic_out ease_quartic_inout ease_bounce_in ease_bounce_out ease_bounce_inout ease_shake_in ease_shake_out ease_shake_inout ease_loop'
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
{
// multi-line string
className: 'string',
begin: /\{"/,
end: /"\}/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
hljs.COMMENT(';', '$', { relevance: 0 }),
{
// pre-processor
className: 'meta',
begin: '#',
end: '$',
keywords: { keyword: 'addion cfunc cmd cmpopt comfunc const defcfunc deffunc define else endif enum epack func global if ifdef ifndef include modcfunc modfunc modinit modterm module pack packopt regcmd runtime undef usecom uselib' },
contains: [
hljs.inherit(hljs.QUOTE_STRING_MODE, { className: 'string' }),
hljs.NUMBER_MODE,
hljs.C_NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
// label
className: 'symbol',
begin: '^\\*(\\w+|@)'
},
hljs.NUMBER_MODE,
hljs.C_NUMBER_MODE
]
};
}
var hsp_1 = hsp;
/*
Language: HTTP
Description: HTTP request and response headers with automatic body highlighting
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Category: protocols, web
Website: https://developer.mozilla.org/en-US/docs/Web/HTTP/Overview
*/
function http(hljs) {
const regex = hljs.regex;
const VERSION = 'HTTP/([32]|1\\.[01])';
const HEADER_NAME = /[A-Za-z][A-Za-z0-9-]*/;
const HEADER = {
className: 'attribute',
begin: regex.concat('^', HEADER_NAME, '(?=\\:\\s)'),
starts: { contains: [
{
className: "punctuation",
begin: /: /,
relevance: 0,
starts: {
end: '$',
relevance: 0
}
}
] }
};
const HEADERS_AND_BODY = [
HEADER,
{
begin: '\\n\\n',
starts: {
subLanguage: [],
endsWithParent: true
}
}
];
return {
name: 'HTTP',
aliases: [ 'https' ],
illegal: /\S/,
contains: [
// response
{
begin: '^(?=' + VERSION + " \\d{3})",
end: /$/,
contains: [
{
className: "meta",
begin: VERSION
},
{
className: 'number',
begin: '\\b\\d{3}\\b'
}
],
starts: {
end: /\b\B/,
illegal: /\S/,
contains: HEADERS_AND_BODY
}
},
// request
{
begin: '(?=^[A-Z]+ (.*?) ' + VERSION + '$)',
end: /$/,
contains: [
{
className: 'string',
begin: ' ',
end: ' ',
excludeBegin: true,
excludeEnd: true
},
{
className: "meta",
begin: VERSION
},
{
className: 'keyword',
begin: '[A-Z]+'
}
],
starts: {
end: /\b\B/,
illegal: /\S/,
contains: HEADERS_AND_BODY
}
},
// to allow headers to work even without a preamble
hljs.inherit(HEADER, { relevance: 0 })
]
};
}
var http_1 = http;
/*
Language: Hy
Description: Hy is a wonderful dialect of Lisp thats embedded in Python.
Author: Sergey Sobko <s.sobko@profitware.ru>
Website: http://docs.hylang.org/en/stable/
Category: lisp
*/
function hy(hljs) {
const SYMBOLSTART = 'a-zA-Z_\\-!.?+*=<>&#\'';
const SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';
const keywords = {
$pattern: SYMBOL_RE,
built_in:
// keywords
'!= % %= & &= * ** **= *= *map '
+ '+ += , --build-class-- --import-- -= . / // //= '
+ '/= < << <<= <= = > >= >> >>= '
+ '@ @= ^ ^= abs accumulate all and any ap-compose '
+ 'ap-dotimes ap-each ap-each-while ap-filter ap-first ap-if ap-last ap-map ap-map-when ap-pipe '
+ 'ap-reduce ap-reject apply as-> ascii assert assoc bin break butlast '
+ 'callable calling-module-name car case cdr chain chr coll? combinations compile '
+ 'compress cond cons cons? continue count curry cut cycle dec '
+ 'def default-method defclass defmacro defmacro-alias defmacro/g! defmain defmethod defmulti defn '
+ 'defn-alias defnc defnr defreader defseq del delattr delete-route dict-comp dir '
+ 'disassemble dispatch-reader-macro distinct divmod do doto drop drop-last drop-while empty? '
+ 'end-sequence eval eval-and-compile eval-when-compile even? every? except exec filter first '
+ 'flatten float? fn fnc fnr for for* format fraction genexpr '
+ 'gensym get getattr global globals group-by hasattr hash hex id '
+ 'identity if if* if-not if-python2 import in inc input instance? '
+ 'integer integer-char? integer? interleave interpose is is-coll is-cons is-empty is-even '
+ 'is-every is-float is-instance is-integer is-integer-char is-iterable is-iterator is-keyword is-neg is-none '
+ 'is-not is-numeric is-odd is-pos is-string is-symbol is-zero isinstance islice issubclass '
+ 'iter iterable? iterate iterator? keyword keyword? lambda last len let '
+ 'lif lif-not list* list-comp locals loop macro-error macroexpand macroexpand-1 macroexpand-all '
+ 'map max merge-with method-decorator min multi-decorator multicombinations name neg? next '
+ 'none? nonlocal not not-in not? nth numeric? oct odd? open '
+ 'or ord partition permutations pos? post-route postwalk pow prewalk print '
+ 'product profile/calls profile/cpu put-route quasiquote quote raise range read read-str '
+ 'recursive-replace reduce remove repeat repeatedly repr require rest round route '
+ 'route-with-methods rwm second seq set-comp setattr setv some sorted string '
+ 'string? sum switch symbol? take take-nth take-while tee try unless '
+ 'unquote unquote-splicing vars walk when while with with* with-decorator with-gensyms '
+ 'xi xor yield yield-from zero? zip zip-longest | |= ~'
};
const SIMPLE_NUMBER_RE = '[-+]?\\d+(\\.\\d+)?';
const SYMBOL = {
begin: SYMBOL_RE,
relevance: 0
};
const NUMBER = {
className: 'number',
begin: SIMPLE_NUMBER_RE,
relevance: 0
};
const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null });
const COMMENT = hljs.COMMENT(
';',
'$',
{ relevance: 0 }
);
const LITERAL = {
className: 'literal',
begin: /\b([Tt]rue|[Ff]alse|nil|None)\b/
};
const COLLECTION = {
begin: '[\\[\\{]',
end: '[\\]\\}]',
relevance: 0
};
const HINT = {
className: 'comment',
begin: '\\^' + SYMBOL_RE
};
const HINT_COL = hljs.COMMENT('\\^\\{', '\\}');
const KEY = {
className: 'symbol',
begin: '[:]{1,2}' + SYMBOL_RE
};
const LIST = {
begin: '\\(',
end: '\\)'
};
const BODY = {
endsWithParent: true,
relevance: 0
};
const NAME = {
className: 'name',
relevance: 0,
keywords: keywords,
begin: SYMBOL_RE,
starts: BODY
};
const DEFAULT_CONTAINS = [
LIST,
STRING,
HINT,
HINT_COL,
COMMENT,
KEY,
COLLECTION,
NUMBER,
LITERAL,
SYMBOL
];
LIST.contains = [
hljs.COMMENT('comment', ''),
NAME,
BODY
];
BODY.contains = DEFAULT_CONTAINS;
COLLECTION.contains = DEFAULT_CONTAINS;
return {
name: 'Hy',
aliases: [ 'hylang' ],
illegal: /\S/,
contains: [
hljs.SHEBANG(),
LIST,
STRING,
HINT,
HINT_COL,
COMMENT,
KEY,
COLLECTION,
NUMBER,
LITERAL
]
};
}
var hy_1 = hy;
/*
Language: Inform 7
Author: Bruno Dias <bruno.r.dias@gmail.com>
Description: Language definition for Inform 7, a DSL for writing parser interactive fiction.
Website: http://inform7.com
*/
function inform7(hljs) {
const START_BRACKET = '\\[';
const END_BRACKET = '\\]';
return {
name: 'Inform 7',
aliases: [ 'i7' ],
case_insensitive: true,
keywords: {
// Some keywords more or less unique to I7, for relevance.
keyword:
// kind:
'thing room person man woman animal container '
+ 'supporter backdrop door '
// characteristic:
+ 'scenery open closed locked inside gender '
// verb:
+ 'is are say understand '
// misc keyword:
+ 'kind of rule' },
contains: [
{
className: 'string',
begin: '"',
end: '"',
relevance: 0,
contains: [
{
className: 'subst',
begin: START_BRACKET,
end: END_BRACKET
}
]
},
{
className: 'section',
begin: /^(Volume|Book|Part|Chapter|Section|Table)\b/,
end: '$'
},
{
// Rule definition
// This is here for relevance.
begin: /^(Check|Carry out|Report|Instead of|To|Rule|When|Before|After)\b/,
end: ':',
contains: [
{
// Rule name
begin: '\\(This',
end: '\\)'
}
]
},
{
className: 'comment',
begin: START_BRACKET,
end: END_BRACKET,
contains: [ 'self' ]
}
]
};
}
var inform7_1 = inform7;
/*
Language: TOML, also INI
Description: TOML aims to be a minimal configuration file format that's easy to read due to obvious semantics.
Contributors: Guillaume Gomez <guillaume1.gomez@gmail.com>
Category: common, config
Website: https://github.com/toml-lang/toml
*/
function ini(hljs) {
const regex = hljs.regex;
const NUMBERS = {
className: 'number',
relevance: 0,
variants: [
{ begin: /([+-]+)?[\d]+_[\d_]+/ },
{ begin: hljs.NUMBER_RE }
]
};
const COMMENTS = hljs.COMMENT();
COMMENTS.variants = [
{
begin: /;/,
end: /$/
},
{
begin: /#/,
end: /$/
}
];
const VARIABLES = {
className: 'variable',
variants: [
{ begin: /\$[\w\d"][\w\d_]*/ },
{ begin: /\$\{(.*?)\}/ }
]
};
const LITERALS = {
className: 'literal',
begin: /\bon|off|true|false|yes|no\b/
};
const STRINGS = {
className: "string",
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
{
begin: "'''",
end: "'''",
relevance: 10
},
{
begin: '"""',
end: '"""',
relevance: 10
},
{
begin: '"',
end: '"'
},
{
begin: "'",
end: "'"
}
]
};
const ARRAY = {
begin: /\[/,
end: /\]/,
contains: [
COMMENTS,
LITERALS,
VARIABLES,
STRINGS,
NUMBERS,
'self'
],
relevance: 0
};
const BARE_KEY = /[A-Za-z0-9_-]+/;
const QUOTED_KEY_DOUBLE_QUOTE = /"(\\"|[^"])*"/;
const QUOTED_KEY_SINGLE_QUOTE = /'[^']*'/;
const ANY_KEY = regex.either(
BARE_KEY, QUOTED_KEY_DOUBLE_QUOTE, QUOTED_KEY_SINGLE_QUOTE
);
const DOTTED_KEY = regex.concat(
ANY_KEY, '(\\s*\\.\\s*', ANY_KEY, ')*',
regex.lookahead(/\s*=\s*[^#\s]/)
);
return {
name: 'TOML, also INI',
aliases: [ 'toml' ],
case_insensitive: true,
illegal: /\S/,
contains: [
COMMENTS,
{
className: 'section',
begin: /\[+/,
end: /\]+/
},
{
begin: DOTTED_KEY,
className: 'attr',
starts: {
end: /$/,
contains: [
COMMENTS,
ARRAY,
LITERALS,
VARIABLES,
STRINGS,
NUMBERS
]
}
}
]
};
}
var ini_1 = ini;
/*
Language: IRPF90
Author: Anthony Scemama <scemama@irsamc.ups-tlse.fr>
Description: IRPF90 is an open-source Fortran code generator
Website: http://irpf90.ups-tlse.fr
Category: scientific
*/
/** @type LanguageFn */
function irpf90(hljs) {
const regex = hljs.regex;
const PARAMS = {
className: 'params',
begin: '\\(',
end: '\\)'
};
// regex in both fortran and irpf90 should match
const OPTIONAL_NUMBER_SUFFIX = /(_[a-z_\d]+)?/;
const OPTIONAL_NUMBER_EXP = /([de][+-]?\d+)?/;
const NUMBER = {
className: 'number',
variants: [
{ begin: regex.concat(/\b\d+/, /\.(\d*)/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) },
{ begin: regex.concat(/\b\d+/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) },
{ begin: regex.concat(/\.\d+/, OPTIONAL_NUMBER_EXP, OPTIONAL_NUMBER_SUFFIX) }
],
relevance: 0
};
const F_KEYWORDS = {
literal: '.False. .True.',
keyword: 'kind do while private call intrinsic where elsewhere '
+ 'type endtype endmodule endselect endinterface end enddo endif if forall endforall only contains default return stop then '
+ 'public subroutine|10 function program .and. .or. .not. .le. .eq. .ge. .gt. .lt. '
+ 'goto save else use module select case '
+ 'access blank direct exist file fmt form formatted iostat name named nextrec number opened rec recl sequential status unformatted unit '
+ 'continue format pause cycle exit '
+ 'c_null_char c_alert c_backspace c_form_feed flush wait decimal round iomsg '
+ 'synchronous nopass non_overridable pass protected volatile abstract extends import '
+ 'non_intrinsic value deferred generic final enumerator class associate bind enum '
+ 'c_int c_short c_long c_long_long c_signed_char c_size_t c_int8_t c_int16_t c_int32_t c_int64_t c_int_least8_t c_int_least16_t '
+ 'c_int_least32_t c_int_least64_t c_int_fast8_t c_int_fast16_t c_int_fast32_t c_int_fast64_t c_intmax_t C_intptr_t c_float c_double '
+ 'c_long_double c_float_complex c_double_complex c_long_double_complex c_bool c_char c_null_ptr c_null_funptr '
+ 'c_new_line c_carriage_return c_horizontal_tab c_vertical_tab iso_c_binding c_loc c_funloc c_associated c_f_pointer '
+ 'c_ptr c_funptr iso_fortran_env character_storage_size error_unit file_storage_size input_unit iostat_end iostat_eor '
+ 'numeric_storage_size output_unit c_f_procpointer ieee_arithmetic ieee_support_underflow_control '
+ 'ieee_get_underflow_mode ieee_set_underflow_mode newunit contiguous recursive '
+ 'pad position action delim readwrite eor advance nml interface procedure namelist include sequence elemental pure '
+ 'integer real character complex logical dimension allocatable|10 parameter '
+ 'external implicit|10 none double precision assign intent optional pointer '
+ 'target in out common equivalence data '
// IRPF90 special keywords
+ 'begin_provider &begin_provider end_provider begin_shell end_shell begin_template end_template subst assert touch '
+ 'soft_touch provide no_dep free irp_if irp_else irp_endif irp_write irp_read',
built_in: 'alog alog10 amax0 amax1 amin0 amin1 amod cabs ccos cexp clog csin csqrt dabs dacos dasin datan datan2 dcos dcosh ddim dexp dint '
+ 'dlog dlog10 dmax1 dmin1 dmod dnint dsign dsin dsinh dsqrt dtan dtanh float iabs idim idint idnint ifix isign max0 max1 min0 min1 sngl '
+ 'algama cdabs cdcos cdexp cdlog cdsin cdsqrt cqabs cqcos cqexp cqlog cqsin cqsqrt dcmplx dconjg derf derfc dfloat dgamma dimag dlgama '
+ 'iqint qabs qacos qasin qatan qatan2 qcmplx qconjg qcos qcosh qdim qerf qerfc qexp qgamma qimag qlgama qlog qlog10 qmax1 qmin1 qmod '
+ 'qnint qsign qsin qsinh qsqrt qtan qtanh abs acos aimag aint anint asin atan atan2 char cmplx conjg cos cosh exp ichar index int log '
+ 'log10 max min nint sign sin sinh sqrt tan tanh print write dim lge lgt lle llt mod nullify allocate deallocate '
+ 'adjustl adjustr all allocated any associated bit_size btest ceiling count cshift date_and_time digits dot_product '
+ 'eoshift epsilon exponent floor fraction huge iand ibclr ibits ibset ieor ior ishft ishftc lbound len_trim matmul '
+ 'maxexponent maxloc maxval merge minexponent minloc minval modulo mvbits nearest pack present product '
+ 'radix random_number random_seed range repeat reshape rrspacing scale scan selected_int_kind selected_real_kind '
+ 'set_exponent shape size spacing spread sum system_clock tiny transpose trim ubound unpack verify achar iachar transfer '
+ 'dble entry dprod cpu_time command_argument_count get_command get_command_argument get_environment_variable is_iostat_end '
+ 'ieee_arithmetic ieee_support_underflow_control ieee_get_underflow_mode ieee_set_underflow_mode '
+ 'is_iostat_eor move_alloc new_line selected_char_kind same_type_as extends_type_of '
+ 'acosh asinh atanh bessel_j0 bessel_j1 bessel_jn bessel_y0 bessel_y1 bessel_yn erf erfc erfc_scaled gamma log_gamma hypot norm2 '
+ 'atomic_define atomic_ref execute_command_line leadz trailz storage_size merge_bits '
+ 'bge bgt ble blt dshiftl dshiftr findloc iall iany iparity image_index lcobound ucobound maskl maskr '
+ 'num_images parity popcnt poppar shifta shiftl shiftr this_image '
// IRPF90 special built_ins
+ 'IRP_ALIGN irp_here'
};
return {
name: 'IRPF90',
case_insensitive: true,
keywords: F_KEYWORDS,
illegal: /\/\*/,
contains: [
hljs.inherit(hljs.APOS_STRING_MODE, {
className: 'string',
relevance: 0
}),
hljs.inherit(hljs.QUOTE_STRING_MODE, {
className: 'string',
relevance: 0
}),
{
className: 'function',
beginKeywords: 'subroutine function program',
illegal: '[${=\\n]',
contains: [
hljs.UNDERSCORE_TITLE_MODE,
PARAMS
]
},
hljs.COMMENT('!', '$', { relevance: 0 }),
hljs.COMMENT('begin_doc', 'end_doc', { relevance: 10 }),
NUMBER
]
};
}
var irpf90_1 = irpf90;
/*
Language: ISBL
Author: Dmitriy Tarasov <dimatar@gmail.com>
Description: built-in language DIRECTUM
Category: enterprise
*/
function isbl(hljs) {
// Определение идентификаторов
const UNDERSCORE_IDENT_RE = "[A-Za-zА-Яа-яёЁ_!][A-Za-zА-Яа-яёЁ_0-9]*";
// Определение имен функций
const FUNCTION_NAME_IDENT_RE = "[A-Za-zА-Яа-яёЁ_][A-Za-zА-Яа-яёЁ_0-9]*";
// keyword : ключевые слова
const KEYWORD =
"and и else иначе endexcept endfinally endforeach конецвсе endif конецесли endwhile конецпока "
+ "except exitfor finally foreach все if если in в not не or или try while пока ";
// SYSRES Constants
const sysres_constants =
"SYSRES_CONST_ACCES_RIGHT_TYPE_EDIT "
+ "SYSRES_CONST_ACCES_RIGHT_TYPE_FULL "
+ "SYSRES_CONST_ACCES_RIGHT_TYPE_VIEW "
+ "SYSRES_CONST_ACCESS_MODE_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_NO_ACCESS_VIEW "
+ "SYSRES_CONST_ACCESS_NO_ACCESS_VIEW_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_ADD_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_ADD_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_CHANGE_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_CHANGE_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_DELETE_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_DELETE_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_EXECUTE_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_EXECUTE_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_NO_ACCESS_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_NO_ACCESS_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_RATIFY_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_RATIFY_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_VIEW "
+ "SYSRES_CONST_ACCESS_RIGHTS_VIEW_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_VIEW_REQUISITE_CODE "
+ "SYSRES_CONST_ACCESS_RIGHTS_VIEW_REQUISITE_YES_CODE "
+ "SYSRES_CONST_ACCESS_TYPE_CHANGE "
+ "SYSRES_CONST_ACCESS_TYPE_CHANGE_CODE "
+ "SYSRES_CONST_ACCESS_TYPE_EXISTS "
+ "SYSRES_CONST_ACCESS_TYPE_EXISTS_CODE "
+ "SYSRES_CONST_ACCESS_TYPE_FULL "
+ "SYSRES_CONST_ACCESS_TYPE_FULL_CODE "
+ "SYSRES_CONST_ACCESS_TYPE_VIEW "
+ "SYSRES_CONST_ACCESS_TYPE_VIEW_CODE "
+ "SYSRES_CONST_ACTION_TYPE_ABORT "
+ "SYSRES_CONST_ACTION_TYPE_ACCEPT "
+ "SYSRES_CONST_ACTION_TYPE_ACCESS_RIGHTS "
+ "SYSRES_CONST_ACTION_TYPE_ADD_ATTACHMENT "
+ "SYSRES_CONST_ACTION_TYPE_CHANGE_CARD "
+ "SYSRES_CONST_ACTION_TYPE_CHANGE_KIND "
+ "SYSRES_CONST_ACTION_TYPE_CHANGE_STORAGE "
+ "SYSRES_CONST_ACTION_TYPE_CONTINUE "
+ "SYSRES_CONST_ACTION_TYPE_COPY "
+ "SYSRES_CONST_ACTION_TYPE_CREATE "
+ "SYSRES_CONST_ACTION_TYPE_CREATE_VERSION "
+ "SYSRES_CONST_ACTION_TYPE_DELETE "
+ "SYSRES_CONST_ACTION_TYPE_DELETE_ATTACHMENT "
+ "SYSRES_CONST_ACTION_TYPE_DELETE_VERSION "
+ "SYSRES_CONST_ACTION_TYPE_DISABLE_DELEGATE_ACCESS_RIGHTS "
+ "SYSRES_CONST_ACTION_TYPE_ENABLE_DELEGATE_ACCESS_RIGHTS "
+ "SYSRES_CONST_ACTION_TYPE_ENCRYPTION_BY_CERTIFICATE "
+ "SYSRES_CONST_ACTION_TYPE_ENCRYPTION_BY_CERTIFICATE_AND_PASSWORD "
+ "SYSRES_CONST_ACTION_TYPE_ENCRYPTION_BY_PASSWORD "
+ "SYSRES_CONST_ACTION_TYPE_EXPORT_WITH_LOCK "
+ "SYSRES_CONST_ACTION_TYPE_EXPORT_WITHOUT_LOCK "
+ "SYSRES_CONST_ACTION_TYPE_IMPORT_WITH_UNLOCK "
+ "SYSRES_CONST_ACTION_TYPE_IMPORT_WITHOUT_UNLOCK "
+ "SYSRES_CONST_ACTION_TYPE_LIFE_CYCLE_STAGE "
+ "SYSRES_CONST_ACTION_TYPE_LOCK "
+ "SYSRES_CONST_ACTION_TYPE_LOCK_FOR_SERVER "
+ "SYSRES_CONST_ACTION_TYPE_LOCK_MODIFY "
+ "SYSRES_CONST_ACTION_TYPE_MARK_AS_READED "
+ "SYSRES_CONST_ACTION_TYPE_MARK_AS_UNREADED "
+ "SYSRES_CONST_ACTION_TYPE_MODIFY "
+ "SYSRES_CONST_ACTION_TYPE_MODIFY_CARD "
+ "SYSRES_CONST_ACTION_TYPE_MOVE_TO_ARCHIVE "
+ "SYSRES_CONST_ACTION_TYPE_OFF_ENCRYPTION "
+ "SYSRES_CONST_ACTION_TYPE_PASSWORD_CHANGE "
+ "SYSRES_CONST_ACTION_TYPE_PERFORM "
+ "SYSRES_CONST_ACTION_TYPE_RECOVER_FROM_LOCAL_COPY "
+ "SYSRES_CONST_ACTION_TYPE_RESTART "
+ "SYSRES_CONST_ACTION_TYPE_RESTORE_FROM_ARCHIVE "
+ "SYSRES_CONST_ACTION_TYPE_REVISION "
+ "SYSRES_CONST_ACTION_TYPE_SEND_BY_MAIL "
+ "SYSRES_CONST_ACTION_TYPE_SIGN "
+ "SYSRES_CONST_ACTION_TYPE_START "
+ "SYSRES_CONST_ACTION_TYPE_UNLOCK "
+ "SYSRES_CONST_ACTION_TYPE_UNLOCK_FROM_SERVER "
+ "SYSRES_CONST_ACTION_TYPE_VERSION_STATE "
+ "SYSRES_CONST_ACTION_TYPE_VERSION_VISIBILITY "
+ "SYSRES_CONST_ACTION_TYPE_VIEW "
+ "SYSRES_CONST_ACTION_TYPE_VIEW_SHADOW_COPY "
+ "SYSRES_CONST_ACTION_TYPE_WORKFLOW_DESCRIPTION_MODIFY "
+ "SYSRES_CONST_ACTION_TYPE_WRITE_HISTORY "
+ "SYSRES_CONST_ACTIVE_VERSION_STATE_PICK_VALUE "
+ "SYSRES_CONST_ADD_REFERENCE_MODE_NAME "
+ "SYSRES_CONST_ADDITION_REQUISITE_CODE "
+ "SYSRES_CONST_ADDITIONAL_PARAMS_REQUISITE_CODE "
+ "SYSRES_CONST_ADITIONAL_JOB_END_DATE_REQUISITE_NAME "
+ "SYSRES_CONST_ADITIONAL_JOB_READ_REQUISITE_NAME "
+ "SYSRES_CONST_ADITIONAL_JOB_START_DATE_REQUISITE_NAME "
+ "SYSRES_CONST_ADITIONAL_JOB_STATE_REQUISITE_NAME "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_ADDING_USER_TO_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_ADDING_USER_TO_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_COMP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_COMP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_USER_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_USER_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DATABASE_USER_CREATION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DATABASE_USER_CREATION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DATABASE_USER_DELETION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DATABASE_USER_DELETION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_COMP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_COMP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_USER_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_USER_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_USER_FROM_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_DELETION_USER_FROM_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_FILTERER_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_FILTERER_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_FILTERER_RESTRICTION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_FILTERER_RESTRICTION_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_PRIVILEGE_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_PRIVILEGE_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_RIGHTS_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_GRANTING_RIGHTS_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_IS_MAIN_SERVER_CHANGED_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_IS_MAIN_SERVER_CHANGED_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_IS_PUBLIC_CHANGED_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_IS_PUBLIC_CHANGED_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_FILTERER_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_FILTERER_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_FILTERER_RESTRICTION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_FILTERER_RESTRICTION_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_PRIVILEGE_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_PRIVILEGE_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_RIGHTS_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_REMOVING_RIGHTS_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_SERVER_LOGIN_CREATION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_SERVER_LOGIN_CREATION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_SERVER_LOGIN_DELETION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_SERVER_LOGIN_DELETION_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_CATEGORY_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_CATEGORY_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_COMP_TITLE_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_COMP_TITLE_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_FULL_NAME_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_FULL_NAME_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_PARENT_GROUP_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_PARENT_GROUP_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_AUTH_TYPE_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_AUTH_TYPE_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_LOGIN_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_LOGIN_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_STATUS_ACTION "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_UPDATING_USER_STATUS_ACTION_CODE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_USER_PASSWORD_CHANGE "
+ "SYSRES_CONST_ADMINISTRATION_HISTORY_USER_PASSWORD_CHANGE_ACTION "
+ "SYSRES_CONST_ALL_ACCEPT_CONDITION_RUS "
+ "SYSRES_CONST_ALL_USERS_GROUP "
+ "SYSRES_CONST_ALL_USERS_GROUP_NAME "
+ "SYSRES_CONST_ALL_USERS_SERVER_GROUP_NAME "
+ "SYSRES_CONST_ALLOWED_ACCESS_TYPE_CODE "
+ "SYSRES_CONST_ALLOWED_ACCESS_TYPE_NAME "
+ "SYSRES_CONST_APP_VIEWER_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_APPROVING_SIGNATURE_NAME "
+ "SYSRES_CONST_APPROVING_SIGNATURE_REQUISITE_CODE "
+ "SYSRES_CONST_ASSISTANT_SUBSTITUE_TYPE "
+ "SYSRES_CONST_ASSISTANT_SUBSTITUE_TYPE_CODE "
+ "SYSRES_CONST_ATTACH_TYPE_COMPONENT_TOKEN "
+ "SYSRES_CONST_ATTACH_TYPE_DOC "
+ "SYSRES_CONST_ATTACH_TYPE_EDOC "
+ "SYSRES_CONST_ATTACH_TYPE_FOLDER "
+ "SYSRES_CONST_ATTACH_TYPE_JOB "
+ "SYSRES_CONST_ATTACH_TYPE_REFERENCE "
+ "SYSRES_CONST_ATTACH_TYPE_TASK "
+ "SYSRES_CONST_AUTH_ENCODED_PASSWORD "
+ "SYSRES_CONST_AUTH_ENCODED_PASSWORD_CODE "
+ "SYSRES_CONST_AUTH_NOVELL "
+ "SYSRES_CONST_AUTH_PASSWORD "
+ "SYSRES_CONST_AUTH_PASSWORD_CODE "
+ "SYSRES_CONST_AUTH_WINDOWS "
+ "SYSRES_CONST_AUTHENTICATING_SIGNATURE_NAME "
+ "SYSRES_CONST_AUTHENTICATING_SIGNATURE_REQUISITE_CODE "
+ "SYSRES_CONST_AUTO_ENUM_METHOD_FLAG "
+ "SYSRES_CONST_AUTO_NUMERATION_CODE "
+ "SYSRES_CONST_AUTO_STRONG_ENUM_METHOD_FLAG "
+ "SYSRES_CONST_AUTOTEXT_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_AUTOTEXT_TEXT_REQUISITE_CODE "
+ "SYSRES_CONST_AUTOTEXT_USAGE_ALL "
+ "SYSRES_CONST_AUTOTEXT_USAGE_ALL_CODE "
+ "SYSRES_CONST_AUTOTEXT_USAGE_SIGN "
+ "SYSRES_CONST_AUTOTEXT_USAGE_SIGN_CODE "
+ "SYSRES_CONST_AUTOTEXT_USAGE_WORK "
+ "SYSRES_CONST_AUTOTEXT_USAGE_WORK_CODE "
+ "SYSRES_CONST_AUTOTEXT_USE_ANYWHERE_CODE "
+ "SYSRES_CONST_AUTOTEXT_USE_ON_SIGNING_CODE "
+ "SYSRES_CONST_AUTOTEXT_USE_ON_WORK_CODE "
+ "SYSRES_CONST_BEGIN_DATE_REQUISITE_CODE "
+ "SYSRES_CONST_BLACK_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_BLUE_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_BTN_PART "
+ "SYSRES_CONST_CALCULATED_ROLE_TYPE_CODE "
+ "SYSRES_CONST_CALL_TYPE_VARIABLE_BUTTON_VALUE "
+ "SYSRES_CONST_CALL_TYPE_VARIABLE_PROGRAM_VALUE "
+ "SYSRES_CONST_CANCEL_MESSAGE_FUNCTION_RESULT "
+ "SYSRES_CONST_CARD_PART "
+ "SYSRES_CONST_CARD_REFERENCE_MODE_NAME "
+ "SYSRES_CONST_CERTIFICATE_TYPE_REQUISITE_ENCRYPT_VALUE "
+ "SYSRES_CONST_CERTIFICATE_TYPE_REQUISITE_SIGN_AND_ENCRYPT_VALUE "
+ "SYSRES_CONST_CERTIFICATE_TYPE_REQUISITE_SIGN_VALUE "
+ "SYSRES_CONST_CHECK_PARAM_VALUE_DATE_PARAM_TYPE "
+ "SYSRES_CONST_CHECK_PARAM_VALUE_FLOAT_PARAM_TYPE "
+ "SYSRES_CONST_CHECK_PARAM_VALUE_INTEGER_PARAM_TYPE "
+ "SYSRES_CONST_CHECK_PARAM_VALUE_PICK_PARAM_TYPE "
+ "SYSRES_CONST_CHECK_PARAM_VALUE_REEFRENCE_PARAM_TYPE "
+ "SYSRES_CONST_CLOSED_RECORD_FLAG_VALUE_FEMININE "
+ "SYSRES_CONST_CLOSED_RECORD_FLAG_VALUE_MASCULINE "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_ADMIN "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_DEVELOPER "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_DOCS "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_EDOC_CARDS "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_EXTERNAL_EXECUTABLE "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_OTHER "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_REFERENCE "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_REPORT "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_SCRIPT "
+ "SYSRES_CONST_CODE_COMPONENT_TYPE_URL "
+ "SYSRES_CONST_CODE_REQUISITE_ACCESS "
+ "SYSRES_CONST_CODE_REQUISITE_CODE "
+ "SYSRES_CONST_CODE_REQUISITE_COMPONENT "
+ "SYSRES_CONST_CODE_REQUISITE_DESCRIPTION "
+ "SYSRES_CONST_CODE_REQUISITE_EXCLUDE_COMPONENT "
+ "SYSRES_CONST_CODE_REQUISITE_RECORD "
+ "SYSRES_CONST_COMMENT_REQ_CODE "
+ "SYSRES_CONST_COMMON_SETTINGS_REQUISITE_CODE "
+ "SYSRES_CONST_COMP_CODE_GRD "
+ "SYSRES_CONST_COMPONENT_GROUP_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_COMPONENT_TYPE_ADMIN_COMPONENTS "
+ "SYSRES_CONST_COMPONENT_TYPE_DEVELOPER_COMPONENTS "
+ "SYSRES_CONST_COMPONENT_TYPE_DOCS "
+ "SYSRES_CONST_COMPONENT_TYPE_EDOC_CARDS "
+ "SYSRES_CONST_COMPONENT_TYPE_EDOCS "
+ "SYSRES_CONST_COMPONENT_TYPE_EXTERNAL_EXECUTABLE "
+ "SYSRES_CONST_COMPONENT_TYPE_OTHER "
+ "SYSRES_CONST_COMPONENT_TYPE_REFERENCE_TYPES "
+ "SYSRES_CONST_COMPONENT_TYPE_REFERENCES "
+ "SYSRES_CONST_COMPONENT_TYPE_REPORTS "
+ "SYSRES_CONST_COMPONENT_TYPE_SCRIPTS "
+ "SYSRES_CONST_COMPONENT_TYPE_URL "
+ "SYSRES_CONST_COMPONENTS_REMOTE_SERVERS_VIEW_CODE "
+ "SYSRES_CONST_CONDITION_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_CONST_FIRM_STATUS_COMMON "
+ "SYSRES_CONST_CONST_FIRM_STATUS_INDIVIDUAL "
+ "SYSRES_CONST_CONST_NEGATIVE_VALUE "
+ "SYSRES_CONST_CONST_POSITIVE_VALUE "
+ "SYSRES_CONST_CONST_SERVER_STATUS_DONT_REPLICATE "
+ "SYSRES_CONST_CONST_SERVER_STATUS_REPLICATE "
+ "SYSRES_CONST_CONTENTS_REQUISITE_CODE "
+ "SYSRES_CONST_DATA_TYPE_BOOLEAN "
+ "SYSRES_CONST_DATA_TYPE_DATE "
+ "SYSRES_CONST_DATA_TYPE_FLOAT "
+ "SYSRES_CONST_DATA_TYPE_INTEGER "
+ "SYSRES_CONST_DATA_TYPE_PICK "
+ "SYSRES_CONST_DATA_TYPE_REFERENCE "
+ "SYSRES_CONST_DATA_TYPE_STRING "
+ "SYSRES_CONST_DATA_TYPE_TEXT "
+ "SYSRES_CONST_DATA_TYPE_VARIANT "
+ "SYSRES_CONST_DATE_CLOSE_REQ_CODE "
+ "SYSRES_CONST_DATE_FORMAT_DATE_ONLY_CHAR "
+ "SYSRES_CONST_DATE_OPEN_REQ_CODE "
+ "SYSRES_CONST_DATE_REQUISITE "
+ "SYSRES_CONST_DATE_REQUISITE_CODE "
+ "SYSRES_CONST_DATE_REQUISITE_NAME "
+ "SYSRES_CONST_DATE_REQUISITE_TYPE "
+ "SYSRES_CONST_DATE_TYPE_CHAR "
+ "SYSRES_CONST_DATETIME_FORMAT_VALUE "
+ "SYSRES_CONST_DEA_ACCESS_RIGHTS_ACTION_CODE "
+ "SYSRES_CONST_DESCRIPTION_LOCALIZE_ID_REQUISITE_CODE "
+ "SYSRES_CONST_DESCRIPTION_REQUISITE_CODE "
+ "SYSRES_CONST_DET1_PART "
+ "SYSRES_CONST_DET2_PART "
+ "SYSRES_CONST_DET3_PART "
+ "SYSRES_CONST_DET4_PART "
+ "SYSRES_CONST_DET5_PART "
+ "SYSRES_CONST_DET6_PART "
+ "SYSRES_CONST_DETAIL_DATASET_KEY_REQUISITE_CODE "
+ "SYSRES_CONST_DETAIL_PICK_REQUISITE_CODE "
+ "SYSRES_CONST_DETAIL_REQ_CODE "
+ "SYSRES_CONST_DO_NOT_USE_ACCESS_TYPE_CODE "
+ "SYSRES_CONST_DO_NOT_USE_ACCESS_TYPE_NAME "
+ "SYSRES_CONST_DO_NOT_USE_ON_VIEW_ACCESS_TYPE_CODE "
+ "SYSRES_CONST_DO_NOT_USE_ON_VIEW_ACCESS_TYPE_NAME "
+ "SYSRES_CONST_DOCUMENT_STORAGES_CODE "
+ "SYSRES_CONST_DOCUMENT_TEMPLATES_TYPE_NAME "
+ "SYSRES_CONST_DOUBLE_REQUISITE_CODE "
+ "SYSRES_CONST_EDITOR_CLOSE_FILE_OBSERV_TYPE_CODE "
+ "SYSRES_CONST_EDITOR_CLOSE_PROCESS_OBSERV_TYPE_CODE "
+ "SYSRES_CONST_EDITOR_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_APPLICATION_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_CREATE_SEVERAL_PROCESSES_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_EXTENSION_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_OBSERVER_BY_PROCESS_TYPE "
+ "SYSRES_CONST_EDITORS_REFERENCE_CODE "
+ "SYSRES_CONST_EDITORS_REPLACE_SPEC_CHARS_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_USE_PLUGINS_REQUISITE_CODE "
+ "SYSRES_CONST_EDITORS_VIEW_DOCUMENT_OPENED_TO_EDIT_CODE "
+ "SYSRES_CONST_EDOC_CARD_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_CARD_TYPES_LINK_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_CERTIFICATE_AND_PASSWORD_ENCODE_CODE "
+ "SYSRES_CONST_EDOC_CERTIFICATE_ENCODE_CODE "
+ "SYSRES_CONST_EDOC_DATE_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_KIND_REFERENCE_CODE "
+ "SYSRES_CONST_EDOC_KINDS_BY_TEMPLATE_ACTION_CODE "
+ "SYSRES_CONST_EDOC_MANAGE_ACCESS_CODE "
+ "SYSRES_CONST_EDOC_NONE_ENCODE_CODE "
+ "SYSRES_CONST_EDOC_NUMBER_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_PASSWORD_ENCODE_CODE "
+ "SYSRES_CONST_EDOC_READONLY_ACCESS_CODE "
+ "SYSRES_CONST_EDOC_SHELL_LIFE_TYPE_VIEW_VALUE "
+ "SYSRES_CONST_EDOC_SIZE_RESTRICTION_PRIORITY_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_CHECK_ACCESS_RIGHTS_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_COMPUTER_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_DATABASE_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_EDIT_IN_STORAGE_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_LOCAL_PATH_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_STORAGE_SHARED_SOURCE_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_TEMPLATE_REQUISITE_CODE "
+ "SYSRES_CONST_EDOC_TYPES_REFERENCE_CODE "
+ "SYSRES_CONST_EDOC_VERSION_ACTIVE_STAGE_CODE "
+ "SYSRES_CONST_EDOC_VERSION_DESIGN_STAGE_CODE "
+ "SYSRES_CONST_EDOC_VERSION_OBSOLETE_STAGE_CODE "
+ "SYSRES_CONST_EDOC_WRITE_ACCES_CODE "
+ "SYSRES_CONST_EDOCUMENT_CARD_REQUISITES_REFERENCE_CODE_SELECTED_REQUISITE "
+ "SYSRES_CONST_ENCODE_CERTIFICATE_TYPE_CODE "
+ "SYSRES_CONST_END_DATE_REQUISITE_CODE "
+ "SYSRES_CONST_ENUMERATION_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_EXECUTE_ACCESS_RIGHTS_TYPE_CODE "
+ "SYSRES_CONST_EXECUTIVE_FILE_STORAGE_TYPE "
+ "SYSRES_CONST_EXIST_CONST "
+ "SYSRES_CONST_EXIST_VALUE "
+ "SYSRES_CONST_EXPORT_LOCK_TYPE_ASK "
+ "SYSRES_CONST_EXPORT_LOCK_TYPE_WITH_LOCK "
+ "SYSRES_CONST_EXPORT_LOCK_TYPE_WITHOUT_LOCK "
+ "SYSRES_CONST_EXPORT_VERSION_TYPE_ASK "
+ "SYSRES_CONST_EXPORT_VERSION_TYPE_LAST "
+ "SYSRES_CONST_EXPORT_VERSION_TYPE_LAST_ACTIVE "
+ "SYSRES_CONST_EXTENSION_REQUISITE_CODE "
+ "SYSRES_CONST_FILTER_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_FILTER_REQUISITE_CODE "
+ "SYSRES_CONST_FILTER_TYPE_COMMON_CODE "
+ "SYSRES_CONST_FILTER_TYPE_COMMON_NAME "
+ "SYSRES_CONST_FILTER_TYPE_USER_CODE "
+ "SYSRES_CONST_FILTER_TYPE_USER_NAME "
+ "SYSRES_CONST_FILTER_VALUE_REQUISITE_NAME "
+ "SYSRES_CONST_FLOAT_NUMBER_FORMAT_CHAR "
+ "SYSRES_CONST_FLOAT_REQUISITE_TYPE "
+ "SYSRES_CONST_FOLDER_AUTHOR_VALUE "
+ "SYSRES_CONST_FOLDER_KIND_ANY_OBJECTS "
+ "SYSRES_CONST_FOLDER_KIND_COMPONENTS "
+ "SYSRES_CONST_FOLDER_KIND_EDOCS "
+ "SYSRES_CONST_FOLDER_KIND_JOBS "
+ "SYSRES_CONST_FOLDER_KIND_TASKS "
+ "SYSRES_CONST_FOLDER_TYPE_COMMON "
+ "SYSRES_CONST_FOLDER_TYPE_COMPONENT "
+ "SYSRES_CONST_FOLDER_TYPE_FAVORITES "
+ "SYSRES_CONST_FOLDER_TYPE_INBOX "
+ "SYSRES_CONST_FOLDER_TYPE_OUTBOX "
+ "SYSRES_CONST_FOLDER_TYPE_QUICK_LAUNCH "
+ "SYSRES_CONST_FOLDER_TYPE_SEARCH "
+ "SYSRES_CONST_FOLDER_TYPE_SHORTCUTS "
+ "SYSRES_CONST_FOLDER_TYPE_USER "
+ "SYSRES_CONST_FROM_DICTIONARY_ENUM_METHOD_FLAG "
+ "SYSRES_CONST_FULL_SUBSTITUTE_TYPE "
+ "SYSRES_CONST_FULL_SUBSTITUTE_TYPE_CODE "
+ "SYSRES_CONST_FUNCTION_CANCEL_RESULT "
+ "SYSRES_CONST_FUNCTION_CATEGORY_SYSTEM "
+ "SYSRES_CONST_FUNCTION_CATEGORY_USER "
+ "SYSRES_CONST_FUNCTION_FAILURE_RESULT "
+ "SYSRES_CONST_FUNCTION_SAVE_RESULT "
+ "SYSRES_CONST_GENERATED_REQUISITE "
+ "SYSRES_CONST_GREEN_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_GROUP_ACCOUNT_TYPE_VALUE_CODE "
+ "SYSRES_CONST_GROUP_CATEGORY_NORMAL_CODE "
+ "SYSRES_CONST_GROUP_CATEGORY_NORMAL_NAME "
+ "SYSRES_CONST_GROUP_CATEGORY_SERVICE_CODE "
+ "SYSRES_CONST_GROUP_CATEGORY_SERVICE_NAME "
+ "SYSRES_CONST_GROUP_COMMON_CATEGORY_FIELD_VALUE "
+ "SYSRES_CONST_GROUP_FULL_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_GROUP_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_GROUP_RIGHTS_T_REQUISITE_CODE "
+ "SYSRES_CONST_GROUP_SERVER_CODES_REQUISITE_CODE "
+ "SYSRES_CONST_GROUP_SERVER_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_GROUP_SERVICE_CATEGORY_FIELD_VALUE "
+ "SYSRES_CONST_GROUP_USER_REQUISITE_CODE "
+ "SYSRES_CONST_GROUPS_REFERENCE_CODE "
+ "SYSRES_CONST_GROUPS_REQUISITE_CODE "
+ "SYSRES_CONST_HIDDEN_MODE_NAME "
+ "SYSRES_CONST_HIGH_LVL_REQUISITE_CODE "
+ "SYSRES_CONST_HISTORY_ACTION_CREATE_CODE "
+ "SYSRES_CONST_HISTORY_ACTION_DELETE_CODE "
+ "SYSRES_CONST_HISTORY_ACTION_EDIT_CODE "
+ "SYSRES_CONST_HOUR_CHAR "
+ "SYSRES_CONST_ID_REQUISITE_CODE "
+ "SYSRES_CONST_IDSPS_REQUISITE_CODE "
+ "SYSRES_CONST_IMAGE_MODE_COLOR "
+ "SYSRES_CONST_IMAGE_MODE_GREYSCALE "
+ "SYSRES_CONST_IMAGE_MODE_MONOCHROME "
+ "SYSRES_CONST_IMPORTANCE_HIGH "
+ "SYSRES_CONST_IMPORTANCE_LOW "
+ "SYSRES_CONST_IMPORTANCE_NORMAL "
+ "SYSRES_CONST_IN_DESIGN_VERSION_STATE_PICK_VALUE "
+ "SYSRES_CONST_INCOMING_WORK_RULE_TYPE_CODE "
+ "SYSRES_CONST_INT_REQUISITE "
+ "SYSRES_CONST_INT_REQUISITE_TYPE "
+ "SYSRES_CONST_INTEGER_NUMBER_FORMAT_CHAR "
+ "SYSRES_CONST_INTEGER_TYPE_CHAR "
+ "SYSRES_CONST_IS_GENERATED_REQUISITE_NEGATIVE_VALUE "
+ "SYSRES_CONST_IS_PUBLIC_ROLE_REQUISITE_CODE "
+ "SYSRES_CONST_IS_REMOTE_USER_NEGATIVE_VALUE "
+ "SYSRES_CONST_IS_REMOTE_USER_POSITIVE_VALUE "
+ "SYSRES_CONST_IS_STORED_REQUISITE_NEGATIVE_VALUE "
+ "SYSRES_CONST_IS_STORED_REQUISITE_STORED_VALUE "
+ "SYSRES_CONST_ITALIC_LIFE_CYCLE_STAGE_DRAW_STYLE "
+ "SYSRES_CONST_JOB_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_JOB_KIND_CONTROL_JOB "
+ "SYSRES_CONST_JOB_KIND_JOB "
+ "SYSRES_CONST_JOB_KIND_NOTICE "
+ "SYSRES_CONST_JOB_STATE_ABORTED "
+ "SYSRES_CONST_JOB_STATE_COMPLETE "
+ "SYSRES_CONST_JOB_STATE_WORKING "
+ "SYSRES_CONST_KIND_REQUISITE_CODE "
+ "SYSRES_CONST_KIND_REQUISITE_NAME "
+ "SYSRES_CONST_KINDS_CREATE_SHADOW_COPIES_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_DEFAULT_EDOC_LIFE_STAGE_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_EDOC_ALL_TEPLATES_ALLOWED_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_EDOC_ALLOW_LIFE_CYCLE_STAGE_CHANGING_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_EDOC_ALLOW_MULTIPLE_ACTIVE_VERSIONS_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_EDOC_SHARE_ACCES_RIGHTS_BY_DEFAULT_CODE "
+ "SYSRES_CONST_KINDS_EDOC_TEMPLATE_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_EDOC_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_KINDS_SIGNERS_REQUISITES_CODE "
+ "SYSRES_CONST_KOD_INPUT_TYPE "
+ "SYSRES_CONST_LAST_UPDATE_DATE_REQUISITE_CODE "
+ "SYSRES_CONST_LIFE_CYCLE_START_STAGE_REQUISITE_CODE "
+ "SYSRES_CONST_LILAC_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_LINK_OBJECT_KIND_COMPONENT "
+ "SYSRES_CONST_LINK_OBJECT_KIND_DOCUMENT "
+ "SYSRES_CONST_LINK_OBJECT_KIND_EDOC "
+ "SYSRES_CONST_LINK_OBJECT_KIND_FOLDER "
+ "SYSRES_CONST_LINK_OBJECT_KIND_JOB "
+ "SYSRES_CONST_LINK_OBJECT_KIND_REFERENCE "
+ "SYSRES_CONST_LINK_OBJECT_KIND_TASK "
+ "SYSRES_CONST_LINK_REF_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_LIST_REFERENCE_MODE_NAME "
+ "SYSRES_CONST_LOCALIZATION_DICTIONARY_MAIN_VIEW_CODE "
+ "SYSRES_CONST_MAIN_VIEW_CODE "
+ "SYSRES_CONST_MANUAL_ENUM_METHOD_FLAG "
+ "SYSRES_CONST_MASTER_COMP_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_MASTER_TABLE_REC_ID_REQUISITE_CODE "
+ "SYSRES_CONST_MAXIMIZED_MODE_NAME "
+ "SYSRES_CONST_ME_VALUE "
+ "SYSRES_CONST_MESSAGE_ATTENTION_CAPTION "
+ "SYSRES_CONST_MESSAGE_CONFIRMATION_CAPTION "
+ "SYSRES_CONST_MESSAGE_ERROR_CAPTION "
+ "SYSRES_CONST_MESSAGE_INFORMATION_CAPTION "
+ "SYSRES_CONST_MINIMIZED_MODE_NAME "
+ "SYSRES_CONST_MINUTE_CHAR "
+ "SYSRES_CONST_MODULE_REQUISITE_CODE "
+ "SYSRES_CONST_MONITORING_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_MONTH_FORMAT_VALUE "
+ "SYSRES_CONST_NAME_LOCALIZE_ID_REQUISITE_CODE "
+ "SYSRES_CONST_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_NAME_SINGULAR_REQUISITE_CODE "
+ "SYSRES_CONST_NAMEAN_INPUT_TYPE "
+ "SYSRES_CONST_NEGATIVE_PICK_VALUE "
+ "SYSRES_CONST_NEGATIVE_VALUE "
+ "SYSRES_CONST_NO "
+ "SYSRES_CONST_NO_PICK_VALUE "
+ "SYSRES_CONST_NO_SIGNATURE_REQUISITE_CODE "
+ "SYSRES_CONST_NO_VALUE "
+ "SYSRES_CONST_NONE_ACCESS_RIGHTS_TYPE_CODE "
+ "SYSRES_CONST_NONOPERATING_RECORD_FLAG_VALUE "
+ "SYSRES_CONST_NONOPERATING_RECORD_FLAG_VALUE_MASCULINE "
+ "SYSRES_CONST_NORMAL_ACCESS_RIGHTS_TYPE_CODE "
+ "SYSRES_CONST_NORMAL_LIFE_CYCLE_STAGE_DRAW_STYLE "
+ "SYSRES_CONST_NORMAL_MODE_NAME "
+ "SYSRES_CONST_NOT_ALLOWED_ACCESS_TYPE_CODE "
+ "SYSRES_CONST_NOT_ALLOWED_ACCESS_TYPE_NAME "
+ "SYSRES_CONST_NOTE_REQUISITE_CODE "
+ "SYSRES_CONST_NOTICE_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_NUM_REQUISITE "
+ "SYSRES_CONST_NUM_STR_REQUISITE_CODE "
+ "SYSRES_CONST_NUMERATION_AUTO_NOT_STRONG "
+ "SYSRES_CONST_NUMERATION_AUTO_STRONG "
+ "SYSRES_CONST_NUMERATION_FROM_DICTONARY "
+ "SYSRES_CONST_NUMERATION_MANUAL "
+ "SYSRES_CONST_NUMERIC_TYPE_CHAR "
+ "SYSRES_CONST_NUMREQ_REQUISITE_CODE "
+ "SYSRES_CONST_OBSOLETE_VERSION_STATE_PICK_VALUE "
+ "SYSRES_CONST_OPERATING_RECORD_FLAG_VALUE "
+ "SYSRES_CONST_OPERATING_RECORD_FLAG_VALUE_CODE "
+ "SYSRES_CONST_OPERATING_RECORD_FLAG_VALUE_FEMININE "
+ "SYSRES_CONST_OPERATING_RECORD_FLAG_VALUE_MASCULINE "
+ "SYSRES_CONST_OPTIONAL_FORM_COMP_REQCODE_PREFIX "
+ "SYSRES_CONST_ORANGE_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_ORIGINALREF_REQUISITE_CODE "
+ "SYSRES_CONST_OURFIRM_REF_CODE "
+ "SYSRES_CONST_OURFIRM_REQUISITE_CODE "
+ "SYSRES_CONST_OURFIRM_VAR "
+ "SYSRES_CONST_OUTGOING_WORK_RULE_TYPE_CODE "
+ "SYSRES_CONST_PICK_NEGATIVE_RESULT "
+ "SYSRES_CONST_PICK_POSITIVE_RESULT "
+ "SYSRES_CONST_PICK_REQUISITE "
+ "SYSRES_CONST_PICK_REQUISITE_TYPE "
+ "SYSRES_CONST_PICK_TYPE_CHAR "
+ "SYSRES_CONST_PLAN_STATUS_REQUISITE_CODE "
+ "SYSRES_CONST_PLATFORM_VERSION_COMMENT "
+ "SYSRES_CONST_PLUGINS_SETTINGS_DESCRIPTION_REQUISITE_CODE "
+ "SYSRES_CONST_POSITIVE_PICK_VALUE "
+ "SYSRES_CONST_POWER_TO_CREATE_ACTION_CODE "
+ "SYSRES_CONST_POWER_TO_SIGN_ACTION_CODE "
+ "SYSRES_CONST_PRIORITY_REQUISITE_CODE "
+ "SYSRES_CONST_QUALIFIED_TASK_TYPE "
+ "SYSRES_CONST_QUALIFIED_TASK_TYPE_CODE "
+ "SYSRES_CONST_RECSTAT_REQUISITE_CODE "
+ "SYSRES_CONST_RED_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_REF_ID_T_REF_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_REF_REQUISITE "
+ "SYSRES_CONST_REF_REQUISITE_TYPE "
+ "SYSRES_CONST_REF_REQUISITES_REFERENCE_CODE_SELECTED_REQUISITE "
+ "SYSRES_CONST_REFERENCE_RECORD_HISTORY_CREATE_ACTION_CODE "
+ "SYSRES_CONST_REFERENCE_RECORD_HISTORY_DELETE_ACTION_CODE "
+ "SYSRES_CONST_REFERENCE_RECORD_HISTORY_MODIFY_ACTION_CODE "
+ "SYSRES_CONST_REFERENCE_TYPE_CHAR "
+ "SYSRES_CONST_REFERENCE_TYPE_REQUISITE_NAME "
+ "SYSRES_CONST_REFERENCES_ADD_PARAMS_REQUISITE_CODE "
+ "SYSRES_CONST_REFERENCES_DISPLAY_REQUISITE_REQUISITE_CODE "
+ "SYSRES_CONST_REMOTE_SERVER_STATUS_WORKING "
+ "SYSRES_CONST_REMOTE_SERVER_TYPE_MAIN "
+ "SYSRES_CONST_REMOTE_SERVER_TYPE_SECONDARY "
+ "SYSRES_CONST_REMOTE_USER_FLAG_VALUE_CODE "
+ "SYSRES_CONST_REPORT_APP_EDITOR_INTERNAL "
+ "SYSRES_CONST_REPORT_BASE_REPORT_ID_REQUISITE_CODE "
+ "SYSRES_CONST_REPORT_BASE_REPORT_REQUISITE_CODE "
+ "SYSRES_CONST_REPORT_SCRIPT_REQUISITE_CODE "
+ "SYSRES_CONST_REPORT_TEMPLATE_REQUISITE_CODE "
+ "SYSRES_CONST_REPORT_VIEWER_CODE_REQUISITE_CODE "
+ "SYSRES_CONST_REQ_ALLOW_COMPONENT_DEFAULT_VALUE "
+ "SYSRES_CONST_REQ_ALLOW_RECORD_DEFAULT_VALUE "
+ "SYSRES_CONST_REQ_ALLOW_SERVER_COMPONENT_DEFAULT_VALUE "
+ "SYSRES_CONST_REQ_MODE_AVAILABLE_CODE "
+ "SYSRES_CONST_REQ_MODE_EDIT_CODE "
+ "SYSRES_CONST_REQ_MODE_HIDDEN_CODE "
+ "SYSRES_CONST_REQ_MODE_NOT_AVAILABLE_CODE "
+ "SYSRES_CONST_REQ_MODE_VIEW_CODE "
+ "SYSRES_CONST_REQ_NUMBER_REQUISITE_CODE "
+ "SYSRES_CONST_REQ_SECTION_VALUE "
+ "SYSRES_CONST_REQ_TYPE_VALUE "
+ "SYSRES_CONST_REQUISITE_FORMAT_BY_UNIT "
+ "SYSRES_CONST_REQUISITE_FORMAT_DATE_FULL "
+ "SYSRES_CONST_REQUISITE_FORMAT_DATE_TIME "
+ "SYSRES_CONST_REQUISITE_FORMAT_LEFT "
+ "SYSRES_CONST_REQUISITE_FORMAT_RIGHT "
+ "SYSRES_CONST_REQUISITE_FORMAT_WITHOUT_UNIT "
+ "SYSRES_CONST_REQUISITE_NUMBER_REQUISITE_CODE "
+ "SYSRES_CONST_REQUISITE_SECTION_ACTIONS "
+ "SYSRES_CONST_REQUISITE_SECTION_BUTTON "
+ "SYSRES_CONST_REQUISITE_SECTION_BUTTONS "
+ "SYSRES_CONST_REQUISITE_SECTION_CARD "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE10 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE11 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE12 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE13 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE14 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE15 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE16 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE17 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE18 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE19 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE2 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE20 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE21 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE22 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE23 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE24 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE3 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE4 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE5 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE6 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE7 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE8 "
+ "SYSRES_CONST_REQUISITE_SECTION_TABLE9 "
+ "SYSRES_CONST_REQUISITES_PSEUDOREFERENCE_REQUISITE_NUMBER_REQUISITE_CODE "
+ "SYSRES_CONST_RIGHT_ALIGNMENT_CODE "
+ "SYSRES_CONST_ROLES_REFERENCE_CODE "
+ "SYSRES_CONST_ROUTE_STEP_AFTER_RUS "
+ "SYSRES_CONST_ROUTE_STEP_AND_CONDITION_RUS "
+ "SYSRES_CONST_ROUTE_STEP_OR_CONDITION_RUS "
+ "SYSRES_CONST_ROUTE_TYPE_COMPLEX "
+ "SYSRES_CONST_ROUTE_TYPE_PARALLEL "
+ "SYSRES_CONST_ROUTE_TYPE_SERIAL "
+ "SYSRES_CONST_SBDATASETDESC_NEGATIVE_VALUE "
+ "SYSRES_CONST_SBDATASETDESC_POSITIVE_VALUE "
+ "SYSRES_CONST_SBVIEWSDESC_POSITIVE_VALUE "
+ "SYSRES_CONST_SCRIPT_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_SEARCH_BY_TEXT_REQUISITE_CODE "
+ "SYSRES_CONST_SEARCHES_COMPONENT_CONTENT "
+ "SYSRES_CONST_SEARCHES_CRITERIA_ACTION_NAME "
+ "SYSRES_CONST_SEARCHES_EDOC_CONTENT "
+ "SYSRES_CONST_SEARCHES_FOLDER_CONTENT "
+ "SYSRES_CONST_SEARCHES_JOB_CONTENT "
+ "SYSRES_CONST_SEARCHES_REFERENCE_CODE "
+ "SYSRES_CONST_SEARCHES_TASK_CONTENT "
+ "SYSRES_CONST_SECOND_CHAR "
+ "SYSRES_CONST_SECTION_REQUISITE_ACTIONS_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_CARD_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_CODE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_1_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_2_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_3_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_4_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_5_VALUE "
+ "SYSRES_CONST_SECTION_REQUISITE_DETAIL_6_VALUE "
+ "SYSRES_CONST_SELECT_REFERENCE_MODE_NAME "
+ "SYSRES_CONST_SELECT_TYPE_SELECTABLE "
+ "SYSRES_CONST_SELECT_TYPE_SELECTABLE_ONLY_CHILD "
+ "SYSRES_CONST_SELECT_TYPE_SELECTABLE_WITH_CHILD "
+ "SYSRES_CONST_SELECT_TYPE_UNSLECTABLE "
+ "SYSRES_CONST_SERVER_TYPE_MAIN "
+ "SYSRES_CONST_SERVICE_USER_CATEGORY_FIELD_VALUE "
+ "SYSRES_CONST_SETTINGS_USER_REQUISITE_CODE "
+ "SYSRES_CONST_SIGNATURE_AND_ENCODE_CERTIFICATE_TYPE_CODE "
+ "SYSRES_CONST_SIGNATURE_CERTIFICATE_TYPE_CODE "
+ "SYSRES_CONST_SINGULAR_TITLE_REQUISITE_CODE "
+ "SYSRES_CONST_SQL_SERVER_AUTHENTIFICATION_FLAG_VALUE_CODE "
+ "SYSRES_CONST_SQL_SERVER_ENCODE_AUTHENTIFICATION_FLAG_VALUE_CODE "
+ "SYSRES_CONST_STANDART_ROUTE_REFERENCE_CODE "
+ "SYSRES_CONST_STANDART_ROUTE_REFERENCE_COMMENT_REQUISITE_CODE "
+ "SYSRES_CONST_STANDART_ROUTES_GROUPS_REFERENCE_CODE "
+ "SYSRES_CONST_STATE_REQ_NAME "
+ "SYSRES_CONST_STATE_REQUISITE_ACTIVE_VALUE "
+ "SYSRES_CONST_STATE_REQUISITE_CLOSED_VALUE "
+ "SYSRES_CONST_STATE_REQUISITE_CODE "
+ "SYSRES_CONST_STATIC_ROLE_TYPE_CODE "
+ "SYSRES_CONST_STATUS_PLAN_DEFAULT_VALUE "
+ "SYSRES_CONST_STATUS_VALUE_AUTOCLEANING "
+ "SYSRES_CONST_STATUS_VALUE_BLUE_SQUARE "
+ "SYSRES_CONST_STATUS_VALUE_COMPLETE "
+ "SYSRES_CONST_STATUS_VALUE_GREEN_SQUARE "
+ "SYSRES_CONST_STATUS_VALUE_ORANGE_SQUARE "
+ "SYSRES_CONST_STATUS_VALUE_PURPLE_SQUARE "
+ "SYSRES_CONST_STATUS_VALUE_RED_SQUARE "
+ "SYSRES_CONST_STATUS_VALUE_SUSPEND "
+ "SYSRES_CONST_STATUS_VALUE_YELLOW_SQUARE "
+ "SYSRES_CONST_STDROUTE_SHOW_TO_USERS_REQUISITE_CODE "
+ "SYSRES_CONST_STORAGE_TYPE_FILE "
+ "SYSRES_CONST_STORAGE_TYPE_SQL_SERVER "
+ "SYSRES_CONST_STR_REQUISITE "
+ "SYSRES_CONST_STRIKEOUT_LIFE_CYCLE_STAGE_DRAW_STYLE "
+ "SYSRES_CONST_STRING_FORMAT_LEFT_ALIGN_CHAR "
+ "SYSRES_CONST_STRING_FORMAT_RIGHT_ALIGN_CHAR "
+ "SYSRES_CONST_STRING_REQUISITE_CODE "
+ "SYSRES_CONST_STRING_REQUISITE_TYPE "
+ "SYSRES_CONST_STRING_TYPE_CHAR "
+ "SYSRES_CONST_SUBSTITUTES_PSEUDOREFERENCE_CODE "
+ "SYSRES_CONST_SUBTASK_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_SYSTEM_SETTING_CURRENT_USER_PARAM_VALUE "
+ "SYSRES_CONST_SYSTEM_SETTING_EMPTY_VALUE_PARAM_VALUE "
+ "SYSRES_CONST_SYSTEM_VERSION_COMMENT "
+ "SYSRES_CONST_TASK_ACCESS_TYPE_ALL "
+ "SYSRES_CONST_TASK_ACCESS_TYPE_ALL_MEMBERS "
+ "SYSRES_CONST_TASK_ACCESS_TYPE_MANUAL "
+ "SYSRES_CONST_TASK_ENCODE_TYPE_CERTIFICATION "
+ "SYSRES_CONST_TASK_ENCODE_TYPE_CERTIFICATION_AND_PASSWORD "
+ "SYSRES_CONST_TASK_ENCODE_TYPE_NONE "
+ "SYSRES_CONST_TASK_ENCODE_TYPE_PASSWORD "
+ "SYSRES_CONST_TASK_ROUTE_ALL_CONDITION "
+ "SYSRES_CONST_TASK_ROUTE_AND_CONDITION "
+ "SYSRES_CONST_TASK_ROUTE_OR_CONDITION "
+ "SYSRES_CONST_TASK_STATE_ABORTED "
+ "SYSRES_CONST_TASK_STATE_COMPLETE "
+ "SYSRES_CONST_TASK_STATE_CONTINUED "
+ "SYSRES_CONST_TASK_STATE_CONTROL "
+ "SYSRES_CONST_TASK_STATE_INIT "
+ "SYSRES_CONST_TASK_STATE_WORKING "
+ "SYSRES_CONST_TASK_TITLE "
+ "SYSRES_CONST_TASK_TYPES_GROUPS_REFERENCE_CODE "
+ "SYSRES_CONST_TASK_TYPES_REFERENCE_CODE "
+ "SYSRES_CONST_TEMPLATES_REFERENCE_CODE "
+ "SYSRES_CONST_TEST_DATE_REQUISITE_NAME "
+ "SYSRES_CONST_TEST_DEV_DATABASE_NAME "
+ "SYSRES_CONST_TEST_DEV_SYSTEM_CODE "
+ "SYSRES_CONST_TEST_EDMS_DATABASE_NAME "
+ "SYSRES_CONST_TEST_EDMS_MAIN_CODE "
+ "SYSRES_CONST_TEST_EDMS_MAIN_DB_NAME "
+ "SYSRES_CONST_TEST_EDMS_SECOND_CODE "
+ "SYSRES_CONST_TEST_EDMS_SECOND_DB_NAME "
+ "SYSRES_CONST_TEST_EDMS_SYSTEM_CODE "
+ "SYSRES_CONST_TEST_NUMERIC_REQUISITE_NAME "
+ "SYSRES_CONST_TEXT_REQUISITE "
+ "SYSRES_CONST_TEXT_REQUISITE_CODE "
+ "SYSRES_CONST_TEXT_REQUISITE_TYPE "
+ "SYSRES_CONST_TEXT_TYPE_CHAR "
+ "SYSRES_CONST_TYPE_CODE_REQUISITE_CODE "
+ "SYSRES_CONST_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_UNDEFINED_LIFE_CYCLE_STAGE_FONT_COLOR "
+ "SYSRES_CONST_UNITS_SECTION_ID_REQUISITE_CODE "
+ "SYSRES_CONST_UNITS_SECTION_REQUISITE_CODE "
+ "SYSRES_CONST_UNOPERATING_RECORD_FLAG_VALUE_CODE "
+ "SYSRES_CONST_UNSTORED_DATA_REQUISITE_CODE "
+ "SYSRES_CONST_UNSTORED_DATA_REQUISITE_NAME "
+ "SYSRES_CONST_USE_ACCESS_TYPE_CODE "
+ "SYSRES_CONST_USE_ACCESS_TYPE_NAME "
+ "SYSRES_CONST_USER_ACCOUNT_TYPE_VALUE_CODE "
+ "SYSRES_CONST_USER_ADDITIONAL_INFORMATION_REQUISITE_CODE "
+ "SYSRES_CONST_USER_AND_GROUP_ID_FROM_PSEUDOREFERENCE_REQUISITE_CODE "
+ "SYSRES_CONST_USER_CATEGORY_NORMAL "
+ "SYSRES_CONST_USER_CERTIFICATE_REQUISITE_CODE "
+ "SYSRES_CONST_USER_CERTIFICATE_STATE_REQUISITE_CODE "
+ "SYSRES_CONST_USER_CERTIFICATE_SUBJECT_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_USER_CERTIFICATE_THUMBPRINT_REQUISITE_CODE "
+ "SYSRES_CONST_USER_COMMON_CATEGORY "
+ "SYSRES_CONST_USER_COMMON_CATEGORY_CODE "
+ "SYSRES_CONST_USER_FULL_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_USER_GROUP_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_USER_LOGIN_REQUISITE_CODE "
+ "SYSRES_CONST_USER_REMOTE_CONTROLLER_REQUISITE_CODE "
+ "SYSRES_CONST_USER_REMOTE_SYSTEM_REQUISITE_CODE "
+ "SYSRES_CONST_USER_RIGHTS_T_REQUISITE_CODE "
+ "SYSRES_CONST_USER_SERVER_NAME_REQUISITE_CODE "
+ "SYSRES_CONST_USER_SERVICE_CATEGORY "
+ "SYSRES_CONST_USER_SERVICE_CATEGORY_CODE "
+ "SYSRES_CONST_USER_STATUS_ADMINISTRATOR_CODE "
+ "SYSRES_CONST_USER_STATUS_ADMINISTRATOR_NAME "
+ "SYSRES_CONST_USER_STATUS_DEVELOPER_CODE "
+ "SYSRES_CONST_USER_STATUS_DEVELOPER_NAME "
+ "SYSRES_CONST_USER_STATUS_DISABLED_CODE "
+ "SYSRES_CONST_USER_STATUS_DISABLED_NAME "
+ "SYSRES_CONST_USER_STATUS_SYSTEM_DEVELOPER_CODE "
+ "SYSRES_CONST_USER_STATUS_USER_CODE "
+ "SYSRES_CONST_USER_STATUS_USER_NAME "
+ "SYSRES_CONST_USER_STATUS_USER_NAME_DEPRECATED "
+ "SYSRES_CONST_USER_TYPE_FIELD_VALUE_USER "
+ "SYSRES_CONST_USER_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_CONTROLLER_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_IS_MAIN_SERVER_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_REFERENCE_CODE "
+ "SYSRES_CONST_USERS_REGISTRATION_CERTIFICATES_ACTION_NAME "
+ "SYSRES_CONST_USERS_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_SYSTEM_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_USER_ACCESS_RIGHTS_TYPR_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_USER_AUTHENTICATION_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_USER_COMPONENT_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_USER_GROUP_REQUISITE_CODE "
+ "SYSRES_CONST_USERS_VIEW_CERTIFICATES_ACTION_NAME "
+ "SYSRES_CONST_VIEW_DEFAULT_CODE "
+ "SYSRES_CONST_VIEW_DEFAULT_NAME "
+ "SYSRES_CONST_VIEWER_REQUISITE_CODE "
+ "SYSRES_CONST_WAITING_BLOCK_DESCRIPTION "
+ "SYSRES_CONST_WIZARD_FORM_LABEL_TEST_STRING "
+ "SYSRES_CONST_WIZARD_QUERY_PARAM_HEIGHT_ETALON_STRING "
+ "SYSRES_CONST_WIZARD_REFERENCE_COMMENT_REQUISITE_CODE "
+ "SYSRES_CONST_WORK_RULES_DESCRIPTION_REQUISITE_CODE "
+ "SYSRES_CONST_WORK_TIME_CALENDAR_REFERENCE_CODE "
+ "SYSRES_CONST_WORK_WORKFLOW_HARD_ROUTE_TYPE_VALUE "
+ "SYSRES_CONST_WORK_WORKFLOW_HARD_ROUTE_TYPE_VALUE_CODE "
+ "SYSRES_CONST_WORK_WORKFLOW_HARD_ROUTE_TYPE_VALUE_CODE_RUS "
+ "SYSRES_CONST_WORK_WORKFLOW_SOFT_ROUTE_TYPE_VALUE_CODE_RUS "
+ "SYSRES_CONST_WORKFLOW_ROUTE_TYPR_HARD "
+ "SYSRES_CONST_WORKFLOW_ROUTE_TYPR_SOFT "
+ "SYSRES_CONST_XML_ENCODING "
+ "SYSRES_CONST_XREC_STAT_REQUISITE_CODE "
+ "SYSRES_CONST_XRECID_FIELD_NAME "
+ "SYSRES_CONST_YES "
+ "SYSRES_CONST_YES_NO_2_REQUISITE_CODE "
+ "SYSRES_CONST_YES_NO_REQUISITE_CODE "
+ "SYSRES_CONST_YES_NO_T_REF_TYPE_REQUISITE_CODE "
+ "SYSRES_CONST_YES_PICK_VALUE "
+ "SYSRES_CONST_YES_VALUE ";
// Base constant
const base_constants = "CR FALSE nil NO_VALUE NULL TAB TRUE YES_VALUE ";
// Base group name
const base_group_name_constants =
"ADMINISTRATORS_GROUP_NAME CUSTOMIZERS_GROUP_NAME DEVELOPERS_GROUP_NAME SERVICE_USERS_GROUP_NAME ";
// Decision block properties
const decision_block_properties_constants =
"DECISION_BLOCK_FIRST_OPERAND_PROPERTY DECISION_BLOCK_NAME_PROPERTY DECISION_BLOCK_OPERATION_PROPERTY "
+ "DECISION_BLOCK_RESULT_TYPE_PROPERTY DECISION_BLOCK_SECOND_OPERAND_PROPERTY ";
// File extension
const file_extension_constants =
"ANY_FILE_EXTENTION COMPRESSED_DOCUMENT_EXTENSION EXTENDED_DOCUMENT_EXTENSION "
+ "SHORT_COMPRESSED_DOCUMENT_EXTENSION SHORT_EXTENDED_DOCUMENT_EXTENSION ";
// Job block properties
const job_block_properties_constants =
"JOB_BLOCK_ABORT_DEADLINE_PROPERTY "
+ "JOB_BLOCK_AFTER_FINISH_EVENT "
+ "JOB_BLOCK_AFTER_QUERY_PARAMETERS_EVENT "
+ "JOB_BLOCK_ATTACHMENT_PROPERTY "
+ "JOB_BLOCK_ATTACHMENTS_RIGHTS_GROUP_PROPERTY "
+ "JOB_BLOCK_ATTACHMENTS_RIGHTS_TYPE_PROPERTY "
+ "JOB_BLOCK_BEFORE_QUERY_PARAMETERS_EVENT "
+ "JOB_BLOCK_BEFORE_START_EVENT "
+ "JOB_BLOCK_CREATED_JOBS_PROPERTY "
+ "JOB_BLOCK_DEADLINE_PROPERTY "
+ "JOB_BLOCK_EXECUTION_RESULTS_PROPERTY "
+ "JOB_BLOCK_IS_PARALLEL_PROPERTY "
+ "JOB_BLOCK_IS_RELATIVE_ABORT_DEADLINE_PROPERTY "
+ "JOB_BLOCK_IS_RELATIVE_DEADLINE_PROPERTY "
+ "JOB_BLOCK_JOB_TEXT_PROPERTY "
+ "JOB_BLOCK_NAME_PROPERTY "
+ "JOB_BLOCK_NEED_SIGN_ON_PERFORM_PROPERTY "
+ "JOB_BLOCK_PERFORMER_PROPERTY "
+ "JOB_BLOCK_RELATIVE_ABORT_DEADLINE_TYPE_PROPERTY "
+ "JOB_BLOCK_RELATIVE_DEADLINE_TYPE_PROPERTY "
+ "JOB_BLOCK_SUBJECT_PROPERTY ";
// Language code
const language_code_constants = "ENGLISH_LANGUAGE_CODE RUSSIAN_LANGUAGE_CODE ";
// Launching external applications
const launching_external_applications_constants =
"smHidden smMaximized smMinimized smNormal wmNo wmYes ";
// Link kind
const link_kind_constants =
"COMPONENT_TOKEN_LINK_KIND "
+ "DOCUMENT_LINK_KIND "
+ "EDOCUMENT_LINK_KIND "
+ "FOLDER_LINK_KIND "
+ "JOB_LINK_KIND "
+ "REFERENCE_LINK_KIND "
+ "TASK_LINK_KIND ";
// Lock type
const lock_type_constants =
"COMPONENT_TOKEN_LOCK_TYPE EDOCUMENT_VERSION_LOCK_TYPE ";
// Monitor block properties
const monitor_block_properties_constants =
"MONITOR_BLOCK_AFTER_FINISH_EVENT "
+ "MONITOR_BLOCK_BEFORE_START_EVENT "
+ "MONITOR_BLOCK_DEADLINE_PROPERTY "
+ "MONITOR_BLOCK_INTERVAL_PROPERTY "
+ "MONITOR_BLOCK_INTERVAL_TYPE_PROPERTY "
+ "MONITOR_BLOCK_IS_RELATIVE_DEADLINE_PROPERTY "
+ "MONITOR_BLOCK_NAME_PROPERTY "
+ "MONITOR_BLOCK_RELATIVE_DEADLINE_TYPE_PROPERTY "
+ "MONITOR_BLOCK_SEARCH_SCRIPT_PROPERTY ";
// Notice block properties
const notice_block_properties_constants =
"NOTICE_BLOCK_AFTER_FINISH_EVENT "
+ "NOTICE_BLOCK_ATTACHMENT_PROPERTY "
+ "NOTICE_BLOCK_ATTACHMENTS_RIGHTS_GROUP_PROPERTY "
+ "NOTICE_BLOCK_ATTACHMENTS_RIGHTS_TYPE_PROPERTY "
+ "NOTICE_BLOCK_BEFORE_START_EVENT "
+ "NOTICE_BLOCK_CREATED_NOTICES_PROPERTY "
+ "NOTICE_BLOCK_DEADLINE_PROPERTY "
+ "NOTICE_BLOCK_IS_RELATIVE_DEADLINE_PROPERTY "
+ "NOTICE_BLOCK_NAME_PROPERTY "
+ "NOTICE_BLOCK_NOTICE_TEXT_PROPERTY "
+ "NOTICE_BLOCK_PERFORMER_PROPERTY "
+ "NOTICE_BLOCK_RELATIVE_DEADLINE_TYPE_PROPERTY "
+ "NOTICE_BLOCK_SUBJECT_PROPERTY ";
// Object events
const object_events_constants =
"dseAfterCancel "
+ "dseAfterClose "
+ "dseAfterDelete "
+ "dseAfterDeleteOutOfTransaction "
+ "dseAfterInsert "
+ "dseAfterOpen "
+ "dseAfterScroll "
+ "dseAfterUpdate "
+ "dseAfterUpdateOutOfTransaction "
+ "dseBeforeCancel "
+ "dseBeforeClose "
+ "dseBeforeDelete "
+ "dseBeforeDetailUpdate "
+ "dseBeforeInsert "
+ "dseBeforeOpen "
+ "dseBeforeUpdate "
+ "dseOnAnyRequisiteChange "
+ "dseOnCloseRecord "
+ "dseOnDeleteError "
+ "dseOnOpenRecord "
+ "dseOnPrepareUpdate "
+ "dseOnUpdateError "
+ "dseOnUpdateRatifiedRecord "
+ "dseOnValidDelete "
+ "dseOnValidUpdate "
+ "reOnChange "
+ "reOnChangeValues "
+ "SELECTION_BEGIN_ROUTE_EVENT "
+ "SELECTION_END_ROUTE_EVENT ";
// Object params
const object_params_constants =
"CURRENT_PERIOD_IS_REQUIRED "
+ "PREVIOUS_CARD_TYPE_NAME "
+ "SHOW_RECORD_PROPERTIES_FORM ";
// Other
const other_constants =
"ACCESS_RIGHTS_SETTING_DIALOG_CODE "
+ "ADMINISTRATOR_USER_CODE "
+ "ANALYTIC_REPORT_TYPE "
+ "asrtHideLocal "
+ "asrtHideRemote "
+ "CALCULATED_ROLE_TYPE_CODE "
+ "COMPONENTS_REFERENCE_DEVELOPER_VIEW_CODE "
+ "DCTS_TEST_PROTOCOLS_FOLDER_PATH "
+ "E_EDOC_VERSION_ALREADY_APPROVINGLY_SIGNED "
+ "E_EDOC_VERSION_ALREADY_APPROVINGLY_SIGNED_BY_USER "
+ "E_EDOC_VERSION_ALREDY_SIGNED "
+ "E_EDOC_VERSION_ALREDY_SIGNED_BY_USER "
+ "EDOC_TYPES_CODE_REQUISITE_FIELD_NAME "
+ "EDOCUMENTS_ALIAS_NAME "
+ "FILES_FOLDER_PATH "
+ "FILTER_OPERANDS_DELIMITER "
+ "FILTER_OPERATIONS_DELIMITER "
+ "FORMCARD_NAME "
+ "FORMLIST_NAME "
+ "GET_EXTENDED_DOCUMENT_EXTENSION_CREATION_MODE "
+ "GET_EXTENDED_DOCUMENT_EXTENSION_IMPORT_MODE "
+ "INTEGRATED_REPORT_TYPE "
+ "IS_BUILDER_APPLICATION_ROLE "
+ "IS_BUILDER_APPLICATION_ROLE2 "
+ "IS_BUILDER_USERS "
+ "ISBSYSDEV "
+ "LOG_FOLDER_PATH "
+ "mbCancel "
+ "mbNo "
+ "mbNoToAll "
+ "mbOK "
+ "mbYes "
+ "mbYesToAll "
+ "MEMORY_DATASET_DESRIPTIONS_FILENAME "
+ "mrNo "
+ "mrNoToAll "
+ "mrYes "
+ "mrYesToAll "
+ "MULTIPLE_SELECT_DIALOG_CODE "
+ "NONOPERATING_RECORD_FLAG_FEMININE "
+ "NONOPERATING_RECORD_FLAG_MASCULINE "
+ "OPERATING_RECORD_FLAG_FEMININE "
+ "OPERATING_RECORD_FLAG_MASCULINE "
+ "PROFILING_SETTINGS_COMMON_SETTINGS_CODE_VALUE "
+ "PROGRAM_INITIATED_LOOKUP_ACTION "
+ "ratDelete "
+ "ratEdit "
+ "ratInsert "
+ "REPORT_TYPE "
+ "REQUIRED_PICK_VALUES_VARIABLE "
+ "rmCard "
+ "rmList "
+ "SBRTE_PROGID_DEV "
+ "SBRTE_PROGID_RELEASE "
+ "STATIC_ROLE_TYPE_CODE "
+ "SUPPRESS_EMPTY_TEMPLATE_CREATION "
+ "SYSTEM_USER_CODE "
+ "UPDATE_DIALOG_DATASET "
+ "USED_IN_OBJECT_HINT_PARAM "
+ "USER_INITIATED_LOOKUP_ACTION "
+ "USER_NAME_FORMAT "
+ "USER_SELECTION_RESTRICTIONS "
+ "WORKFLOW_TEST_PROTOCOLS_FOLDER_PATH "
+ "ELS_SUBTYPE_CONTROL_NAME "
+ "ELS_FOLDER_KIND_CONTROL_NAME "
+ "REPEAT_PROCESS_CURRENT_OBJECT_EXCEPTION_NAME ";
// Privileges
const privileges_constants =
"PRIVILEGE_COMPONENT_FULL_ACCESS "
+ "PRIVILEGE_DEVELOPMENT_EXPORT "
+ "PRIVILEGE_DEVELOPMENT_IMPORT "
+ "PRIVILEGE_DOCUMENT_DELETE "
+ "PRIVILEGE_ESD "
+ "PRIVILEGE_FOLDER_DELETE "
+ "PRIVILEGE_MANAGE_ACCESS_RIGHTS "
+ "PRIVILEGE_MANAGE_REPLICATION "
+ "PRIVILEGE_MANAGE_SESSION_SERVER "
+ "PRIVILEGE_OBJECT_FULL_ACCESS "
+ "PRIVILEGE_OBJECT_VIEW "
+ "PRIVILEGE_RESERVE_LICENSE "
+ "PRIVILEGE_SYSTEM_CUSTOMIZE "
+ "PRIVILEGE_SYSTEM_DEVELOP "
+ "PRIVILEGE_SYSTEM_INSTALL "
+ "PRIVILEGE_TASK_DELETE "
+ "PRIVILEGE_USER_PLUGIN_SETTINGS_CUSTOMIZE "
+ "PRIVILEGES_PSEUDOREFERENCE_CODE ";
// Pseudoreference code
const pseudoreference_code_constants =
"ACCESS_TYPES_PSEUDOREFERENCE_CODE "
+ "ALL_AVAILABLE_COMPONENTS_PSEUDOREFERENCE_CODE "
+ "ALL_AVAILABLE_PRIVILEGES_PSEUDOREFERENCE_CODE "
+ "ALL_REPLICATE_COMPONENTS_PSEUDOREFERENCE_CODE "
+ "AVAILABLE_DEVELOPERS_COMPONENTS_PSEUDOREFERENCE_CODE "
+ "COMPONENTS_PSEUDOREFERENCE_CODE "
+ "FILTRATER_SETTINGS_CONFLICTS_PSEUDOREFERENCE_CODE "
+ "GROUPS_PSEUDOREFERENCE_CODE "
+ "RECEIVE_PROTOCOL_PSEUDOREFERENCE_CODE "
+ "REFERENCE_REQUISITE_PSEUDOREFERENCE_CODE "
+ "REFERENCE_REQUISITES_PSEUDOREFERENCE_CODE "
+ "REFTYPES_PSEUDOREFERENCE_CODE "
+ "REPLICATION_SEANCES_DIARY_PSEUDOREFERENCE_CODE "
+ "SEND_PROTOCOL_PSEUDOREFERENCE_CODE "
+ "SUBSTITUTES_PSEUDOREFERENCE_CODE "
+ "SYSTEM_SETTINGS_PSEUDOREFERENCE_CODE "
+ "UNITS_PSEUDOREFERENCE_CODE "
+ "USERS_PSEUDOREFERENCE_CODE "
+ "VIEWERS_PSEUDOREFERENCE_CODE ";
// Requisite ISBCertificateType values
const requisite_ISBCertificateType_values_constants =
"CERTIFICATE_TYPE_ENCRYPT "
+ "CERTIFICATE_TYPE_SIGN "
+ "CERTIFICATE_TYPE_SIGN_AND_ENCRYPT ";
// Requisite ISBEDocStorageType values
const requisite_ISBEDocStorageType_values_constants =
"STORAGE_TYPE_FILE "
+ "STORAGE_TYPE_NAS_CIFS "
+ "STORAGE_TYPE_SAPERION "
+ "STORAGE_TYPE_SQL_SERVER ";
// Requisite CompType2 values
const requisite_compType2_values_constants =
"COMPTYPE2_REQUISITE_DOCUMENTS_VALUE "
+ "COMPTYPE2_REQUISITE_TASKS_VALUE "
+ "COMPTYPE2_REQUISITE_FOLDERS_VALUE "
+ "COMPTYPE2_REQUISITE_REFERENCES_VALUE ";
// Requisite name
const requisite_name_constants =
"SYSREQ_CODE "
+ "SYSREQ_COMPTYPE2 "
+ "SYSREQ_CONST_AVAILABLE_FOR_WEB "
+ "SYSREQ_CONST_COMMON_CODE "
+ "SYSREQ_CONST_COMMON_VALUE "
+ "SYSREQ_CONST_FIRM_CODE "
+ "SYSREQ_CONST_FIRM_STATUS "
+ "SYSREQ_CONST_FIRM_VALUE "
+ "SYSREQ_CONST_SERVER_STATUS "
+ "SYSREQ_CONTENTS "
+ "SYSREQ_DATE_OPEN "
+ "SYSREQ_DATE_CLOSE "
+ "SYSREQ_DESCRIPTION "
+ "SYSREQ_DESCRIPTION_LOCALIZE_ID "
+ "SYSREQ_DOUBLE "
+ "SYSREQ_EDOC_ACCESS_TYPE "
+ "SYSREQ_EDOC_AUTHOR "
+ "SYSREQ_EDOC_CREATED "
+ "SYSREQ_EDOC_DELEGATE_RIGHTS_REQUISITE_CODE "
+ "SYSREQ_EDOC_EDITOR "
+ "SYSREQ_EDOC_ENCODE_TYPE "
+ "SYSREQ_EDOC_ENCRYPTION_PLUGIN_NAME "
+ "SYSREQ_EDOC_ENCRYPTION_PLUGIN_VERSION "
+ "SYSREQ_EDOC_EXPORT_DATE "
+ "SYSREQ_EDOC_EXPORTER "
+ "SYSREQ_EDOC_KIND "
+ "SYSREQ_EDOC_LIFE_STAGE_NAME "
+ "SYSREQ_EDOC_LOCKED_FOR_SERVER_CODE "
+ "SYSREQ_EDOC_MODIFIED "
+ "SYSREQ_EDOC_NAME "
+ "SYSREQ_EDOC_NOTE "
+ "SYSREQ_EDOC_QUALIFIED_ID "
+ "SYSREQ_EDOC_SESSION_KEY "
+ "SYSREQ_EDOC_SESSION_KEY_ENCRYPTION_PLUGIN_NAME "
+ "SYSREQ_EDOC_SESSION_KEY_ENCRYPTION_PLUGIN_VERSION "
+ "SYSREQ_EDOC_SIGNATURE_TYPE "
+ "SYSREQ_EDOC_SIGNED "
+ "SYSREQ_EDOC_STORAGE "
+ "SYSREQ_EDOC_STORAGES_ARCHIVE_STORAGE "
+ "SYSREQ_EDOC_STORAGES_CHECK_RIGHTS "
+ "SYSREQ_EDOC_STORAGES_COMPUTER_NAME "
+ "SYSREQ_EDOC_STORAGES_EDIT_IN_STORAGE "
+ "SYSREQ_EDOC_STORAGES_EXECUTIVE_STORAGE "
+ "SYSREQ_EDOC_STORAGES_FUNCTION "
+ "SYSREQ_EDOC_STORAGES_INITIALIZED "
+ "SYSREQ_EDOC_STORAGES_LOCAL_PATH "
+ "SYSREQ_EDOC_STORAGES_SAPERION_DATABASE_NAME "
+ "SYSREQ_EDOC_STORAGES_SEARCH_BY_TEXT "
+ "SYSREQ_EDOC_STORAGES_SERVER_NAME "
+ "SYSREQ_EDOC_STORAGES_SHARED_SOURCE_NAME "
+ "SYSREQ_EDOC_STORAGES_TYPE "
+ "SYSREQ_EDOC_TEXT_MODIFIED "
+ "SYSREQ_EDOC_TYPE_ACT_CODE "
+ "SYSREQ_EDOC_TYPE_ACT_DESCRIPTION "
+ "SYSREQ_EDOC_TYPE_ACT_DESCRIPTION_LOCALIZE_ID "
+ "SYSREQ_EDOC_TYPE_ACT_ON_EXECUTE "
+ "SYSREQ_EDOC_TYPE_ACT_ON_EXECUTE_EXISTS "
+ "SYSREQ_EDOC_TYPE_ACT_SECTION "
+ "SYSREQ_EDOC_TYPE_ADD_PARAMS "
+ "SYSREQ_EDOC_TYPE_COMMENT "
+ "SYSREQ_EDOC_TYPE_EVENT_TEXT "
+ "SYSREQ_EDOC_TYPE_NAME_IN_SINGULAR "
+ "SYSREQ_EDOC_TYPE_NAME_IN_SINGULAR_LOCALIZE_ID "
+ "SYSREQ_EDOC_TYPE_NAME_LOCALIZE_ID "
+ "SYSREQ_EDOC_TYPE_NUMERATION_METHOD "
+ "SYSREQ_EDOC_TYPE_PSEUDO_REQUISITE_CODE "
+ "SYSREQ_EDOC_TYPE_REQ_CODE "
+ "SYSREQ_EDOC_TYPE_REQ_DESCRIPTION "
+ "SYSREQ_EDOC_TYPE_REQ_DESCRIPTION_LOCALIZE_ID "
+ "SYSREQ_EDOC_TYPE_REQ_IS_LEADING "
+ "SYSREQ_EDOC_TYPE_REQ_IS_REQUIRED "
+ "SYSREQ_EDOC_TYPE_REQ_NUMBER "
+ "SYSREQ_EDOC_TYPE_REQ_ON_CHANGE "
+ "SYSREQ_EDOC_TYPE_REQ_ON_CHANGE_EXISTS "
+ "SYSREQ_EDOC_TYPE_REQ_ON_SELECT "
+ "SYSREQ_EDOC_TYPE_REQ_ON_SELECT_KIND "
+ "SYSREQ_EDOC_TYPE_REQ_SECTION "
+ "SYSREQ_EDOC_TYPE_VIEW_CARD "
+ "SYSREQ_EDOC_TYPE_VIEW_CODE "
+ "SYSREQ_EDOC_TYPE_VIEW_COMMENT "
+ "SYSREQ_EDOC_TYPE_VIEW_IS_MAIN "
+ "SYSREQ_EDOC_TYPE_VIEW_NAME "
+ "SYSREQ_EDOC_TYPE_VIEW_NAME_LOCALIZE_ID "
+ "SYSREQ_EDOC_VERSION_AUTHOR "
+ "SYSREQ_EDOC_VERSION_CRC "
+ "SYSREQ_EDOC_VERSION_DATA "
+ "SYSREQ_EDOC_VERSION_EDITOR "
+ "SYSREQ_EDOC_VERSION_EXPORT_DATE "
+ "SYSREQ_EDOC_VERSION_EXPORTER "
+ "SYSREQ_EDOC_VERSION_HIDDEN "
+ "SYSREQ_EDOC_VERSION_LIFE_STAGE "
+ "SYSREQ_EDOC_VERSION_MODIFIED "
+ "SYSREQ_EDOC_VERSION_NOTE "
+ "SYSREQ_EDOC_VERSION_SIGNATURE_TYPE "
+ "SYSREQ_EDOC_VERSION_SIGNED "
+ "SYSREQ_EDOC_VERSION_SIZE "
+ "SYSREQ_EDOC_VERSION_SOURCE "
+ "SYSREQ_EDOC_VERSION_TEXT_MODIFIED "
+ "SYSREQ_EDOCKIND_DEFAULT_VERSION_STATE_CODE "
+ "SYSREQ_FOLDER_KIND "
+ "SYSREQ_FUNC_CATEGORY "
+ "SYSREQ_FUNC_COMMENT "
+ "SYSREQ_FUNC_GROUP "
+ "SYSREQ_FUNC_GROUP_COMMENT "
+ "SYSREQ_FUNC_GROUP_NUMBER "
+ "SYSREQ_FUNC_HELP "
+ "SYSREQ_FUNC_PARAM_DEF_VALUE "
+ "SYSREQ_FUNC_PARAM_IDENT "
+ "SYSREQ_FUNC_PARAM_NUMBER "
+ "SYSREQ_FUNC_PARAM_TYPE "
+ "SYSREQ_FUNC_TEXT "
+ "SYSREQ_GROUP_CATEGORY "
+ "SYSREQ_ID "
+ "SYSREQ_LAST_UPDATE "
+ "SYSREQ_LEADER_REFERENCE "
+ "SYSREQ_LINE_NUMBER "
+ "SYSREQ_MAIN_RECORD_ID "
+ "SYSREQ_NAME "
+ "SYSREQ_NAME_LOCALIZE_ID "
+ "SYSREQ_NOTE "
+ "SYSREQ_ORIGINAL_RECORD "
+ "SYSREQ_OUR_FIRM "
+ "SYSREQ_PROFILING_SETTINGS_BATCH_LOGING "
+ "SYSREQ_PROFILING_SETTINGS_BATCH_SIZE "
+ "SYSREQ_PROFILING_SETTINGS_PROFILING_ENABLED "
+ "SYSREQ_PROFILING_SETTINGS_SQL_PROFILING_ENABLED "
+ "SYSREQ_PROFILING_SETTINGS_START_LOGGED "
+ "SYSREQ_RECORD_STATUS "
+ "SYSREQ_REF_REQ_FIELD_NAME "
+ "SYSREQ_REF_REQ_FORMAT "
+ "SYSREQ_REF_REQ_GENERATED "
+ "SYSREQ_REF_REQ_LENGTH "
+ "SYSREQ_REF_REQ_PRECISION "
+ "SYSREQ_REF_REQ_REFERENCE "
+ "SYSREQ_REF_REQ_SECTION "
+ "SYSREQ_REF_REQ_STORED "
+ "SYSREQ_REF_REQ_TOKENS "
+ "SYSREQ_REF_REQ_TYPE "
+ "SYSREQ_REF_REQ_VIEW "
+ "SYSREQ_REF_TYPE_ACT_CODE "
+ "SYSREQ_REF_TYPE_ACT_DESCRIPTION "
+ "SYSREQ_REF_TYPE_ACT_DESCRIPTION_LOCALIZE_ID "
+ "SYSREQ_REF_TYPE_ACT_ON_EXECUTE "
+ "SYSREQ_REF_TYPE_ACT_ON_EXECUTE_EXISTS "
+ "SYSREQ_REF_TYPE_ACT_SECTION "
+ "SYSREQ_REF_TYPE_ADD_PARAMS "
+ "SYSREQ_REF_TYPE_COMMENT "
+ "SYSREQ_REF_TYPE_COMMON_SETTINGS "
+ "SYSREQ_REF_TYPE_DISPLAY_REQUISITE_NAME "
+ "SYSREQ_REF_TYPE_EVENT_TEXT "
+ "SYSREQ_REF_TYPE_MAIN_LEADING_REF "
+ "SYSREQ_REF_TYPE_NAME_IN_SINGULAR "
+ "SYSREQ_REF_TYPE_NAME_IN_SINGULAR_LOCALIZE_ID "
+ "SYSREQ_REF_TYPE_NAME_LOCALIZE_ID "
+ "SYSREQ_REF_TYPE_NUMERATION_METHOD "
+ "SYSREQ_REF_TYPE_REQ_CODE "
+ "SYSREQ_REF_TYPE_REQ_DESCRIPTION "
+ "SYSREQ_REF_TYPE_REQ_DESCRIPTION_LOCALIZE_ID "
+ "SYSREQ_REF_TYPE_REQ_IS_CONTROL "
+ "SYSREQ_REF_TYPE_REQ_IS_FILTER "
+ "SYSREQ_REF_TYPE_REQ_IS_LEADING "
+ "SYSREQ_REF_TYPE_REQ_IS_REQUIRED "
+ "SYSREQ_REF_TYPE_REQ_NUMBER "
+ "SYSREQ_REF_TYPE_REQ_ON_CHANGE "
+ "SYSREQ_REF_TYPE_REQ_ON_CHANGE_EXISTS "
+ "SYSREQ_REF_TYPE_REQ_ON_SELECT "
+ "SYSREQ_REF_TYPE_REQ_ON_SELECT_KIND "
+ "SYSREQ_REF_TYPE_REQ_SECTION "
+ "SYSREQ_REF_TYPE_VIEW_CARD "
+ "SYSREQ_REF_TYPE_VIEW_CODE "
+ "SYSREQ_REF_TYPE_VIEW_COMMENT "
+ "SYSREQ_REF_TYPE_VIEW_IS_MAIN "
+ "SYSREQ_REF_TYPE_VIEW_NAME "
+ "SYSREQ_REF_TYPE_VIEW_NAME_LOCALIZE_ID "
+ "SYSREQ_REFERENCE_TYPE_ID "
+ "SYSREQ_STATE "
+ "SYSREQ_STATЕ "
+ "SYSREQ_SYSTEM_SETTINGS_VALUE "
+ "SYSREQ_TYPE "
+ "SYSREQ_UNIT "
+ "SYSREQ_UNIT_ID "
+ "SYSREQ_USER_GROUPS_GROUP_FULL_NAME "
+ "SYSREQ_USER_GROUPS_GROUP_NAME "
+ "SYSREQ_USER_GROUPS_GROUP_SERVER_NAME "
+ "SYSREQ_USERS_ACCESS_RIGHTS "
+ "SYSREQ_USERS_AUTHENTICATION "
+ "SYSREQ_USERS_CATEGORY "
+ "SYSREQ_USERS_COMPONENT "
+ "SYSREQ_USERS_COMPONENT_USER_IS_PUBLIC "
+ "SYSREQ_USERS_DOMAIN "
+ "SYSREQ_USERS_FULL_USER_NAME "
+ "SYSREQ_USERS_GROUP "
+ "SYSREQ_USERS_IS_MAIN_SERVER "
+ "SYSREQ_USERS_LOGIN "
+ "SYSREQ_USERS_REFERENCE_USER_IS_PUBLIC "
+ "SYSREQ_USERS_STATUS "
+ "SYSREQ_USERS_USER_CERTIFICATE "
+ "SYSREQ_USERS_USER_CERTIFICATE_INFO "
+ "SYSREQ_USERS_USER_CERTIFICATE_PLUGIN_NAME "
+ "SYSREQ_USERS_USER_CERTIFICATE_PLUGIN_VERSION "
+ "SYSREQ_USERS_USER_CERTIFICATE_STATE "
+ "SYSREQ_USERS_USER_CERTIFICATE_SUBJECT_NAME "
+ "SYSREQ_USERS_USER_CERTIFICATE_THUMBPRINT "
+ "SYSREQ_USERS_USER_DEFAULT_CERTIFICATE "
+ "SYSREQ_USERS_USER_DESCRIPTION "
+ "SYSREQ_USERS_USER_GLOBAL_NAME "
+ "SYSREQ_USERS_USER_LOGIN "
+ "SYSREQ_USERS_USER_MAIN_SERVER "
+ "SYSREQ_USERS_USER_TYPE "
+ "SYSREQ_WORK_RULES_FOLDER_ID ";
// Result
const result_constants = "RESULT_VAR_NAME RESULT_VAR_NAME_ENG ";
// Rule identification
const rule_identification_constants =
"AUTO_NUMERATION_RULE_ID "
+ "CANT_CHANGE_ID_REQUISITE_RULE_ID "
+ "CANT_CHANGE_OURFIRM_REQUISITE_RULE_ID "
+ "CHECK_CHANGING_REFERENCE_RECORD_USE_RULE_ID "
+ "CHECK_CODE_REQUISITE_RULE_ID "
+ "CHECK_DELETING_REFERENCE_RECORD_USE_RULE_ID "
+ "CHECK_FILTRATER_CHANGES_RULE_ID "
+ "CHECK_RECORD_INTERVAL_RULE_ID "
+ "CHECK_REFERENCE_INTERVAL_RULE_ID "
+ "CHECK_REQUIRED_DATA_FULLNESS_RULE_ID "
+ "CHECK_REQUIRED_REQUISITES_FULLNESS_RULE_ID "
+ "MAKE_RECORD_UNRATIFIED_RULE_ID "
+ "RESTORE_AUTO_NUMERATION_RULE_ID "
+ "SET_FIRM_CONTEXT_FROM_RECORD_RULE_ID "
+ "SET_FIRST_RECORD_IN_LIST_FORM_RULE_ID "
+ "SET_IDSPS_VALUE_RULE_ID "
+ "SET_NEXT_CODE_VALUE_RULE_ID "
+ "SET_OURFIRM_BOUNDS_RULE_ID "
+ "SET_OURFIRM_REQUISITE_RULE_ID ";
// Script block properties
const script_block_properties_constants =
"SCRIPT_BLOCK_AFTER_FINISH_EVENT "
+ "SCRIPT_BLOCK_BEFORE_START_EVENT "
+ "SCRIPT_BLOCK_EXECUTION_RESULTS_PROPERTY "
+ "SCRIPT_BLOCK_NAME_PROPERTY "
+ "SCRIPT_BLOCK_SCRIPT_PROPERTY ";
// Subtask block properties
const subtask_block_properties_constants =
"SUBTASK_BLOCK_ABORT_DEADLINE_PROPERTY "
+ "SUBTASK_BLOCK_AFTER_FINISH_EVENT "
+ "SUBTASK_BLOCK_ASSIGN_PARAMS_EVENT "
+ "SUBTASK_BLOCK_ATTACHMENTS_PROPERTY "
+ "SUBTASK_BLOCK_ATTACHMENTS_RIGHTS_GROUP_PROPERTY "
+ "SUBTASK_BLOCK_ATTACHMENTS_RIGHTS_TYPE_PROPERTY "
+ "SUBTASK_BLOCK_BEFORE_START_EVENT "
+ "SUBTASK_BLOCK_CREATED_TASK_PROPERTY "
+ "SUBTASK_BLOCK_CREATION_EVENT "
+ "SUBTASK_BLOCK_DEADLINE_PROPERTY "
+ "SUBTASK_BLOCK_IMPORTANCE_PROPERTY "
+ "SUBTASK_BLOCK_INITIATOR_PROPERTY "
+ "SUBTASK_BLOCK_IS_RELATIVE_ABORT_DEADLINE_PROPERTY "
+ "SUBTASK_BLOCK_IS_RELATIVE_DEADLINE_PROPERTY "
+ "SUBTASK_BLOCK_JOBS_TYPE_PROPERTY "
+ "SUBTASK_BLOCK_NAME_PROPERTY "
+ "SUBTASK_BLOCK_PARALLEL_ROUTE_PROPERTY "
+ "SUBTASK_BLOCK_PERFORMERS_PROPERTY "
+ "SUBTASK_BLOCK_RELATIVE_ABORT_DEADLINE_TYPE_PROPERTY "
+ "SUBTASK_BLOCK_RELATIVE_DEADLINE_TYPE_PROPERTY "
+ "SUBTASK_BLOCK_REQUIRE_SIGN_PROPERTY "
+ "SUBTASK_BLOCK_STANDARD_ROUTE_PROPERTY "
+ "SUBTASK_BLOCK_START_EVENT "
+ "SUBTASK_BLOCK_STEP_CONTROL_PROPERTY "
+ "SUBTASK_BLOCK_SUBJECT_PROPERTY "
+ "SUBTASK_BLOCK_TASK_CONTROL_PROPERTY "
+ "SUBTASK_BLOCK_TEXT_PROPERTY "
+ "SUBTASK_BLOCK_UNLOCK_ATTACHMENTS_ON_STOP_PROPERTY "
+ "SUBTASK_BLOCK_USE_STANDARD_ROUTE_PROPERTY "
+ "SUBTASK_BLOCK_WAIT_FOR_TASK_COMPLETE_PROPERTY ";
// System component
const system_component_constants =
"SYSCOMP_CONTROL_JOBS "
+ "SYSCOMP_FOLDERS "
+ "SYSCOMP_JOBS "
+ "SYSCOMP_NOTICES "
+ "SYSCOMP_TASKS ";
// System dialogs
const system_dialogs_constants =
"SYSDLG_CREATE_EDOCUMENT "
+ "SYSDLG_CREATE_EDOCUMENT_VERSION "
+ "SYSDLG_CURRENT_PERIOD "
+ "SYSDLG_EDIT_FUNCTION_HELP "
+ "SYSDLG_EDOCUMENT_KINDS_FOR_TEMPLATE "
+ "SYSDLG_EXPORT_MULTIPLE_EDOCUMENTS "
+ "SYSDLG_EXPORT_SINGLE_EDOCUMENT "
+ "SYSDLG_IMPORT_EDOCUMENT "
+ "SYSDLG_MULTIPLE_SELECT "
+ "SYSDLG_SETUP_ACCESS_RIGHTS "
+ "SYSDLG_SETUP_DEFAULT_RIGHTS "
+ "SYSDLG_SETUP_FILTER_CONDITION "
+ "SYSDLG_SETUP_SIGN_RIGHTS "
+ "SYSDLG_SETUP_TASK_OBSERVERS "
+ "SYSDLG_SETUP_TASK_ROUTE "
+ "SYSDLG_SETUP_USERS_LIST "
+ "SYSDLG_SIGN_EDOCUMENT "
+ "SYSDLG_SIGN_MULTIPLE_EDOCUMENTS ";
// System reference names
const system_reference_names_constants =
"SYSREF_ACCESS_RIGHTS_TYPES "
+ "SYSREF_ADMINISTRATION_HISTORY "
+ "SYSREF_ALL_AVAILABLE_COMPONENTS "
+ "SYSREF_ALL_AVAILABLE_PRIVILEGES "
+ "SYSREF_ALL_REPLICATING_COMPONENTS "
+ "SYSREF_AVAILABLE_DEVELOPERS_COMPONENTS "
+ "SYSREF_CALENDAR_EVENTS "
+ "SYSREF_COMPONENT_TOKEN_HISTORY "
+ "SYSREF_COMPONENT_TOKENS "
+ "SYSREF_COMPONENTS "
+ "SYSREF_CONSTANTS "
+ "SYSREF_DATA_RECEIVE_PROTOCOL "
+ "SYSREF_DATA_SEND_PROTOCOL "
+ "SYSREF_DIALOGS "
+ "SYSREF_DIALOGS_REQUISITES "
+ "SYSREF_EDITORS "
+ "SYSREF_EDOC_CARDS "
+ "SYSREF_EDOC_TYPES "
+ "SYSREF_EDOCUMENT_CARD_REQUISITES "
+ "SYSREF_EDOCUMENT_CARD_TYPES "
+ "SYSREF_EDOCUMENT_CARD_TYPES_REFERENCE "
+ "SYSREF_EDOCUMENT_CARDS "
+ "SYSREF_EDOCUMENT_HISTORY "
+ "SYSREF_EDOCUMENT_KINDS "
+ "SYSREF_EDOCUMENT_REQUISITES "
+ "SYSREF_EDOCUMENT_SIGNATURES "
+ "SYSREF_EDOCUMENT_TEMPLATES "
+ "SYSREF_EDOCUMENT_TEXT_STORAGES "
+ "SYSREF_EDOCUMENT_VIEWS "
+ "SYSREF_FILTERER_SETUP_CONFLICTS "
+ "SYSREF_FILTRATER_SETTING_CONFLICTS "
+ "SYSREF_FOLDER_HISTORY "
+ "SYSREF_FOLDERS "
+ "SYSREF_FUNCTION_GROUPS "
+ "SYSREF_FUNCTION_PARAMS "
+ "SYSREF_FUNCTIONS "
+ "SYSREF_JOB_HISTORY "
+ "SYSREF_LINKS "
+ "SYSREF_LOCALIZATION_DICTIONARY "
+ "SYSREF_LOCALIZATION_LANGUAGES "
+ "SYSREF_MODULES "
+ "SYSREF_PRIVILEGES "
+ "SYSREF_RECORD_HISTORY "
+ "SYSREF_REFERENCE_REQUISITES "
+ "SYSREF_REFERENCE_TYPE_VIEWS "
+ "SYSREF_REFERENCE_TYPES "
+ "SYSREF_REFERENCES "
+ "SYSREF_REFERENCES_REQUISITES "
+ "SYSREF_REMOTE_SERVERS "
+ "SYSREF_REPLICATION_SESSIONS_LOG "
+ "SYSREF_REPLICATION_SESSIONS_PROTOCOL "
+ "SYSREF_REPORTS "
+ "SYSREF_ROLES "
+ "SYSREF_ROUTE_BLOCK_GROUPS "
+ "SYSREF_ROUTE_BLOCKS "
+ "SYSREF_SCRIPTS "
+ "SYSREF_SEARCHES "
+ "SYSREF_SERVER_EVENTS "
+ "SYSREF_SERVER_EVENTS_HISTORY "
+ "SYSREF_STANDARD_ROUTE_GROUPS "
+ "SYSREF_STANDARD_ROUTES "
+ "SYSREF_STATUSES "
+ "SYSREF_SYSTEM_SETTINGS "
+ "SYSREF_TASK_HISTORY "
+ "SYSREF_TASK_KIND_GROUPS "
+ "SYSREF_TASK_KINDS "
+ "SYSREF_TASK_RIGHTS "
+ "SYSREF_TASK_SIGNATURES "
+ "SYSREF_TASKS "
+ "SYSREF_UNITS "
+ "SYSREF_USER_GROUPS "
+ "SYSREF_USER_GROUPS_REFERENCE "
+ "SYSREF_USER_SUBSTITUTION "
+ "SYSREF_USERS "
+ "SYSREF_USERS_REFERENCE "
+ "SYSREF_VIEWERS "
+ "SYSREF_WORKING_TIME_CALENDARS ";
// Table name
const table_name_constants =
"ACCESS_RIGHTS_TABLE_NAME "
+ "EDMS_ACCESS_TABLE_NAME "
+ "EDOC_TYPES_TABLE_NAME ";
// Test
const test_constants =
"TEST_DEV_DB_NAME "
+ "TEST_DEV_SYSTEM_CODE "
+ "TEST_EDMS_DB_NAME "
+ "TEST_EDMS_MAIN_CODE "
+ "TEST_EDMS_MAIN_DB_NAME "
+ "TEST_EDMS_SECOND_CODE "
+ "TEST_EDMS_SECOND_DB_NAME "
+ "TEST_EDMS_SYSTEM_CODE "
+ "TEST_ISB5_MAIN_CODE "
+ "TEST_ISB5_SECOND_CODE "
+ "TEST_SQL_SERVER_2005_NAME "
+ "TEST_SQL_SERVER_NAME ";
// Using the dialog windows
const using_the_dialog_windows_constants =
"ATTENTION_CAPTION "
+ "cbsCommandLinks "
+ "cbsDefault "
+ "CONFIRMATION_CAPTION "
+ "ERROR_CAPTION "
+ "INFORMATION_CAPTION "
+ "mrCancel "
+ "mrOk ";
// Using the document
const using_the_document_constants =
"EDOC_VERSION_ACTIVE_STAGE_CODE "
+ "EDOC_VERSION_DESIGN_STAGE_CODE "
+ "EDOC_VERSION_OBSOLETE_STAGE_CODE ";
// Using the EA and encryption
const using_the_EA_and_encryption_constants =
"cpDataEnciphermentEnabled "
+ "cpDigitalSignatureEnabled "
+ "cpID "
+ "cpIssuer "
+ "cpPluginVersion "
+ "cpSerial "
+ "cpSubjectName "
+ "cpSubjSimpleName "
+ "cpValidFromDate "
+ "cpValidToDate ";
// Using the ISBL-editor
const using_the_ISBL_editor_constants =
"ISBL_SYNTAX " + "NO_SYNTAX " + "XML_SYNTAX ";
// Wait block properties
const wait_block_properties_constants =
"WAIT_BLOCK_AFTER_FINISH_EVENT "
+ "WAIT_BLOCK_BEFORE_START_EVENT "
+ "WAIT_BLOCK_DEADLINE_PROPERTY "
+ "WAIT_BLOCK_IS_RELATIVE_DEADLINE_PROPERTY "
+ "WAIT_BLOCK_NAME_PROPERTY "
+ "WAIT_BLOCK_RELATIVE_DEADLINE_TYPE_PROPERTY ";
// SYSRES Common
const sysres_common_constants =
"SYSRES_COMMON "
+ "SYSRES_CONST "
+ "SYSRES_MBFUNC "
+ "SYSRES_SBDATA "
+ "SYSRES_SBGUI "
+ "SYSRES_SBINTF "
+ "SYSRES_SBREFDSC "
+ "SYSRES_SQLERRORS "
+ "SYSRES_SYSCOMP ";
// Константы ==> built_in
const CONSTANTS =
sysres_constants
+ base_constants
+ base_group_name_constants
+ decision_block_properties_constants
+ file_extension_constants
+ job_block_properties_constants
+ language_code_constants
+ launching_external_applications_constants
+ link_kind_constants
+ lock_type_constants
+ monitor_block_properties_constants
+ notice_block_properties_constants
+ object_events_constants
+ object_params_constants
+ other_constants
+ privileges_constants
+ pseudoreference_code_constants
+ requisite_ISBCertificateType_values_constants
+ requisite_ISBEDocStorageType_values_constants
+ requisite_compType2_values_constants
+ requisite_name_constants
+ result_constants
+ rule_identification_constants
+ script_block_properties_constants
+ subtask_block_properties_constants
+ system_component_constants
+ system_dialogs_constants
+ system_reference_names_constants
+ table_name_constants
+ test_constants
+ using_the_dialog_windows_constants
+ using_the_document_constants
+ using_the_EA_and_encryption_constants
+ using_the_ISBL_editor_constants
+ wait_block_properties_constants
+ sysres_common_constants;
// enum TAccountType
const TAccountType = "atUser atGroup atRole ";
// enum TActionEnabledMode
const TActionEnabledMode =
"aemEnabledAlways "
+ "aemDisabledAlways "
+ "aemEnabledOnBrowse "
+ "aemEnabledOnEdit "
+ "aemDisabledOnBrowseEmpty ";
// enum TAddPosition
const TAddPosition = "apBegin apEnd ";
// enum TAlignment
const TAlignment = "alLeft alRight ";
// enum TAreaShowMode
const TAreaShowMode =
"asmNever "
+ "asmNoButCustomize "
+ "asmAsLastTime "
+ "asmYesButCustomize "
+ "asmAlways ";
// enum TCertificateInvalidationReason
const TCertificateInvalidationReason = "cirCommon cirRevoked ";
// enum TCertificateType
const TCertificateType = "ctSignature ctEncode ctSignatureEncode ";
// enum TCheckListBoxItemState
const TCheckListBoxItemState = "clbUnchecked clbChecked clbGrayed ";
// enum TCloseOnEsc
const TCloseOnEsc = "ceISB ceAlways ceNever ";
// enum TCompType
const TCompType =
"ctDocument "
+ "ctReference "
+ "ctScript "
+ "ctUnknown "
+ "ctReport "
+ "ctDialog "
+ "ctFunction "
+ "ctFolder "
+ "ctEDocument "
+ "ctTask "
+ "ctJob "
+ "ctNotice "
+ "ctControlJob ";
// enum TConditionFormat
const TConditionFormat = "cfInternal cfDisplay ";
// enum TConnectionIntent
const TConnectionIntent = "ciUnspecified ciWrite ciRead ";
// enum TContentKind
const TContentKind =
"ckFolder "
+ "ckEDocument "
+ "ckTask "
+ "ckJob "
+ "ckComponentToken "
+ "ckAny "
+ "ckReference "
+ "ckScript "
+ "ckReport "
+ "ckDialog ";
// enum TControlType
const TControlType =
"ctISBLEditor "
+ "ctBevel "
+ "ctButton "
+ "ctCheckListBox "
+ "ctComboBox "
+ "ctComboEdit "
+ "ctGrid "
+ "ctDBCheckBox "
+ "ctDBComboBox "
+ "ctDBEdit "
+ "ctDBEllipsis "
+ "ctDBMemo "
+ "ctDBNavigator "
+ "ctDBRadioGroup "
+ "ctDBStatusLabel "
+ "ctEdit "
+ "ctGroupBox "
+ "ctInplaceHint "
+ "ctMemo "
+ "ctPanel "
+ "ctListBox "
+ "ctRadioButton "
+ "ctRichEdit "
+ "ctTabSheet "
+ "ctWebBrowser "
+ "ctImage "
+ "ctHyperLink "
+ "ctLabel "
+ "ctDBMultiEllipsis "
+ "ctRibbon "
+ "ctRichView "
+ "ctInnerPanel "
+ "ctPanelGroup "
+ "ctBitButton ";
// enum TCriterionContentType
const TCriterionContentType =
"cctDate "
+ "cctInteger "
+ "cctNumeric "
+ "cctPick "
+ "cctReference "
+ "cctString "
+ "cctText ";
// enum TCultureType
const TCultureType = "cltInternal cltPrimary cltGUI ";
// enum TDataSetEventType
const TDataSetEventType =
"dseBeforeOpen "
+ "dseAfterOpen "
+ "dseBeforeClose "
+ "dseAfterClose "
+ "dseOnValidDelete "
+ "dseBeforeDelete "
+ "dseAfterDelete "
+ "dseAfterDeleteOutOfTransaction "
+ "dseOnDeleteError "
+ "dseBeforeInsert "
+ "dseAfterInsert "
+ "dseOnValidUpdate "
+ "dseBeforeUpdate "
+ "dseOnUpdateRatifiedRecord "
+ "dseAfterUpdate "
+ "dseAfterUpdateOutOfTransaction "
+ "dseOnUpdateError "
+ "dseAfterScroll "
+ "dseOnOpenRecord "
+ "dseOnCloseRecord "
+ "dseBeforeCancel "
+ "dseAfterCancel "
+ "dseOnUpdateDeadlockError "
+ "dseBeforeDetailUpdate "
+ "dseOnPrepareUpdate "
+ "dseOnAnyRequisiteChange ";
// enum TDataSetState
const TDataSetState = "dssEdit dssInsert dssBrowse dssInActive ";
// enum TDateFormatType
const TDateFormatType = "dftDate dftShortDate dftDateTime dftTimeStamp ";
// enum TDateOffsetType
const TDateOffsetType = "dotDays dotHours dotMinutes dotSeconds ";
// enum TDateTimeKind
const TDateTimeKind = "dtkndLocal dtkndUTC ";
// enum TDeaAccessRights
const TDeaAccessRights = "arNone arView arEdit arFull ";
// enum TDocumentDefaultAction
const TDocumentDefaultAction = "ddaView ddaEdit ";
// enum TEditMode
const TEditMode =
"emLock "
+ "emEdit "
+ "emSign "
+ "emExportWithLock "
+ "emImportWithUnlock "
+ "emChangeVersionNote "
+ "emOpenForModify "
+ "emChangeLifeStage "
+ "emDelete "
+ "emCreateVersion "
+ "emImport "
+ "emUnlockExportedWithLock "
+ "emStart "
+ "emAbort "
+ "emReInit "
+ "emMarkAsReaded "
+ "emMarkAsUnreaded "
+ "emPerform "
+ "emAccept "
+ "emResume "
+ "emChangeRights "
+ "emEditRoute "
+ "emEditObserver "
+ "emRecoveryFromLocalCopy "
+ "emChangeWorkAccessType "
+ "emChangeEncodeTypeToCertificate "
+ "emChangeEncodeTypeToPassword "
+ "emChangeEncodeTypeToNone "
+ "emChangeEncodeTypeToCertificatePassword "
+ "emChangeStandardRoute "
+ "emGetText "
+ "emOpenForView "
+ "emMoveToStorage "
+ "emCreateObject "
+ "emChangeVersionHidden "
+ "emDeleteVersion "
+ "emChangeLifeCycleStage "
+ "emApprovingSign "
+ "emExport "
+ "emContinue "
+ "emLockFromEdit "
+ "emUnLockForEdit "
+ "emLockForServer "
+ "emUnlockFromServer "
+ "emDelegateAccessRights "
+ "emReEncode ";
// enum TEditorCloseObservType
const TEditorCloseObservType = "ecotFile ecotProcess ";
// enum TEdmsApplicationAction
const TEdmsApplicationAction = "eaGet eaCopy eaCreate eaCreateStandardRoute ";
// enum TEDocumentLockType
const TEDocumentLockType = "edltAll edltNothing edltQuery ";
// enum TEDocumentStepShowMode
const TEDocumentStepShowMode = "essmText essmCard ";
// enum TEDocumentStepVersionType
const TEDocumentStepVersionType = "esvtLast esvtLastActive esvtSpecified ";
// enum TEDocumentStorageFunction
const TEDocumentStorageFunction = "edsfExecutive edsfArchive ";
// enum TEDocumentStorageType
const TEDocumentStorageType = "edstSQLServer edstFile ";
// enum TEDocumentVersionSourceType
const TEDocumentVersionSourceType =
"edvstNone edvstEDocumentVersionCopy edvstFile edvstTemplate edvstScannedFile ";
// enum TEDocumentVersionState
const TEDocumentVersionState = "vsDefault vsDesign vsActive vsObsolete ";
// enum TEncodeType
const TEncodeType = "etNone etCertificate etPassword etCertificatePassword ";
// enum TExceptionCategory
const TExceptionCategory = "ecException ecWarning ecInformation ";
// enum TExportedSignaturesType
const TExportedSignaturesType = "estAll estApprovingOnly ";
// enum TExportedVersionType
const TExportedVersionType = "evtLast evtLastActive evtQuery ";
// enum TFieldDataType
const TFieldDataType =
"fdtString "
+ "fdtNumeric "
+ "fdtInteger "
+ "fdtDate "
+ "fdtText "
+ "fdtUnknown "
+ "fdtWideString "
+ "fdtLargeInteger ";
// enum TFolderType
const TFolderType =
"ftInbox "
+ "ftOutbox "
+ "ftFavorites "
+ "ftCommonFolder "
+ "ftUserFolder "
+ "ftComponents "
+ "ftQuickLaunch "
+ "ftShortcuts "
+ "ftSearch ";
// enum TGridRowHeight
const TGridRowHeight = "grhAuto " + "grhX1 " + "grhX2 " + "grhX3 ";
// enum THyperlinkType
const THyperlinkType = "hltText " + "hltRTF " + "hltHTML ";
// enum TImageFileFormat
const TImageFileFormat =
"iffBMP "
+ "iffJPEG "
+ "iffMultiPageTIFF "
+ "iffSinglePageTIFF "
+ "iffTIFF "
+ "iffPNG ";
// enum TImageMode
const TImageMode = "im8bGrayscale " + "im24bRGB " + "im1bMonochrome ";
// enum TImageType
const TImageType = "itBMP " + "itJPEG " + "itWMF " + "itPNG ";
// enum TInplaceHintKind
const TInplaceHintKind =
"ikhInformation " + "ikhWarning " + "ikhError " + "ikhNoIcon ";
// enum TISBLContext
const TISBLContext =
"icUnknown "
+ "icScript "
+ "icFunction "
+ "icIntegratedReport "
+ "icAnalyticReport "
+ "icDataSetEventHandler "
+ "icActionHandler "
+ "icFormEventHandler "
+ "icLookUpEventHandler "
+ "icRequisiteChangeEventHandler "
+ "icBeforeSearchEventHandler "
+ "icRoleCalculation "
+ "icSelectRouteEventHandler "
+ "icBlockPropertyCalculation "
+ "icBlockQueryParamsEventHandler "
+ "icChangeSearchResultEventHandler "
+ "icBlockEventHandler "
+ "icSubTaskInitEventHandler "
+ "icEDocDataSetEventHandler "
+ "icEDocLookUpEventHandler "
+ "icEDocActionHandler "
+ "icEDocFormEventHandler "
+ "icEDocRequisiteChangeEventHandler "
+ "icStructuredConversionRule "
+ "icStructuredConversionEventBefore "
+ "icStructuredConversionEventAfter "
+ "icWizardEventHandler "
+ "icWizardFinishEventHandler "
+ "icWizardStepEventHandler "
+ "icWizardStepFinishEventHandler "
+ "icWizardActionEnableEventHandler "
+ "icWizardActionExecuteEventHandler "
+ "icCreateJobsHandler "
+ "icCreateNoticesHandler "
+ "icBeforeLookUpEventHandler "
+ "icAfterLookUpEventHandler "
+ "icTaskAbortEventHandler "
+ "icWorkflowBlockActionHandler "
+ "icDialogDataSetEventHandler "
+ "icDialogActionHandler "
+ "icDialogLookUpEventHandler "
+ "icDialogRequisiteChangeEventHandler "
+ "icDialogFormEventHandler "
+ "icDialogValidCloseEventHandler "
+ "icBlockFormEventHandler "
+ "icTaskFormEventHandler "
+ "icReferenceMethod "
+ "icEDocMethod "
+ "icDialogMethod "
+ "icProcessMessageHandler ";
// enum TItemShow
const TItemShow = "isShow " + "isHide " + "isByUserSettings ";
// enum TJobKind
const TJobKind = "jkJob " + "jkNotice " + "jkControlJob ";
// enum TJoinType
const TJoinType = "jtInner " + "jtLeft " + "jtRight " + "jtFull " + "jtCross ";
// enum TLabelPos
const TLabelPos = "lbpAbove " + "lbpBelow " + "lbpLeft " + "lbpRight ";
// enum TLicensingType
const TLicensingType = "eltPerConnection " + "eltPerUser ";
// enum TLifeCycleStageFontColor
const TLifeCycleStageFontColor =
"sfcUndefined "
+ "sfcBlack "
+ "sfcGreen "
+ "sfcRed "
+ "sfcBlue "
+ "sfcOrange "
+ "sfcLilac ";
// enum TLifeCycleStageFontStyle
const TLifeCycleStageFontStyle = "sfsItalic " + "sfsStrikeout " + "sfsNormal ";
// enum TLockableDevelopmentComponentType
const TLockableDevelopmentComponentType =
"ldctStandardRoute "
+ "ldctWizard "
+ "ldctScript "
+ "ldctFunction "
+ "ldctRouteBlock "
+ "ldctIntegratedReport "
+ "ldctAnalyticReport "
+ "ldctReferenceType "
+ "ldctEDocumentType "
+ "ldctDialog "
+ "ldctServerEvents ";
// enum TMaxRecordCountRestrictionType
const TMaxRecordCountRestrictionType =
"mrcrtNone " + "mrcrtUser " + "mrcrtMaximal " + "mrcrtCustom ";
// enum TRangeValueType
const TRangeValueType =
"vtEqual " + "vtGreaterOrEqual " + "vtLessOrEqual " + "vtRange ";
// enum TRelativeDate
const TRelativeDate =
"rdYesterday "
+ "rdToday "
+ "rdTomorrow "
+ "rdThisWeek "
+ "rdThisMonth "
+ "rdThisYear "
+ "rdNextMonth "
+ "rdNextWeek "
+ "rdLastWeek "
+ "rdLastMonth ";
// enum TReportDestination
const TReportDestination = "rdWindow " + "rdFile " + "rdPrinter ";
// enum TReqDataType
const TReqDataType =
"rdtString "
+ "rdtNumeric "
+ "rdtInteger "
+ "rdtDate "
+ "rdtReference "
+ "rdtAccount "
+ "rdtText "
+ "rdtPick "
+ "rdtUnknown "
+ "rdtLargeInteger "
+ "rdtDocument ";
// enum TRequisiteEventType
const TRequisiteEventType = "reOnChange " + "reOnChangeValues ";
// enum TSBTimeType
const TSBTimeType = "ttGlobal " + "ttLocal " + "ttUser " + "ttSystem ";
// enum TSearchShowMode
const TSearchShowMode =
"ssmBrowse " + "ssmSelect " + "ssmMultiSelect " + "ssmBrowseModal ";
// enum TSelectMode
const TSelectMode = "smSelect " + "smLike " + "smCard ";
// enum TSignatureType
const TSignatureType = "stNone " + "stAuthenticating " + "stApproving ";
// enum TSignerContentType
const TSignerContentType = "sctString " + "sctStream ";
// enum TStringsSortType
const TStringsSortType = "sstAnsiSort " + "sstNaturalSort ";
// enum TStringValueType
const TStringValueType = "svtEqual " + "svtContain ";
// enum TStructuredObjectAttributeType
const TStructuredObjectAttributeType =
"soatString "
+ "soatNumeric "
+ "soatInteger "
+ "soatDatetime "
+ "soatReferenceRecord "
+ "soatText "
+ "soatPick "
+ "soatBoolean "
+ "soatEDocument "
+ "soatAccount "
+ "soatIntegerCollection "
+ "soatNumericCollection "
+ "soatStringCollection "
+ "soatPickCollection "
+ "soatDatetimeCollection "
+ "soatBooleanCollection "
+ "soatReferenceRecordCollection "
+ "soatEDocumentCollection "
+ "soatAccountCollection "
+ "soatContents "
+ "soatUnknown ";
// enum TTaskAbortReason
const TTaskAbortReason = "tarAbortByUser " + "tarAbortByWorkflowException ";
// enum TTextValueType
const TTextValueType = "tvtAllWords " + "tvtExactPhrase " + "tvtAnyWord ";
// enum TUserObjectStatus
const TUserObjectStatus =
"usNone "
+ "usCompleted "
+ "usRedSquare "
+ "usBlueSquare "
+ "usYellowSquare "
+ "usGreenSquare "
+ "usOrangeSquare "
+ "usPurpleSquare "
+ "usFollowUp ";
// enum TUserType
const TUserType =
"utUnknown "
+ "utUser "
+ "utDeveloper "
+ "utAdministrator "
+ "utSystemDeveloper "
+ "utDisconnected ";
// enum TValuesBuildType
const TValuesBuildType =
"btAnd " + "btDetailAnd " + "btOr " + "btNotOr " + "btOnly ";
// enum TViewMode
const TViewMode = "vmView " + "vmSelect " + "vmNavigation ";
// enum TViewSelectionMode
const TViewSelectionMode =
"vsmSingle " + "vsmMultiple " + "vsmMultipleCheck " + "vsmNoSelection ";
// enum TWizardActionType
const TWizardActionType =
"wfatPrevious " + "wfatNext " + "wfatCancel " + "wfatFinish ";
// enum TWizardFormElementProperty
const TWizardFormElementProperty =
"wfepUndefined "
+ "wfepText3 "
+ "wfepText6 "
+ "wfepText9 "
+ "wfepSpinEdit "
+ "wfepDropDown "
+ "wfepRadioGroup "
+ "wfepFlag "
+ "wfepText12 "
+ "wfepText15 "
+ "wfepText18 "
+ "wfepText21 "
+ "wfepText24 "
+ "wfepText27 "
+ "wfepText30 "
+ "wfepRadioGroupColumn1 "
+ "wfepRadioGroupColumn2 "
+ "wfepRadioGroupColumn3 ";
// enum TWizardFormElementType
const TWizardFormElementType =
"wfetQueryParameter " + "wfetText " + "wfetDelimiter " + "wfetLabel ";
// enum TWizardParamType
const TWizardParamType =
"wptString "
+ "wptInteger "
+ "wptNumeric "
+ "wptBoolean "
+ "wptDateTime "
+ "wptPick "
+ "wptText "
+ "wptUser "
+ "wptUserList "
+ "wptEDocumentInfo "
+ "wptEDocumentInfoList "
+ "wptReferenceRecordInfo "
+ "wptReferenceRecordInfoList "
+ "wptFolderInfo "
+ "wptTaskInfo "
+ "wptContents "
+ "wptFileName "
+ "wptDate ";
// enum TWizardStepResult
const TWizardStepResult =
"wsrComplete "
+ "wsrGoNext "
+ "wsrGoPrevious "
+ "wsrCustom "
+ "wsrCancel "
+ "wsrGoFinal ";
// enum TWizardStepType
const TWizardStepType =
"wstForm "
+ "wstEDocument "
+ "wstTaskCard "
+ "wstReferenceRecordCard "
+ "wstFinal ";
// enum TWorkAccessType
const TWorkAccessType = "waAll " + "waPerformers " + "waManual ";
// enum TWorkflowBlockType
const TWorkflowBlockType =
"wsbStart "
+ "wsbFinish "
+ "wsbNotice "
+ "wsbStep "
+ "wsbDecision "
+ "wsbWait "
+ "wsbMonitor "
+ "wsbScript "
+ "wsbConnector "
+ "wsbSubTask "
+ "wsbLifeCycleStage "
+ "wsbPause ";
// enum TWorkflowDataType
const TWorkflowDataType =
"wdtInteger "
+ "wdtFloat "
+ "wdtString "
+ "wdtPick "
+ "wdtDateTime "
+ "wdtBoolean "
+ "wdtTask "
+ "wdtJob "
+ "wdtFolder "
+ "wdtEDocument "
+ "wdtReferenceRecord "
+ "wdtUser "
+ "wdtGroup "
+ "wdtRole "
+ "wdtIntegerCollection "
+ "wdtFloatCollection "
+ "wdtStringCollection "
+ "wdtPickCollection "
+ "wdtDateTimeCollection "
+ "wdtBooleanCollection "
+ "wdtTaskCollection "
+ "wdtJobCollection "
+ "wdtFolderCollection "
+ "wdtEDocumentCollection "
+ "wdtReferenceRecordCollection "
+ "wdtUserCollection "
+ "wdtGroupCollection "
+ "wdtRoleCollection "
+ "wdtContents "
+ "wdtUserList "
+ "wdtSearchDescription "
+ "wdtDeadLine "
+ "wdtPickSet "
+ "wdtAccountCollection ";
// enum TWorkImportance
const TWorkImportance = "wiLow " + "wiNormal " + "wiHigh ";
// enum TWorkRouteType
const TWorkRouteType = "wrtSoft " + "wrtHard ";
// enum TWorkState
const TWorkState =
"wsInit "
+ "wsRunning "
+ "wsDone "
+ "wsControlled "
+ "wsAborted "
+ "wsContinued ";
// enum TWorkTextBuildingMode
const TWorkTextBuildingMode =
"wtmFull " + "wtmFromCurrent " + "wtmOnlyCurrent ";
// Перечисления
const ENUMS =
TAccountType
+ TActionEnabledMode
+ TAddPosition
+ TAlignment
+ TAreaShowMode
+ TCertificateInvalidationReason
+ TCertificateType
+ TCheckListBoxItemState
+ TCloseOnEsc
+ TCompType
+ TConditionFormat
+ TConnectionIntent
+ TContentKind
+ TControlType
+ TCriterionContentType
+ TCultureType
+ TDataSetEventType
+ TDataSetState
+ TDateFormatType
+ TDateOffsetType
+ TDateTimeKind
+ TDeaAccessRights
+ TDocumentDefaultAction
+ TEditMode
+ TEditorCloseObservType
+ TEdmsApplicationAction
+ TEDocumentLockType
+ TEDocumentStepShowMode
+ TEDocumentStepVersionType
+ TEDocumentStorageFunction
+ TEDocumentStorageType
+ TEDocumentVersionSourceType
+ TEDocumentVersionState
+ TEncodeType
+ TExceptionCategory
+ TExportedSignaturesType
+ TExportedVersionType
+ TFieldDataType
+ TFolderType
+ TGridRowHeight
+ THyperlinkType
+ TImageFileFormat
+ TImageMode
+ TImageType
+ TInplaceHintKind
+ TISBLContext
+ TItemShow
+ TJobKind
+ TJoinType
+ TLabelPos
+ TLicensingType
+ TLifeCycleStageFontColor
+ TLifeCycleStageFontStyle
+ TLockableDevelopmentComponentType
+ TMaxRecordCountRestrictionType
+ TRangeValueType
+ TRelativeDate
+ TReportDestination
+ TReqDataType
+ TRequisiteEventType
+ TSBTimeType
+ TSearchShowMode
+ TSelectMode
+ TSignatureType
+ TSignerContentType
+ TStringsSortType
+ TStringValueType
+ TStructuredObjectAttributeType
+ TTaskAbortReason
+ TTextValueType
+ TUserObjectStatus
+ TUserType
+ TValuesBuildType
+ TViewMode
+ TViewSelectionMode
+ TWizardActionType
+ TWizardFormElementProperty
+ TWizardFormElementType
+ TWizardParamType
+ TWizardStepResult
+ TWizardStepType
+ TWorkAccessType
+ TWorkflowBlockType
+ TWorkflowDataType
+ TWorkImportance
+ TWorkRouteType
+ TWorkState
+ TWorkTextBuildingMode;
// Системные функции ==> SYSFUNCTIONS
const system_functions =
"AddSubString "
+ "AdjustLineBreaks "
+ "AmountInWords "
+ "Analysis "
+ "ArrayDimCount "
+ "ArrayHighBound "
+ "ArrayLowBound "
+ "ArrayOf "
+ "ArrayReDim "
+ "Assert "
+ "Assigned "
+ "BeginOfMonth "
+ "BeginOfPeriod "
+ "BuildProfilingOperationAnalysis "
+ "CallProcedure "
+ "CanReadFile "
+ "CArrayElement "
+ "CDataSetRequisite "
+ "ChangeDate "
+ "ChangeReferenceDataset "
+ "Char "
+ "CharPos "
+ "CheckParam "
+ "CheckParamValue "
+ "CompareStrings "
+ "ConstantExists "
+ "ControlState "
+ "ConvertDateStr "
+ "Copy "
+ "CopyFile "
+ "CreateArray "
+ "CreateCachedReference "
+ "CreateConnection "
+ "CreateDialog "
+ "CreateDualListDialog "
+ "CreateEditor "
+ "CreateException "
+ "CreateFile "
+ "CreateFolderDialog "
+ "CreateInputDialog "
+ "CreateLinkFile "
+ "CreateList "
+ "CreateLock "
+ "CreateMemoryDataSet "
+ "CreateObject "
+ "CreateOpenDialog "
+ "CreateProgress "
+ "CreateQuery "
+ "CreateReference "
+ "CreateReport "
+ "CreateSaveDialog "
+ "CreateScript "
+ "CreateSQLPivotFunction "
+ "CreateStringList "
+ "CreateTreeListSelectDialog "
+ "CSelectSQL "
+ "CSQL "
+ "CSubString "
+ "CurrentUserID "
+ "CurrentUserName "
+ "CurrentVersion "
+ "DataSetLocateEx "
+ "DateDiff "
+ "DateTimeDiff "
+ "DateToStr "
+ "DayOfWeek "
+ "DeleteFile "
+ "DirectoryExists "
+ "DisableCheckAccessRights "
+ "DisableCheckFullShowingRestriction "
+ "DisableMassTaskSendingRestrictions "
+ "DropTable "
+ "DupeString "
+ "EditText "
+ "EnableCheckAccessRights "
+ "EnableCheckFullShowingRestriction "
+ "EnableMassTaskSendingRestrictions "
+ "EndOfMonth "
+ "EndOfPeriod "
+ "ExceptionExists "
+ "ExceptionsOff "
+ "ExceptionsOn "
+ "Execute "
+ "ExecuteProcess "
+ "Exit "
+ "ExpandEnvironmentVariables "
+ "ExtractFileDrive "
+ "ExtractFileExt "
+ "ExtractFileName "
+ "ExtractFilePath "
+ "ExtractParams "
+ "FileExists "
+ "FileSize "
+ "FindFile "
+ "FindSubString "
+ "FirmContext "
+ "ForceDirectories "
+ "Format "
+ "FormatDate "
+ "FormatNumeric "
+ "FormatSQLDate "
+ "FormatString "
+ "FreeException "
+ "GetComponent "
+ "GetComponentLaunchParam "
+ "GetConstant "
+ "GetLastException "
+ "GetReferenceRecord "
+ "GetRefTypeByRefID "
+ "GetTableID "
+ "GetTempFolder "
+ "IfThen "
+ "In "
+ "IndexOf "
+ "InputDialog "
+ "InputDialogEx "
+ "InteractiveMode "
+ "IsFileLocked "
+ "IsGraphicFile "
+ "IsNumeric "
+ "Length "
+ "LoadString "
+ "LoadStringFmt "
+ "LocalTimeToUTC "
+ "LowerCase "
+ "Max "
+ "MessageBox "
+ "MessageBoxEx "
+ "MimeDecodeBinary "
+ "MimeDecodeString "
+ "MimeEncodeBinary "
+ "MimeEncodeString "
+ "Min "
+ "MoneyInWords "
+ "MoveFile "
+ "NewID "
+ "Now "
+ "OpenFile "
+ "Ord "
+ "Precision "
+ "Raise "
+ "ReadCertificateFromFile "
+ "ReadFile "
+ "ReferenceCodeByID "
+ "ReferenceNumber "
+ "ReferenceRequisiteMode "
+ "ReferenceRequisiteValue "
+ "RegionDateSettings "
+ "RegionNumberSettings "
+ "RegionTimeSettings "
+ "RegRead "
+ "RegWrite "
+ "RenameFile "
+ "Replace "
+ "Round "
+ "SelectServerCode "
+ "SelectSQL "
+ "ServerDateTime "
+ "SetConstant "
+ "SetManagedFolderFieldsState "
+ "ShowConstantsInputDialog "
+ "ShowMessage "
+ "Sleep "
+ "Split "
+ "SQL "
+ "SQL2XLSTAB "
+ "SQLProfilingSendReport "
+ "StrToDate "
+ "SubString "
+ "SubStringCount "
+ "SystemSetting "
+ "Time "
+ "TimeDiff "
+ "Today "
+ "Transliterate "
+ "Trim "
+ "UpperCase "
+ "UserStatus "
+ "UTCToLocalTime "
+ "ValidateXML "
+ "VarIsClear "
+ "VarIsEmpty "
+ "VarIsNull "
+ "WorkTimeDiff "
+ "WriteFile "
+ "WriteFileEx "
+ "WriteObjectHistory "
+ "Анализ "
+ "БазаДанных "
+ "БлокЕсть "
+ "БлокЕстьРасш "
+ "БлокИнфо "
+ "БлокСнять "
+ "БлокСнятьРасш "
+ "БлокУстановить "
+ "Ввод "
+ "ВводМеню "
+ "ВедС "
+ "ВедСпр "
+ "ВерхняяГраницаМассива "
+ "ВнешПрогр "
+ "Восст "
+ "ВременнаяПапка "
+ "Время "
+ "ВыборSQL "
+ "ВыбратьЗапись "
+ "ВыделитьСтр "
+ "Вызвать "
+ "Выполнить "
+ "ВыпПрогр "
+ "ГрафическийФайл "
+ "ГруппаДополнительно "
+ "ДатаВремяСерв "
+ "ДеньНедели "
+ "ДиалогДаНет "
+ "ДлинаСтр "
+ "ДобПодстр "
+ "ЕПусто "
+ "ЕслиТо "
+ "ЕЧисло "
+ "ЗамПодстр "
+ "ЗаписьСправочника "
+ "ЗначПоляСпр "
+ "ИДТипСпр "
+ "ИзвлечьДиск "
+ "ИзвлечьИмяФайла "
+ "ИзвлечьПуть "
+ "ИзвлечьРасширение "
+ "ИзмДат "
+ "ИзменитьРазмерМассива "
+ "ИзмеренийМассива "
+ "ИмяОрг "
+ "ИмяПоляСпр "
+ "Индекс "
+ "ИндикаторЗакрыть "
+ "ИндикаторОткрыть "
+ "ИндикаторШаг "
+ "ИнтерактивныйРежим "
+ "ИтогТблСпр "
+ "КодВидВедСпр "
+ "КодВидСпрПоИД "
+ "КодПоAnalit "
+ "КодСимвола "
+ "КодСпр "
+ "КолПодстр "
+ "КолПроп "
+ "КонМес "
+ "Конст "
+ "КонстЕсть "
+ "КонстЗнач "
+ "КонТран "
+ "КопироватьФайл "
+ "КопияСтр "
+ "КПериод "
+ "КСтрТблСпр "
+ "Макс "
+ "МаксСтрТблСпр "
+ "Массив "
+ "Меню "
+ "МенюРасш "
+ "Мин "
+ "НаборДанныхНайтиРасш "
+ "НаимВидСпр "
+ "НаимПоAnalit "
+ "НаимСпр "
+ "НастроитьПереводыСтрок "
+ "НачМес "
+ "НачТран "
+ "НижняяГраницаМассива "
+ "НомерСпр "
+ "НПериод "
+ "Окно "
+ "Окр "
+ "Окружение "
+ "ОтлИнфДобавить "
+ "ОтлИнфУдалить "
+ "Отчет "
+ "ОтчетАнал "
+ "ОтчетИнт "
+ "ПапкаСуществует "
+ "Пауза "
+ "ПВыборSQL "
+ "ПереименоватьФайл "
+ "Переменные "
+ "ПереместитьФайл "
+ "Подстр "
+ "ПоискПодстр "
+ "ПоискСтр "
+ "ПолучитьИДТаблицы "
+ "ПользовательДополнительно "
+ "ПользовательИД "
+ "ПользовательИмя "
+ "ПользовательСтатус "
+ "Прервать "
+ "ПроверитьПараметр "
+ "ПроверитьПараметрЗнач "
+ "ПроверитьУсловие "
+ "РазбСтр "
+ "РазнВремя "
+ "РазнДат "
+ "РазнДатаВремя "
+ "РазнРабВремя "
+ "РегУстВрем "
+ "РегУстДат "
+ "РегУстЧсл "
+ "РедТекст "
+ "РеестрЗапись "
+ "РеестрСписокИменПарам "
+ "РеестрЧтение "
+ "РеквСпр "
+ "РеквСпрПр "
+ "Сегодня "
+ "Сейчас "
+ "Сервер "
+ "СерверПроцессИД "
+ "СертификатФайлСчитать "
+ "СжПроб "
+ "Символ "
+ "СистемаДиректумКод "
+ "СистемаИнформация "
+ "СистемаКод "
+ "Содержит "
+ "СоединениеЗакрыть "
+ "СоединениеОткрыть "
+ "СоздатьДиалог "
+ "СоздатьДиалогВыбораИзДвухСписков "
+ "СоздатьДиалогВыбораПапки "
+ "СоздатьДиалогОткрытияФайла "
+ "СоздатьДиалогСохраненияФайла "
+ "СоздатьЗапрос "
+ "СоздатьИндикатор "
+ "СоздатьИсключение "
+ "СоздатьКэшированныйСправочник "
+ "СоздатьМассив "
+ "СоздатьНаборДанных "
+ "СоздатьОбъект "
+ "СоздатьОтчет "
+ "СоздатьПапку "
+ "СоздатьРедактор "
+ "СоздатьСоединение "
+ "СоздатьСписок "
+ "СоздатьСписокСтрок "
+ "СоздатьСправочник "
+ "СоздатьСценарий "
+ "СоздСпр "
+ "СостСпр "
+ "Сохр "
+ "СохрСпр "
+ "СписокСистем "
+ "Спр "
+ "Справочник "
+ "СпрБлокЕсть "
+ "СпрБлокСнять "
+ "СпрБлокСнятьРасш "
+ "СпрБлокУстановить "
+ "СпрИзмНабДан "
+ "СпрКод "
+ "СпрНомер "
+ "СпрОбновить "
+ "СпрОткрыть "
+ "СпрОтменить "
+ "СпрПарам "
+ "СпрПолеЗнач "
+ "СпрПолеИмя "
+ "СпрРекв "
+ "СпрРеквВведЗн "
+ "СпрРеквНовые "
+ "СпрРеквПр "
+ "СпрРеквПредЗн "
+ "СпрРеквРежим "
+ "СпрРеквТипТекст "
+ "СпрСоздать "
+ "СпрСост "
+ "СпрСохранить "
+ "СпрТблИтог "
+ "СпрТблСтр "
+ "СпрТблСтрКол "
+ "СпрТблСтрМакс "
+ "СпрТблСтрМин "
+ "СпрТблСтрПред "
+ "СпрТблСтрСлед "
+ "СпрТблСтрСозд "
+ "СпрТблСтрУд "
+ "СпрТекПредст "
+ "СпрУдалить "
+ "СравнитьСтр "
+ "СтрВерхРегистр "
+ "СтрНижнРегистр "
+ "СтрТблСпр "
+ "СумПроп "
+ "Сценарий "
+ "СценарийПарам "
+ "ТекВерсия "
+ "ТекОрг "
+ "Точн "
+ "Тран "
+ "Транслитерация "
+ "УдалитьТаблицу "
+ "УдалитьФайл "
+ "УдСпр "
+ "УдСтрТблСпр "
+ "Уст "
+ "УстановкиКонстант "
+ "ФайлАтрибутСчитать "
+ "ФайлАтрибутУстановить "
+ "ФайлВремя "
+ "ФайлВремяУстановить "
+ "ФайлВыбрать "
+ "ФайлЗанят "
+ "ФайлЗаписать "
+ "ФайлИскать "
+ "ФайлКопировать "
+ "ФайлМожноЧитать "
+ "ФайлОткрыть "
+ "ФайлПереименовать "
+ "ФайлПерекодировать "
+ "ФайлПереместить "
+ "ФайлПросмотреть "
+ "ФайлРазмер "
+ "ФайлСоздать "
+ "ФайлСсылкаСоздать "
+ "ФайлСуществует "
+ "ФайлСчитать "
+ "ФайлУдалить "
+ "ФмтSQLДат "
+ "ФмтДат "
+ "ФмтСтр "
+ "ФмтЧсл "
+ "Формат "
+ "ЦМассивЭлемент "
+ "ЦНаборДанныхРеквизит "
+ "ЦПодстр ";
// Предопределенные переменные ==> built_in
const predefined_variables =
"AltState "
+ "Application "
+ "CallType "
+ "ComponentTokens "
+ "CreatedJobs "
+ "CreatedNotices "
+ "ControlState "
+ "DialogResult "
+ "Dialogs "
+ "EDocuments "
+ "EDocumentVersionSource "
+ "Folders "
+ "GlobalIDs "
+ "Job "
+ "Jobs "
+ "InputValue "
+ "LookUpReference "
+ "LookUpRequisiteNames "
+ "LookUpSearch "
+ "Object "
+ "ParentComponent "
+ "Processes "
+ "References "
+ "Requisite "
+ "ReportName "
+ "Reports "
+ "Result "
+ "Scripts "
+ "Searches "
+ "SelectedAttachments "
+ "SelectedItems "
+ "SelectMode "
+ "Sender "
+ "ServerEvents "
+ "ServiceFactory "
+ "ShiftState "
+ "SubTask "
+ "SystemDialogs "
+ "Tasks "
+ "Wizard "
+ "Wizards "
+ "Work "
+ "ВызовСпособ "
+ "ИмяОтчета "
+ "РеквЗнач ";
// Интерфейсы ==> type
const interfaces =
"IApplication "
+ "IAccessRights "
+ "IAccountRepository "
+ "IAccountSelectionRestrictions "
+ "IAction "
+ "IActionList "
+ "IAdministrationHistoryDescription "
+ "IAnchors "
+ "IApplication "
+ "IArchiveInfo "
+ "IAttachment "
+ "IAttachmentList "
+ "ICheckListBox "
+ "ICheckPointedList "
+ "IColumn "
+ "IComponent "
+ "IComponentDescription "
+ "IComponentToken "
+ "IComponentTokenFactory "
+ "IComponentTokenInfo "
+ "ICompRecordInfo "
+ "IConnection "
+ "IContents "
+ "IControl "
+ "IControlJob "
+ "IControlJobInfo "
+ "IControlList "
+ "ICrypto "
+ "ICrypto2 "
+ "ICustomJob "
+ "ICustomJobInfo "
+ "ICustomListBox "
+ "ICustomObjectWizardStep "
+ "ICustomWork "
+ "ICustomWorkInfo "
+ "IDataSet "
+ "IDataSetAccessInfo "
+ "IDataSigner "
+ "IDateCriterion "
+ "IDateRequisite "
+ "IDateRequisiteDescription "
+ "IDateValue "
+ "IDeaAccessRights "
+ "IDeaObjectInfo "
+ "IDevelopmentComponentLock "
+ "IDialog "
+ "IDialogFactory "
+ "IDialogPickRequisiteItems "
+ "IDialogsFactory "
+ "IDICSFactory "
+ "IDocRequisite "
+ "IDocumentInfo "
+ "IDualListDialog "
+ "IECertificate "
+ "IECertificateInfo "
+ "IECertificates "
+ "IEditControl "
+ "IEditorForm "
+ "IEdmsExplorer "
+ "IEdmsObject "
+ "IEdmsObjectDescription "
+ "IEdmsObjectFactory "
+ "IEdmsObjectInfo "
+ "IEDocument "
+ "IEDocumentAccessRights "
+ "IEDocumentDescription "
+ "IEDocumentEditor "
+ "IEDocumentFactory "
+ "IEDocumentInfo "
+ "IEDocumentStorage "
+ "IEDocumentVersion "
+ "IEDocumentVersionListDialog "
+ "IEDocumentVersionSource "
+ "IEDocumentWizardStep "
+ "IEDocVerSignature "
+ "IEDocVersionState "
+ "IEnabledMode "
+ "IEncodeProvider "
+ "IEncrypter "
+ "IEvent "
+ "IEventList "
+ "IException "
+ "IExternalEvents "
+ "IExternalHandler "
+ "IFactory "
+ "IField "
+ "IFileDialog "
+ "IFolder "
+ "IFolderDescription "
+ "IFolderDialog "
+ "IFolderFactory "
+ "IFolderInfo "
+ "IForEach "
+ "IForm "
+ "IFormTitle "
+ "IFormWizardStep "
+ "IGlobalIDFactory "
+ "IGlobalIDInfo "
+ "IGrid "
+ "IHasher "
+ "IHistoryDescription "
+ "IHyperLinkControl "
+ "IImageButton "
+ "IImageControl "
+ "IInnerPanel "
+ "IInplaceHint "
+ "IIntegerCriterion "
+ "IIntegerList "
+ "IIntegerRequisite "
+ "IIntegerValue "
+ "IISBLEditorForm "
+ "IJob "
+ "IJobDescription "
+ "IJobFactory "
+ "IJobForm "
+ "IJobInfo "
+ "ILabelControl "
+ "ILargeIntegerCriterion "
+ "ILargeIntegerRequisite "
+ "ILargeIntegerValue "
+ "ILicenseInfo "
+ "ILifeCycleStage "
+ "IList "
+ "IListBox "
+ "ILocalIDInfo "
+ "ILocalization "
+ "ILock "
+ "IMemoryDataSet "
+ "IMessagingFactory "
+ "IMetadataRepository "
+ "INotice "
+ "INoticeInfo "
+ "INumericCriterion "
+ "INumericRequisite "
+ "INumericValue "
+ "IObject "
+ "IObjectDescription "
+ "IObjectImporter "
+ "IObjectInfo "
+ "IObserver "
+ "IPanelGroup "
+ "IPickCriterion "
+ "IPickProperty "
+ "IPickRequisite "
+ "IPickRequisiteDescription "
+ "IPickRequisiteItem "
+ "IPickRequisiteItems "
+ "IPickValue "
+ "IPrivilege "
+ "IPrivilegeList "
+ "IProcess "
+ "IProcessFactory "
+ "IProcessMessage "
+ "IProgress "
+ "IProperty "
+ "IPropertyChangeEvent "
+ "IQuery "
+ "IReference "
+ "IReferenceCriterion "
+ "IReferenceEnabledMode "
+ "IReferenceFactory "
+ "IReferenceHistoryDescription "
+ "IReferenceInfo "
+ "IReferenceRecordCardWizardStep "
+ "IReferenceRequisiteDescription "
+ "IReferencesFactory "
+ "IReferenceValue "
+ "IRefRequisite "
+ "IReport "
+ "IReportFactory "
+ "IRequisite "
+ "IRequisiteDescription "
+ "IRequisiteDescriptionList "
+ "IRequisiteFactory "
+ "IRichEdit "
+ "IRouteStep "
+ "IRule "
+ "IRuleList "
+ "ISchemeBlock "
+ "IScript "
+ "IScriptFactory "
+ "ISearchCriteria "
+ "ISearchCriterion "
+ "ISearchDescription "
+ "ISearchFactory "
+ "ISearchFolderInfo "
+ "ISearchForObjectDescription "
+ "ISearchResultRestrictions "
+ "ISecuredContext "
+ "ISelectDialog "
+ "IServerEvent "
+ "IServerEventFactory "
+ "IServiceDialog "
+ "IServiceFactory "
+ "ISignature "
+ "ISignProvider "
+ "ISignProvider2 "
+ "ISignProvider3 "
+ "ISimpleCriterion "
+ "IStringCriterion "
+ "IStringList "
+ "IStringRequisite "
+ "IStringRequisiteDescription "
+ "IStringValue "
+ "ISystemDialogsFactory "
+ "ISystemInfo "
+ "ITabSheet "
+ "ITask "
+ "ITaskAbortReasonInfo "
+ "ITaskCardWizardStep "
+ "ITaskDescription "
+ "ITaskFactory "
+ "ITaskInfo "
+ "ITaskRoute "
+ "ITextCriterion "
+ "ITextRequisite "
+ "ITextValue "
+ "ITreeListSelectDialog "
+ "IUser "
+ "IUserList "
+ "IValue "
+ "IView "
+ "IWebBrowserControl "
+ "IWizard "
+ "IWizardAction "
+ "IWizardFactory "
+ "IWizardFormElement "
+ "IWizardParam "
+ "IWizardPickParam "
+ "IWizardReferenceParam "
+ "IWizardStep "
+ "IWorkAccessRights "
+ "IWorkDescription "
+ "IWorkflowAskableParam "
+ "IWorkflowAskableParams "
+ "IWorkflowBlock "
+ "IWorkflowBlockResult "
+ "IWorkflowEnabledMode "
+ "IWorkflowParam "
+ "IWorkflowPickParam "
+ "IWorkflowReferenceParam "
+ "IWorkState "
+ "IWorkTreeCustomNode "
+ "IWorkTreeJobNode "
+ "IWorkTreeTaskNode "
+ "IXMLEditorForm "
+ "SBCrypto ";
// built_in : встроенные или библиотечные объекты (константы, перечисления)
const BUILTIN = CONSTANTS + ENUMS;
// class: встроенные наборы значений, системные объекты, фабрики
const CLASS = predefined_variables;
// literal : примитивные типы
const LITERAL = "null true false nil ";
// number : числа
const NUMBERS = {
className: "number",
begin: hljs.NUMBER_RE,
relevance: 0
};
// string : строки
const STRINGS = {
className: "string",
variants: [
{
begin: '"',
end: '"'
},
{
begin: "'",
end: "'"
}
]
};
// Токены
const DOCTAGS = {
className: "doctag",
begin: "\\b(?:TODO|DONE|BEGIN|END|STUB|CHG|FIXME|NOTE|BUG|XXX)\\b",
relevance: 0
};
// Однострочный комментарий
const ISBL_LINE_COMMENT_MODE = {
className: "comment",
begin: "//",
end: "$",
relevance: 0,
contains: [
hljs.PHRASAL_WORDS_MODE,
DOCTAGS
]
};
// Многострочный комментарий
const ISBL_BLOCK_COMMENT_MODE = {
className: "comment",
begin: "/\\*",
end: "\\*/",
relevance: 0,
contains: [
hljs.PHRASAL_WORDS_MODE,
DOCTAGS
]
};
// comment : комментарии
const COMMENTS = { variants: [
ISBL_LINE_COMMENT_MODE,
ISBL_BLOCK_COMMENT_MODE
] };
// keywords : ключевые слова
const KEYWORDS = {
$pattern: UNDERSCORE_IDENT_RE,
keyword: KEYWORD,
built_in: BUILTIN,
class: CLASS,
literal: LITERAL
};
// methods : методы
const METHODS = {
begin: "\\.\\s*" + hljs.UNDERSCORE_IDENT_RE,
keywords: KEYWORDS,
relevance: 0
};
// type : встроенные типы
const TYPES = {
className: "type",
begin: ":[ \\t]*(" + interfaces.trim().replace(/\s/g, "|") + ")",
end: "[ \\t]*=",
excludeEnd: true
};
// variables : переменные
const VARIABLES = {
className: "variable",
keywords: KEYWORDS,
begin: UNDERSCORE_IDENT_RE,
relevance: 0,
contains: [
TYPES,
METHODS
]
};
// Имена функций
const FUNCTION_TITLE = FUNCTION_NAME_IDENT_RE + "\\(";
const TITLE_MODE = {
className: "title",
keywords: {
$pattern: UNDERSCORE_IDENT_RE,
built_in: system_functions
},
begin: FUNCTION_TITLE,
end: "\\(",
returnBegin: true,
excludeEnd: true
};
// function : функции
const FUNCTIONS = {
className: "function",
begin: FUNCTION_TITLE,
end: "\\)$",
returnBegin: true,
keywords: KEYWORDS,
illegal: "[\\[\\]\\|\\$\\?%,~#@]",
contains: [
TITLE_MODE,
METHODS,
VARIABLES,
STRINGS,
NUMBERS,
COMMENTS
]
};
return {
name: 'ISBL',
case_insensitive: true,
keywords: KEYWORDS,
illegal: "\\$|\\?|%|,|;$|~|#|@|</",
contains: [
FUNCTIONS,
TYPES,
METHODS,
VARIABLES,
STRINGS,
NUMBERS,
COMMENTS
]
};
}
var isbl_1 = isbl;
// https://docs.oracle.com/javase/specs/jls/se15/html/jls-3.html#jls-3.10
var decimalDigits$1 = '[0-9](_*[0-9])*';
var frac$1 = `\\.(${decimalDigits$1})`;
var hexDigits$1 = '[0-9a-fA-F](_*[0-9a-fA-F])*';
var NUMERIC$1 = {
className: 'number',
variants: [
// DecimalFloatingPointLiteral
// including ExponentPart
{ begin: `(\\b(${decimalDigits$1})((${frac$1})|\\.)?|(${frac$1}))` +
`[eE][+-]?(${decimalDigits$1})[fFdD]?\\b` },
// excluding ExponentPart
{ begin: `\\b(${decimalDigits$1})((${frac$1})[fFdD]?\\b|\\.([fFdD]\\b)?)` },
{ begin: `(${frac$1})[fFdD]?\\b` },
{ begin: `\\b(${decimalDigits$1})[fFdD]\\b` },
// HexadecimalFloatingPointLiteral
{ begin: `\\b0[xX]((${hexDigits$1})\\.?|(${hexDigits$1})?\\.(${hexDigits$1}))` +
`[pP][+-]?(${decimalDigits$1})[fFdD]?\\b` },
// DecimalIntegerLiteral
{ begin: '\\b(0|[1-9](_*[0-9])*)[lL]?\\b' },
// HexIntegerLiteral
{ begin: `\\b0[xX](${hexDigits$1})[lL]?\\b` },
// OctalIntegerLiteral
{ begin: '\\b0(_*[0-7])*[lL]?\\b' },
// BinaryIntegerLiteral
{ begin: '\\b0[bB][01](_*[01])*[lL]?\\b' },
],
relevance: 0
};
/*
Language: Java
Author: Vsevolod Solovyov <vsevolod.solovyov@gmail.com>
Category: common, enterprise
Website: https://www.java.com/
*/
/**
* Allows recursive regex expressions to a given depth
*
* ie: recurRegex("(abc~~~)", /~~~/g, 2) becomes:
* (abc(abc(abc)))
*
* @param {string} re
* @param {RegExp} substitution (should be a g mode regex)
* @param {number} depth
* @returns {string}``
*/
function recurRegex(re, substitution, depth) {
if (depth === -1) return "";
return re.replace(substitution, _ => {
return recurRegex(re, substitution, depth - 1);
});
}
/** @type LanguageFn */
function java(hljs) {
const regex = hljs.regex;
const JAVA_IDENT_RE = '[\u00C0-\u02B8a-zA-Z_$][\u00C0-\u02B8a-zA-Z_$0-9]*';
const GENERIC_IDENT_RE = JAVA_IDENT_RE
+ recurRegex('(?:<' + JAVA_IDENT_RE + '~~~(?:\\s*,\\s*' + JAVA_IDENT_RE + '~~~)*>)?', /~~~/g, 2);
const MAIN_KEYWORDS = [
'synchronized',
'abstract',
'private',
'var',
'static',
'if',
'const ',
'for',
'while',
'strictfp',
'finally',
'protected',
'import',
'native',
'final',
'void',
'enum',
'else',
'break',
'transient',
'catch',
'instanceof',
'volatile',
'case',
'assert',
'package',
'default',
'public',
'try',
'switch',
'continue',
'throws',
'protected',
'public',
'private',
'module',
'requires',
'exports',
'do',
'sealed',
'yield',
'permits'
];
const BUILT_INS = [
'super',
'this'
];
const LITERALS = [
'false',
'true',
'null'
];
const TYPES = [
'char',
'boolean',
'long',
'float',
'int',
'byte',
'short',
'double'
];
const KEYWORDS = {
keyword: MAIN_KEYWORDS,
literal: LITERALS,
type: TYPES,
built_in: BUILT_INS
};
const ANNOTATION = {
className: 'meta',
begin: '@' + JAVA_IDENT_RE,
contains: [
{
begin: /\(/,
end: /\)/,
contains: [ "self" ] // allow nested () inside our annotation
}
]
};
const PARAMS = {
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
relevance: 0,
contains: [ hljs.C_BLOCK_COMMENT_MODE ],
endsParent: true
};
return {
name: 'Java',
aliases: [ 'jsp' ],
keywords: KEYWORDS,
illegal: /<\/|#/,
contains: [
hljs.COMMENT(
'/\\*\\*',
'\\*/',
{
relevance: 0,
contains: [
{
// eat up @'s in emails to prevent them to be recognized as doctags
begin: /\w+@/,
relevance: 0
},
{
className: 'doctag',
begin: '@[A-Za-z]+'
}
]
}
),
// relevance boost
{
begin: /import java\.[a-z]+\./,
keywords: "import",
relevance: 2
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
begin: /"""/,
end: /"""/,
className: "string",
contains: [ hljs.BACKSLASH_ESCAPE ]
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
match: [
/\b(?:class|interface|enum|extends|implements|new)/,
/\s+/,
JAVA_IDENT_RE
],
className: {
1: "keyword",
3: "title.class"
}
},
{
// Exceptions for hyphenated keywords
match: /non-sealed/,
scope: "keyword"
},
{
begin: [
regex.concat(/(?!else)/, JAVA_IDENT_RE),
/\s+/,
JAVA_IDENT_RE,
/\s+/,
/=(?!=)/
],
className: {
1: "type",
3: "variable",
5: "operator"
}
},
{
begin: [
/record/,
/\s+/,
JAVA_IDENT_RE
],
className: {
1: "keyword",
3: "title.class"
},
contains: [
PARAMS,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
// Expression keywords prevent 'keyword Name(...)' from being
// recognized as a function definition
beginKeywords: 'new throw return else',
relevance: 0
},
{
begin: [
'(?:' + GENERIC_IDENT_RE + '\\s+)',
hljs.UNDERSCORE_IDENT_RE,
/\s*(?=\()/
],
className: { 2: "title.function" },
keywords: KEYWORDS,
contains: [
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
relevance: 0,
contains: [
ANNOTATION,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
NUMERIC$1,
hljs.C_BLOCK_COMMENT_MODE
]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
NUMERIC$1,
ANNOTATION
]
};
}
var java_1 = java;
const IDENT_RE$1 = '[A-Za-z$_][0-9A-Za-z$_]*';
const KEYWORDS$2 = [
"as", // for exports
"in",
"of",
"if",
"for",
"while",
"finally",
"var",
"new",
"function",
"do",
"return",
"void",
"else",
"break",
"catch",
"instanceof",
"with",
"throw",
"case",
"default",
"try",
"switch",
"continue",
"typeof",
"delete",
"let",
"yield",
"const",
"class",
// JS handles these with a special rule
// "get",
// "set",
"debugger",
"async",
"await",
"static",
"import",
"from",
"export",
"extends"
];
const LITERALS$2 = [
"true",
"false",
"null",
"undefined",
"NaN",
"Infinity"
];
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
const TYPES$2 = [
// Fundamental objects
"Object",
"Function",
"Boolean",
"Symbol",
// numbers and dates
"Math",
"Date",
"Number",
"BigInt",
// text
"String",
"RegExp",
// Indexed collections
"Array",
"Float32Array",
"Float64Array",
"Int8Array",
"Uint8Array",
"Uint8ClampedArray",
"Int16Array",
"Int32Array",
"Uint16Array",
"Uint32Array",
"BigInt64Array",
"BigUint64Array",
// Keyed collections
"Set",
"Map",
"WeakSet",
"WeakMap",
// Structured data
"ArrayBuffer",
"SharedArrayBuffer",
"Atomics",
"DataView",
"JSON",
// Control abstraction objects
"Promise",
"Generator",
"GeneratorFunction",
"AsyncFunction",
// Reflection
"Reflect",
"Proxy",
// Internationalization
"Intl",
// WebAssembly
"WebAssembly"
];
const ERROR_TYPES$2 = [
"Error",
"EvalError",
"InternalError",
"RangeError",
"ReferenceError",
"SyntaxError",
"TypeError",
"URIError"
];
const BUILT_IN_GLOBALS$2 = [
"setInterval",
"setTimeout",
"clearInterval",
"clearTimeout",
"require",
"exports",
"eval",
"isFinite",
"isNaN",
"parseFloat",
"parseInt",
"decodeURI",
"decodeURIComponent",
"encodeURI",
"encodeURIComponent",
"escape",
"unescape"
];
const BUILT_IN_VARIABLES$1 = [
"arguments",
"this",
"super",
"console",
"window",
"document",
"localStorage",
"sessionStorage",
"module",
"global" // Node.js
];
const BUILT_INS$2 = [].concat(
BUILT_IN_GLOBALS$2,
TYPES$2,
ERROR_TYPES$2
);
/*
Language: JavaScript
Description: JavaScript (JS) is a lightweight, interpreted, or just-in-time compiled programming language with first-class functions.
Category: common, scripting, web
Website: https://developer.mozilla.org/en-US/docs/Web/JavaScript
*/
/** @type LanguageFn */
function javascript$1(hljs) {
const regex = hljs.regex;
/**
* Takes a string like "<Booger" and checks to see
* if we can find a matching "</Booger" later in the
* content.
* @param {RegExpMatchArray} match
* @param {{after:number}} param1
*/
const hasClosingTag = (match, { after }) => {
const tag = "</" + match[0].slice(1);
const pos = match.input.indexOf(tag, after);
return pos !== -1;
};
const IDENT_RE$1$1 = IDENT_RE$1;
const FRAGMENT = {
begin: '<>',
end: '</>'
};
// to avoid some special cases inside isTrulyOpeningTag
const XML_SELF_CLOSING = /<[A-Za-z0-9\\._:-]+\s*\/>/;
const XML_TAG = {
begin: /<[A-Za-z0-9\\._:-]+/,
end: /\/[A-Za-z0-9\\._:-]+>|\/>/,
/**
* @param {RegExpMatchArray} match
* @param {CallbackResponse} response
*/
isTrulyOpeningTag: (match, response) => {
const afterMatchIndex = match[0].length + match.index;
const nextChar = match.input[afterMatchIndex];
if (
// HTML should not include another raw `<` inside a tag
// nested type?
// `<Array<Array<number>>`, etc.
nextChar === "<" ||
// the , gives away that this is not HTML
// `<T, A extends keyof T, V>`
nextChar === ","
) {
response.ignoreMatch();
return;
}
// `<something>`
// Quite possibly a tag, lets look for a matching closing tag...
if (nextChar === ">") {
// if we cannot find a matching closing tag, then we
// will ignore it
if (!hasClosingTag(match, { after: afterMatchIndex })) {
response.ignoreMatch();
}
}
// `<blah />` (self-closing)
// handled by simpleSelfClosing rule
let m;
const afterMatch = match.input.substring(afterMatchIndex);
// some more template typing stuff
// <T = any>(key?: string) => Modify<
if ((m = afterMatch.match(/^\s*=/))) {
response.ignoreMatch();
return;
}
// `<From extends string>`
// technically this could be HTML, but it smells like a type
// NOTE: This is ugh, but added specifically for https://github.com/highlightjs/highlight.js/issues/3276
if ((m = afterMatch.match(/^\s+extends\s+/))) {
if (m.index === 0) {
response.ignoreMatch();
// eslint-disable-next-line no-useless-return
return;
}
}
}
};
const KEYWORDS$1 = {
$pattern: IDENT_RE$1,
keyword: KEYWORDS$2,
literal: LITERALS$2,
built_in: BUILT_INS$2,
"variable.language": BUILT_IN_VARIABLES$1
};
// https://tc39.es/ecma262/#sec-literals-numeric-literals
const decimalDigits = '[0-9](_?[0-9])*';
const frac = `\\.(${decimalDigits})`;
// DecimalIntegerLiteral, including Annex B NonOctalDecimalIntegerLiteral
// https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals
const decimalInteger = `0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`;
const NUMBER = {
className: 'number',
variants: [
// DecimalLiteral
{ begin: `(\\b(${decimalInteger})((${frac})|\\.)?|(${frac}))` +
`[eE][+-]?(${decimalDigits})\\b` },
{ begin: `\\b(${decimalInteger})\\b((${frac})\\b|\\.)?|(${frac})\\b` },
// DecimalBigIntegerLiteral
{ begin: `\\b(0|[1-9](_?[0-9])*)n\\b` },
// NonDecimalIntegerLiteral
{ begin: "\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b" },
{ begin: "\\b0[bB][0-1](_?[0-1])*n?\\b" },
{ begin: "\\b0[oO][0-7](_?[0-7])*n?\\b" },
// LegacyOctalIntegerLiteral (does not include underscore separators)
// https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals
{ begin: "\\b0[0-7]+n?\\b" },
],
relevance: 0
};
const SUBST = {
className: 'subst',
begin: '\\$\\{',
end: '\\}',
keywords: KEYWORDS$1,
contains: [] // defined later
};
const HTML_TEMPLATE = {
begin: 'html`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'xml'
}
};
const CSS_TEMPLATE = {
begin: 'css`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'css'
}
};
const GRAPHQL_TEMPLATE = {
begin: 'gql`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'graphql'
}
};
const TEMPLATE_STRING = {
className: 'string',
begin: '`',
end: '`',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
};
const JSDOC_COMMENT = hljs.COMMENT(
/\/\*\*(?!\/)/,
'\\*/',
{
relevance: 0,
contains: [
{
begin: '(?=@[A-Za-z]+)',
relevance: 0,
contains: [
{
className: 'doctag',
begin: '@[A-Za-z]+'
},
{
className: 'type',
begin: '\\{',
end: '\\}',
excludeEnd: true,
excludeBegin: true,
relevance: 0
},
{
className: 'variable',
begin: IDENT_RE$1$1 + '(?=\\s*(-)|$)',
endsParent: true,
relevance: 0
},
// eat spaces (not newlines) so we can find
// types or variables
{
begin: /(?=[^\n])\s/,
relevance: 0
}
]
}
]
}
);
const COMMENT = {
className: "comment",
variants: [
JSDOC_COMMENT,
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_LINE_COMMENT_MODE
]
};
const SUBST_INTERNALS = [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
HTML_TEMPLATE,
CSS_TEMPLATE,
GRAPHQL_TEMPLATE,
TEMPLATE_STRING,
// Skip numbers when they are part of a variable name
{ match: /\$\d+/ },
NUMBER,
// This is intentional:
// See https://github.com/highlightjs/highlight.js/issues/3288
// hljs.REGEXP_MODE
];
SUBST.contains = SUBST_INTERNALS
.concat({
// we need to pair up {} inside our subst to prevent
// it from ending too early by matching another }
begin: /\{/,
end: /\}/,
keywords: KEYWORDS$1,
contains: [
"self"
].concat(SUBST_INTERNALS)
});
const SUBST_AND_COMMENTS = [].concat(COMMENT, SUBST.contains);
const PARAMS_CONTAINS = SUBST_AND_COMMENTS.concat([
// eat recursive parens in sub expressions
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS$1,
contains: ["self"].concat(SUBST_AND_COMMENTS)
}
]);
const PARAMS = {
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS$1,
contains: PARAMS_CONTAINS
};
// ES6 classes
const CLASS_OR_EXTENDS = {
variants: [
// class Car extends vehicle
{
match: [
/class/,
/\s+/,
IDENT_RE$1$1,
/\s+/,
/extends/,
/\s+/,
regex.concat(IDENT_RE$1$1, "(", regex.concat(/\./, IDENT_RE$1$1), ")*")
],
scope: {
1: "keyword",
3: "title.class",
5: "keyword",
7: "title.class.inherited"
}
},
// class Car
{
match: [
/class/,
/\s+/,
IDENT_RE$1$1
],
scope: {
1: "keyword",
3: "title.class"
}
},
]
};
const CLASS_REFERENCE = {
relevance: 0,
match:
regex.either(
// Hard coded exceptions
/\bJSON/,
// Float32Array, OutT
/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,
// CSSFactory, CSSFactoryT
/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,
// FPs, FPsT
/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/,
// P
// single letters are not highlighted
// BLAH
// this will be flagged as a UPPER_CASE_CONSTANT instead
),
className: "title.class",
keywords: {
_: [
// se we still get relevance credit for JS library classes
...TYPES$2,
...ERROR_TYPES$2
]
}
};
const USE_STRICT = {
label: "use_strict",
className: 'meta',
relevance: 10,
begin: /^\s*['"]use (strict|asm)['"]/
};
const FUNCTION_DEFINITION = {
variants: [
{
match: [
/function/,
/\s+/,
IDENT_RE$1$1,
/(?=\s*\()/
]
},
// anonymous function
{
match: [
/function/,
/\s*(?=\()/
]
}
],
className: {
1: "keyword",
3: "title.function"
},
label: "func.def",
contains: [ PARAMS ],
illegal: /%/
};
const UPPER_CASE_CONSTANT = {
relevance: 0,
match: /\b[A-Z][A-Z_0-9]+\b/,
className: "variable.constant"
};
function noneOf(list) {
return regex.concat("(?!", list.join("|"), ")");
}
const FUNCTION_CALL = {
match: regex.concat(
/\b/,
noneOf([
...BUILT_IN_GLOBALS$2,
"super",
"import"
]),
IDENT_RE$1$1, regex.lookahead(/\(/)),
className: "title.function",
relevance: 0
};
const PROPERTY_ACCESS = {
begin: regex.concat(/\./, regex.lookahead(
regex.concat(IDENT_RE$1$1, /(?![0-9A-Za-z$_(])/)
)),
end: IDENT_RE$1$1,
excludeBegin: true,
keywords: "prototype",
className: "property",
relevance: 0
};
const GETTER_OR_SETTER = {
match: [
/get|set/,
/\s+/,
IDENT_RE$1$1,
/(?=\()/
],
className: {
1: "keyword",
3: "title.function"
},
contains: [
{ // eat to avoid empty params
begin: /\(\)/
},
PARAMS
]
};
const FUNC_LEAD_IN_RE = '(\\(' +
'[^()]*(\\(' +
'[^()]*(\\(' +
'[^()]*' +
'\\)[^()]*)*' +
'\\)[^()]*)*' +
'\\)|' + hljs.UNDERSCORE_IDENT_RE + ')\\s*=>';
const FUNCTION_VARIABLE = {
match: [
/const|var|let/, /\s+/,
IDENT_RE$1$1, /\s*/,
/=\s*/,
/(async\s*)?/, // async is optional
regex.lookahead(FUNC_LEAD_IN_RE)
],
keywords: "async",
className: {
1: "keyword",
3: "title.function"
},
contains: [
PARAMS
]
};
return {
name: 'JavaScript',
aliases: ['js', 'jsx', 'mjs', 'cjs'],
keywords: KEYWORDS$1,
// this will be extended by TypeScript
exports: { PARAMS_CONTAINS, CLASS_REFERENCE },
illegal: /#(?![$_A-z])/,
contains: [
hljs.SHEBANG({
label: "shebang",
binary: "node",
relevance: 5
}),
USE_STRICT,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
HTML_TEMPLATE,
CSS_TEMPLATE,
GRAPHQL_TEMPLATE,
TEMPLATE_STRING,
COMMENT,
// Skip numbers when they are part of a variable name
{ match: /\$\d+/ },
NUMBER,
CLASS_REFERENCE,
{
className: 'attr',
begin: IDENT_RE$1$1 + regex.lookahead(':'),
relevance: 0
},
FUNCTION_VARIABLE,
{ // "value" container
begin: '(' + hljs.RE_STARTERS_RE + '|\\b(case|return|throw)\\b)\\s*',
keywords: 'return throw case',
relevance: 0,
contains: [
COMMENT,
hljs.REGEXP_MODE,
{
className: 'function',
// we have to count the parens to make sure we actually have the
// correct bounding ( ) before the =>. There could be any number of
// sub-expressions inside also surrounded by parens.
begin: FUNC_LEAD_IN_RE,
returnBegin: true,
end: '\\s*=>',
contains: [
{
className: 'params',
variants: [
{
begin: hljs.UNDERSCORE_IDENT_RE,
relevance: 0
},
{
className: null,
begin: /\(\s*\)/,
skip: true
},
{
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS$1,
contains: PARAMS_CONTAINS
}
]
}
]
},
{ // could be a comma delimited list of params to a function call
begin: /,/,
relevance: 0
},
{
match: /\s+/,
relevance: 0
},
{ // JSX
variants: [
{ begin: FRAGMENT.begin, end: FRAGMENT.end },
{ match: XML_SELF_CLOSING },
{
begin: XML_TAG.begin,
// we carefully check the opening tag to see if it truly
// is a tag and not a false positive
'on:begin': XML_TAG.isTrulyOpeningTag,
end: XML_TAG.end
}
],
subLanguage: 'xml',
contains: [
{
begin: XML_TAG.begin,
end: XML_TAG.end,
skip: true,
contains: ['self']
}
]
}
],
},
FUNCTION_DEFINITION,
{
// prevent this from getting swallowed up by function
// since they appear "function like"
beginKeywords: "while if switch catch for"
},
{
// we have to count the parens to make sure we actually have the correct
// bounding ( ). There could be any number of sub-expressions inside
// also surrounded by parens.
begin: '\\b(?!function)' + hljs.UNDERSCORE_IDENT_RE +
'\\(' + // first parens
'[^()]*(\\(' +
'[^()]*(\\(' +
'[^()]*' +
'\\)[^()]*)*' +
'\\)[^()]*)*' +
'\\)\\s*\\{', // end parens
returnBegin:true,
label: "func.def",
contains: [
PARAMS,
hljs.inherit(hljs.TITLE_MODE, { begin: IDENT_RE$1$1, className: "title.function" })
]
},
// catch ... so it won't trigger the property rule below
{
match: /\.\.\./,
relevance: 0
},
PROPERTY_ACCESS,
// hack: prevents detection of keywords in some circumstances
// .keyword()
// $keyword = x
{
match: '\\$' + IDENT_RE$1$1,
relevance: 0
},
{
match: [ /\bconstructor(?=\s*\()/ ],
className: { 1: "title.function" },
contains: [ PARAMS ]
},
FUNCTION_CALL,
UPPER_CASE_CONSTANT,
CLASS_OR_EXTENDS,
GETTER_OR_SETTER,
{
match: /\$[(.]/ // relevance booster for a pattern common to JS libs: `$(something)` and `$.something`
}
]
};
}
var javascript_1 = javascript$1;
/*
Language: JBoss CLI
Author: Raphaël Parrëe <rparree@edc4it.com>
Description: language definition jboss cli
Website: https://docs.jboss.org/author/display/WFLY/Command+Line+Interface
Category: config
*/
function jbossCli(hljs) {
const PARAM = {
begin: /[\w-]+ *=/,
returnBegin: true,
relevance: 0,
contains: [
{
className: 'attr',
begin: /[\w-]+/
}
]
};
const PARAMSBLOCK = {
className: 'params',
begin: /\(/,
end: /\)/,
contains: [ PARAM ],
relevance: 0
};
const OPERATION = {
className: 'function',
begin: /:[\w\-.]+/,
relevance: 0
};
const PATH = {
className: 'string',
begin: /\B([\/.])[\w\-.\/=]+/
};
const COMMAND_PARAMS = {
className: 'params',
begin: /--[\w\-=\/]+/
};
return {
name: 'JBoss CLI',
aliases: [ 'wildfly-cli' ],
keywords: {
$pattern: '[a-z\-]+',
keyword: 'alias batch cd clear command connect connection-factory connection-info data-source deploy '
+ 'deployment-info deployment-overlay echo echo-dmr help history if jdbc-driver-info jms-queue|20 jms-topic|20 ls '
+ 'patch pwd quit read-attribute read-operation reload rollout-plan run-batch set shutdown try unalias '
+ 'undeploy unset version xa-data-source', // module
literal: 'true false'
},
contains: [
hljs.HASH_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
COMMAND_PARAMS,
OPERATION,
PATH,
PARAMSBLOCK
]
};
}
var jbossCli_1 = jbossCli;
/*
Language: JSON
Description: JSON (JavaScript Object Notation) is a lightweight data-interchange format.
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Website: http://www.json.org
Category: common, protocols, web
*/
function json(hljs) {
const ATTRIBUTE = {
className: 'attr',
begin: /"(\\.|[^\\"\r\n])*"(?=\s*:)/,
relevance: 1.01
};
const PUNCTUATION = {
match: /[{}[\],:]/,
className: "punctuation",
relevance: 0
};
const LITERALS = [
"true",
"false",
"null"
];
// NOTE: normally we would rely on `keywords` for this but using a mode here allows us
// - to use the very tight `illegal: \S` rule later to flag any other character
// - as illegal indicating that despite looking like JSON we do not truly have
// - JSON and thus improve false-positively greatly since JSON will try and claim
// - all sorts of JSON looking stuff
const LITERALS_MODE = {
scope: "literal",
beginKeywords: LITERALS.join(" "),
};
return {
name: 'JSON',
keywords:{
literal: LITERALS,
},
contains: [
ATTRIBUTE,
PUNCTUATION,
hljs.QUOTE_STRING_MODE,
LITERALS_MODE,
hljs.C_NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
],
illegal: '\\S'
};
}
var json_1 = json;
/*
Language: Julia
Description: Julia is a high-level, high-performance, dynamic programming language.
Author: Kenta Sato <bicycle1885@gmail.com>
Contributors: Alex Arslan <ararslan@comcast.net>, Fredrik Ekre <ekrefredrik@gmail.com>
Website: https://julialang.org
*/
function julia(hljs) {
// Since there are numerous special names in Julia, it is too much trouble
// to maintain them by hand. Hence these names (i.e. keywords, literals and
// built-ins) are automatically generated from Julia 1.5.2 itself through
// the following scripts for each.
// ref: https://docs.julialang.org/en/v1/manual/variables/#Allowed-Variable-Names
const VARIABLE_NAME_RE = '[A-Za-z_\\u00A1-\\uFFFF][A-Za-z_0-9\\u00A1-\\uFFFF]*';
// # keyword generator, multi-word keywords handled manually below (Julia 1.5.2)
// import REPL.REPLCompletions
// res = String["in", "isa", "where"]
// for kw in collect(x.keyword for x in REPLCompletions.complete_keyword(""))
// if !(contains(kw, " ") || kw == "struct")
// push!(res, kw)
// end
// end
// sort!(unique!(res))
// foreach(x -> println("\'", x, "\',"), res)
const KEYWORD_LIST = [
'baremodule',
'begin',
'break',
'catch',
'ccall',
'const',
'continue',
'do',
'else',
'elseif',
'end',
'export',
'false',
'finally',
'for',
'function',
'global',
'if',
'import',
'in',
'isa',
'let',
'local',
'macro',
'module',
'quote',
'return',
'true',
'try',
'using',
'where',
'while',
];
// # literal generator (Julia 1.5.2)
// import REPL.REPLCompletions
// res = String["true", "false"]
// for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),
// REPLCompletions.completions("", 0)[1])
// try
// v = eval(Symbol(compl.mod))
// if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)
// push!(res, compl.mod)
// end
// catch e
// end
// end
// sort!(unique!(res))
// foreach(x -> println("\'", x, "\',"), res)
const LITERAL_LIST = [
'ARGS',
'C_NULL',
'DEPOT_PATH',
'ENDIAN_BOM',
'ENV',
'Inf',
'Inf16',
'Inf32',
'Inf64',
'InsertionSort',
'LOAD_PATH',
'MergeSort',
'NaN',
'NaN16',
'NaN32',
'NaN64',
'PROGRAM_FILE',
'QuickSort',
'RoundDown',
'RoundFromZero',
'RoundNearest',
'RoundNearestTiesAway',
'RoundNearestTiesUp',
'RoundToZero',
'RoundUp',
'VERSION|0',
'devnull',
'false',
'im',
'missing',
'nothing',
'pi',
'stderr',
'stdin',
'stdout',
'true',
'undef',
'π',
'',
];
// # built_in generator (Julia 1.5.2)
// import REPL.REPLCompletions
// res = String[]
// for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),
// REPLCompletions.completions("", 0)[1])
// try
// v = eval(Symbol(compl.mod))
// if (v isa Type || v isa TypeVar) && (compl.mod != "=>")
// push!(res, compl.mod)
// end
// catch e
// end
// end
// sort!(unique!(res))
// foreach(x -> println("\'", x, "\',"), res)
const BUILT_IN_LIST = [
'AbstractArray',
'AbstractChannel',
'AbstractChar',
'AbstractDict',
'AbstractDisplay',
'AbstractFloat',
'AbstractIrrational',
'AbstractMatrix',
'AbstractRange',
'AbstractSet',
'AbstractString',
'AbstractUnitRange',
'AbstractVecOrMat',
'AbstractVector',
'Any',
'ArgumentError',
'Array',
'AssertionError',
'BigFloat',
'BigInt',
'BitArray',
'BitMatrix',
'BitSet',
'BitVector',
'Bool',
'BoundsError',
'CapturedException',
'CartesianIndex',
'CartesianIndices',
'Cchar',
'Cdouble',
'Cfloat',
'Channel',
'Char',
'Cint',
'Cintmax_t',
'Clong',
'Clonglong',
'Cmd',
'Colon',
'Complex',
'ComplexF16',
'ComplexF32',
'ComplexF64',
'CompositeException',
'Condition',
'Cptrdiff_t',
'Cshort',
'Csize_t',
'Cssize_t',
'Cstring',
'Cuchar',
'Cuint',
'Cuintmax_t',
'Culong',
'Culonglong',
'Cushort',
'Cvoid',
'Cwchar_t',
'Cwstring',
'DataType',
'DenseArray',
'DenseMatrix',
'DenseVecOrMat',
'DenseVector',
'Dict',
'DimensionMismatch',
'Dims',
'DivideError',
'DomainError',
'EOFError',
'Enum',
'ErrorException',
'Exception',
'ExponentialBackOff',
'Expr',
'Float16',
'Float32',
'Float64',
'Function',
'GlobalRef',
'HTML',
'IO',
'IOBuffer',
'IOContext',
'IOStream',
'IdDict',
'IndexCartesian',
'IndexLinear',
'IndexStyle',
'InexactError',
'InitError',
'Int',
'Int128',
'Int16',
'Int32',
'Int64',
'Int8',
'Integer',
'InterruptException',
'InvalidStateException',
'Irrational',
'KeyError',
'LinRange',
'LineNumberNode',
'LinearIndices',
'LoadError',
'MIME',
'Matrix',
'Method',
'MethodError',
'Missing',
'MissingException',
'Module',
'NTuple',
'NamedTuple',
'Nothing',
'Number',
'OrdinalRange',
'OutOfMemoryError',
'OverflowError',
'Pair',
'PartialQuickSort',
'PermutedDimsArray',
'Pipe',
'ProcessFailedException',
'Ptr',
'QuoteNode',
'Rational',
'RawFD',
'ReadOnlyMemoryError',
'Real',
'ReentrantLock',
'Ref',
'Regex',
'RegexMatch',
'RoundingMode',
'SegmentationFault',
'Set',
'Signed',
'Some',
'StackOverflowError',
'StepRange',
'StepRangeLen',
'StridedArray',
'StridedMatrix',
'StridedVecOrMat',
'StridedVector',
'String',
'StringIndexError',
'SubArray',
'SubString',
'SubstitutionString',
'Symbol',
'SystemError',
'Task',
'TaskFailedException',
'Text',
'TextDisplay',
'Timer',
'Tuple',
'Type',
'TypeError',
'TypeVar',
'UInt',
'UInt128',
'UInt16',
'UInt32',
'UInt64',
'UInt8',
'UndefInitializer',
'UndefKeywordError',
'UndefRefError',
'UndefVarError',
'Union',
'UnionAll',
'UnitRange',
'Unsigned',
'Val',
'Vararg',
'VecElement',
'VecOrMat',
'Vector',
'VersionNumber',
'WeakKeyDict',
'WeakRef',
];
const KEYWORDS = {
$pattern: VARIABLE_NAME_RE,
keyword: KEYWORD_LIST,
literal: LITERAL_LIST,
built_in: BUILT_IN_LIST,
};
// placeholder for recursive self-reference
const DEFAULT = {
keywords: KEYWORDS,
illegal: /<\//
};
// ref: https://docs.julialang.org/en/v1/manual/integers-and-floating-point-numbers/
const NUMBER = {
className: 'number',
// supported numeric literals:
// * binary literal (e.g. 0x10)
// * octal literal (e.g. 0o76543210)
// * hexadecimal literal (e.g. 0xfedcba876543210)
// * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)
// * decimal literal (e.g. 9876543210, 100_000_000)
// * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)
begin: /(\b0x[\d_]*(\.[\d_]*)?|0x\.\d[\d_]*)p[-+]?\d+|\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\b\d[\d_]*(\.[\d_]*)?|\.\d[\d_]*)([eEfF][-+]?\d+)?/,
relevance: 0
};
const CHAR = {
className: 'string',
begin: /'(.|\\[xXuU][a-zA-Z0-9]+)'/
};
const INTERPOLATION = {
className: 'subst',
begin: /\$\(/,
end: /\)/,
keywords: KEYWORDS
};
const INTERPOLATED_VARIABLE = {
className: 'variable',
begin: '\\$' + VARIABLE_NAME_RE
};
// TODO: neatly escape normal code in string literal
const STRING = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
INTERPOLATION,
INTERPOLATED_VARIABLE
],
variants: [
{
begin: /\w*"""/,
end: /"""\w*/,
relevance: 10
},
{
begin: /\w*"/,
end: /"\w*/
}
]
};
const COMMAND = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
INTERPOLATION,
INTERPOLATED_VARIABLE
],
begin: '`',
end: '`'
};
const MACROCALL = {
className: 'meta',
begin: '@' + VARIABLE_NAME_RE
};
const COMMENT = {
className: 'comment',
variants: [
{
begin: '#=',
end: '=#',
relevance: 10
},
{
begin: '#',
end: '$'
}
]
};
DEFAULT.name = 'Julia';
DEFAULT.contains = [
NUMBER,
CHAR,
STRING,
COMMAND,
MACROCALL,
COMMENT,
hljs.HASH_COMMENT_MODE,
{
className: 'keyword',
begin:
'\\b(((abstract|primitive)\\s+)type|(mutable\\s+)?struct)\\b'
},
{ begin: /<:/ } // relevance booster
];
INTERPOLATION.contains = DEFAULT.contains;
return DEFAULT;
}
var julia_1 = julia;
/*
Language: Julia REPL
Description: Julia REPL sessions
Author: Morten Piibeleht <morten.piibeleht@gmail.com>
Website: https://julialang.org
Requires: julia.js
The Julia REPL code blocks look something like the following:
julia> function foo(x)
x + 1
end
foo (generic function with 1 method)
They start on a new line with "julia>". Usually there should also be a space after this, but
we also allow the code to start right after the > character. The code may run over multiple
lines, but the additional lines must start with six spaces (i.e. be indented to match
"julia>"). The rest of the code is assumed to be output from the executed code and will be
left un-highlighted.
Using simply spaces to identify line continuations may get a false-positive if the output
also prints out six spaces, but such cases should be rare.
*/
function juliaRepl(hljs) {
return {
name: 'Julia REPL',
contains: [
{
className: 'meta.prompt',
begin: /^julia>/,
relevance: 10,
starts: {
// end the highlighting if we are on a new line and the line does not have at
// least six spaces in the beginning
end: /^(?![ ]{6})/,
subLanguage: 'julia'
},
},
],
// jldoctest Markdown blocks are used in the Julia manual and package docs indicate
// code snippets that should be verified when the documentation is built. They can be
// either REPL-like or script-like, but are usually REPL-like and therefore we apply
// julia-repl highlighting to them. More information can be found in Documenter's
// manual: https://juliadocs.github.io/Documenter.jl/latest/man/doctests.html
aliases: [ 'jldoctest' ],
};
}
var juliaRepl_1 = juliaRepl;
// https://docs.oracle.com/javase/specs/jls/se15/html/jls-3.html#jls-3.10
var decimalDigits = '[0-9](_*[0-9])*';
var frac = `\\.(${decimalDigits})`;
var hexDigits = '[0-9a-fA-F](_*[0-9a-fA-F])*';
var NUMERIC = {
className: 'number',
variants: [
// DecimalFloatingPointLiteral
// including ExponentPart
{ begin: `(\\b(${decimalDigits})((${frac})|\\.)?|(${frac}))` +
`[eE][+-]?(${decimalDigits})[fFdD]?\\b` },
// excluding ExponentPart
{ begin: `\\b(${decimalDigits})((${frac})[fFdD]?\\b|\\.([fFdD]\\b)?)` },
{ begin: `(${frac})[fFdD]?\\b` },
{ begin: `\\b(${decimalDigits})[fFdD]\\b` },
// HexadecimalFloatingPointLiteral
{ begin: `\\b0[xX]((${hexDigits})\\.?|(${hexDigits})?\\.(${hexDigits}))` +
`[pP][+-]?(${decimalDigits})[fFdD]?\\b` },
// DecimalIntegerLiteral
{ begin: '\\b(0|[1-9](_*[0-9])*)[lL]?\\b' },
// HexIntegerLiteral
{ begin: `\\b0[xX](${hexDigits})[lL]?\\b` },
// OctalIntegerLiteral
{ begin: '\\b0(_*[0-7])*[lL]?\\b' },
// BinaryIntegerLiteral
{ begin: '\\b0[bB][01](_*[01])*[lL]?\\b' },
],
relevance: 0
};
/*
Language: Kotlin
Description: Kotlin is an OSS statically typed programming language that targets the JVM, Android, JavaScript and Native.
Author: Sergey Mashkov <cy6erGn0m@gmail.com>
Website: https://kotlinlang.org
Category: common
*/
function kotlin(hljs) {
const KEYWORDS = {
keyword:
'abstract as val var vararg get set class object open private protected public noinline '
+ 'crossinline dynamic final enum if else do while for when throw try catch finally '
+ 'import package is in fun override companion reified inline lateinit init '
+ 'interface annotation data sealed internal infix operator out by constructor super '
+ 'tailrec where const inner suspend typealias external expect actual',
built_in:
'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',
literal:
'true false null'
};
const KEYWORDS_WITH_LABEL = {
className: 'keyword',
begin: /\b(break|continue|return|this)\b/,
starts: { contains: [
{
className: 'symbol',
begin: /@\w+/
}
] }
};
const LABEL = {
className: 'symbol',
begin: hljs.UNDERSCORE_IDENT_RE + '@'
};
// for string templates
const SUBST = {
className: 'subst',
begin: /\$\{/,
end: /\}/,
contains: [ hljs.C_NUMBER_MODE ]
};
const VARIABLE = {
className: 'variable',
begin: '\\$' + hljs.UNDERSCORE_IDENT_RE
};
const STRING = {
className: 'string',
variants: [
{
begin: '"""',
end: '"""(?=[^"])',
contains: [
VARIABLE,
SUBST
]
},
// Can't use built-in modes easily, as we want to use STRING in the meta
// context as 'meta-string' and there's no syntax to remove explicitly set
// classNames in built-in modes.
{
begin: '\'',
end: '\'',
illegal: /\n/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '"',
end: '"',
illegal: /\n/,
contains: [
hljs.BACKSLASH_ESCAPE,
VARIABLE,
SUBST
]
}
]
};
SUBST.contains.push(STRING);
const ANNOTATION_USE_SITE = {
className: 'meta',
begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\s*:(?:\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'
};
const ANNOTATION = {
className: 'meta',
begin: '@' + hljs.UNDERSCORE_IDENT_RE,
contains: [
{
begin: /\(/,
end: /\)/,
contains: [
hljs.inherit(STRING, { className: 'string' }),
"self"
]
}
]
};
// https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals
// According to the doc above, the number mode of kotlin is the same as java 8,
// so the code below is copied from java.js
const KOTLIN_NUMBER_MODE = NUMERIC;
const KOTLIN_NESTED_COMMENT = hljs.COMMENT(
'/\\*', '\\*/',
{ contains: [ hljs.C_BLOCK_COMMENT_MODE ] }
);
const KOTLIN_PAREN_TYPE = { variants: [
{
className: 'type',
begin: hljs.UNDERSCORE_IDENT_RE
},
{
begin: /\(/,
end: /\)/,
contains: [] // defined later
}
] };
const KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;
KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];
KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];
return {
name: 'Kotlin',
aliases: [
'kt',
'kts'
],
keywords: KEYWORDS,
contains: [
hljs.COMMENT(
'/\\*\\*',
'\\*/',
{
relevance: 0,
contains: [
{
className: 'doctag',
begin: '@[A-Za-z]+'
}
]
}
),
hljs.C_LINE_COMMENT_MODE,
KOTLIN_NESTED_COMMENT,
KEYWORDS_WITH_LABEL,
LABEL,
ANNOTATION_USE_SITE,
ANNOTATION,
{
className: 'function',
beginKeywords: 'fun',
end: '[(]|$',
returnBegin: true,
excludeEnd: true,
keywords: KEYWORDS,
relevance: 5,
contains: [
{
begin: hljs.UNDERSCORE_IDENT_RE + '\\s*\\(',
returnBegin: true,
relevance: 0,
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
},
{
className: 'type',
begin: /</,
end: />/,
keywords: 'reified',
relevance: 0
},
{
className: 'params',
begin: /\(/,
end: /\)/,
endsParent: true,
keywords: KEYWORDS,
relevance: 0,
contains: [
{
begin: /:/,
end: /[=,\/]/,
endsWithParent: true,
contains: [
KOTLIN_PAREN_TYPE,
hljs.C_LINE_COMMENT_MODE,
KOTLIN_NESTED_COMMENT
],
relevance: 0
},
hljs.C_LINE_COMMENT_MODE,
KOTLIN_NESTED_COMMENT,
ANNOTATION_USE_SITE,
ANNOTATION,
STRING,
hljs.C_NUMBER_MODE
]
},
KOTLIN_NESTED_COMMENT
]
},
{
begin: [
/class|interface|trait/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE
],
beginScope: {
3: "title.class"
},
keywords: 'class interface trait',
end: /[:\{(]|$/,
excludeEnd: true,
illegal: 'extends implements',
contains: [
{ beginKeywords: 'public protected internal private constructor' },
hljs.UNDERSCORE_TITLE_MODE,
{
className: 'type',
begin: /</,
end: />/,
excludeBegin: true,
excludeEnd: true,
relevance: 0
},
{
className: 'type',
begin: /[,:]\s*/,
end: /[<\(,){\s]|$/,
excludeBegin: true,
returnEnd: true
},
ANNOTATION_USE_SITE,
ANNOTATION
]
},
STRING,
{
className: 'meta',
begin: "^#!/usr/bin/env",
end: '$',
illegal: '\n'
},
KOTLIN_NUMBER_MODE
]
};
}
var kotlin_1 = kotlin;
/*
Language: Lasso
Author: Eric Knibbe <eric@lassosoft.com>
Description: Lasso is a language and server platform for database-driven web applications. This definition handles Lasso 9 syntax and LassoScript for Lasso 8.6 and earlier.
Website: http://www.lassosoft.com/What-Is-Lasso
*/
function lasso(hljs) {
const LASSO_IDENT_RE = '[a-zA-Z_][\\w.]*';
const LASSO_ANGLE_RE = '<\\?(lasso(script)?|=)';
const LASSO_CLOSE_RE = '\\]|\\?>';
const LASSO_KEYWORDS = {
$pattern: LASSO_IDENT_RE + '|&[lg]t;',
literal:
'true false none minimal full all void and or not '
+ 'bw nbw ew new cn ncn lt lte gt gte eq neq rx nrx ft',
built_in:
'array date decimal duration integer map pair string tag xml null '
+ 'boolean bytes keyword list locale queue set stack staticarray '
+ 'local var variable global data self inherited currentcapture givenblock',
keyword:
'cache database_names database_schemanames database_tablenames '
+ 'define_tag define_type email_batch encode_set html_comment handle '
+ 'handle_error header if inline iterate ljax_target link '
+ 'link_currentaction link_currentgroup link_currentrecord link_detail '
+ 'link_firstgroup link_firstrecord link_lastgroup link_lastrecord '
+ 'link_nextgroup link_nextrecord link_prevgroup link_prevrecord log '
+ 'loop namespace_using output_none portal private protect records '
+ 'referer referrer repeating resultset rows search_args '
+ 'search_arguments select sort_args sort_arguments thread_atomic '
+ 'value_list while abort case else fail_if fail_ifnot fail if_empty '
+ 'if_false if_null if_true loop_abort loop_continue loop_count params '
+ 'params_up return return_value run_children soap_definetag '
+ 'soap_lastrequest soap_lastresponse tag_name ascending average by '
+ 'define descending do equals frozen group handle_failure import in '
+ 'into join let match max min on order parent protected provide public '
+ 'require returnhome skip split_thread sum take thread to trait type '
+ 'where with yield yieldhome'
};
const HTML_COMMENT = hljs.COMMENT(
'<!--',
'-->',
{ relevance: 0 }
);
const LASSO_NOPROCESS = {
className: 'meta',
begin: '\\[noprocess\\]',
starts: {
end: '\\[/noprocess\\]',
returnEnd: true,
contains: [ HTML_COMMENT ]
}
};
const LASSO_START = {
className: 'meta',
begin: '\\[/noprocess|' + LASSO_ANGLE_RE
};
const LASSO_DATAMEMBER = {
className: 'symbol',
begin: '\'' + LASSO_IDENT_RE + '\''
};
const LASSO_CODE = [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.inherit(hljs.C_NUMBER_MODE, { begin: hljs.C_NUMBER_RE + '|(-?infinity|NaN)\\b' }),
hljs.inherit(hljs.APOS_STRING_MODE, { illegal: null }),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
className: 'string',
begin: '`',
end: '`'
},
{ // variables
variants: [
{ begin: '[#$]' + LASSO_IDENT_RE },
{
begin: '#',
end: '\\d+',
illegal: '\\W'
}
] },
{
className: 'type',
begin: '::\\s*',
end: LASSO_IDENT_RE,
illegal: '\\W'
},
{
className: 'params',
variants: [
{
begin: '-(?!infinity)' + LASSO_IDENT_RE,
relevance: 0
},
{ begin: '(\\.\\.\\.)' }
]
},
{
begin: /(->|\.)\s*/,
relevance: 0,
contains: [ LASSO_DATAMEMBER ]
},
{
className: 'class',
beginKeywords: 'define',
returnEnd: true,
end: '\\(|=>',
contains: [ hljs.inherit(hljs.TITLE_MODE, { begin: LASSO_IDENT_RE + '(=(?!>))?|[-+*/%](?!>)' }) ]
}
];
return {
name: 'Lasso',
aliases: [
'ls',
'lassoscript'
],
case_insensitive: true,
keywords: LASSO_KEYWORDS,
contains: [
{
className: 'meta',
begin: LASSO_CLOSE_RE,
relevance: 0,
starts: { // markup
end: '\\[|' + LASSO_ANGLE_RE,
returnEnd: true,
relevance: 0,
contains: [ HTML_COMMENT ]
}
},
LASSO_NOPROCESS,
LASSO_START,
{
className: 'meta',
begin: '\\[no_square_brackets',
starts: {
end: '\\[/no_square_brackets\\]', // not implemented in the language
keywords: LASSO_KEYWORDS,
contains: [
{
className: 'meta',
begin: LASSO_CLOSE_RE,
relevance: 0,
starts: {
end: '\\[noprocess\\]|' + LASSO_ANGLE_RE,
returnEnd: true,
contains: [ HTML_COMMENT ]
}
},
LASSO_NOPROCESS,
LASSO_START
].concat(LASSO_CODE)
}
},
{
className: 'meta',
begin: '\\[',
relevance: 0
},
{
className: 'meta',
begin: '^#!',
end: 'lasso9$',
relevance: 10
}
].concat(LASSO_CODE)
};
}
var lasso_1 = lasso;
/*
Language: LaTeX
Author: Benedikt Wilde <bwilde@posteo.de>
Website: https://www.latex-project.org
Category: markup
*/
/** @type LanguageFn */
function latex(hljs) {
const regex = hljs.regex;
const KNOWN_CONTROL_WORDS = regex.either(...[
'(?:NeedsTeXFormat|RequirePackage|GetIdInfo)',
'Provides(?:Expl)?(?:Package|Class|File)',
'(?:DeclareOption|ProcessOptions)',
'(?:documentclass|usepackage|input|include)',
'makeat(?:letter|other)',
'ExplSyntax(?:On|Off)',
'(?:new|renew|provide)?command',
'(?:re)newenvironment',
'(?:New|Renew|Provide|Declare)(?:Expandable)?DocumentCommand',
'(?:New|Renew|Provide|Declare)DocumentEnvironment',
'(?:(?:e|g|x)?def|let)',
'(?:begin|end)',
'(?:part|chapter|(?:sub){0,2}section|(?:sub)?paragraph)',
'caption',
'(?:label|(?:eq|page|name)?ref|(?:paren|foot|super)?cite)',
'(?:alpha|beta|[Gg]amma|[Dd]elta|(?:var)?epsilon|zeta|eta|[Tt]heta|vartheta)',
'(?:iota|(?:var)?kappa|[Ll]ambda|mu|nu|[Xx]i|[Pp]i|varpi|(?:var)rho)',
'(?:[Ss]igma|varsigma|tau|[Uu]psilon|[Pp]hi|varphi|chi|[Pp]si|[Oo]mega)',
'(?:frac|sum|prod|lim|infty|times|sqrt|leq|geq|left|right|middle|[bB]igg?)',
'(?:[lr]angle|q?quad|[lcvdi]?dots|d?dot|hat|tilde|bar)'
].map(word => word + '(?![a-zA-Z@:_])'));
const L3_REGEX = new RegExp([
// A function \module_function_name:signature or \__module_function_name:signature,
// where both module and function_name need at least two characters and
// function_name may contain single underscores.
'(?:__)?[a-zA-Z]{2,}_[a-zA-Z](?:_?[a-zA-Z])+:[a-zA-Z]*',
// A variable \scope_module_and_name_type or \scope__module_ane_name_type,
// where scope is one of l, g or c, type needs at least two characters
// and module_and_name may contain single underscores.
'[lgc]__?[a-zA-Z](?:_?[a-zA-Z])*_[a-zA-Z]{2,}',
// A quark \q_the_name or \q__the_name or
// scan mark \s_the_name or \s__vthe_name,
// where variable_name needs at least two characters and
// may contain single underscores.
'[qs]__?[a-zA-Z](?:_?[a-zA-Z])+',
// Other LaTeX3 macro names that are not covered by the three rules above.
'use(?:_i)?:[a-zA-Z]*',
'(?:else|fi|or):',
'(?:if|cs|exp):w',
'(?:hbox|vbox):n',
'::[a-zA-Z]_unbraced',
'::[a-zA-Z:]'
].map(pattern => pattern + '(?![a-zA-Z:_])').join('|'));
const L2_VARIANTS = [
{ begin: /[a-zA-Z@]+/ }, // control word
{ begin: /[^a-zA-Z@]?/ } // control symbol
];
const DOUBLE_CARET_VARIANTS = [
{ begin: /\^{6}[0-9a-f]{6}/ },
{ begin: /\^{5}[0-9a-f]{5}/ },
{ begin: /\^{4}[0-9a-f]{4}/ },
{ begin: /\^{3}[0-9a-f]{3}/ },
{ begin: /\^{2}[0-9a-f]{2}/ },
{ begin: /\^{2}[\u0000-\u007f]/ }
];
const CONTROL_SEQUENCE = {
className: 'keyword',
begin: /\\/,
relevance: 0,
contains: [
{
endsParent: true,
begin: KNOWN_CONTROL_WORDS
},
{
endsParent: true,
begin: L3_REGEX
},
{
endsParent: true,
variants: DOUBLE_CARET_VARIANTS
},
{
endsParent: true,
relevance: 0,
variants: L2_VARIANTS
}
]
};
const MACRO_PARAM = {
className: 'params',
relevance: 0,
begin: /#+\d?/
};
const DOUBLE_CARET_CHAR = {
// relevance: 1
variants: DOUBLE_CARET_VARIANTS };
const SPECIAL_CATCODE = {
className: 'built_in',
relevance: 0,
begin: /[$&^_]/
};
const MAGIC_COMMENT = {
className: 'meta',
begin: /% ?!(T[eE]X|tex|BIB|bib)/,
end: '$',
relevance: 10
};
const COMMENT = hljs.COMMENT(
'%',
'$',
{ relevance: 0 }
);
const EVERYTHING_BUT_VERBATIM = [
CONTROL_SEQUENCE,
MACRO_PARAM,
DOUBLE_CARET_CHAR,
SPECIAL_CATCODE,
MAGIC_COMMENT,
COMMENT
];
const BRACE_GROUP_NO_VERBATIM = {
begin: /\{/,
end: /\}/,
relevance: 0,
contains: [
'self',
...EVERYTHING_BUT_VERBATIM
]
};
const ARGUMENT_BRACES = hljs.inherit(
BRACE_GROUP_NO_VERBATIM,
{
relevance: 0,
endsParent: true,
contains: [
BRACE_GROUP_NO_VERBATIM,
...EVERYTHING_BUT_VERBATIM
]
}
);
const ARGUMENT_BRACKETS = {
begin: /\[/,
end: /\]/,
endsParent: true,
relevance: 0,
contains: [
BRACE_GROUP_NO_VERBATIM,
...EVERYTHING_BUT_VERBATIM
]
};
const SPACE_GOBBLER = {
begin: /\s+/,
relevance: 0
};
const ARGUMENT_M = [ ARGUMENT_BRACES ];
const ARGUMENT_O = [ ARGUMENT_BRACKETS ];
const ARGUMENT_AND_THEN = function(arg, starts_mode) {
return {
contains: [ SPACE_GOBBLER ],
starts: {
relevance: 0,
contains: arg,
starts: starts_mode
}
};
};
const CSNAME = function(csname, starts_mode) {
return {
begin: '\\\\' + csname + '(?![a-zA-Z@:_])',
keywords: {
$pattern: /\\[a-zA-Z]+/,
keyword: '\\' + csname
},
relevance: 0,
contains: [ SPACE_GOBBLER ],
starts: starts_mode
};
};
const BEGIN_ENV = function(envname, starts_mode) {
return hljs.inherit(
{
begin: '\\\\begin(?=[ \t]*(\\r?\\n[ \t]*)?\\{' + envname + '\\})',
keywords: {
$pattern: /\\[a-zA-Z]+/,
keyword: '\\begin'
},
relevance: 0,
},
ARGUMENT_AND_THEN(ARGUMENT_M, starts_mode)
);
};
const VERBATIM_DELIMITED_EQUAL = (innerName = "string") => {
return hljs.END_SAME_AS_BEGIN({
className: innerName,
begin: /(.|\r?\n)/,
end: /(.|\r?\n)/,
excludeBegin: true,
excludeEnd: true,
endsParent: true
});
};
const VERBATIM_DELIMITED_ENV = function(envname) {
return {
className: 'string',
end: '(?=\\\\end\\{' + envname + '\\})'
};
};
const VERBATIM_DELIMITED_BRACES = (innerName = "string") => {
return {
relevance: 0,
begin: /\{/,
starts: {
endsParent: true,
contains: [
{
className: innerName,
end: /(?=\})/,
endsParent: true,
contains: [
{
begin: /\{/,
end: /\}/,
relevance: 0,
contains: [ "self" ]
}
],
}
]
}
};
};
const VERBATIM = [
...[
'verb',
'lstinline'
].map(csname => CSNAME(csname, { contains: [ VERBATIM_DELIMITED_EQUAL() ] })),
CSNAME('mint', ARGUMENT_AND_THEN(ARGUMENT_M, { contains: [ VERBATIM_DELIMITED_EQUAL() ] })),
CSNAME('mintinline', ARGUMENT_AND_THEN(ARGUMENT_M, { contains: [
VERBATIM_DELIMITED_BRACES(),
VERBATIM_DELIMITED_EQUAL()
] })),
CSNAME('url', { contains: [
VERBATIM_DELIMITED_BRACES("link"),
VERBATIM_DELIMITED_BRACES("link")
] }),
CSNAME('hyperref', { contains: [ VERBATIM_DELIMITED_BRACES("link") ] }),
CSNAME('href', ARGUMENT_AND_THEN(ARGUMENT_O, { contains: [ VERBATIM_DELIMITED_BRACES("link") ] })),
...[].concat(...[
'',
'\\*'
].map(suffix => [
BEGIN_ENV('verbatim' + suffix, VERBATIM_DELIMITED_ENV('verbatim' + suffix)),
BEGIN_ENV('filecontents' + suffix, ARGUMENT_AND_THEN(ARGUMENT_M, VERBATIM_DELIMITED_ENV('filecontents' + suffix))),
...[
'',
'B',
'L'
].map(prefix =>
BEGIN_ENV(prefix + 'Verbatim' + suffix, ARGUMENT_AND_THEN(ARGUMENT_O, VERBATIM_DELIMITED_ENV(prefix + 'Verbatim' + suffix)))
)
])),
BEGIN_ENV('minted', ARGUMENT_AND_THEN(ARGUMENT_O, ARGUMENT_AND_THEN(ARGUMENT_M, VERBATIM_DELIMITED_ENV('minted')))),
];
return {
name: 'LaTeX',
aliases: [ 'tex' ],
contains: [
...VERBATIM,
...EVERYTHING_BUT_VERBATIM
]
};
}
var latex_1 = latex;
/*
Language: LDIF
Contributors: Jacob Childress <jacobc@gmail.com>
Category: enterprise, config
Website: https://en.wikipedia.org/wiki/LDAP_Data_Interchange_Format
*/
/** @type LanguageFn */
function ldif(hljs) {
return {
name: 'LDIF',
contains: [
{
className: 'attribute',
match: '^dn(?=:)',
relevance: 10
},
{
className: 'attribute',
match: '^\\w+(?=:)'
},
{
className: 'literal',
match: '^-'
},
hljs.HASH_COMMENT_MODE
]
};
}
var ldif_1 = ldif;
/*
Language: Leaf
Description: A Swift-based templating language created for the Vapor project.
Website: https://docs.vapor.codes/leaf/overview
Category: template
*/
function leaf(hljs) {
const IDENT = /([A-Za-z_][A-Za-z_0-9]*)?/;
const LITERALS = [
'true',
'false',
'in'
];
const PARAMS = {
scope: 'params',
begin: /\(/,
end: /\)(?=\:?)/,
endsParent: true,
relevance: 7,
contains: [
{
scope: 'string',
begin: '"',
end: '"'
},
{
scope: 'keyword',
match: LITERALS.join("|"),
},
{
scope: 'variable',
match: /[A-Za-z_][A-Za-z_0-9]*/
},
{
scope: 'operator',
match: /\+|\-|\*|\/|\%|\=\=|\=|\!|\>|\<|\&\&|\|\|/
}
]
};
const INSIDE_DISPATCH = {
match: [
IDENT,
/(?=\()/,
],
scope: {
1: "keyword"
},
contains: [ PARAMS ]
};
PARAMS.contains.unshift(INSIDE_DISPATCH);
return {
name: 'Leaf',
contains: [
// #ident():
{
match: [
/#+/,
IDENT,
/(?=\()/,
],
scope: {
1: "punctuation",
2: "keyword"
},
// will start up after the ending `)` match from line ~44
// just to grab the trailing `:` if we can match it
starts: {
contains: [
{
match: /\:/,
scope: "punctuation"
}
]
},
contains: [
PARAMS
],
},
// #ident or #ident:
{
match: [
/#+/,
IDENT,
/:?/,
],
scope: {
1: "punctuation",
2: "keyword",
3: "punctuation"
}
},
]
};
}
var leaf_1 = leaf;
const MODES$2 = (hljs) => {
return {
IMPORTANT: {
scope: 'meta',
begin: '!important'
},
BLOCK_COMMENT: hljs.C_BLOCK_COMMENT_MODE,
HEXCOLOR: {
scope: 'number',
begin: /#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/
},
FUNCTION_DISPATCH: {
className: "built_in",
begin: /[\w-]+(?=\()/
},
ATTRIBUTE_SELECTOR_MODE: {
scope: 'selector-attr',
begin: /\[/,
end: /\]/,
illegal: '$',
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
},
CSS_NUMBER_MODE: {
scope: 'number',
begin: hljs.NUMBER_RE + '(' +
'%|em|ex|ch|rem' +
'|vw|vh|vmin|vmax' +
'|cm|mm|in|pt|pc|px' +
'|deg|grad|rad|turn' +
'|s|ms' +
'|Hz|kHz' +
'|dpi|dpcm|dppx' +
')?',
relevance: 0
},
CSS_VARIABLE: {
className: "attr",
begin: /--[A-Za-z_][A-Za-z0-9_-]*/
}
};
};
const TAGS$2 = [
'a',
'abbr',
'address',
'article',
'aside',
'audio',
'b',
'blockquote',
'body',
'button',
'canvas',
'caption',
'cite',
'code',
'dd',
'del',
'details',
'dfn',
'div',
'dl',
'dt',
'em',
'fieldset',
'figcaption',
'figure',
'footer',
'form',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'header',
'hgroup',
'html',
'i',
'iframe',
'img',
'input',
'ins',
'kbd',
'label',
'legend',
'li',
'main',
'mark',
'menu',
'nav',
'object',
'ol',
'p',
'q',
'quote',
'samp',
'section',
'span',
'strong',
'summary',
'sup',
'table',
'tbody',
'td',
'textarea',
'tfoot',
'th',
'thead',
'time',
'tr',
'ul',
'var',
'video'
];
const MEDIA_FEATURES$2 = [
'any-hover',
'any-pointer',
'aspect-ratio',
'color',
'color-gamut',
'color-index',
'device-aspect-ratio',
'device-height',
'device-width',
'display-mode',
'forced-colors',
'grid',
'height',
'hover',
'inverted-colors',
'monochrome',
'orientation',
'overflow-block',
'overflow-inline',
'pointer',
'prefers-color-scheme',
'prefers-contrast',
'prefers-reduced-motion',
'prefers-reduced-transparency',
'resolution',
'scan',
'scripting',
'update',
'width',
// TODO: find a better solution?
'min-width',
'max-width',
'min-height',
'max-height'
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-classes
const PSEUDO_CLASSES$2 = [
'active',
'any-link',
'blank',
'checked',
'current',
'default',
'defined',
'dir', // dir()
'disabled',
'drop',
'empty',
'enabled',
'first',
'first-child',
'first-of-type',
'fullscreen',
'future',
'focus',
'focus-visible',
'focus-within',
'has', // has()
'host', // host or host()
'host-context', // host-context()
'hover',
'indeterminate',
'in-range',
'invalid',
'is', // is()
'lang', // lang()
'last-child',
'last-of-type',
'left',
'link',
'local-link',
'not', // not()
'nth-child', // nth-child()
'nth-col', // nth-col()
'nth-last-child', // nth-last-child()
'nth-last-col', // nth-last-col()
'nth-last-of-type', //nth-last-of-type()
'nth-of-type', //nth-of-type()
'only-child',
'only-of-type',
'optional',
'out-of-range',
'past',
'placeholder-shown',
'read-only',
'read-write',
'required',
'right',
'root',
'scope',
'target',
'target-within',
'user-invalid',
'valid',
'visited',
'where' // where()
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-elements
const PSEUDO_ELEMENTS$2 = [
'after',
'backdrop',
'before',
'cue',
'cue-region',
'first-letter',
'first-line',
'grammar-error',
'marker',
'part',
'placeholder',
'selection',
'slotted',
'spelling-error'
];
const ATTRIBUTES$2 = [
'align-content',
'align-items',
'align-self',
'all',
'animation',
'animation-delay',
'animation-direction',
'animation-duration',
'animation-fill-mode',
'animation-iteration-count',
'animation-name',
'animation-play-state',
'animation-timing-function',
'backface-visibility',
'background',
'background-attachment',
'background-blend-mode',
'background-clip',
'background-color',
'background-image',
'background-origin',
'background-position',
'background-repeat',
'background-size',
'block-size',
'border',
'border-block',
'border-block-color',
'border-block-end',
'border-block-end-color',
'border-block-end-style',
'border-block-end-width',
'border-block-start',
'border-block-start-color',
'border-block-start-style',
'border-block-start-width',
'border-block-style',
'border-block-width',
'border-bottom',
'border-bottom-color',
'border-bottom-left-radius',
'border-bottom-right-radius',
'border-bottom-style',
'border-bottom-width',
'border-collapse',
'border-color',
'border-image',
'border-image-outset',
'border-image-repeat',
'border-image-slice',
'border-image-source',
'border-image-width',
'border-inline',
'border-inline-color',
'border-inline-end',
'border-inline-end-color',
'border-inline-end-style',
'border-inline-end-width',
'border-inline-start',
'border-inline-start-color',
'border-inline-start-style',
'border-inline-start-width',
'border-inline-style',
'border-inline-width',
'border-left',
'border-left-color',
'border-left-style',
'border-left-width',
'border-radius',
'border-right',
'border-right-color',
'border-right-style',
'border-right-width',
'border-spacing',
'border-style',
'border-top',
'border-top-color',
'border-top-left-radius',
'border-top-right-radius',
'border-top-style',
'border-top-width',
'border-width',
'bottom',
'box-decoration-break',
'box-shadow',
'box-sizing',
'break-after',
'break-before',
'break-inside',
'caption-side',
'caret-color',
'clear',
'clip',
'clip-path',
'clip-rule',
'color',
'column-count',
'column-fill',
'column-gap',
'column-rule',
'column-rule-color',
'column-rule-style',
'column-rule-width',
'column-span',
'column-width',
'columns',
'contain',
'content',
'content-visibility',
'counter-increment',
'counter-reset',
'cue',
'cue-after',
'cue-before',
'cursor',
'direction',
'display',
'empty-cells',
'filter',
'flex',
'flex-basis',
'flex-direction',
'flex-flow',
'flex-grow',
'flex-shrink',
'flex-wrap',
'float',
'flow',
'font',
'font-display',
'font-family',
'font-feature-settings',
'font-kerning',
'font-language-override',
'font-size',
'font-size-adjust',
'font-smoothing',
'font-stretch',
'font-style',
'font-synthesis',
'font-variant',
'font-variant-caps',
'font-variant-east-asian',
'font-variant-ligatures',
'font-variant-numeric',
'font-variant-position',
'font-variation-settings',
'font-weight',
'gap',
'glyph-orientation-vertical',
'grid',
'grid-area',
'grid-auto-columns',
'grid-auto-flow',
'grid-auto-rows',
'grid-column',
'grid-column-end',
'grid-column-start',
'grid-gap',
'grid-row',
'grid-row-end',
'grid-row-start',
'grid-template',
'grid-template-areas',
'grid-template-columns',
'grid-template-rows',
'hanging-punctuation',
'height',
'hyphens',
'icon',
'image-orientation',
'image-rendering',
'image-resolution',
'ime-mode',
'inline-size',
'isolation',
'justify-content',
'left',
'letter-spacing',
'line-break',
'line-height',
'list-style',
'list-style-image',
'list-style-position',
'list-style-type',
'margin',
'margin-block',
'margin-block-end',
'margin-block-start',
'margin-bottom',
'margin-inline',
'margin-inline-end',
'margin-inline-start',
'margin-left',
'margin-right',
'margin-top',
'marks',
'mask',
'mask-border',
'mask-border-mode',
'mask-border-outset',
'mask-border-repeat',
'mask-border-slice',
'mask-border-source',
'mask-border-width',
'mask-clip',
'mask-composite',
'mask-image',
'mask-mode',
'mask-origin',
'mask-position',
'mask-repeat',
'mask-size',
'mask-type',
'max-block-size',
'max-height',
'max-inline-size',
'max-width',
'min-block-size',
'min-height',
'min-inline-size',
'min-width',
'mix-blend-mode',
'nav-down',
'nav-index',
'nav-left',
'nav-right',
'nav-up',
'none',
'normal',
'object-fit',
'object-position',
'opacity',
'order',
'orphans',
'outline',
'outline-color',
'outline-offset',
'outline-style',
'outline-width',
'overflow',
'overflow-wrap',
'overflow-x',
'overflow-y',
'padding',
'padding-block',
'padding-block-end',
'padding-block-start',
'padding-bottom',
'padding-inline',
'padding-inline-end',
'padding-inline-start',
'padding-left',
'padding-right',
'padding-top',
'page-break-after',
'page-break-before',
'page-break-inside',
'pause',
'pause-after',
'pause-before',
'perspective',
'perspective-origin',
'pointer-events',
'position',
'quotes',
'resize',
'rest',
'rest-after',
'rest-before',
'right',
'row-gap',
'scroll-margin',
'scroll-margin-block',
'scroll-margin-block-end',
'scroll-margin-block-start',
'scroll-margin-bottom',
'scroll-margin-inline',
'scroll-margin-inline-end',
'scroll-margin-inline-start',
'scroll-margin-left',
'scroll-margin-right',
'scroll-margin-top',
'scroll-padding',
'scroll-padding-block',
'scroll-padding-block-end',
'scroll-padding-block-start',
'scroll-padding-bottom',
'scroll-padding-inline',
'scroll-padding-inline-end',
'scroll-padding-inline-start',
'scroll-padding-left',
'scroll-padding-right',
'scroll-padding-top',
'scroll-snap-align',
'scroll-snap-stop',
'scroll-snap-type',
'scrollbar-color',
'scrollbar-gutter',
'scrollbar-width',
'shape-image-threshold',
'shape-margin',
'shape-outside',
'speak',
'speak-as',
'src', // @font-face
'tab-size',
'table-layout',
'text-align',
'text-align-all',
'text-align-last',
'text-combine-upright',
'text-decoration',
'text-decoration-color',
'text-decoration-line',
'text-decoration-style',
'text-emphasis',
'text-emphasis-color',
'text-emphasis-position',
'text-emphasis-style',
'text-indent',
'text-justify',
'text-orientation',
'text-overflow',
'text-rendering',
'text-shadow',
'text-transform',
'text-underline-position',
'top',
'transform',
'transform-box',
'transform-origin',
'transform-style',
'transition',
'transition-delay',
'transition-duration',
'transition-property',
'transition-timing-function',
'unicode-bidi',
'vertical-align',
'visibility',
'voice-balance',
'voice-duration',
'voice-family',
'voice-pitch',
'voice-range',
'voice-rate',
'voice-stress',
'voice-volume',
'white-space',
'widows',
'width',
'will-change',
'word-break',
'word-spacing',
'word-wrap',
'writing-mode',
'z-index'
// reverse makes sure longer attributes `font-weight` are matched fully
// instead of getting false positives on say `font`
].reverse();
// some grammars use them all as a single group
const PSEUDO_SELECTORS = PSEUDO_CLASSES$2.concat(PSEUDO_ELEMENTS$2);
/*
Language: Less
Description: It's CSS, with just a little more.
Author: Max Mikhailov <seven.phases.max@gmail.com>
Website: http://lesscss.org
Category: common, css, web
*/
/** @type LanguageFn */
function less(hljs) {
const modes = MODES$2(hljs);
const PSEUDO_SELECTORS$1 = PSEUDO_SELECTORS;
const AT_MODIFIERS = "and or not only";
const IDENT_RE = '[\\w-]+'; // yes, Less identifiers may begin with a digit
const INTERP_IDENT_RE = '(' + IDENT_RE + '|@\\{' + IDENT_RE + '\\})';
/* Generic Modes */
const RULES = []; const VALUE_MODES = []; // forward def. for recursive modes
const STRING_MODE = function(c) {
return {
// Less strings are not multiline (also include '~' for more consistent coloring of "escaped" strings)
className: 'string',
begin: '~?' + c + '.*?' + c
};
};
const IDENT_MODE = function(name, begin, relevance) {
return {
className: name,
begin: begin,
relevance: relevance
};
};
const AT_KEYWORDS = {
$pattern: /[a-z-]+/,
keyword: AT_MODIFIERS,
attribute: MEDIA_FEATURES$2.join(" ")
};
const PARENS_MODE = {
// used only to properly balance nested parens inside mixin call, def. arg list
begin: '\\(',
end: '\\)',
contains: VALUE_MODES,
keywords: AT_KEYWORDS,
relevance: 0
};
// generic Less highlighter (used almost everywhere except selectors):
VALUE_MODES.push(
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRING_MODE("'"),
STRING_MODE('"'),
modes.CSS_NUMBER_MODE, // fixme: it does not include dot for numbers like .5em :(
{
begin: '(url|data-uri)\\(',
starts: {
className: 'string',
end: '[\\)\\n]',
excludeEnd: true
}
},
modes.HEXCOLOR,
PARENS_MODE,
IDENT_MODE('variable', '@@?' + IDENT_RE, 10),
IDENT_MODE('variable', '@\\{' + IDENT_RE + '\\}'),
IDENT_MODE('built_in', '~?`[^`]*?`'), // inline javascript (or whatever host language) *multiline* string
{ // @media features (its here to not duplicate things in AT_RULE_MODE with extra PARENS_MODE overriding):
className: 'attribute',
begin: IDENT_RE + '\\s*:',
end: ':',
returnBegin: true,
excludeEnd: true
},
modes.IMPORTANT,
{ beginKeywords: 'and not' },
modes.FUNCTION_DISPATCH
);
const VALUE_WITH_RULESETS = VALUE_MODES.concat({
begin: /\{/,
end: /\}/,
contains: RULES
});
const MIXIN_GUARD_MODE = {
beginKeywords: 'when',
endsWithParent: true,
contains: [ { beginKeywords: 'and not' } ].concat(VALUE_MODES) // using this form to override VALUEs 'function' match
};
/* Rule-Level Modes */
const RULE_MODE = {
begin: INTERP_IDENT_RE + '\\s*:',
returnBegin: true,
end: /[;}]/,
relevance: 0,
contains: [
{ begin: /-(webkit|moz|ms|o)-/ },
modes.CSS_VARIABLE,
{
className: 'attribute',
begin: '\\b(' + ATTRIBUTES$2.join('|') + ')\\b',
end: /(?=:)/,
starts: {
endsWithParent: true,
illegal: '[<=$]',
relevance: 0,
contains: VALUE_MODES
}
}
]
};
const AT_RULE_MODE = {
className: 'keyword',
begin: '@(import|media|charset|font-face|(-[a-z]+-)?keyframes|supports|document|namespace|page|viewport|host)\\b',
starts: {
end: '[;{}]',
keywords: AT_KEYWORDS,
returnEnd: true,
contains: VALUE_MODES,
relevance: 0
}
};
// variable definitions and calls
const VAR_RULE_MODE = {
className: 'variable',
variants: [
// using more strict pattern for higher relevance to increase chances of Less detection.
// this is *the only* Less specific statement used in most of the sources, so...
// (well still often loose to the css-parser unless there's '//' comment,
// simply because 1 variable just can't beat 99 properties :)
{
begin: '@' + IDENT_RE + '\\s*:',
relevance: 15
},
{ begin: '@' + IDENT_RE }
],
starts: {
end: '[;}]',
returnEnd: true,
contains: VALUE_WITH_RULESETS
}
};
const SELECTOR_MODE = {
// first parse unambiguous selectors (i.e. those not starting with tag)
// then fall into the scary lookahead-discriminator variant.
// this mode also handles mixin definitions and calls
variants: [
{
begin: '[\\.#:&\\[>]',
end: '[;{}]' // mixin calls end with ';'
},
{
begin: INTERP_IDENT_RE,
end: /\{/
}
],
returnBegin: true,
returnEnd: true,
illegal: '[<=\'$"]',
relevance: 0,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
MIXIN_GUARD_MODE,
IDENT_MODE('keyword', 'all\\b'),
IDENT_MODE('variable', '@\\{' + IDENT_RE + '\\}'), // otherwise its identified as tag
{
begin: '\\b(' + TAGS$2.join('|') + ')\\b',
className: 'selector-tag'
},
modes.CSS_NUMBER_MODE,
IDENT_MODE('selector-tag', INTERP_IDENT_RE, 0),
IDENT_MODE('selector-id', '#' + INTERP_IDENT_RE),
IDENT_MODE('selector-class', '\\.' + INTERP_IDENT_RE, 0),
IDENT_MODE('selector-tag', '&', 0),
modes.ATTRIBUTE_SELECTOR_MODE,
{
className: 'selector-pseudo',
begin: ':(' + PSEUDO_CLASSES$2.join('|') + ')'
},
{
className: 'selector-pseudo',
begin: ':(:)?(' + PSEUDO_ELEMENTS$2.join('|') + ')'
},
{
begin: /\(/,
end: /\)/,
relevance: 0,
contains: VALUE_WITH_RULESETS
}, // argument list of parametric mixins
{ begin: '!important' }, // eat !important after mixin call or it will be colored as tag
modes.FUNCTION_DISPATCH
]
};
const PSEUDO_SELECTOR_MODE = {
begin: IDENT_RE + ':(:)?' + `(${PSEUDO_SELECTORS$1.join('|')})`,
returnBegin: true,
contains: [ SELECTOR_MODE ]
};
RULES.push(
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
AT_RULE_MODE,
VAR_RULE_MODE,
PSEUDO_SELECTOR_MODE,
RULE_MODE,
SELECTOR_MODE,
MIXIN_GUARD_MODE,
modes.FUNCTION_DISPATCH
);
return {
name: 'Less',
case_insensitive: true,
illegal: '[=>\'/<($"]',
contains: RULES
};
}
var less_1 = less;
/*
Language: Lisp
Description: Generic lisp syntax
Author: Vasily Polovnyov <vast@whiteants.net>
Category: lisp
*/
function lisp(hljs) {
const LISP_IDENT_RE = '[a-zA-Z_\\-+\\*\\/<=>&#][a-zA-Z0-9_\\-+*\\/<=>&#!]*';
const MEC_RE = '\\|[^]*?\\|';
const LISP_SIMPLE_NUMBER_RE = '(-|\\+)?\\d+(\\.\\d+|\\/\\d+)?((d|e|f|l|s|D|E|F|L|S)(\\+|-)?\\d+)?';
const LITERAL = {
className: 'literal',
begin: '\\b(t{1}|nil)\\b'
};
const NUMBER = {
className: 'number',
variants: [
{
begin: LISP_SIMPLE_NUMBER_RE,
relevance: 0
},
{ begin: '#(b|B)[0-1]+(/[0-1]+)?' },
{ begin: '#(o|O)[0-7]+(/[0-7]+)?' },
{ begin: '#(x|X)[0-9a-fA-F]+(/[0-9a-fA-F]+)?' },
{
begin: '#(c|C)\\(' + LISP_SIMPLE_NUMBER_RE + ' +' + LISP_SIMPLE_NUMBER_RE,
end: '\\)'
}
]
};
const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null });
const COMMENT = hljs.COMMENT(
';', '$',
{ relevance: 0 }
);
const VARIABLE = {
begin: '\\*',
end: '\\*'
};
const KEYWORD = {
className: 'symbol',
begin: '[:&]' + LISP_IDENT_RE
};
const IDENT = {
begin: LISP_IDENT_RE,
relevance: 0
};
const MEC = { begin: MEC_RE };
const QUOTED_LIST = {
begin: '\\(',
end: '\\)',
contains: [
'self',
LITERAL,
STRING,
NUMBER,
IDENT
]
};
const QUOTED = {
contains: [
NUMBER,
STRING,
VARIABLE,
KEYWORD,
QUOTED_LIST,
IDENT
],
variants: [
{
begin: '[\'`]\\(',
end: '\\)'
},
{
begin: '\\(quote ',
end: '\\)',
keywords: { name: 'quote' }
},
{ begin: '\'' + MEC_RE }
]
};
const QUOTED_ATOM = { variants: [
{ begin: '\'' + LISP_IDENT_RE },
{ begin: '#\'' + LISP_IDENT_RE + '(::' + LISP_IDENT_RE + ')*' }
] };
const LIST = {
begin: '\\(\\s*',
end: '\\)'
};
const BODY = {
endsWithParent: true,
relevance: 0
};
LIST.contains = [
{
className: 'name',
variants: [
{
begin: LISP_IDENT_RE,
relevance: 0,
},
{ begin: MEC_RE }
]
},
BODY
];
BODY.contains = [
QUOTED,
QUOTED_ATOM,
LIST,
LITERAL,
NUMBER,
STRING,
COMMENT,
VARIABLE,
KEYWORD,
MEC,
IDENT
];
return {
name: 'Lisp',
illegal: /\S/,
contains: [
NUMBER,
hljs.SHEBANG(),
LITERAL,
STRING,
COMMENT,
QUOTED,
QUOTED_ATOM,
LIST,
IDENT
]
};
}
var lisp_1 = lisp;
/*
Language: LiveCode
Author: Ralf Bitter <rabit@revigniter.com>
Description: Language definition for LiveCode server accounting for revIgniter (a web application framework) characteristics.
Version: 1.1
Date: 2019-04-17
Category: enterprise
*/
function livecodeserver(hljs) {
const VARIABLE = {
className: 'variable',
variants: [
{ begin: '\\b([gtps][A-Z]{1}[a-zA-Z0-9]*)(\\[.+\\])?(?:\\s*?)' },
{ begin: '\\$_[A-Z]+' }
],
relevance: 0
};
const COMMENT_MODES = [
hljs.C_BLOCK_COMMENT_MODE,
hljs.HASH_COMMENT_MODE,
hljs.COMMENT('--', '$'),
hljs.COMMENT('[^:]//', '$')
];
const TITLE1 = hljs.inherit(hljs.TITLE_MODE, { variants: [
{ begin: '\\b_*rig[A-Z][A-Za-z0-9_\\-]*' },
{ begin: '\\b_[a-z0-9\\-]+' }
] });
const TITLE2 = hljs.inherit(hljs.TITLE_MODE, { begin: '\\b([A-Za-z0-9_\\-]+)\\b' });
return {
name: 'LiveCode',
case_insensitive: false,
keywords: {
keyword:
'$_COOKIE $_FILES $_GET $_GET_BINARY $_GET_RAW $_POST $_POST_BINARY $_POST_RAW $_SESSION $_SERVER '
+ 'codepoint codepoints segment segments codeunit codeunits sentence sentences trueWord trueWords paragraph '
+ 'after byte bytes english the until http forever descending using line real8 with seventh '
+ 'for stdout finally element word words fourth before black ninth sixth characters chars stderr '
+ 'uInt1 uInt1s uInt2 uInt2s stdin string lines relative rel any fifth items from middle mid '
+ 'at else of catch then third it file milliseconds seconds second secs sec int1 int1s int4 '
+ 'int4s internet int2 int2s normal text item last long detailed effective uInt4 uInt4s repeat '
+ 'end repeat URL in try into switch to words https token binfile each tenth as ticks tick '
+ 'system real4 by dateItems without char character ascending eighth whole dateTime numeric short '
+ 'first ftp integer abbreviated abbr abbrev private case while if '
+ 'div mod wrap and or bitAnd bitNot bitOr bitXor among not in a an within '
+ 'contains ends with begins the keys of keys',
literal:
'SIX TEN FORMFEED NINE ZERO NONE SPACE FOUR FALSE COLON CRLF PI COMMA ENDOFFILE EOF EIGHT FIVE '
+ 'QUOTE EMPTY ONE TRUE RETURN CR LINEFEED RIGHT BACKSLASH NULL SEVEN TAB THREE TWO '
+ 'six ten formfeed nine zero none space four false colon crlf pi comma endoffile eof eight five '
+ 'quote empty one true return cr linefeed right backslash null seven tab three two '
+ 'RIVERSION RISTATE FILE_READ_MODE FILE_WRITE_MODE FILE_WRITE_MODE DIR_WRITE_MODE FILE_READ_UMASK '
+ 'FILE_WRITE_UMASK DIR_READ_UMASK DIR_WRITE_UMASK',
built_in:
'put abs acos aliasReference annuity arrayDecode arrayEncode asin atan atan2 average avg avgDev base64Decode '
+ 'base64Encode baseConvert binaryDecode binaryEncode byteOffset byteToNum cachedURL cachedURLs charToNum '
+ 'cipherNames codepointOffset codepointProperty codepointToNum codeunitOffset commandNames compound compress '
+ 'constantNames cos date dateFormat decompress difference directories '
+ 'diskSpace DNSServers exp exp1 exp2 exp10 extents files flushEvents folders format functionNames geometricMean global '
+ 'globals hasMemory harmonicMean hostAddress hostAddressToName hostName hostNameToAddress isNumber ISOToMac itemOffset '
+ 'keys len length libURLErrorData libUrlFormData libURLftpCommand libURLLastHTTPHeaders libURLLastRHHeaders '
+ 'libUrlMultipartFormAddPart libUrlMultipartFormData libURLVersion lineOffset ln ln1 localNames log log2 log10 '
+ 'longFilePath lower macToISO matchChunk matchText matrixMultiply max md5Digest median merge messageAuthenticationCode messageDigest millisec '
+ 'millisecs millisecond milliseconds min monthNames nativeCharToNum normalizeText num number numToByte numToChar '
+ 'numToCodepoint numToNativeChar offset open openfiles openProcesses openProcessIDs openSockets '
+ 'paragraphOffset paramCount param params peerAddress pendingMessages platform popStdDev populationStandardDeviation '
+ 'populationVariance popVariance processID random randomBytes replaceText result revCreateXMLTree revCreateXMLTreeFromFile '
+ 'revCurrentRecord revCurrentRecordIsFirst revCurrentRecordIsLast revDatabaseColumnCount revDatabaseColumnIsNull '
+ 'revDatabaseColumnLengths revDatabaseColumnNames revDatabaseColumnNamed revDatabaseColumnNumbered '
+ 'revDatabaseColumnTypes revDatabaseConnectResult revDatabaseCursors revDatabaseID revDatabaseTableNames '
+ 'revDatabaseType revDataFromQuery revdb_closeCursor revdb_columnbynumber revdb_columncount revdb_columnisnull '
+ 'revdb_columnlengths revdb_columnnames revdb_columntypes revdb_commit revdb_connect revdb_connections '
+ 'revdb_connectionerr revdb_currentrecord revdb_cursorconnection revdb_cursorerr revdb_cursors revdb_dbtype '
+ 'revdb_disconnect revdb_execute revdb_iseof revdb_isbof revdb_movefirst revdb_movelast revdb_movenext '
+ 'revdb_moveprev revdb_query revdb_querylist revdb_recordcount revdb_rollback revdb_tablenames '
+ 'revGetDatabaseDriverPath revNumberOfRecords revOpenDatabase revOpenDatabases revQueryDatabase '
+ 'revQueryDatabaseBlob revQueryResult revQueryIsAtStart revQueryIsAtEnd revUnixFromMacPath revXMLAttribute '
+ 'revXMLAttributes revXMLAttributeValues revXMLChildContents revXMLChildNames revXMLCreateTreeFromFileWithNamespaces '
+ 'revXMLCreateTreeWithNamespaces revXMLDataFromXPathQuery revXMLEvaluateXPath revXMLFirstChild revXMLMatchingNode '
+ 'revXMLNextSibling revXMLNodeContents revXMLNumberOfChildren revXMLParent revXMLPreviousSibling '
+ 'revXMLRootNode revXMLRPC_CreateRequest revXMLRPC_Documents revXMLRPC_Error '
+ 'revXMLRPC_GetHost revXMLRPC_GetMethod revXMLRPC_GetParam revXMLText revXMLRPC_Execute '
+ 'revXMLRPC_GetParamCount revXMLRPC_GetParamNode revXMLRPC_GetParamType revXMLRPC_GetPath revXMLRPC_GetPort '
+ 'revXMLRPC_GetProtocol revXMLRPC_GetRequest revXMLRPC_GetResponse revXMLRPC_GetSocket revXMLTree '
+ 'revXMLTrees revXMLValidateDTD revZipDescribeItem revZipEnumerateItems revZipOpenArchives round sampVariance '
+ 'sec secs seconds sentenceOffset sha1Digest shell shortFilePath sin specialFolderPath sqrt standardDeviation statRound '
+ 'stdDev sum sysError systemVersion tan tempName textDecode textEncode tick ticks time to tokenOffset toLower toUpper '
+ 'transpose truewordOffset trunc uniDecode uniEncode upper URLDecode URLEncode URLStatus uuid value variableNames '
+ 'variance version waitDepth weekdayNames wordOffset xsltApplyStylesheet xsltApplyStylesheetFromFile xsltLoadStylesheet '
+ 'xsltLoadStylesheetFromFile add breakpoint cancel clear local variable file word line folder directory URL close socket process '
+ 'combine constant convert create new alias folder directory decrypt delete variable word line folder '
+ 'directory URL dispatch divide do encrypt filter get include intersect kill libURLDownloadToFile '
+ 'libURLFollowHttpRedirects libURLftpUpload libURLftpUploadFile libURLresetAll libUrlSetAuthCallback libURLSetDriver '
+ 'libURLSetCustomHTTPHeaders libUrlSetExpect100 libURLSetFTPListCommand libURLSetFTPMode libURLSetFTPStopTime '
+ 'libURLSetStatusCallback load extension loadedExtensions multiply socket prepare process post seek rel relative read from process rename '
+ 'replace require resetAll resolve revAddXMLNode revAppendXML revCloseCursor revCloseDatabase revCommitDatabase '
+ 'revCopyFile revCopyFolder revCopyXMLNode revDeleteFolder revDeleteXMLNode revDeleteAllXMLTrees '
+ 'revDeleteXMLTree revExecuteSQL revGoURL revInsertXMLNode revMoveFolder revMoveToFirstRecord revMoveToLastRecord '
+ 'revMoveToNextRecord revMoveToPreviousRecord revMoveToRecord revMoveXMLNode revPutIntoXMLNode revRollBackDatabase '
+ 'revSetDatabaseDriverPath revSetXMLAttribute revXMLRPC_AddParam revXMLRPC_DeleteAllDocuments revXMLAddDTD '
+ 'revXMLRPC_Free revXMLRPC_FreeAll revXMLRPC_DeleteDocument revXMLRPC_DeleteParam revXMLRPC_SetHost '
+ 'revXMLRPC_SetMethod revXMLRPC_SetPort revXMLRPC_SetProtocol revXMLRPC_SetSocket revZipAddItemWithData '
+ 'revZipAddItemWithFile revZipAddUncompressedItemWithData revZipAddUncompressedItemWithFile revZipCancel '
+ 'revZipCloseArchive revZipDeleteItem revZipExtractItemToFile revZipExtractItemToVariable revZipSetProgressCallback '
+ 'revZipRenameItem revZipReplaceItemWithData revZipReplaceItemWithFile revZipOpenArchive send set sort split start stop '
+ 'subtract symmetric union unload vectorDotProduct wait write'
},
contains: [
VARIABLE,
{
className: 'keyword',
begin: '\\bend\\sif\\b'
},
{
className: 'function',
beginKeywords: 'function',
end: '$',
contains: [
VARIABLE,
TITLE2,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE,
TITLE1
]
},
{
className: 'function',
begin: '\\bend\\s+',
end: '$',
keywords: 'end',
contains: [
TITLE2,
TITLE1
],
relevance: 0
},
{
beginKeywords: 'command on',
end: '$',
contains: [
VARIABLE,
TITLE2,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE,
TITLE1
]
},
{
className: 'meta',
variants: [
{
begin: '<\\?(rev|lc|livecode)',
relevance: 10
},
{ begin: '<\\?' },
{ begin: '\\?>' }
]
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE,
TITLE1
].concat(COMMENT_MODES),
illegal: ';$|^\\[|^=|&|\\{'
};
}
var livecodeserver_1 = livecodeserver;
const KEYWORDS$1 = [
"as", // for exports
"in",
"of",
"if",
"for",
"while",
"finally",
"var",
"new",
"function",
"do",
"return",
"void",
"else",
"break",
"catch",
"instanceof",
"with",
"throw",
"case",
"default",
"try",
"switch",
"continue",
"typeof",
"delete",
"let",
"yield",
"const",
"class",
// JS handles these with a special rule
// "get",
// "set",
"debugger",
"async",
"await",
"static",
"import",
"from",
"export",
"extends"
];
const LITERALS$1 = [
"true",
"false",
"null",
"undefined",
"NaN",
"Infinity"
];
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
const TYPES$1 = [
// Fundamental objects
"Object",
"Function",
"Boolean",
"Symbol",
// numbers and dates
"Math",
"Date",
"Number",
"BigInt",
// text
"String",
"RegExp",
// Indexed collections
"Array",
"Float32Array",
"Float64Array",
"Int8Array",
"Uint8Array",
"Uint8ClampedArray",
"Int16Array",
"Int32Array",
"Uint16Array",
"Uint32Array",
"BigInt64Array",
"BigUint64Array",
// Keyed collections
"Set",
"Map",
"WeakSet",
"WeakMap",
// Structured data
"ArrayBuffer",
"SharedArrayBuffer",
"Atomics",
"DataView",
"JSON",
// Control abstraction objects
"Promise",
"Generator",
"GeneratorFunction",
"AsyncFunction",
// Reflection
"Reflect",
"Proxy",
// Internationalization
"Intl",
// WebAssembly
"WebAssembly"
];
const ERROR_TYPES$1 = [
"Error",
"EvalError",
"InternalError",
"RangeError",
"ReferenceError",
"SyntaxError",
"TypeError",
"URIError"
];
const BUILT_IN_GLOBALS$1 = [
"setInterval",
"setTimeout",
"clearInterval",
"clearTimeout",
"require",
"exports",
"eval",
"isFinite",
"isNaN",
"parseFloat",
"parseInt",
"decodeURI",
"decodeURIComponent",
"encodeURI",
"encodeURIComponent",
"escape",
"unescape"
];
const BUILT_INS$1 = [].concat(
BUILT_IN_GLOBALS$1,
TYPES$1,
ERROR_TYPES$1
);
/*
Language: LiveScript
Author: Taneli Vatanen <taneli.vatanen@gmail.com>
Contributors: Jen Evers-Corvina <jen@sevvie.net>
Origin: coffeescript.js
Description: LiveScript is a programming language that transcompiles to JavaScript. For info about language see http://livescript.net/
Website: https://livescript.net
Category: scripting
*/
function livescript(hljs) {
const LIVESCRIPT_BUILT_INS = [
'npm',
'print'
];
const LIVESCRIPT_LITERALS = [
'yes',
'no',
'on',
'off',
'it',
'that',
'void'
];
const LIVESCRIPT_KEYWORDS = [
'then',
'unless',
'until',
'loop',
'of',
'by',
'when',
'and',
'or',
'is',
'isnt',
'not',
'it',
'that',
'otherwise',
'from',
'to',
'til',
'fallthrough',
'case',
'enum',
'native',
'list',
'map',
'__hasProp',
'__extends',
'__slice',
'__bind',
'__indexOf'
];
const KEYWORDS$1$1 = {
keyword: KEYWORDS$1.concat(LIVESCRIPT_KEYWORDS),
literal: LITERALS$1.concat(LIVESCRIPT_LITERALS),
built_in: BUILT_INS$1.concat(LIVESCRIPT_BUILT_INS)
};
const JS_IDENT_RE = '[A-Za-z$_](?:-[0-9A-Za-z$_]|[0-9A-Za-z$_])*';
const TITLE = hljs.inherit(hljs.TITLE_MODE, { begin: JS_IDENT_RE });
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: KEYWORDS$1$1
};
const SUBST_SIMPLE = {
className: 'subst',
begin: /#[A-Za-z$_]/,
end: /(?:-[0-9A-Za-z$_]|[0-9A-Za-z$_])*/,
keywords: KEYWORDS$1$1
};
const EXPRESSIONS = [
hljs.BINARY_NUMBER_MODE,
{
className: 'number',
begin: '(\\b0[xX][a-fA-F0-9_]+)|(\\b\\d(\\d|_\\d)*(\\.(\\d(\\d|_\\d)*)?)?(_*[eE]([-+]\\d(_\\d|\\d)*)?)?[_a-z]*)',
relevance: 0,
starts: {
end: '(\\s*/)?',
relevance: 0
} // a number tries to eat the following slash to prevent treating it as a regexp
},
{
className: 'string',
variants: [
{
begin: /'''/,
end: /'''/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /'/,
end: /'/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /"""/,
end: /"""/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
SUBST_SIMPLE
]
},
{
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST,
SUBST_SIMPLE
]
},
{
begin: /\\/,
end: /(\s|$)/,
excludeEnd: true
}
]
},
{
className: 'regexp',
variants: [
{
begin: '//',
end: '//[gim]*',
contains: [
SUBST,
hljs.HASH_COMMENT_MODE
]
},
{
// regex can't start with space to parse x / 2 / 3 as two divisions
// regex can't start with *, and it supports an "illegal" in the main mode
begin: /\/(?![ *])(\\.|[^\\\n])*?\/[gim]*(?=\W)/ }
]
},
{ begin: '@' + JS_IDENT_RE },
{
begin: '``',
end: '``',
excludeBegin: true,
excludeEnd: true,
subLanguage: 'javascript'
}
];
SUBST.contains = EXPRESSIONS;
const PARAMS = {
className: 'params',
begin: '\\(',
returnBegin: true,
/* We need another contained nameless mode to not have every nested
pair of parens to be called "params" */
contains: [
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS$1$1,
contains: [ 'self' ].concat(EXPRESSIONS)
}
]
};
const SYMBOLS = { begin: '(#=>|=>|\\|>>|-?->|!->)' };
const CLASS_DEFINITION = {
variants: [
{ match: [
/class\s+/,
JS_IDENT_RE,
/\s+extends\s+/,
JS_IDENT_RE
] },
{ match: [
/class\s+/,
JS_IDENT_RE
] }
],
scope: {
2: "title.class",
4: "title.class.inherited"
},
keywords: KEYWORDS$1$1
};
return {
name: 'LiveScript',
aliases: [ 'ls' ],
keywords: KEYWORDS$1$1,
illegal: /\/\*/,
contains: EXPRESSIONS.concat([
hljs.COMMENT('\\/\\*', '\\*\\/'),
hljs.HASH_COMMENT_MODE,
SYMBOLS, // relevance booster
{
className: 'function',
contains: [
TITLE,
PARAMS
],
returnBegin: true,
variants: [
{
begin: '(' + JS_IDENT_RE + '\\s*(?:=|:=)\\s*)?(\\(.*\\)\\s*)?\\B->\\*?',
end: '->\\*?'
},
{
begin: '(' + JS_IDENT_RE + '\\s*(?:=|:=)\\s*)?!?(\\(.*\\)\\s*)?\\B[-~]{1,2}>\\*?',
end: '[-~]{1,2}>\\*?'
},
{
begin: '(' + JS_IDENT_RE + '\\s*(?:=|:=)\\s*)?(\\(.*\\)\\s*)?\\B!?[-~]{1,2}>\\*?',
end: '!?[-~]{1,2}>\\*?'
}
]
},
CLASS_DEFINITION,
{
begin: JS_IDENT_RE + ':',
end: ':',
returnBegin: true,
returnEnd: true,
relevance: 0
}
])
};
}
var livescript_1 = livescript;
/*
Language: LLVM IR
Author: Michael Rodler <contact@f0rki.at>
Description: language used as intermediate representation in the LLVM compiler framework
Website: https://llvm.org/docs/LangRef.html
Category: assembler
Audit: 2020
*/
/** @type LanguageFn */
function llvm(hljs) {
const regex = hljs.regex;
const IDENT_RE = /([-a-zA-Z$._][\w$.-]*)/;
const TYPE = {
className: 'type',
begin: /\bi\d+(?=\s|\b)/
};
const OPERATOR = {
className: 'operator',
relevance: 0,
begin: /=/
};
const PUNCTUATION = {
className: 'punctuation',
relevance: 0,
begin: /,/
};
const NUMBER = {
className: 'number',
variants: [
{ begin: /[su]?0[xX][KMLHR]?[a-fA-F0-9]+/ },
{ begin: /[-+]?\d+(?:[.]\d+)?(?:[eE][-+]?\d+(?:[.]\d+)?)?/ }
],
relevance: 0
};
const LABEL = {
className: 'symbol',
variants: [ { begin: /^\s*[a-z]+:/ }, // labels
],
relevance: 0
};
const VARIABLE = {
className: 'variable',
variants: [
{ begin: regex.concat(/%/, IDENT_RE) },
{ begin: /%\d+/ },
{ begin: /#\d+/ },
]
};
const FUNCTION = {
className: 'title',
variants: [
{ begin: regex.concat(/@/, IDENT_RE) },
{ begin: /@\d+/ },
{ begin: regex.concat(/!/, IDENT_RE) },
{ begin: regex.concat(/!\d+/, IDENT_RE) },
// https://llvm.org/docs/LangRef.html#namedmetadatastructure
// obviously a single digit can also be used in this fashion
{ begin: /!\d+/ }
]
};
return {
name: 'LLVM IR',
// TODO: split into different categories of keywords
keywords:
'begin end true false declare define global '
+ 'constant private linker_private internal '
+ 'available_externally linkonce linkonce_odr weak '
+ 'weak_odr appending dllimport dllexport common '
+ 'default hidden protected extern_weak external '
+ 'thread_local zeroinitializer undef null to tail '
+ 'target triple datalayout volatile nuw nsw nnan '
+ 'ninf nsz arcp fast exact inbounds align '
+ 'addrspace section alias module asm sideeffect '
+ 'gc dbg linker_private_weak attributes blockaddress '
+ 'initialexec localdynamic localexec prefix unnamed_addr '
+ 'ccc fastcc coldcc x86_stdcallcc x86_fastcallcc '
+ 'arm_apcscc arm_aapcscc arm_aapcs_vfpcc ptx_device '
+ 'ptx_kernel intel_ocl_bicc msp430_intrcc spir_func '
+ 'spir_kernel x86_64_sysvcc x86_64_win64cc x86_thiscallcc '
+ 'cc c signext zeroext inreg sret nounwind '
+ 'noreturn noalias nocapture byval nest readnone '
+ 'readonly inlinehint noinline alwaysinline optsize ssp '
+ 'sspreq noredzone noimplicitfloat naked builtin cold '
+ 'nobuiltin noduplicate nonlazybind optnone returns_twice '
+ 'sanitize_address sanitize_memory sanitize_thread sspstrong '
+ 'uwtable returned type opaque eq ne slt sgt '
+ 'sle sge ult ugt ule uge oeq one olt ogt '
+ 'ole oge ord uno ueq une x acq_rel acquire '
+ 'alignstack atomic catch cleanup filter inteldialect '
+ 'max min monotonic nand personality release seq_cst '
+ 'singlethread umax umin unordered xchg add fadd '
+ 'sub fsub mul fmul udiv sdiv fdiv urem srem '
+ 'frem shl lshr ashr and or xor icmp fcmp '
+ 'phi call trunc zext sext fptrunc fpext uitofp '
+ 'sitofp fptoui fptosi inttoptr ptrtoint bitcast '
+ 'addrspacecast select va_arg ret br switch invoke '
+ 'unwind unreachable indirectbr landingpad resume '
+ 'malloc alloca free load store getelementptr '
+ 'extractelement insertelement shufflevector getresult '
+ 'extractvalue insertvalue atomicrmw cmpxchg fence '
+ 'argmemonly double',
contains: [
TYPE,
// this matches "empty comments"...
// ...because it's far more likely this is a statement terminator in
// another language than an actual comment
hljs.COMMENT(/;\s*$/, null, { relevance: 0 }),
hljs.COMMENT(/;/, /$/),
{
className: 'string',
begin: /"/,
end: /"/,
contains: [
{
className: 'char.escape',
match: /\\\d\d/
}
]
},
FUNCTION,
PUNCTUATION,
OPERATOR,
VARIABLE,
LABEL,
NUMBER
]
};
}
var llvm_1 = llvm;
/*
Language: LSL (Linden Scripting Language)
Description: The Linden Scripting Language is used in Second Life by Linden Labs.
Author: Builder's Brewery <buildersbrewery@gmail.com>
Website: http://wiki.secondlife.com/wiki/LSL_Portal
Category: scripting
*/
function lsl(hljs) {
const LSL_STRING_ESCAPE_CHARS = {
className: 'subst',
begin: /\\[tn"\\]/
};
const LSL_STRINGS = {
className: 'string',
begin: '"',
end: '"',
contains: [ LSL_STRING_ESCAPE_CHARS ]
};
const LSL_NUMBERS = {
className: 'number',
relevance: 0,
begin: hljs.C_NUMBER_RE
};
const LSL_CONSTANTS = {
className: 'literal',
variants: [
{ begin: '\\b(PI|TWO_PI|PI_BY_TWO|DEG_TO_RAD|RAD_TO_DEG|SQRT2)\\b' },
{ begin: '\\b(XP_ERROR_(EXPERIENCES_DISABLED|EXPERIENCE_(DISABLED|SUSPENDED)|INVALID_(EXPERIENCE|PARAMETERS)|KEY_NOT_FOUND|MATURITY_EXCEEDED|NONE|NOT_(FOUND|PERMITTED(_LAND)?)|NO_EXPERIENCE|QUOTA_EXCEEDED|RETRY_UPDATE|STORAGE_EXCEPTION|STORE_DISABLED|THROTTLED|UNKNOWN_ERROR)|JSON_APPEND|STATUS_(PHYSICS|ROTATE_[XYZ]|PHANTOM|SANDBOX|BLOCK_GRAB(_OBJECT)?|(DIE|RETURN)_AT_EDGE|CAST_SHADOWS|OK|MALFORMED_PARAMS|TYPE_MISMATCH|BOUNDS_ERROR|NOT_(FOUND|SUPPORTED)|INTERNAL_ERROR|WHITELIST_FAILED)|AGENT(_(BY_(LEGACY_|USER)NAME|FLYING|ATTACHMENTS|SCRIPTED|MOUSELOOK|SITTING|ON_OBJECT|AWAY|WALKING|IN_AIR|TYPING|CROUCHING|BUSY|ALWAYS_RUN|AUTOPILOT|LIST_(PARCEL(_OWNER)?|REGION)))?|CAMERA_(PITCH|DISTANCE|BEHINDNESS_(ANGLE|LAG)|(FOCUS|POSITION)(_(THRESHOLD|LOCKED|LAG))?|FOCUS_OFFSET|ACTIVE)|ANIM_ON|LOOP|REVERSE|PING_PONG|SMOOTH|ROTATE|SCALE|ALL_SIDES|LINK_(ROOT|SET|ALL_(OTHERS|CHILDREN)|THIS)|ACTIVE|PASS(IVE|_(ALWAYS|IF_NOT_HANDLED|NEVER))|SCRIPTED|CONTROL_(FWD|BACK|(ROT_)?(LEFT|RIGHT)|UP|DOWN|(ML_)?LBUTTON)|PERMISSION_(RETURN_OBJECTS|DEBIT|OVERRIDE_ANIMATIONS|SILENT_ESTATE_MANAGEMENT|TAKE_CONTROLS|TRIGGER_ANIMATION|ATTACH|CHANGE_LINKS|(CONTROL|TRACK)_CAMERA|TELEPORT)|INVENTORY_(TEXTURE|SOUND|OBJECT|SCRIPT|LANDMARK|CLOTHING|NOTECARD|BODYPART|ANIMATION|GESTURE|ALL|NONE)|CHANGED_(INVENTORY|COLOR|SHAPE|SCALE|TEXTURE|LINK|ALLOWED_DROP|OWNER|REGION(_START)?|TELEPORT|MEDIA)|OBJECT_(CLICK_ACTION|HOVER_HEIGHT|LAST_OWNER_ID|(PHYSICS|SERVER|STREAMING)_COST|UNKNOWN_DETAIL|CHARACTER_TIME|PHANTOM|PHYSICS|TEMP_(ATTACHED|ON_REZ)|NAME|DESC|POS|PRIM_(COUNT|EQUIVALENCE)|RETURN_(PARCEL(_OWNER)?|REGION)|REZZER_KEY|ROO?T|VELOCITY|OMEGA|OWNER|GROUP(_TAG)?|CREATOR|ATTACHED_(POINT|SLOTS_AVAILABLE)|RENDER_WEIGHT|(BODY_SHAPE|PATHFINDING)_TYPE|(RUNNING|TOTAL)_SCRIPT_COUNT|TOTAL_INVENTORY_COUNT|SCRIPT_(MEMORY|TIME))|TYPE_(INTEGER|FLOAT|STRING|KEY|VECTOR|ROTATION|INVALID)|(DEBUG|PUBLIC)_CHANNEL|ATTACH_(AVATAR_CENTER|CHEST|HEAD|BACK|PELVIS|MOUTH|CHIN|NECK|NOSE|BELLY|[LR](SHOULDER|HAND|FOOT|EAR|EYE|[UL](ARM|LEG)|HIP)|(LEFT|RIGHT)_PEC|HUD_(CENTER_[12]|TOP_(RIGHT|CENTER|LEFT)|BOTTOM(_(RIGHT|LEFT))?)|[LR]HAND_RING1|TAIL_(BASE|TIP)|[LR]WING|FACE_(JAW|[LR]EAR|[LR]EYE|TOUNGE)|GROIN|HIND_[LR]FOOT)|LAND_(LEVEL|RAISE|LOWER|SMOOTH|NOISE|REVERT)|DATA_(ONLINE|NAME|BORN|SIM_(POS|STATUS|RATING)|PAYINFO)|PAYMENT_INFO_(ON_FILE|USED)|REMOTE_DATA_(CHANNEL|REQUEST|REPLY)|PSYS_(PART_(BF_(ZERO|ONE(_MINUS_(DEST_COLOR|SOURCE_(ALPHA|COLOR)))?|DEST_COLOR|SOURCE_(ALPHA|COLOR))|BLEND_FUNC_(DEST|SOURCE)|FLAGS|(START|END)_(COLOR|ALPHA|SCALE|GLOW)|MAX_AGE|(RIBBON|WIND|INTERP_(COLOR|SCALE)|BOUNCE|FOLLOW_(SRC|VELOCITY)|TARGET_(POS|LINEAR)|EMISSIVE)_MASK)|SRC_(MAX_AGE|PATTERN|ANGLE_(BEGIN|END)|BURST_(RATE|PART_COUNT|RADIUS|SPEED_(MIN|MAX))|ACCEL|TEXTURE|TARGET_KEY|OMEGA|PATTERN_(DROP|EXPLODE|ANGLE(_CONE(_EMPTY)?)?)))|VEHICLE_(REFERENCE_FRAME|TYPE_(NONE|SLED|CAR|BOAT|AIRPLANE|BALLOON)|(LINEAR|ANGULAR)_(FRICTION_TIMESCALE|MOTOR_DIRECTION)|LINEAR_MOTOR_OFFSET|HOVER_(HEIGHT|EFFICIENCY|TIMESCALE)|BUOYANCY|(LINEAR|ANGULAR)_(DEFLECTION_(EFFICIENCY|TIMESCALE)|MOTOR_(DECAY_)?TIMESCALE)|VERTICAL_ATTRACTION_(EFFICIENCY|TIMESCALE)|BANKING_(EFFICIENCY|MIX|TIMESCALE)|FLAG_(NO_DEFLECTION_UP|LIMIT_(ROLL_ONLY|MOTOR_UP)|HOVER_((WATER|TERRAIN|UP)_ONLY|GLOBAL_HEIGHT)|MOUSELOOK_(STEER|BANK)|CAMERA_DECOUPLED))|PRIM_(ALLOW_UNSIT|ALPHA_MODE(_(BLEND|EMISSIVE|MASK|NONE))?|NORMAL|SPECULAR|TYPE(_(BOX|CYLINDER|PRISM|SPHERE|TORUS|TUBE|RING|SCULPT))?|HOLE_(DEFAULT|CIRCLE|SQUARE|TRIANGLE)|MATERIAL(_(STONE|METAL|GLASS|WOOD|FLESH|PLASTIC|RUBBER))?|SHINY_(NONE|LOW|MEDIUM|HIGH)|BUMP_(NONE|BRIGHT|DARK|WOOD|BARK|BRICKS|CHECKER|CONCRETE|TILE|STONE|DISKS|GRAVEL|BLOBS|SIDING|LARGETILE|STUCCO|SUCTION|WEAVE)|TEXGEN_(DEFAULT|PLANAR)|SCRIPTED_SIT_ONLY|SCULPT_(TYPE_(SPHERE|TORUS|PLANE|CYLINDER|MASK)|FLAG_(MIRROR|INVERT))|PHYSICS(_(SHAPE_(CONVEX|NONE|PRIM|TYPE)))?|(POS|ROT)_LOCAL|SLICE|TEXT|FLEXIBLE|POINT_LIGHT|TEMP_ON_REZ|PHANTOM|POSITION|SIT_TARGET|SIZE|ROTATION|TEXTURE|NAME|OMEGA|DESC|LINK_TARGET|COLOR|BUMP_SHINY|FULLBRIGHT|TEXGEN|GLOW|MEDIA_(ALT_IMAGE_ENABLE|CONTROLS|(CURRENT|HOME)_URL|AUTO_(LOOP|PLAY|SCALE|ZOOM)|FIRST_CLICK_INTERACT|(WIDTH|HEIGHT)_PIXELS|WHITELIST(_ENABLE)?|PERMS_(INTERACT|CONTROL)|PARAM_MAX|CONTROLS_(STANDARD|MINI)|PERM_(NONE|OWNER|GROUP|ANYONE)|MAX_(URL_LENGTH|WHITELIST_(SIZE|COUNT)|(WIDTH|HEIGHT)_PIXELS)))|MASK_(BASE|OWNER|GROUP|EVERYONE|NEXT)|PERM_(TRANSFER|MODIFY|COPY|MOVE|ALL)|PARCEL_(MEDIA_COMMAND_(STOP|PAUSE|PLAY|LOOP|TEXTURE|URL|TIME|AGENT|UNLOAD|AUTO_ALIGN|TYPE|SIZE|DESC|LOOP_SET)|FLAG_(ALLOW_(FLY|(GROUP_)?SCRIPTS|LANDMARK|TERRAFORM|DAMAGE|CREATE_(GROUP_)?OBJECTS)|USE_(ACCESS_(GROUP|LIST)|BAN_LIST|LAND_PASS_LIST)|LOCAL_SOUND_ONLY|RESTRICT_PUSHOBJECT|ALLOW_(GROUP|ALL)_OBJECT_ENTRY)|COUNT_(TOTAL|OWNER|GROUP|OTHER|SELECTED|TEMP)|DETAILS_(NAME|DESC|OWNER|GROUP|AREA|ID|SEE_AVATARS))|LIST_STAT_(MAX|MIN|MEAN|MEDIAN|STD_DEV|SUM(_SQUARES)?|NUM_COUNT|GEOMETRIC_MEAN|RANGE)|PAY_(HIDE|DEFAULT)|REGION_FLAG_(ALLOW_DAMAGE|FIXED_SUN|BLOCK_TERRAFORM|SANDBOX|DISABLE_(COLLISIONS|PHYSICS)|BLOCK_FLY|ALLOW_DIRECT_TELEPORT|RESTRICT_PUSHOBJECT)|HTTP_(METHOD|MIMETYPE|BODY_(MAXLENGTH|TRUNCATED)|CUSTOM_HEADER|PRAGMA_NO_CACHE|VERBOSE_THROTTLE|VERIFY_CERT)|SIT_(INVALID_(AGENT|LINK_OBJECT)|NO(T_EXPERIENCE|_(ACCESS|EXPERIENCE_PERMISSION|SIT_TARGET)))|STRING_(TRIM(_(HEAD|TAIL))?)|CLICK_ACTION_(NONE|TOUCH|SIT|BUY|PAY|OPEN(_MEDIA)?|PLAY|ZOOM)|TOUCH_INVALID_FACE|PROFILE_(NONE|SCRIPT_MEMORY)|RC_(DATA_FLAGS|DETECT_PHANTOM|GET_(LINK_NUM|NORMAL|ROOT_KEY)|MAX_HITS|REJECT_(TYPES|AGENTS|(NON)?PHYSICAL|LAND))|RCERR_(CAST_TIME_EXCEEDED|SIM_PERF_LOW|UNKNOWN)|ESTATE_ACCESS_(ALLOWED_(AGENT|GROUP)_(ADD|REMOVE)|BANNED_AGENT_(ADD|REMOVE))|DENSITY|FRICTION|RESTITUTION|GRAVITY_MULTIPLIER|KFM_(COMMAND|CMD_(PLAY|STOP|PAUSE)|MODE|FORWARD|LOOP|PING_PONG|REVERSE|DATA|ROTATION|TRANSLATION)|ERR_(GENERIC|PARCEL_PERMISSIONS|MALFORMED_PARAMS|RUNTIME_PERMISSIONS|THROTTLED)|CHARACTER_(CMD_((SMOOTH_)?STOP|JUMP)|DESIRED_(TURN_)?SPEED|RADIUS|STAY_WITHIN_PARCEL|LENGTH|ORIENTATION|ACCOUNT_FOR_SKIPPED_FRAMES|AVOIDANCE_MODE|TYPE(_([ABCD]|NONE))?|MAX_(DECEL|TURN_RADIUS|(ACCEL|SPEED)))|PURSUIT_(OFFSET|FUZZ_FACTOR|GOAL_TOLERANCE|INTERCEPT)|REQUIRE_LINE_OF_SIGHT|FORCE_DIRECT_PATH|VERTICAL|HORIZONTAL|AVOID_(CHARACTERS|DYNAMIC_OBSTACLES|NONE)|PU_(EVADE_(HIDDEN|SPOTTED)|FAILURE_(DYNAMIC_PATHFINDING_DISABLED|INVALID_(GOAL|START)|NO_(NAVMESH|VALID_DESTINATION)|OTHER|TARGET_GONE|(PARCEL_)?UNREACHABLE)|(GOAL|SLOWDOWN_DISTANCE)_REACHED)|TRAVERSAL_TYPE(_(FAST|NONE|SLOW))?|CONTENT_TYPE_(ATOM|FORM|HTML|JSON|LLSD|RSS|TEXT|XHTML|XML)|GCNP_(RADIUS|STATIC)|(PATROL|WANDER)_PAUSE_AT_WAYPOINTS|OPT_(AVATAR|CHARACTER|EXCLUSION_VOLUME|LEGACY_LINKSET|MATERIAL_VOLUME|OTHER|STATIC_OBSTACLE|WALKABLE)|SIM_STAT_PCT_CHARS_STEPPED)\\b' },
{ begin: '\\b(FALSE|TRUE)\\b' },
{ begin: '\\b(ZERO_ROTATION)\\b' },
{ begin: '\\b(EOF|JSON_(ARRAY|DELETE|FALSE|INVALID|NULL|NUMBER|OBJECT|STRING|TRUE)|NULL_KEY|TEXTURE_(BLANK|DEFAULT|MEDIA|PLYWOOD|TRANSPARENT)|URL_REQUEST_(GRANTED|DENIED))\\b' },
{ begin: '\\b(ZERO_VECTOR|TOUCH_INVALID_(TEXCOORD|VECTOR))\\b' }
]
};
const LSL_FUNCTIONS = {
className: 'built_in',
begin: '\\b(ll(AgentInExperience|(Create|DataSize|Delete|KeyCount|Keys|Read|Update)KeyValue|GetExperience(Details|ErrorMessage)|ReturnObjectsBy(ID|Owner)|Json(2List|[GS]etValue|ValueType)|Sin|Cos|Tan|Atan2|Sqrt|Pow|Abs|Fabs|Frand|Floor|Ceil|Round|Vec(Mag|Norm|Dist)|Rot(Between|2(Euler|Fwd|Left|Up))|(Euler|Axes)2Rot|Whisper|(Region|Owner)?Say|Shout|Listen(Control|Remove)?|Sensor(Repeat|Remove)?|Detected(Name|Key|Owner|Type|Pos|Vel|Grab|Rot|Group|LinkNumber)|Die|Ground|Wind|([GS]et)(AnimationOverride|MemoryLimit|PrimMediaParams|ParcelMusicURL|Object(Desc|Name)|PhysicsMaterial|Status|Scale|Color|Alpha|Texture|Pos|Rot|Force|Torque)|ResetAnimationOverride|(Scale|Offset|Rotate)Texture|(Rot)?Target(Remove)?|(Stop)?MoveToTarget|Apply(Rotational)?Impulse|Set(KeyframedMotion|ContentType|RegionPos|(Angular)?Velocity|Buoyancy|HoverHeight|ForceAndTorque|TimerEvent|ScriptState|Damage|TextureAnim|Sound(Queueing|Radius)|Vehicle(Type|(Float|Vector|Rotation)Param)|(Touch|Sit)?Text|Camera(Eye|At)Offset|PrimitiveParams|ClickAction|Link(Alpha|Color|PrimitiveParams(Fast)?|Texture(Anim)?|Camera|Media)|RemoteScriptAccessPin|PayPrice|LocalRot)|ScaleByFactor|Get((Max|Min)ScaleFactor|ClosestNavPoint|StaticPath|SimStats|Env|PrimitiveParams|Link(PrimitiveParams|Number(OfSides)?|Key|Name|Media)|HTTPHeader|FreeURLs|Object(Details|PermMask|PrimCount)|Parcel(MaxPrims|Details|Prim(Count|Owners))|Attached(List)?|(SPMax|Free|Used)Memory|Region(Name|TimeDilation|FPS|Corner|AgentCount)|Root(Position|Rotation)|UnixTime|(Parcel|Region)Flags|(Wall|GMT)clock|SimulatorHostname|BoundingBox|GeometricCenter|Creator|NumberOf(Prims|NotecardLines|Sides)|Animation(List)?|(Camera|Local)(Pos|Rot)|Vel|Accel|Omega|Time(stamp|OfDay)|(Object|CenterOf)?Mass|MassMKS|Energy|Owner|(Owner)?Key|SunDirection|Texture(Offset|Scale|Rot)|Inventory(Number|Name|Key|Type|Creator|PermMask)|Permissions(Key)?|StartParameter|List(Length|EntryType)|Date|Agent(Size|Info|Language|List)|LandOwnerAt|NotecardLine|Script(Name|State))|(Get|Reset|GetAndReset)Time|PlaySound(Slave)?|LoopSound(Master|Slave)?|(Trigger|Stop|Preload)Sound|((Get|Delete)Sub|Insert)String|To(Upper|Lower)|Give(InventoryList|Money)|RezObject|(Stop)?LookAt|Sleep|CollisionFilter|(Take|Release)Controls|DetachFromAvatar|AttachToAvatar(Temp)?|InstantMessage|(GetNext)?Email|StopHover|MinEventDelay|RotLookAt|String(Length|Trim)|(Start|Stop)Animation|TargetOmega|Request(Experience)?Permissions|(Create|Break)Link|BreakAllLinks|(Give|Remove)Inventory|Water|PassTouches|Request(Agent|Inventory)Data|TeleportAgent(Home|GlobalCoords)?|ModifyLand|CollisionSound|ResetScript|MessageLinked|PushObject|PassCollisions|AxisAngle2Rot|Rot2(Axis|Angle)|A(cos|sin)|AngleBetween|AllowInventoryDrop|SubStringIndex|List2(CSV|Integer|Json|Float|String|Key|Vector|Rot|List(Strided)?)|DeleteSubList|List(Statistics|Sort|Randomize|(Insert|Find|Replace)List)|EdgeOfWorld|AdjustSoundVolume|Key2Name|TriggerSoundLimited|EjectFromLand|(CSV|ParseString)2List|OverMyLand|SameGroup|UnSit|Ground(Slope|Normal|Contour)|GroundRepel|(Set|Remove)VehicleFlags|SitOnLink|(AvatarOn)?(Link)?SitTarget|Script(Danger|Profiler)|Dialog|VolumeDetect|ResetOtherScript|RemoteLoadScriptPin|(Open|Close)RemoteDataChannel|SendRemoteData|RemoteDataReply|(Integer|String)ToBase64|XorBase64|Log(10)?|Base64To(String|Integer)|ParseStringKeepNulls|RezAtRoot|RequestSimulatorData|ForceMouselook|(Load|Release|(E|Une)scape)URL|ParcelMedia(CommandList|Query)|ModPow|MapDestination|(RemoveFrom|AddTo|Reset)Land(Pass|Ban)List|(Set|Clear)CameraParams|HTTP(Request|Response)|TextBox|DetectedTouch(UV|Face|Pos|(N|Bin)ormal|ST)|(MD5|SHA1|DumpList2)String|Request(Secure)?URL|Clear(Prim|Link)Media|(Link)?ParticleSystem|(Get|Request)(Username|DisplayName)|RegionSayTo|CastRay|GenerateKey|TransferLindenDollars|ManageEstateAccess|(Create|Delete)Character|ExecCharacterCmd|Evade|FleeFrom|NavigateTo|PatrolPoints|Pursue|UpdateCharacter|WanderWithin))\\b'
};
return {
name: 'LSL (Linden Scripting Language)',
illegal: ':',
contains: [
LSL_STRINGS,
{
className: 'comment',
variants: [
hljs.COMMENT('//', '$'),
hljs.COMMENT('/\\*', '\\*/')
],
relevance: 0
},
LSL_NUMBERS,
{
className: 'section',
variants: [
{ begin: '\\b(state|default)\\b' },
{ begin: '\\b(state_(entry|exit)|touch(_(start|end))?|(land_)?collision(_(start|end))?|timer|listen|(no_)?sensor|control|(not_)?at_(rot_)?target|money|email|experience_permissions(_denied)?|run_time_permissions|changed|attach|dataserver|moving_(start|end)|link_message|(on|object)_rez|remote_data|http_re(sponse|quest)|path_update|transaction_result)\\b' }
]
},
LSL_FUNCTIONS,
LSL_CONSTANTS,
{
className: 'type',
begin: '\\b(integer|float|string|key|vector|quaternion|rotation|list)\\b'
}
]
};
}
var lsl_1 = lsl;
/*
Language: Lua
Description: Lua is a powerful, efficient, lightweight, embeddable scripting language.
Author: Andrew Fedorov <dmmdrs@mail.ru>
Category: common, scripting
Website: https://www.lua.org
*/
function lua(hljs) {
const OPENING_LONG_BRACKET = '\\[=*\\[';
const CLOSING_LONG_BRACKET = '\\]=*\\]';
const LONG_BRACKETS = {
begin: OPENING_LONG_BRACKET,
end: CLOSING_LONG_BRACKET,
contains: [ 'self' ]
};
const COMMENTS = [
hljs.COMMENT('--(?!' + OPENING_LONG_BRACKET + ')', '$'),
hljs.COMMENT(
'--' + OPENING_LONG_BRACKET,
CLOSING_LONG_BRACKET,
{
contains: [ LONG_BRACKETS ],
relevance: 10
}
)
];
return {
name: 'Lua',
keywords: {
$pattern: hljs.UNDERSCORE_IDENT_RE,
literal: "true false nil",
keyword: "and break do else elseif end for goto if in local not or repeat return then until while",
built_in:
// Metatags and globals:
'_G _ENV _VERSION __index __newindex __mode __call __metatable __tostring __len '
+ '__gc __add __sub __mul __div __mod __pow __concat __unm __eq __lt __le assert '
// Standard methods and properties:
+ 'collectgarbage dofile error getfenv getmetatable ipairs load loadfile loadstring '
+ 'module next pairs pcall print rawequal rawget rawset require select setfenv '
+ 'setmetatable tonumber tostring type unpack xpcall arg self '
// Library methods and properties (one line per library):
+ 'coroutine resume yield status wrap create running debug getupvalue '
+ 'debug sethook getmetatable gethook setmetatable setlocal traceback setfenv getinfo setupvalue getlocal getregistry getfenv '
+ 'io lines write close flush open output type read stderr stdin input stdout popen tmpfile '
+ 'math log max acos huge ldexp pi cos tanh pow deg tan cosh sinh random randomseed frexp ceil floor rad abs sqrt modf asin min mod fmod log10 atan2 exp sin atan '
+ 'os exit setlocale date getenv difftime remove time clock tmpname rename execute package preload loadlib loaded loaders cpath config path seeall '
+ 'string sub upper len gfind rep find match char dump gmatch reverse byte format gsub lower '
+ 'table setn insert getn foreachi maxn foreach concat sort remove'
},
contains: COMMENTS.concat([
{
className: 'function',
beginKeywords: 'function',
end: '\\)',
contains: [
hljs.inherit(hljs.TITLE_MODE, { begin: '([_a-zA-Z]\\w*\\.)*([_a-zA-Z]\\w*:)?[_a-zA-Z]\\w*' }),
{
className: 'params',
begin: '\\(',
endsWithParent: true,
contains: COMMENTS
}
].concat(COMMENTS)
},
hljs.C_NUMBER_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: OPENING_LONG_BRACKET,
end: CLOSING_LONG_BRACKET,
contains: [ LONG_BRACKETS ],
relevance: 5
}
])
};
}
var lua_1 = lua;
/*
Language: Makefile
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Contributors: Joël Porquet <joel@porquet.org>
Website: https://www.gnu.org/software/make/manual/html_node/Introduction.html
Category: common
*/
function makefile(hljs) {
/* Variables: simple (eg $(var)) and special (eg $@) */
const VARIABLE = {
className: 'variable',
variants: [
{
begin: '\\$\\(' + hljs.UNDERSCORE_IDENT_RE + '\\)',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{ begin: /\$[@%<?\^\+\*]/ }
]
};
/* Quoted string with variables inside */
const QUOTE_STRING = {
className: 'string',
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
VARIABLE
]
};
/* Function: $(func arg,...) */
const FUNC = {
className: 'variable',
begin: /\$\([\w-]+\s/,
end: /\)/,
keywords: { built_in:
'subst patsubst strip findstring filter filter-out sort '
+ 'word wordlist firstword lastword dir notdir suffix basename '
+ 'addsuffix addprefix join wildcard realpath abspath error warning '
+ 'shell origin flavor foreach if or and call eval file value' },
contains: [ VARIABLE ]
};
/* Variable assignment */
const ASSIGNMENT = { begin: '^' + hljs.UNDERSCORE_IDENT_RE + '\\s*(?=[:+?]?=)' };
/* Meta targets (.PHONY) */
const META = {
className: 'meta',
begin: /^\.PHONY:/,
end: /$/,
keywords: {
$pattern: /[\.\w]+/,
keyword: '.PHONY'
}
};
/* Targets */
const TARGET = {
className: 'section',
begin: /^[^\s]+:/,
end: /$/,
contains: [ VARIABLE ]
};
return {
name: 'Makefile',
aliases: [
'mk',
'mak',
'make',
],
keywords: {
$pattern: /[\w-]+/,
keyword: 'define endef undefine ifdef ifndef ifeq ifneq else endif '
+ 'include -include sinclude override export unexport private vpath'
},
contains: [
hljs.HASH_COMMENT_MODE,
VARIABLE,
QUOTE_STRING,
FUNC,
ASSIGNMENT,
META,
TARGET
]
};
}
var makefile_1 = makefile;
const SYSTEM_SYMBOLS = [
"AASTriangle",
"AbelianGroup",
"Abort",
"AbortKernels",
"AbortProtect",
"AbortScheduledTask",
"Above",
"Abs",
"AbsArg",
"AbsArgPlot",
"Absolute",
"AbsoluteCorrelation",
"AbsoluteCorrelationFunction",
"AbsoluteCurrentValue",
"AbsoluteDashing",
"AbsoluteFileName",
"AbsoluteOptions",
"AbsolutePointSize",
"AbsoluteThickness",
"AbsoluteTime",
"AbsoluteTiming",
"AcceptanceThreshold",
"AccountingForm",
"Accumulate",
"Accuracy",
"AccuracyGoal",
"AcousticAbsorbingValue",
"AcousticImpedanceValue",
"AcousticNormalVelocityValue",
"AcousticPDEComponent",
"AcousticPressureCondition",
"AcousticRadiationValue",
"AcousticSoundHardValue",
"AcousticSoundSoftCondition",
"ActionDelay",
"ActionMenu",
"ActionMenuBox",
"ActionMenuBoxOptions",
"Activate",
"Active",
"ActiveClassification",
"ActiveClassificationObject",
"ActiveItem",
"ActivePrediction",
"ActivePredictionObject",
"ActiveStyle",
"AcyclicGraphQ",
"AddOnHelpPath",
"AddSides",
"AddTo",
"AddToSearchIndex",
"AddUsers",
"AdjacencyGraph",
"AdjacencyList",
"AdjacencyMatrix",
"AdjacentMeshCells",
"Adjugate",
"AdjustmentBox",
"AdjustmentBoxOptions",
"AdjustTimeSeriesForecast",
"AdministrativeDivisionData",
"AffineHalfSpace",
"AffineSpace",
"AffineStateSpaceModel",
"AffineTransform",
"After",
"AggregatedEntityClass",
"AggregationLayer",
"AircraftData",
"AirportData",
"AirPressureData",
"AirSoundAttenuation",
"AirTemperatureData",
"AiryAi",
"AiryAiPrime",
"AiryAiZero",
"AiryBi",
"AiryBiPrime",
"AiryBiZero",
"AlgebraicIntegerQ",
"AlgebraicNumber",
"AlgebraicNumberDenominator",
"AlgebraicNumberNorm",
"AlgebraicNumberPolynomial",
"AlgebraicNumberTrace",
"AlgebraicRules",
"AlgebraicRulesData",
"Algebraics",
"AlgebraicUnitQ",
"Alignment",
"AlignmentMarker",
"AlignmentPoint",
"All",
"AllowAdultContent",
"AllowChatServices",
"AllowedCloudExtraParameters",
"AllowedCloudParameterExtensions",
"AllowedDimensions",
"AllowedFrequencyRange",
"AllowedHeads",
"AllowGroupClose",
"AllowIncomplete",
"AllowInlineCells",
"AllowKernelInitialization",
"AllowLooseGrammar",
"AllowReverseGroupClose",
"AllowScriptLevelChange",
"AllowVersionUpdate",
"AllTrue",
"Alphabet",
"AlphabeticOrder",
"AlphabeticSort",
"AlphaChannel",
"AlternateImage",
"AlternatingFactorial",
"AlternatingGroup",
"AlternativeHypothesis",
"Alternatives",
"AltitudeMethod",
"AmbientLight",
"AmbiguityFunction",
"AmbiguityList",
"Analytic",
"AnatomyData",
"AnatomyForm",
"AnatomyPlot3D",
"AnatomySkinStyle",
"AnatomyStyling",
"AnchoredSearch",
"And",
"AndersonDarlingTest",
"AngerJ",
"AngleBisector",
"AngleBracket",
"AnglePath",
"AnglePath3D",
"AngleVector",
"AngularGauge",
"Animate",
"AnimatedImage",
"AnimationCycleOffset",
"AnimationCycleRepetitions",
"AnimationDirection",
"AnimationDisplayTime",
"AnimationRate",
"AnimationRepetitions",
"AnimationRunning",
"AnimationRunTime",
"AnimationTimeIndex",
"AnimationVideo",
"Animator",
"AnimatorBox",
"AnimatorBoxOptions",
"AnimatorElements",
"Annotate",
"Annotation",
"AnnotationDelete",
"AnnotationKeys",
"AnnotationRules",
"AnnotationValue",
"Annuity",
"AnnuityDue",
"Annulus",
"AnomalyDetection",
"AnomalyDetector",
"AnomalyDetectorFunction",
"Anonymous",
"Antialiasing",
"Antihermitian",
"AntihermitianMatrixQ",
"Antisymmetric",
"AntisymmetricMatrixQ",
"Antonyms",
"AnyOrder",
"AnySubset",
"AnyTrue",
"Apart",
"ApartSquareFree",
"APIFunction",
"Appearance",
"AppearanceElements",
"AppearanceRules",
"AppellF1",
"Append",
"AppendCheck",
"AppendLayer",
"AppendTo",
"Application",
"Apply",
"ApplyReaction",
"ApplySides",
"ApplyTo",
"ArcCos",
"ArcCosh",
"ArcCot",
"ArcCoth",
"ArcCsc",
"ArcCsch",
"ArcCurvature",
"ARCHProcess",
"ArcLength",
"ArcSec",
"ArcSech",
"ArcSin",
"ArcSinDistribution",
"ArcSinh",
"ArcTan",
"ArcTanh",
"Area",
"Arg",
"ArgMax",
"ArgMin",
"ArgumentCountQ",
"ArgumentsOptions",
"ARIMAProcess",
"ArithmeticGeometricMean",
"ARMAProcess",
"Around",
"AroundReplace",
"ARProcess",
"Array",
"ArrayComponents",
"ArrayDepth",
"ArrayFilter",
"ArrayFlatten",
"ArrayMesh",
"ArrayPad",
"ArrayPlot",
"ArrayPlot3D",
"ArrayQ",
"ArrayReduce",
"ArrayResample",
"ArrayReshape",
"ArrayRules",
"Arrays",
"Arrow",
"Arrow3DBox",
"ArrowBox",
"Arrowheads",
"ASATriangle",
"Ask",
"AskAppend",
"AskConfirm",
"AskDisplay",
"AskedQ",
"AskedValue",
"AskFunction",
"AskState",
"AskTemplateDisplay",
"AspectRatio",
"AspectRatioFixed",
"Assert",
"AssessmentFunction",
"AssessmentResultObject",
"AssociateTo",
"Association",
"AssociationFormat",
"AssociationMap",
"AssociationQ",
"AssociationThread",
"AssumeDeterministic",
"Assuming",
"Assumptions",
"AstroAngularSeparation",
"AstroBackground",
"AstroCenter",
"AstroDistance",
"AstroGraphics",
"AstroGridLines",
"AstroGridLinesStyle",
"AstronomicalData",
"AstroPosition",
"AstroProjection",
"AstroRange",
"AstroRangePadding",
"AstroReferenceFrame",
"AstroStyling",
"AstroZoomLevel",
"Asymptotic",
"AsymptoticDSolveValue",
"AsymptoticEqual",
"AsymptoticEquivalent",
"AsymptoticExpectation",
"AsymptoticGreater",
"AsymptoticGreaterEqual",
"AsymptoticIntegrate",
"AsymptoticLess",
"AsymptoticLessEqual",
"AsymptoticOutputTracker",
"AsymptoticProbability",
"AsymptoticProduct",
"AsymptoticRSolveValue",
"AsymptoticSolve",
"AsymptoticSum",
"Asynchronous",
"AsynchronousTaskObject",
"AsynchronousTasks",
"Atom",
"AtomCoordinates",
"AtomCount",
"AtomDiagramCoordinates",
"AtomLabels",
"AtomLabelStyle",
"AtomList",
"AtomQ",
"AttachCell",
"AttachedCell",
"AttentionLayer",
"Attributes",
"Audio",
"AudioAmplify",
"AudioAnnotate",
"AudioAnnotationLookup",
"AudioBlockMap",
"AudioCapture",
"AudioChannelAssignment",
"AudioChannelCombine",
"AudioChannelMix",
"AudioChannels",
"AudioChannelSeparate",
"AudioData",
"AudioDelay",
"AudioDelete",
"AudioDevice",
"AudioDistance",
"AudioEncoding",
"AudioFade",
"AudioFrequencyShift",
"AudioGenerator",
"AudioIdentify",
"AudioInputDevice",
"AudioInsert",
"AudioInstanceQ",
"AudioIntervals",
"AudioJoin",
"AudioLabel",
"AudioLength",
"AudioLocalMeasurements",
"AudioLooping",
"AudioLoudness",
"AudioMeasurements",
"AudioNormalize",
"AudioOutputDevice",
"AudioOverlay",
"AudioPad",
"AudioPan",
"AudioPartition",
"AudioPause",
"AudioPitchShift",
"AudioPlay",
"AudioPlot",
"AudioQ",
"AudioRecord",
"AudioReplace",
"AudioResample",
"AudioReverb",
"AudioReverse",
"AudioSampleRate",
"AudioSpectralMap",
"AudioSpectralTransformation",
"AudioSplit",
"AudioStop",
"AudioStream",
"AudioStreams",
"AudioTimeStretch",
"AudioTrackApply",
"AudioTrackSelection",
"AudioTrim",
"AudioType",
"AugmentedPolyhedron",
"AugmentedSymmetricPolynomial",
"Authenticate",
"Authentication",
"AuthenticationDialog",
"AutoAction",
"Autocomplete",
"AutocompletionFunction",
"AutoCopy",
"AutocorrelationTest",
"AutoDelete",
"AutoEvaluateEvents",
"AutoGeneratedPackage",
"AutoIndent",
"AutoIndentSpacings",
"AutoItalicWords",
"AutoloadPath",
"AutoMatch",
"Automatic",
"AutomaticImageSize",
"AutoMultiplicationSymbol",
"AutoNumberFormatting",
"AutoOpenNotebooks",
"AutoOpenPalettes",
"AutoOperatorRenderings",
"AutoQuoteCharacters",
"AutoRefreshed",
"AutoRemove",
"AutorunSequencing",
"AutoScaling",
"AutoScroll",
"AutoSpacing",
"AutoStyleOptions",
"AutoStyleWords",
"AutoSubmitting",
"Axes",
"AxesEdge",
"AxesLabel",
"AxesOrigin",
"AxesStyle",
"AxiomaticTheory",
"Axis",
"Axis3DBox",
"Axis3DBoxOptions",
"AxisBox",
"AxisBoxOptions",
"AxisLabel",
"AxisObject",
"AxisStyle",
"BabyMonsterGroupB",
"Back",
"BackFaceColor",
"BackFaceGlowColor",
"BackFaceOpacity",
"BackFaceSpecularColor",
"BackFaceSpecularExponent",
"BackFaceSurfaceAppearance",
"BackFaceTexture",
"Background",
"BackgroundAppearance",
"BackgroundTasksSettings",
"Backslash",
"Backsubstitution",
"Backward",
"Ball",
"Band",
"BandpassFilter",
"BandstopFilter",
"BarabasiAlbertGraphDistribution",
"BarChart",
"BarChart3D",
"BarcodeImage",
"BarcodeRecognize",
"BaringhausHenzeTest",
"BarLegend",
"BarlowProschanImportance",
"BarnesG",
"BarOrigin",
"BarSpacing",
"BartlettHannWindow",
"BartlettWindow",
"BaseDecode",
"BaseEncode",
"BaseForm",
"Baseline",
"BaselinePosition",
"BaseStyle",
"BasicRecurrentLayer",
"BatchNormalizationLayer",
"BatchSize",
"BatesDistribution",
"BattleLemarieWavelet",
"BayesianMaximization",
"BayesianMaximizationObject",
"BayesianMinimization",
"BayesianMinimizationObject",
"Because",
"BeckmannDistribution",
"Beep",
"Before",
"Begin",
"BeginDialogPacket",
"BeginPackage",
"BellB",
"BellY",
"Below",
"BenfordDistribution",
"BeniniDistribution",
"BenktanderGibratDistribution",
"BenktanderWeibullDistribution",
"BernoulliB",
"BernoulliDistribution",
"BernoulliGraphDistribution",
"BernoulliProcess",
"BernsteinBasis",
"BesagL",
"BesselFilterModel",
"BesselI",
"BesselJ",
"BesselJZero",
"BesselK",
"BesselY",
"BesselYZero",
"Beta",
"BetaBinomialDistribution",
"BetaDistribution",
"BetaNegativeBinomialDistribution",
"BetaPrimeDistribution",
"BetaRegularized",
"Between",
"BetweennessCentrality",
"Beveled",
"BeveledPolyhedron",
"BezierCurve",
"BezierCurve3DBox",
"BezierCurve3DBoxOptions",
"BezierCurveBox",
"BezierCurveBoxOptions",
"BezierFunction",
"BilateralFilter",
"BilateralLaplaceTransform",
"BilateralZTransform",
"Binarize",
"BinaryDeserialize",
"BinaryDistance",
"BinaryFormat",
"BinaryImageQ",
"BinaryRead",
"BinaryReadList",
"BinarySerialize",
"BinaryWrite",
"BinCounts",
"BinLists",
"BinnedVariogramList",
"Binomial",
"BinomialDistribution",
"BinomialPointProcess",
"BinomialProcess",
"BinormalDistribution",
"BiorthogonalSplineWavelet",
"BioSequence",
"BioSequenceBackTranslateList",
"BioSequenceComplement",
"BioSequenceInstances",
"BioSequenceModify",
"BioSequencePlot",
"BioSequenceQ",
"BioSequenceReverseComplement",
"BioSequenceTranscribe",
"BioSequenceTranslate",
"BipartiteGraphQ",
"BiquadraticFilterModel",
"BirnbaumImportance",
"BirnbaumSaundersDistribution",
"BitAnd",
"BitClear",
"BitGet",
"BitLength",
"BitNot",
"BitOr",
"BitRate",
"BitSet",
"BitShiftLeft",
"BitShiftRight",
"BitXor",
"BiweightLocation",
"BiweightMidvariance",
"Black",
"BlackmanHarrisWindow",
"BlackmanNuttallWindow",
"BlackmanWindow",
"Blank",
"BlankForm",
"BlankNullSequence",
"BlankSequence",
"Blend",
"Block",
"BlockchainAddressData",
"BlockchainBase",
"BlockchainBlockData",
"BlockchainContractValue",
"BlockchainData",
"BlockchainGet",
"BlockchainKeyEncode",
"BlockchainPut",
"BlockchainTokenData",
"BlockchainTransaction",
"BlockchainTransactionData",
"BlockchainTransactionSign",
"BlockchainTransactionSubmit",
"BlockDiagonalMatrix",
"BlockLowerTriangularMatrix",
"BlockMap",
"BlockRandom",
"BlockUpperTriangularMatrix",
"BlomqvistBeta",
"BlomqvistBetaTest",
"Blue",
"Blur",
"Blurring",
"BodePlot",
"BohmanWindow",
"Bold",
"Bond",
"BondCount",
"BondLabels",
"BondLabelStyle",
"BondList",
"BondQ",
"Bookmarks",
"Boole",
"BooleanConsecutiveFunction",
"BooleanConvert",
"BooleanCountingFunction",
"BooleanFunction",
"BooleanGraph",
"BooleanMaxterms",
"BooleanMinimize",
"BooleanMinterms",
"BooleanQ",
"BooleanRegion",
"Booleans",
"BooleanStrings",
"BooleanTable",
"BooleanVariables",
"BorderDimensions",
"BorelTannerDistribution",
"Bottom",
"BottomHatTransform",
"BoundaryDiscretizeGraphics",
"BoundaryDiscretizeRegion",
"BoundaryMesh",
"BoundaryMeshRegion",
"BoundaryMeshRegionQ",
"BoundaryStyle",
"BoundedRegionQ",
"BoundingRegion",
"Bounds",
"Box",
"BoxBaselineShift",
"BoxData",
"BoxDimensions",
"Boxed",
"Boxes",
"BoxForm",
"BoxFormFormatTypes",
"BoxFrame",
"BoxID",
"BoxMargins",
"BoxMatrix",
"BoxObject",
"BoxRatios",
"BoxRotation",
"BoxRotationPoint",
"BoxStyle",
"BoxWhiskerChart",
"Bra",
"BracketingBar",
"BraKet",
"BrayCurtisDistance",
"BreadthFirstScan",
"Break",
"BridgeData",
"BrightnessEqualize",
"BroadcastStationData",
"Brown",
"BrownForsytheTest",
"BrownianBridgeProcess",
"BrowserCategory",
"BSplineBasis",
"BSplineCurve",
"BSplineCurve3DBox",
"BSplineCurve3DBoxOptions",
"BSplineCurveBox",
"BSplineCurveBoxOptions",
"BSplineFunction",
"BSplineSurface",
"BSplineSurface3DBox",
"BSplineSurface3DBoxOptions",
"BubbleChart",
"BubbleChart3D",
"BubbleScale",
"BubbleSizes",
"BuckyballGraph",
"BuildCompiledComponent",
"BuildingData",
"BulletGauge",
"BusinessDayQ",
"ButterflyGraph",
"ButterworthFilterModel",
"Button",
"ButtonBar",
"ButtonBox",
"ButtonBoxOptions",
"ButtonCell",
"ButtonContents",
"ButtonData",
"ButtonEvaluator",
"ButtonExpandable",
"ButtonFrame",
"ButtonFunction",
"ButtonMargins",
"ButtonMinHeight",
"ButtonNote",
"ButtonNotebook",
"ButtonSource",
"ButtonStyle",
"ButtonStyleMenuListing",
"Byte",
"ByteArray",
"ByteArrayFormat",
"ByteArrayFormatQ",
"ByteArrayQ",
"ByteArrayToString",
"ByteCount",
"ByteOrdering",
"C",
"CachedValue",
"CacheGraphics",
"CachePersistence",
"CalendarConvert",
"CalendarData",
"CalendarType",
"Callout",
"CalloutMarker",
"CalloutStyle",
"CallPacket",
"CanberraDistance",
"Cancel",
"CancelButton",
"CandlestickChart",
"CanonicalGraph",
"CanonicalizePolygon",
"CanonicalizePolyhedron",
"CanonicalizeRegion",
"CanonicalName",
"CanonicalWarpingCorrespondence",
"CanonicalWarpingDistance",
"CantorMesh",
"CantorStaircase",
"Canvas",
"Cap",
"CapForm",
"CapitalDifferentialD",
"Capitalize",
"CapsuleShape",
"CaptureRunning",
"CaputoD",
"CardinalBSplineBasis",
"CarlemanLinearize",
"CarlsonRC",
"CarlsonRD",
"CarlsonRE",
"CarlsonRF",
"CarlsonRG",
"CarlsonRJ",
"CarlsonRK",
"CarlsonRM",
"CarmichaelLambda",
"CaseOrdering",
"Cases",
"CaseSensitive",
"Cashflow",
"Casoratian",
"Cast",
"Catalan",
"CatalanNumber",
"Catch",
"CategoricalDistribution",
"Catenate",
"CatenateLayer",
"CauchyDistribution",
"CauchyMatrix",
"CauchyPointProcess",
"CauchyWindow",
"CayleyGraph",
"CDF",
"CDFDeploy",
"CDFInformation",
"CDFWavelet",
"Ceiling",
"CelestialSystem",
"Cell",
"CellAutoOverwrite",
"CellBaseline",
"CellBoundingBox",
"CellBracketOptions",
"CellChangeTimes",
"CellContents",
"CellContext",
"CellDingbat",
"CellDingbatMargin",
"CellDynamicExpression",
"CellEditDuplicate",
"CellElementsBoundingBox",
"CellElementSpacings",
"CellEpilog",
"CellEvaluationDuplicate",
"CellEvaluationFunction",
"CellEvaluationLanguage",
"CellEventActions",
"CellFrame",
"CellFrameColor",
"CellFrameLabelMargins",
"CellFrameLabels",
"CellFrameMargins",
"CellFrameStyle",
"CellGroup",
"CellGroupData",
"CellGrouping",
"CellGroupingRules",
"CellHorizontalScrolling",
"CellID",
"CellInsertionPointCell",
"CellLabel",
"CellLabelAutoDelete",
"CellLabelMargins",
"CellLabelPositioning",
"CellLabelStyle",
"CellLabelTemplate",
"CellMargins",
"CellObject",
"CellOpen",
"CellPrint",
"CellProlog",
"Cells",
"CellSize",
"CellStyle",
"CellTags",
"CellTrayPosition",
"CellTrayWidgets",
"CellularAutomaton",
"CensoredDistribution",
"Censoring",
"Center",
"CenterArray",
"CenterDot",
"CenteredInterval",
"CentralFeature",
"CentralMoment",
"CentralMomentGeneratingFunction",
"Cepstrogram",
"CepstrogramArray",
"CepstrumArray",
"CForm",
"ChampernowneNumber",
"ChangeOptions",
"ChannelBase",
"ChannelBrokerAction",
"ChannelDatabin",
"ChannelHistoryLength",
"ChannelListen",
"ChannelListener",
"ChannelListeners",
"ChannelListenerWait",
"ChannelObject",
"ChannelPreSendFunction",
"ChannelReceiverFunction",
"ChannelSend",
"ChannelSubscribers",
"ChanVeseBinarize",
"Character",
"CharacterCounts",
"CharacterEncoding",
"CharacterEncodingsPath",
"CharacteristicFunction",
"CharacteristicPolynomial",
"CharacterName",
"CharacterNormalize",
"CharacterRange",
"Characters",
"ChartBaseStyle",
"ChartElementData",
"ChartElementDataFunction",
"ChartElementFunction",
"ChartElements",
"ChartLabels",
"ChartLayout",
"ChartLegends",
"ChartStyle",
"Chebyshev1FilterModel",
"Chebyshev2FilterModel",
"ChebyshevDistance",
"ChebyshevT",
"ChebyshevU",
"Check",
"CheckAbort",
"CheckAll",
"CheckArguments",
"Checkbox",
"CheckboxBar",
"CheckboxBox",
"CheckboxBoxOptions",
"ChemicalConvert",
"ChemicalData",
"ChemicalFormula",
"ChemicalInstance",
"ChemicalReaction",
"ChessboardDistance",
"ChiDistribution",
"ChineseRemainder",
"ChiSquareDistribution",
"ChoiceButtons",
"ChoiceDialog",
"CholeskyDecomposition",
"Chop",
"ChromaticityPlot",
"ChromaticityPlot3D",
"ChromaticPolynomial",
"Circle",
"CircleBox",
"CircleDot",
"CircleMinus",
"CirclePlus",
"CirclePoints",
"CircleThrough",
"CircleTimes",
"CirculantGraph",
"CircularArcThrough",
"CircularOrthogonalMatrixDistribution",
"CircularQuaternionMatrixDistribution",
"CircularRealMatrixDistribution",
"CircularSymplecticMatrixDistribution",
"CircularUnitaryMatrixDistribution",
"Circumsphere",
"CityData",
"ClassifierFunction",
"ClassifierInformation",
"ClassifierMeasurements",
"ClassifierMeasurementsObject",
"Classify",
"ClassPriors",
"Clear",
"ClearAll",
"ClearAttributes",
"ClearCookies",
"ClearPermissions",
"ClearSystemCache",
"ClebschGordan",
"ClickPane",
"ClickToCopy",
"ClickToCopyEnabled",
"Clip",
"ClipboardNotebook",
"ClipFill",
"ClippingStyle",
"ClipPlanes",
"ClipPlanesStyle",
"ClipRange",
"Clock",
"ClockGauge",
"ClockwiseContourIntegral",
"Close",
"Closed",
"CloseKernels",
"ClosenessCentrality",
"Closing",
"ClosingAutoSave",
"ClosingEvent",
"CloudAccountData",
"CloudBase",
"CloudConnect",
"CloudConnections",
"CloudDeploy",
"CloudDirectory",
"CloudDisconnect",
"CloudEvaluate",
"CloudExport",
"CloudExpression",
"CloudExpressions",
"CloudFunction",
"CloudGet",
"CloudImport",
"CloudLoggingData",
"CloudObject",
"CloudObjectInformation",
"CloudObjectInformationData",
"CloudObjectNameFormat",
"CloudObjects",
"CloudObjectURLType",
"CloudPublish",
"CloudPut",
"CloudRenderingMethod",
"CloudSave",
"CloudShare",
"CloudSubmit",
"CloudSymbol",
"CloudUnshare",
"CloudUserID",
"ClusterClassify",
"ClusterDissimilarityFunction",
"ClusteringComponents",
"ClusteringMeasurements",
"ClusteringTree",
"CMYKColor",
"Coarse",
"CodeAssistOptions",
"Coefficient",
"CoefficientArrays",
"CoefficientDomain",
"CoefficientList",
"CoefficientRules",
"CoifletWavelet",
"Collect",
"CollinearPoints",
"Colon",
"ColonForm",
"ColorBalance",
"ColorCombine",
"ColorConvert",
"ColorCoverage",
"ColorData",
"ColorDataFunction",
"ColorDetect",
"ColorDistance",
"ColorFunction",
"ColorFunctionBinning",
"ColorFunctionScaling",
"Colorize",
"ColorNegate",
"ColorOutput",
"ColorProfileData",
"ColorQ",
"ColorQuantize",
"ColorReplace",
"ColorRules",
"ColorSelectorSettings",
"ColorSeparate",
"ColorSetter",
"ColorSetterBox",
"ColorSetterBoxOptions",
"ColorSlider",
"ColorsNear",
"ColorSpace",
"ColorToneMapping",
"Column",
"ColumnAlignments",
"ColumnBackgrounds",
"ColumnForm",
"ColumnLines",
"ColumnsEqual",
"ColumnSpacings",
"ColumnWidths",
"CombinatorB",
"CombinatorC",
"CombinatorI",
"CombinatorK",
"CombinatorS",
"CombinatorW",
"CombinatorY",
"CombinedEntityClass",
"CombinerFunction",
"CometData",
"CommonDefaultFormatTypes",
"Commonest",
"CommonestFilter",
"CommonName",
"CommonUnits",
"CommunityBoundaryStyle",
"CommunityGraphPlot",
"CommunityLabels",
"CommunityRegionStyle",
"CompanyData",
"CompatibleUnitQ",
"CompilationOptions",
"CompilationTarget",
"Compile",
"Compiled",
"CompiledCodeFunction",
"CompiledComponent",
"CompiledExpressionDeclaration",
"CompiledFunction",
"CompiledLayer",
"CompilerCallback",
"CompilerEnvironment",
"CompilerEnvironmentAppend",
"CompilerEnvironmentAppendTo",
"CompilerEnvironmentObject",
"CompilerOptions",
"Complement",
"ComplementedEntityClass",
"CompleteGraph",
"CompleteGraphQ",
"CompleteIntegral",
"CompleteKaryTree",
"CompletionsListPacket",
"Complex",
"ComplexArrayPlot",
"ComplexContourPlot",
"Complexes",
"ComplexExpand",
"ComplexInfinity",
"ComplexityFunction",
"ComplexListPlot",
"ComplexPlot",
"ComplexPlot3D",
"ComplexRegionPlot",
"ComplexStreamPlot",
"ComplexVectorPlot",
"ComponentMeasurements",
"ComponentwiseContextMenu",
"Compose",
"ComposeList",
"ComposeSeries",
"CompositeQ",
"Composition",
"CompoundElement",
"CompoundExpression",
"CompoundPoissonDistribution",
"CompoundPoissonProcess",
"CompoundRenewalProcess",
"Compress",
"CompressedData",
"CompressionLevel",
"ComputeUncertainty",
"ConcaveHullMesh",
"Condition",
"ConditionalExpression",
"Conditioned",
"Cone",
"ConeBox",
"ConfidenceLevel",
"ConfidenceRange",
"ConfidenceTransform",
"ConfigurationPath",
"Confirm",
"ConfirmAssert",
"ConfirmBy",
"ConfirmMatch",
"ConfirmQuiet",
"ConformationMethod",
"ConformAudio",
"ConformImages",
"Congruent",
"ConicGradientFilling",
"ConicHullRegion",
"ConicHullRegion3DBox",
"ConicHullRegion3DBoxOptions",
"ConicHullRegionBox",
"ConicHullRegionBoxOptions",
"ConicOptimization",
"Conjugate",
"ConjugateTranspose",
"Conjunction",
"Connect",
"ConnectedComponents",
"ConnectedGraphComponents",
"ConnectedGraphQ",
"ConnectedMeshComponents",
"ConnectedMoleculeComponents",
"ConnectedMoleculeQ",
"ConnectionSettings",
"ConnectLibraryCallbackFunction",
"ConnectSystemModelComponents",
"ConnectSystemModelController",
"ConnesWindow",
"ConoverTest",
"ConservativeConvectionPDETerm",
"ConsoleMessage",
"Constant",
"ConstantArray",
"ConstantArrayLayer",
"ConstantImage",
"ConstantPlusLayer",
"ConstantRegionQ",
"Constants",
"ConstantTimesLayer",
"ConstellationData",
"ConstrainedMax",
"ConstrainedMin",
"Construct",
"Containing",
"ContainsAll",
"ContainsAny",
"ContainsExactly",
"ContainsNone",
"ContainsOnly",
"ContentDetectorFunction",
"ContentFieldOptions",
"ContentLocationFunction",
"ContentObject",
"ContentPadding",
"ContentsBoundingBox",
"ContentSelectable",
"ContentSize",
"Context",
"ContextMenu",
"Contexts",
"ContextToFileName",
"Continuation",
"Continue",
"ContinuedFraction",
"ContinuedFractionK",
"ContinuousAction",
"ContinuousMarkovProcess",
"ContinuousTask",
"ContinuousTimeModelQ",
"ContinuousWaveletData",
"ContinuousWaveletTransform",
"ContourDetect",
"ContourGraphics",
"ContourIntegral",
"ContourLabels",
"ContourLines",
"ContourPlot",
"ContourPlot3D",
"Contours",
"ContourShading",
"ContourSmoothing",
"ContourStyle",
"ContraharmonicMean",
"ContrastiveLossLayer",
"Control",
"ControlActive",
"ControlAlignment",
"ControlGroupContentsBox",
"ControllabilityGramian",
"ControllabilityMatrix",
"ControllableDecomposition",
"ControllableModelQ",
"ControllerDuration",
"ControllerInformation",
"ControllerInformationData",
"ControllerLinking",
"ControllerManipulate",
"ControllerMethod",
"ControllerPath",
"ControllerState",
"ControlPlacement",
"ControlsRendering",
"ControlType",
"ConvectionPDETerm",
"Convergents",
"ConversionOptions",
"ConversionRules",
"ConvertToPostScript",
"ConvertToPostScriptPacket",
"ConvexHullMesh",
"ConvexHullRegion",
"ConvexOptimization",
"ConvexPolygonQ",
"ConvexPolyhedronQ",
"ConvexRegionQ",
"ConvolutionLayer",
"Convolve",
"ConwayGroupCo1",
"ConwayGroupCo2",
"ConwayGroupCo3",
"CookieFunction",
"Cookies",
"CoordinateBoundingBox",
"CoordinateBoundingBoxArray",
"CoordinateBounds",
"CoordinateBoundsArray",
"CoordinateChartData",
"CoordinatesToolOptions",
"CoordinateTransform",
"CoordinateTransformData",
"CoplanarPoints",
"CoprimeQ",
"Coproduct",
"CopulaDistribution",
"Copyable",
"CopyDatabin",
"CopyDirectory",
"CopyFile",
"CopyFunction",
"CopyTag",
"CopyToClipboard",
"CoreNilpotentDecomposition",
"CornerFilter",
"CornerNeighbors",
"Correlation",
"CorrelationDistance",
"CorrelationFunction",
"CorrelationTest",
"Cos",
"Cosh",
"CoshIntegral",
"CosineDistance",
"CosineWindow",
"CosIntegral",
"Cot",
"Coth",
"CoulombF",
"CoulombG",
"CoulombH1",
"CoulombH2",
"Count",
"CountDistinct",
"CountDistinctBy",
"CounterAssignments",
"CounterBox",
"CounterBoxOptions",
"CounterClockwiseContourIntegral",
"CounterEvaluator",
"CounterFunction",
"CounterIncrements",
"CounterStyle",
"CounterStyleMenuListing",
"CountRoots",
"CountryData",
"Counts",
"CountsBy",
"Covariance",
"CovarianceEstimatorFunction",
"CovarianceFunction",
"CoxianDistribution",
"CoxIngersollRossProcess",
"CoxModel",
"CoxModelFit",
"CramerVonMisesTest",
"CreateArchive",
"CreateCellID",
"CreateChannel",
"CreateCloudExpression",
"CreateCompilerEnvironment",
"CreateDatabin",
"CreateDataStructure",
"CreateDataSystemModel",
"CreateDialog",
"CreateDirectory",
"CreateDocument",
"CreateFile",
"CreateIntermediateDirectories",
"CreateLicenseEntitlement",
"CreateManagedLibraryExpression",
"CreateNotebook",
"CreatePacletArchive",
"CreatePalette",
"CreatePermissionsGroup",
"CreateScheduledTask",
"CreateSearchIndex",
"CreateSystemModel",
"CreateTemporary",
"CreateTypeInstance",
"CreateUUID",
"CreateWindow",
"CriterionFunction",
"CriticalityFailureImportance",
"CriticalitySuccessImportance",
"CriticalSection",
"Cross",
"CrossEntropyLossLayer",
"CrossingCount",
"CrossingDetect",
"CrossingPolygon",
"CrossMatrix",
"Csc",
"Csch",
"CSGRegion",
"CSGRegionQ",
"CSGRegionTree",
"CTCLossLayer",
"Cube",
"CubeRoot",
"Cubics",
"Cuboid",
"CuboidBox",
"CuboidBoxOptions",
"Cumulant",
"CumulantGeneratingFunction",
"CumulativeFeatureImpactPlot",
"Cup",
"CupCap",
"Curl",
"CurlyDoubleQuote",
"CurlyQuote",
"CurrencyConvert",
"CurrentDate",
"CurrentImage",
"CurrentNotebookImage",
"CurrentScreenImage",
"CurrentValue",
"Curry",
"CurryApplied",
"CurvatureFlowFilter",
"CurveClosed",
"Cyan",
"CycleGraph",
"CycleIndexPolynomial",
"Cycles",
"CyclicGroup",
"Cyclotomic",
"Cylinder",
"CylinderBox",
"CylinderBoxOptions",
"CylindricalDecomposition",
"CylindricalDecompositionFunction",
"D",
"DagumDistribution",
"DamData",
"DamerauLevenshteinDistance",
"DampingFactor",
"Darker",
"Dashed",
"Dashing",
"DatabaseConnect",
"DatabaseDisconnect",
"DatabaseReference",
"Databin",
"DatabinAdd",
"DatabinRemove",
"Databins",
"DatabinSubmit",
"DatabinUpload",
"DataCompression",
"DataDistribution",
"DataRange",
"DataReversed",
"Dataset",
"DatasetDisplayPanel",
"DatasetTheme",
"DataStructure",
"DataStructureQ",
"Date",
"DateBounds",
"Dated",
"DateDelimiters",
"DateDifference",
"DatedUnit",
"DateFormat",
"DateFunction",
"DateGranularity",
"DateHistogram",
"DateInterval",
"DateList",
"DateListLogPlot",
"DateListPlot",
"DateListStepPlot",
"DateObject",
"DateObjectQ",
"DateOverlapsQ",
"DatePattern",
"DatePlus",
"DateRange",
"DateReduction",
"DateScale",
"DateSelect",
"DateString",
"DateTicksFormat",
"DateValue",
"DateWithinQ",
"DaubechiesWavelet",
"DavisDistribution",
"DawsonF",
"DayCount",
"DayCountConvention",
"DayHemisphere",
"DaylightQ",
"DayMatchQ",
"DayName",
"DayNightTerminator",
"DayPlus",
"DayRange",
"DayRound",
"DeBruijnGraph",
"DeBruijnSequence",
"Debug",
"DebugTag",
"Decapitalize",
"Decimal",
"DecimalForm",
"DeclareCompiledComponent",
"DeclareKnownSymbols",
"DeclarePackage",
"Decompose",
"DeconvolutionLayer",
"Decrement",
"Decrypt",
"DecryptFile",
"DedekindEta",
"DeepSpaceProbeData",
"Default",
"Default2DTool",
"Default3DTool",
"DefaultAttachedCellStyle",
"DefaultAxesStyle",
"DefaultBaseStyle",
"DefaultBoxStyle",
"DefaultButton",
"DefaultColor",
"DefaultControlPlacement",
"DefaultDockedCellStyle",
"DefaultDuplicateCellStyle",
"DefaultDuration",
"DefaultElement",
"DefaultFaceGridsStyle",
"DefaultFieldHintStyle",
"DefaultFont",
"DefaultFontProperties",
"DefaultFormatType",
"DefaultFrameStyle",
"DefaultFrameTicksStyle",
"DefaultGridLinesStyle",
"DefaultInlineFormatType",
"DefaultInputFormatType",
"DefaultLabelStyle",
"DefaultMenuStyle",
"DefaultNaturalLanguage",
"DefaultNewCellStyle",
"DefaultNewInlineCellStyle",
"DefaultNotebook",
"DefaultOptions",
"DefaultOutputFormatType",
"DefaultPrintPrecision",
"DefaultStyle",
"DefaultStyleDefinitions",
"DefaultTextFormatType",
"DefaultTextInlineFormatType",
"DefaultTicksStyle",
"DefaultTooltipStyle",
"DefaultValue",
"DefaultValues",
"Defer",
"DefineExternal",
"DefineInputStreamMethod",
"DefineOutputStreamMethod",
"DefineResourceFunction",
"Definition",
"Degree",
"DegreeCentrality",
"DegreeGraphDistribution",
"DegreeLexicographic",
"DegreeReverseLexicographic",
"DEigensystem",
"DEigenvalues",
"Deinitialization",
"Del",
"DelaunayMesh",
"Delayed",
"Deletable",
"Delete",
"DeleteAdjacentDuplicates",
"DeleteAnomalies",
"DeleteBorderComponents",
"DeleteCases",
"DeleteChannel",
"DeleteCloudExpression",
"DeleteContents",
"DeleteDirectory",
"DeleteDuplicates",
"DeleteDuplicatesBy",
"DeleteElements",
"DeleteFile",
"DeleteMissing",
"DeleteObject",
"DeletePermissionsKey",
"DeleteSearchIndex",
"DeleteSmallComponents",
"DeleteStopwords",
"DeleteWithContents",
"DeletionWarning",
"DelimitedArray",
"DelimitedSequence",
"Delimiter",
"DelimiterAutoMatching",
"DelimiterFlashTime",
"DelimiterMatching",
"Delimiters",
"DeliveryFunction",
"Dendrogram",
"Denominator",
"DensityGraphics",
"DensityHistogram",
"DensityPlot",
"DensityPlot3D",
"DependentVariables",
"Deploy",
"Deployed",
"Depth",
"DepthFirstScan",
"Derivative",
"DerivativeFilter",
"DerivativePDETerm",
"DerivedKey",
"DescriptorStateSpace",
"DesignMatrix",
"DestroyAfterEvaluation",
"Det",
"DeviceClose",
"DeviceConfigure",
"DeviceExecute",
"DeviceExecuteAsynchronous",
"DeviceObject",
"DeviceOpen",
"DeviceOpenQ",
"DeviceRead",
"DeviceReadBuffer",
"DeviceReadLatest",
"DeviceReadList",
"DeviceReadTimeSeries",
"Devices",
"DeviceStreams",
"DeviceWrite",
"DeviceWriteBuffer",
"DGaussianWavelet",
"DiacriticalPositioning",
"Diagonal",
"DiagonalizableMatrixQ",
"DiagonalMatrix",
"DiagonalMatrixQ",
"Dialog",
"DialogIndent",
"DialogInput",
"DialogLevel",
"DialogNotebook",
"DialogProlog",
"DialogReturn",
"DialogSymbols",
"Diamond",
"DiamondMatrix",
"DiceDissimilarity",
"DictionaryLookup",
"DictionaryWordQ",
"DifferenceDelta",
"DifferenceOrder",
"DifferenceQuotient",
"DifferenceRoot",
"DifferenceRootReduce",
"Differences",
"DifferentialD",
"DifferentialRoot",
"DifferentialRootReduce",
"DifferentiatorFilter",
"DiffusionPDETerm",
"DiggleGatesPointProcess",
"DiggleGrattonPointProcess",
"DigitalSignature",
"DigitBlock",
"DigitBlockMinimum",
"DigitCharacter",
"DigitCount",
"DigitQ",
"DihedralAngle",
"DihedralGroup",
"Dilation",
"DimensionalCombinations",
"DimensionalMeshComponents",
"DimensionReduce",
"DimensionReducerFunction",
"DimensionReduction",
"Dimensions",
"DiracComb",
"DiracDelta",
"DirectedEdge",
"DirectedEdges",
"DirectedGraph",
"DirectedGraphQ",
"DirectedInfinity",
"Direction",
"DirectionalLight",
"Directive",
"Directory",
"DirectoryName",
"DirectoryQ",
"DirectoryStack",
"DirichletBeta",
"DirichletCharacter",
"DirichletCondition",
"DirichletConvolve",
"DirichletDistribution",
"DirichletEta",
"DirichletL",
"DirichletLambda",
"DirichletTransform",
"DirichletWindow",
"DisableConsolePrintPacket",
"DisableFormatting",
"DiscreteAsymptotic",
"DiscreteChirpZTransform",
"DiscreteConvolve",
"DiscreteDelta",
"DiscreteHadamardTransform",
"DiscreteIndicator",
"DiscreteInputOutputModel",
"DiscreteLimit",
"DiscreteLQEstimatorGains",
"DiscreteLQRegulatorGains",
"DiscreteLyapunovSolve",
"DiscreteMarkovProcess",
"DiscreteMaxLimit",
"DiscreteMinLimit",
"DiscretePlot",
"DiscretePlot3D",
"DiscreteRatio",
"DiscreteRiccatiSolve",
"DiscreteShift",
"DiscreteTimeModelQ",
"DiscreteUniformDistribution",
"DiscreteVariables",
"DiscreteWaveletData",
"DiscreteWaveletPacketTransform",
"DiscreteWaveletTransform",
"DiscretizeGraphics",
"DiscretizeRegion",
"Discriminant",
"DisjointQ",
"Disjunction",
"Disk",
"DiskBox",
"DiskBoxOptions",
"DiskMatrix",
"DiskSegment",
"Dispatch",
"DispatchQ",
"DispersionEstimatorFunction",
"Display",
"DisplayAllSteps",
"DisplayEndPacket",
"DisplayForm",
"DisplayFunction",
"DisplayPacket",
"DisplayRules",
"DisplayString",
"DisplayTemporary",
"DisplayWith",
"DisplayWithRef",
"DisplayWithVariable",
"DistanceFunction",
"DistanceMatrix",
"DistanceTransform",
"Distribute",
"Distributed",
"DistributedContexts",
"DistributeDefinitions",
"DistributionChart",
"DistributionDomain",
"DistributionFitTest",
"DistributionParameterAssumptions",
"DistributionParameterQ",
"Dithering",
"Div",
"Divergence",
"Divide",
"DivideBy",
"Dividers",
"DivideSides",
"Divisible",
"Divisors",
"DivisorSigma",
"DivisorSum",
"DMSList",
"DMSString",
"Do",
"DockedCell",
"DockedCells",
"DocumentGenerator",
"DocumentGeneratorInformation",
"DocumentGeneratorInformationData",
"DocumentGenerators",
"DocumentNotebook",
"DocumentWeightingRules",
"Dodecahedron",
"DomainRegistrationInformation",
"DominantColors",
"DominatorTreeGraph",
"DominatorVertexList",
"DOSTextFormat",
"Dot",
"DotDashed",
"DotEqual",
"DotLayer",
"DotPlusLayer",
"Dotted",
"DoubleBracketingBar",
"DoubleContourIntegral",
"DoubleDownArrow",
"DoubleLeftArrow",
"DoubleLeftRightArrow",
"DoubleLeftTee",
"DoubleLongLeftArrow",
"DoubleLongLeftRightArrow",
"DoubleLongRightArrow",
"DoubleRightArrow",
"DoubleRightTee",
"DoubleUpArrow",
"DoubleUpDownArrow",
"DoubleVerticalBar",
"DoublyInfinite",
"Down",
"DownArrow",
"DownArrowBar",
"DownArrowUpArrow",
"DownLeftRightVector",
"DownLeftTeeVector",
"DownLeftVector",
"DownLeftVectorBar",
"DownRightTeeVector",
"DownRightVector",
"DownRightVectorBar",
"Downsample",
"DownTee",
"DownTeeArrow",
"DownValues",
"DownValuesFunction",
"DragAndDrop",
"DrawBackFaces",
"DrawEdges",
"DrawFrontFaces",
"DrawHighlighted",
"DrazinInverse",
"Drop",
"DropoutLayer",
"DropShadowing",
"DSolve",
"DSolveChangeVariables",
"DSolveValue",
"Dt",
"DualLinearProgramming",
"DualPlanarGraph",
"DualPolyhedron",
"DualSystemsModel",
"DumpGet",
"DumpSave",
"DuplicateFreeQ",
"Duration",
"Dynamic",
"DynamicBox",
"DynamicBoxOptions",
"DynamicEvaluationTimeout",
"DynamicGeoGraphics",
"DynamicImage",
"DynamicLocation",
"DynamicModule",
"DynamicModuleBox",
"DynamicModuleBoxOptions",
"DynamicModuleParent",
"DynamicModuleValues",
"DynamicName",
"DynamicNamespace",
"DynamicReference",
"DynamicSetting",
"DynamicUpdating",
"DynamicWrapper",
"DynamicWrapperBox",
"DynamicWrapperBoxOptions",
"E",
"EarthImpactData",
"EarthquakeData",
"EccentricityCentrality",
"Echo",
"EchoEvaluation",
"EchoFunction",
"EchoLabel",
"EchoTiming",
"EclipseType",
"EdgeAdd",
"EdgeBetweennessCentrality",
"EdgeCapacity",
"EdgeCapForm",
"EdgeChromaticNumber",
"EdgeColor",
"EdgeConnectivity",
"EdgeContract",
"EdgeCost",
"EdgeCount",
"EdgeCoverQ",
"EdgeCycleMatrix",
"EdgeDashing",
"EdgeDelete",
"EdgeDetect",
"EdgeForm",
"EdgeIndex",
"EdgeJoinForm",
"EdgeLabeling",
"EdgeLabels",
"EdgeLabelStyle",
"EdgeList",
"EdgeOpacity",
"EdgeQ",
"EdgeRenderingFunction",
"EdgeRules",
"EdgeShapeFunction",
"EdgeStyle",
"EdgeTaggedGraph",
"EdgeTaggedGraphQ",
"EdgeTags",
"EdgeThickness",
"EdgeTransitiveGraphQ",
"EdgeValueRange",
"EdgeValueSizes",
"EdgeWeight",
"EdgeWeightedGraphQ",
"Editable",
"EditButtonSettings",
"EditCellTagsSettings",
"EditDistance",
"EffectiveInterest",
"Eigensystem",
"Eigenvalues",
"EigenvectorCentrality",
"Eigenvectors",
"Element",
"ElementData",
"ElementwiseLayer",
"ElidedForms",
"Eliminate",
"EliminationOrder",
"Ellipsoid",
"EllipticE",
"EllipticExp",
"EllipticExpPrime",
"EllipticF",
"EllipticFilterModel",
"EllipticK",
"EllipticLog",
"EllipticNomeQ",
"EllipticPi",
"EllipticReducedHalfPeriods",
"EllipticTheta",
"EllipticThetaPrime",
"EmbedCode",
"EmbeddedHTML",
"EmbeddedService",
"EmbeddedSQLEntityClass",
"EmbeddedSQLExpression",
"EmbeddingLayer",
"EmbeddingObject",
"EmitSound",
"EmphasizeSyntaxErrors",
"EmpiricalDistribution",
"Empty",
"EmptyGraphQ",
"EmptyRegion",
"EmptySpaceF",
"EnableConsolePrintPacket",
"Enabled",
"Enclose",
"Encode",
"Encrypt",
"EncryptedObject",
"EncryptFile",
"End",
"EndAdd",
"EndDialogPacket",
"EndOfBuffer",
"EndOfFile",
"EndOfLine",
"EndOfString",
"EndPackage",
"EngineEnvironment",
"EngineeringForm",
"Enter",
"EnterExpressionPacket",
"EnterTextPacket",
"Entity",
"EntityClass",
"EntityClassList",
"EntityCopies",
"EntityFunction",
"EntityGroup",
"EntityInstance",
"EntityList",
"EntityPrefetch",
"EntityProperties",
"EntityProperty",
"EntityPropertyClass",
"EntityRegister",
"EntityStore",
"EntityStores",
"EntityTypeName",
"EntityUnregister",
"EntityValue",
"Entropy",
"EntropyFilter",
"Environment",
"Epilog",
"EpilogFunction",
"Equal",
"EqualColumns",
"EqualRows",
"EqualTilde",
"EqualTo",
"EquatedTo",
"Equilibrium",
"EquirippleFilterKernel",
"Equivalent",
"Erf",
"Erfc",
"Erfi",
"ErlangB",
"ErlangC",
"ErlangDistribution",
"Erosion",
"ErrorBox",
"ErrorBoxOptions",
"ErrorNorm",
"ErrorPacket",
"ErrorsDialogSettings",
"EscapeRadius",
"EstimatedBackground",
"EstimatedDistribution",
"EstimatedPointNormals",
"EstimatedPointProcess",
"EstimatedProcess",
"EstimatedVariogramModel",
"EstimatorGains",
"EstimatorRegulator",
"EuclideanDistance",
"EulerAngles",
"EulerCharacteristic",
"EulerE",
"EulerGamma",
"EulerianGraphQ",
"EulerMatrix",
"EulerPhi",
"Evaluatable",
"Evaluate",
"Evaluated",
"EvaluatePacket",
"EvaluateScheduledTask",
"EvaluationBox",
"EvaluationCell",
"EvaluationCompletionAction",
"EvaluationData",
"EvaluationElements",
"EvaluationEnvironment",
"EvaluationMode",
"EvaluationMonitor",
"EvaluationNotebook",
"EvaluationObject",
"EvaluationOrder",
"EvaluationPrivileges",
"EvaluationRateLimit",
"Evaluator",
"EvaluatorNames",
"EvenQ",
"EventData",
"EventEvaluator",
"EventHandler",
"EventHandlerTag",
"EventLabels",
"EventSeries",
"ExactBlackmanWindow",
"ExactNumberQ",
"ExactRootIsolation",
"ExampleData",
"Except",
"ExcludedContexts",
"ExcludedForms",
"ExcludedLines",
"ExcludedPhysicalQuantities",
"ExcludePods",
"Exclusions",
"ExclusionsStyle",
"Exists",
"Exit",
"ExitDialog",
"ExoplanetData",
"Exp",
"Expand",
"ExpandAll",
"ExpandDenominator",
"ExpandFileName",
"ExpandNumerator",
"Expectation",
"ExpectationE",
"ExpectedValue",
"ExpGammaDistribution",
"ExpIntegralE",
"ExpIntegralEi",
"ExpirationDate",
"Exponent",
"ExponentFunction",
"ExponentialDistribution",
"ExponentialFamily",
"ExponentialGeneratingFunction",
"ExponentialMovingAverage",
"ExponentialPowerDistribution",
"ExponentPosition",
"ExponentStep",
"Export",
"ExportAutoReplacements",
"ExportByteArray",
"ExportForm",
"ExportPacket",
"ExportString",
"Expression",
"ExpressionCell",
"ExpressionGraph",
"ExpressionPacket",
"ExpressionTree",
"ExpressionUUID",
"ExpToTrig",
"ExtendedEntityClass",
"ExtendedGCD",
"Extension",
"ExtentElementFunction",
"ExtentMarkers",
"ExtentSize",
"ExternalBundle",
"ExternalCall",
"ExternalDataCharacterEncoding",
"ExternalEvaluate",
"ExternalFunction",
"ExternalFunctionName",
"ExternalIdentifier",
"ExternalObject",
"ExternalOptions",
"ExternalSessionObject",
"ExternalSessions",
"ExternalStorageBase",
"ExternalStorageDownload",
"ExternalStorageGet",
"ExternalStorageObject",
"ExternalStoragePut",
"ExternalStorageUpload",
"ExternalTypeSignature",
"ExternalValue",
"Extract",
"ExtractArchive",
"ExtractLayer",
"ExtractPacletArchive",
"ExtremeValueDistribution",
"FaceAlign",
"FaceForm",
"FaceGrids",
"FaceGridsStyle",
"FaceRecognize",
"FacialFeatures",
"Factor",
"FactorComplete",
"Factorial",
"Factorial2",
"FactorialMoment",
"FactorialMomentGeneratingFunction",
"FactorialPower",
"FactorInteger",
"FactorList",
"FactorSquareFree",
"FactorSquareFreeList",
"FactorTerms",
"FactorTermsList",
"Fail",
"Failure",
"FailureAction",
"FailureDistribution",
"FailureQ",
"False",
"FareySequence",
"FARIMAProcess",
"FeatureDistance",
"FeatureExtract",
"FeatureExtraction",
"FeatureExtractor",
"FeatureExtractorFunction",
"FeatureImpactPlot",
"FeatureNames",
"FeatureNearest",
"FeatureSpacePlot",
"FeatureSpacePlot3D",
"FeatureTypes",
"FeatureValueDependencyPlot",
"FeatureValueImpactPlot",
"FEDisableConsolePrintPacket",
"FeedbackLinearize",
"FeedbackSector",
"FeedbackSectorStyle",
"FeedbackType",
"FEEnableConsolePrintPacket",
"FetalGrowthData",
"Fibonacci",
"Fibonorial",
"FieldCompletionFunction",
"FieldHint",
"FieldHintStyle",
"FieldMasked",
"FieldSize",
"File",
"FileBaseName",
"FileByteCount",
"FileConvert",
"FileDate",
"FileExistsQ",
"FileExtension",
"FileFormat",
"FileFormatProperties",
"FileFormatQ",
"FileHandler",
"FileHash",
"FileInformation",
"FileName",
"FileNameDepth",
"FileNameDialogSettings",
"FileNameDrop",
"FileNameForms",
"FileNameJoin",
"FileNames",
"FileNameSetter",
"FileNameSplit",
"FileNameTake",
"FileNameToFormatList",
"FilePrint",
"FileSize",
"FileSystemMap",
"FileSystemScan",
"FileSystemTree",
"FileTemplate",
"FileTemplateApply",
"FileType",
"FilledCurve",
"FilledCurveBox",
"FilledCurveBoxOptions",
"FilledTorus",
"FillForm",
"Filling",
"FillingStyle",
"FillingTransform",
"FilteredEntityClass",
"FilterRules",
"FinancialBond",
"FinancialData",
"FinancialDerivative",
"FinancialIndicator",
"Find",
"FindAnomalies",
"FindArgMax",
"FindArgMin",
"FindChannels",
"FindClique",
"FindClusters",
"FindCookies",
"FindCurvePath",
"FindCycle",
"FindDevices",
"FindDistribution",
"FindDistributionParameters",
"FindDivisions",
"FindEdgeColoring",
"FindEdgeCover",
"FindEdgeCut",
"FindEdgeIndependentPaths",
"FindEquationalProof",
"FindEulerianCycle",
"FindExternalEvaluators",
"FindFaces",
"FindFile",
"FindFit",
"FindFormula",
"FindFundamentalCycles",
"FindGeneratingFunction",
"FindGeoLocation",
"FindGeometricConjectures",
"FindGeometricTransform",
"FindGraphCommunities",
"FindGraphIsomorphism",
"FindGraphPartition",
"FindHamiltonianCycle",
"FindHamiltonianPath",
"FindHiddenMarkovStates",
"FindImageText",
"FindIndependentEdgeSet",
"FindIndependentVertexSet",
"FindInstance",
"FindIntegerNullVector",
"FindIsomers",
"FindIsomorphicSubgraph",
"FindKClan",
"FindKClique",
"FindKClub",
"FindKPlex",
"FindLibrary",
"FindLinearRecurrence",
"FindList",
"FindMatchingColor",
"FindMaximum",
"FindMaximumCut",
"FindMaximumFlow",
"FindMaxValue",
"FindMeshDefects",
"FindMinimum",
"FindMinimumCostFlow",
"FindMinimumCut",
"FindMinValue",
"FindMoleculeSubstructure",
"FindPath",
"FindPeaks",
"FindPermutation",
"FindPlanarColoring",
"FindPointProcessParameters",
"FindPostmanTour",
"FindProcessParameters",
"FindRegionTransform",
"FindRepeat",
"FindRoot",
"FindSequenceFunction",
"FindSettings",
"FindShortestPath",
"FindShortestTour",
"FindSpanningTree",
"FindSubgraphIsomorphism",
"FindSystemModelEquilibrium",
"FindTextualAnswer",
"FindThreshold",
"FindTransientRepeat",
"FindVertexColoring",
"FindVertexCover",
"FindVertexCut",
"FindVertexIndependentPaths",
"Fine",
"FinishDynamic",
"FiniteAbelianGroupCount",
"FiniteGroupCount",
"FiniteGroupData",
"First",
"FirstCase",
"FirstPassageTimeDistribution",
"FirstPosition",
"FischerGroupFi22",
"FischerGroupFi23",
"FischerGroupFi24Prime",
"FisherHypergeometricDistribution",
"FisherRatioTest",
"FisherZDistribution",
"Fit",
"FitAll",
"FitRegularization",
"FittedModel",
"FixedOrder",
"FixedPoint",
"FixedPointList",
"FlashSelection",
"Flat",
"FlatShading",
"Flatten",
"FlattenAt",
"FlattenLayer",
"FlatTopWindow",
"FlightData",
"FlipView",
"Floor",
"FlowPolynomial",
"Fold",
"FoldList",
"FoldPair",
"FoldPairList",
"FoldWhile",
"FoldWhileList",
"FollowRedirects",
"Font",
"FontColor",
"FontFamily",
"FontForm",
"FontName",
"FontOpacity",
"FontPostScriptName",
"FontProperties",
"FontReencoding",
"FontSize",
"FontSlant",
"FontSubstitutions",
"FontTracking",
"FontVariations",
"FontWeight",
"For",
"ForAll",
"ForAllType",
"ForceVersionInstall",
"Format",
"FormatRules",
"FormatType",
"FormatTypeAutoConvert",
"FormatValues",
"FormBox",
"FormBoxOptions",
"FormControl",
"FormFunction",
"FormLayoutFunction",
"FormObject",
"FormPage",
"FormProtectionMethod",
"FormTheme",
"FormulaData",
"FormulaLookup",
"FortranForm",
"Forward",
"ForwardBackward",
"ForwardCloudCredentials",
"Fourier",
"FourierCoefficient",
"FourierCosCoefficient",
"FourierCosSeries",
"FourierCosTransform",
"FourierDCT",
"FourierDCTFilter",
"FourierDCTMatrix",
"FourierDST",
"FourierDSTMatrix",
"FourierMatrix",
"FourierParameters",
"FourierSequenceTransform",
"FourierSeries",
"FourierSinCoefficient",
"FourierSinSeries",
"FourierSinTransform",
"FourierTransform",
"FourierTrigSeries",
"FoxH",
"FoxHReduce",
"FractionalBrownianMotionProcess",
"FractionalD",
"FractionalGaussianNoiseProcess",
"FractionalPart",
"FractionBox",
"FractionBoxOptions",
"FractionLine",
"Frame",
"FrameBox",
"FrameBoxOptions",
"Framed",
"FrameInset",
"FrameLabel",
"Frameless",
"FrameListVideo",
"FrameMargins",
"FrameRate",
"FrameStyle",
"FrameTicks",
"FrameTicksStyle",
"FRatioDistribution",
"FrechetDistribution",
"FreeQ",
"FrenetSerretSystem",
"FrequencySamplingFilterKernel",
"FresnelC",
"FresnelF",
"FresnelG",
"FresnelS",
"Friday",
"FrobeniusNumber",
"FrobeniusSolve",
"FromAbsoluteTime",
"FromCharacterCode",
"FromCoefficientRules",
"FromContinuedFraction",
"FromDate",
"FromDateString",
"FromDigits",
"FromDMS",
"FromEntity",
"FromJulianDate",
"FromLetterNumber",
"FromPolarCoordinates",
"FromRawPointer",
"FromRomanNumeral",
"FromSphericalCoordinates",
"FromUnixTime",
"Front",
"FrontEndDynamicExpression",
"FrontEndEventActions",
"FrontEndExecute",
"FrontEndObject",
"FrontEndResource",
"FrontEndResourceString",
"FrontEndStackSize",
"FrontEndToken",
"FrontEndTokenExecute",
"FrontEndValueCache",
"FrontEndVersion",
"FrontFaceColor",
"FrontFaceGlowColor",
"FrontFaceOpacity",
"FrontFaceSpecularColor",
"FrontFaceSpecularExponent",
"FrontFaceSurfaceAppearance",
"FrontFaceTexture",
"Full",
"FullAxes",
"FullDefinition",
"FullForm",
"FullGraphics",
"FullInformationOutputRegulator",
"FullOptions",
"FullRegion",
"FullSimplify",
"Function",
"FunctionAnalytic",
"FunctionBijective",
"FunctionCompile",
"FunctionCompileExport",
"FunctionCompileExportByteArray",
"FunctionCompileExportLibrary",
"FunctionCompileExportString",
"FunctionContinuous",
"FunctionConvexity",
"FunctionDeclaration",
"FunctionDiscontinuities",
"FunctionDomain",
"FunctionExpand",
"FunctionInjective",
"FunctionInterpolation",
"FunctionLayer",
"FunctionMeromorphic",
"FunctionMonotonicity",
"FunctionPeriod",
"FunctionPoles",
"FunctionRange",
"FunctionSign",
"FunctionSingularities",
"FunctionSpace",
"FunctionSurjective",
"FussellVeselyImportance",
"GaborFilter",
"GaborMatrix",
"GaborWavelet",
"GainMargins",
"GainPhaseMargins",
"GalaxyData",
"GalleryView",
"Gamma",
"GammaDistribution",
"GammaRegularized",
"GapPenalty",
"GARCHProcess",
"GatedRecurrentLayer",
"Gather",
"GatherBy",
"GaugeFaceElementFunction",
"GaugeFaceStyle",
"GaugeFrameElementFunction",
"GaugeFrameSize",
"GaugeFrameStyle",
"GaugeLabels",
"GaugeMarkers",
"GaugeStyle",
"GaussianFilter",
"GaussianIntegers",
"GaussianMatrix",
"GaussianOrthogonalMatrixDistribution",
"GaussianSymplecticMatrixDistribution",
"GaussianUnitaryMatrixDistribution",
"GaussianWindow",
"GCD",
"GegenbauerC",
"General",
"GeneralizedLinearModelFit",
"GenerateAsymmetricKeyPair",
"GenerateConditions",
"GeneratedAssetFormat",
"GeneratedAssetLocation",
"GeneratedCell",
"GeneratedCellStyles",
"GeneratedDocumentBinding",
"GenerateDerivedKey",
"GenerateDigitalSignature",
"GenerateDocument",
"GeneratedParameters",
"GeneratedQuantityMagnitudes",
"GenerateFileSignature",
"GenerateHTTPResponse",
"GenerateSecuredAuthenticationKey",
"GenerateSymmetricKey",
"GeneratingFunction",
"GeneratorDescription",
"GeneratorHistoryLength",
"GeneratorOutputType",
"Generic",
"GenericCylindricalDecomposition",
"GenomeData",
"GenomeLookup",
"GeoAntipode",
"GeoArea",
"GeoArraySize",
"GeoBackground",
"GeoBoundary",
"GeoBoundingBox",
"GeoBounds",
"GeoBoundsRegion",
"GeoBoundsRegionBoundary",
"GeoBubbleChart",
"GeoCenter",
"GeoCircle",
"GeoContourPlot",
"GeoDensityPlot",
"GeodesicClosing",
"GeodesicDilation",
"GeodesicErosion",
"GeodesicOpening",
"GeodesicPolyhedron",
"GeoDestination",
"GeodesyData",
"GeoDirection",
"GeoDisk",
"GeoDisplacement",
"GeoDistance",
"GeoDistanceList",
"GeoElevationData",
"GeoEntities",
"GeoGraphics",
"GeoGraphPlot",
"GeoGraphValuePlot",
"GeogravityModelData",
"GeoGridDirectionDifference",
"GeoGridLines",
"GeoGridLinesStyle",
"GeoGridPosition",
"GeoGridRange",
"GeoGridRangePadding",
"GeoGridUnitArea",
"GeoGridUnitDistance",
"GeoGridVector",
"GeoGroup",
"GeoHemisphere",
"GeoHemisphereBoundary",
"GeoHistogram",
"GeoIdentify",
"GeoImage",
"GeoLabels",
"GeoLength",
"GeoListPlot",
"GeoLocation",
"GeologicalPeriodData",
"GeomagneticModelData",
"GeoMarker",
"GeometricAssertion",
"GeometricBrownianMotionProcess",
"GeometricDistribution",
"GeometricMean",
"GeometricMeanFilter",
"GeometricOptimization",
"GeometricScene",
"GeometricStep",
"GeometricStylingRules",
"GeometricTest",
"GeometricTransformation",
"GeometricTransformation3DBox",
"GeometricTransformation3DBoxOptions",
"GeometricTransformationBox",
"GeometricTransformationBoxOptions",
"GeoModel",
"GeoNearest",
"GeoOrientationData",
"GeoPath",
"GeoPolygon",
"GeoPosition",
"GeoPositionENU",
"GeoPositionXYZ",
"GeoProjection",
"GeoProjectionData",
"GeoRange",
"GeoRangePadding",
"GeoRegionValuePlot",
"GeoResolution",
"GeoScaleBar",
"GeoServer",
"GeoSmoothHistogram",
"GeoStreamPlot",
"GeoStyling",
"GeoStylingImageFunction",
"GeoVariant",
"GeoVector",
"GeoVectorENU",
"GeoVectorPlot",
"GeoVectorXYZ",
"GeoVisibleRegion",
"GeoVisibleRegionBoundary",
"GeoWithinQ",
"GeoZoomLevel",
"GestureHandler",
"GestureHandlerTag",
"Get",
"GetContext",
"GetEnvironment",
"GetFileName",
"GetLinebreakInformationPacket",
"GibbsPointProcess",
"Glaisher",
"GlobalClusteringCoefficient",
"GlobalPreferences",
"GlobalSession",
"Glow",
"GoldenAngle",
"GoldenRatio",
"GompertzMakehamDistribution",
"GoochShading",
"GoodmanKruskalGamma",
"GoodmanKruskalGammaTest",
"Goto",
"GouraudShading",
"Grad",
"Gradient",
"GradientFilter",
"GradientFittedMesh",
"GradientOrientationFilter",
"GrammarApply",
"GrammarRules",
"GrammarToken",
"Graph",
"Graph3D",
"GraphAssortativity",
"GraphAutomorphismGroup",
"GraphCenter",
"GraphComplement",
"GraphData",
"GraphDensity",
"GraphDiameter",
"GraphDifference",
"GraphDisjointUnion",
"GraphDistance",
"GraphDistanceMatrix",
"GraphEmbedding",
"GraphHighlight",
"GraphHighlightStyle",
"GraphHub",
"Graphics",
"Graphics3D",
"Graphics3DBox",
"Graphics3DBoxOptions",
"GraphicsArray",
"GraphicsBaseline",
"GraphicsBox",
"GraphicsBoxOptions",
"GraphicsColor",
"GraphicsColumn",
"GraphicsComplex",
"GraphicsComplex3DBox",
"GraphicsComplex3DBoxOptions",
"GraphicsComplexBox",
"GraphicsComplexBoxOptions",
"GraphicsContents",
"GraphicsData",
"GraphicsGrid",
"GraphicsGridBox",
"GraphicsGroup",
"GraphicsGroup3DBox",
"GraphicsGroup3DBoxOptions",
"GraphicsGroupBox",
"GraphicsGroupBoxOptions",
"GraphicsGrouping",
"GraphicsHighlightColor",
"GraphicsRow",
"GraphicsSpacing",
"GraphicsStyle",
"GraphIntersection",
"GraphJoin",
"GraphLayerLabels",
"GraphLayers",
"GraphLayerStyle",
"GraphLayout",
"GraphLinkEfficiency",
"GraphPeriphery",
"GraphPlot",
"GraphPlot3D",
"GraphPower",
"GraphProduct",
"GraphPropertyDistribution",
"GraphQ",
"GraphRadius",
"GraphReciprocity",
"GraphRoot",
"GraphStyle",
"GraphSum",
"GraphTree",
"GraphUnion",
"Gray",
"GrayLevel",
"Greater",
"GreaterEqual",
"GreaterEqualLess",
"GreaterEqualThan",
"GreaterFullEqual",
"GreaterGreater",
"GreaterLess",
"GreaterSlantEqual",
"GreaterThan",
"GreaterTilde",
"GreekStyle",
"Green",
"GreenFunction",
"Grid",
"GridBaseline",
"GridBox",
"GridBoxAlignment",
"GridBoxBackground",
"GridBoxDividers",
"GridBoxFrame",
"GridBoxItemSize",
"GridBoxItemStyle",
"GridBoxOptions",
"GridBoxSpacings",
"GridCreationSettings",
"GridDefaultElement",
"GridElementStyleOptions",
"GridFrame",
"GridFrameMargins",
"GridGraph",
"GridLines",
"GridLinesStyle",
"GridVideo",
"GroebnerBasis",
"GroupActionBase",
"GroupBy",
"GroupCentralizer",
"GroupElementFromWord",
"GroupElementPosition",
"GroupElementQ",
"GroupElements",
"GroupElementToWord",
"GroupGenerators",
"Groupings",
"GroupMultiplicationTable",
"GroupOpenerColor",
"GroupOpenerInsideFrame",
"GroupOrbits",
"GroupOrder",
"GroupPageBreakWithin",
"GroupSetwiseStabilizer",
"GroupStabilizer",
"GroupStabilizerChain",
"GroupTogetherGrouping",
"GroupTogetherNestedGrouping",
"GrowCutComponents",
"Gudermannian",
"GuidedFilter",
"GumbelDistribution",
"HaarWavelet",
"HadamardMatrix",
"HalfLine",
"HalfNormalDistribution",
"HalfPlane",
"HalfSpace",
"HalftoneShading",
"HamiltonianGraphQ",
"HammingDistance",
"HammingWindow",
"HandlerFunctions",
"HandlerFunctionsKeys",
"HankelH1",
"HankelH2",
"HankelMatrix",
"HankelTransform",
"HannPoissonWindow",
"HannWindow",
"HaradaNortonGroupHN",
"HararyGraph",
"HardcorePointProcess",
"HarmonicMean",
"HarmonicMeanFilter",
"HarmonicNumber",
"Hash",
"HatchFilling",
"HatchShading",
"Haversine",
"HazardFunction",
"Head",
"HeadCompose",
"HeaderAlignment",
"HeaderBackground",
"HeaderDisplayFunction",
"HeaderLines",
"Headers",
"HeaderSize",
"HeaderStyle",
"Heads",
"HeatFluxValue",
"HeatInsulationValue",
"HeatOutflowValue",
"HeatRadiationValue",
"HeatSymmetryValue",
"HeatTemperatureCondition",
"HeatTransferPDEComponent",
"HeatTransferValue",
"HeavisideLambda",
"HeavisidePi",
"HeavisideTheta",
"HeldGroupHe",
"HeldPart",
"HelmholtzPDEComponent",
"HelpBrowserLookup",
"HelpBrowserNotebook",
"HelpBrowserSettings",
"HelpViewerSettings",
"Here",
"HermiteDecomposition",
"HermiteH",
"Hermitian",
"HermitianMatrixQ",
"HessenbergDecomposition",
"Hessian",
"HeunB",
"HeunBPrime",
"HeunC",
"HeunCPrime",
"HeunD",
"HeunDPrime",
"HeunG",
"HeunGPrime",
"HeunT",
"HeunTPrime",
"HexadecimalCharacter",
"Hexahedron",
"HexahedronBox",
"HexahedronBoxOptions",
"HiddenItems",
"HiddenMarkovProcess",
"HiddenSurface",
"Highlighted",
"HighlightGraph",
"HighlightImage",
"HighlightMesh",
"HighlightString",
"HighpassFilter",
"HigmanSimsGroupHS",
"HilbertCurve",
"HilbertFilter",
"HilbertMatrix",
"Histogram",
"Histogram3D",
"HistogramDistribution",
"HistogramList",
"HistogramPointDensity",
"HistogramTransform",
"HistogramTransformInterpolation",
"HistoricalPeriodData",
"HitMissTransform",
"HITSCentrality",
"HjorthDistribution",
"HodgeDual",
"HoeffdingD",
"HoeffdingDTest",
"Hold",
"HoldAll",
"HoldAllComplete",
"HoldComplete",
"HoldFirst",
"HoldForm",
"HoldPattern",
"HoldRest",
"HolidayCalendar",
"HomeDirectory",
"HomePage",
"Horizontal",
"HorizontalForm",
"HorizontalGauge",
"HorizontalScrollPosition",
"HornerForm",
"HostLookup",
"HotellingTSquareDistribution",
"HoytDistribution",
"HTMLSave",
"HTTPErrorResponse",
"HTTPRedirect",
"HTTPRequest",
"HTTPRequestData",
"HTTPResponse",
"Hue",
"HumanGrowthData",
"HumpDownHump",
"HumpEqual",
"HurwitzLerchPhi",
"HurwitzZeta",
"HyperbolicDistribution",
"HypercubeGraph",
"HyperexponentialDistribution",
"Hyperfactorial",
"Hypergeometric0F1",
"Hypergeometric0F1Regularized",
"Hypergeometric1F1",
"Hypergeometric1F1Regularized",
"Hypergeometric2F1",
"Hypergeometric2F1Regularized",
"HypergeometricDistribution",
"HypergeometricPFQ",
"HypergeometricPFQRegularized",
"HypergeometricU",
"Hyperlink",
"HyperlinkAction",
"HyperlinkCreationSettings",
"Hyperplane",
"Hyphenation",
"HyphenationOptions",
"HypoexponentialDistribution",
"HypothesisTestData",
"I",
"IconData",
"Iconize",
"IconizedObject",
"IconRules",
"Icosahedron",
"Identity",
"IdentityMatrix",
"If",
"IfCompiled",
"IgnoreCase",
"IgnoreDiacritics",
"IgnoreIsotopes",
"IgnorePunctuation",
"IgnoreSpellCheck",
"IgnoreStereochemistry",
"IgnoringInactive",
"Im",
"Image",
"Image3D",
"Image3DProjection",
"Image3DSlices",
"ImageAccumulate",
"ImageAdd",
"ImageAdjust",
"ImageAlign",
"ImageApply",
"ImageApplyIndexed",
"ImageAspectRatio",
"ImageAssemble",
"ImageAugmentationLayer",
"ImageBoundingBoxes",
"ImageCache",
"ImageCacheValid",
"ImageCapture",
"ImageCaptureFunction",
"ImageCases",
"ImageChannels",
"ImageClip",
"ImageCollage",
"ImageColorSpace",
"ImageCompose",
"ImageContainsQ",
"ImageContents",
"ImageConvolve",
"ImageCooccurrence",
"ImageCorners",
"ImageCorrelate",
"ImageCorrespondingPoints",
"ImageCrop",
"ImageData",
"ImageDeconvolve",
"ImageDemosaic",
"ImageDifference",
"ImageDimensions",
"ImageDisplacements",
"ImageDistance",
"ImageEditMode",
"ImageEffect",
"ImageExposureCombine",
"ImageFeatureTrack",
"ImageFileApply",
"ImageFileFilter",
"ImageFileScan",
"ImageFilter",
"ImageFocusCombine",
"ImageForestingComponents",
"ImageFormattingWidth",
"ImageForwardTransformation",
"ImageGraphics",
"ImageHistogram",
"ImageIdentify",
"ImageInstanceQ",
"ImageKeypoints",
"ImageLabels",
"ImageLegends",
"ImageLevels",
"ImageLines",
"ImageMargins",
"ImageMarker",
"ImageMarkers",
"ImageMeasurements",
"ImageMesh",
"ImageMultiply",
"ImageOffset",
"ImagePad",
"ImagePadding",
"ImagePartition",
"ImagePeriodogram",
"ImagePerspectiveTransformation",
"ImagePosition",
"ImagePreviewFunction",
"ImagePyramid",
"ImagePyramidApply",
"ImageQ",
"ImageRangeCache",
"ImageRecolor",
"ImageReflect",
"ImageRegion",
"ImageResize",
"ImageResolution",
"ImageRestyle",
"ImageRotate",
"ImageRotated",
"ImageSaliencyFilter",
"ImageScaled",
"ImageScan",
"ImageSize",
"ImageSizeAction",
"ImageSizeCache",
"ImageSizeMultipliers",
"ImageSizeRaw",
"ImageStitch",
"ImageSubtract",
"ImageTake",
"ImageTransformation",
"ImageTrim",
"ImageType",
"ImageValue",
"ImageValuePositions",
"ImageVectorscopePlot",
"ImageWaveformPlot",
"ImagingDevice",
"ImplicitD",
"ImplicitRegion",
"Implies",
"Import",
"ImportAutoReplacements",
"ImportByteArray",
"ImportedObject",
"ImportOptions",
"ImportString",
"ImprovementImportance",
"In",
"Inactivate",
"Inactive",
"InactiveStyle",
"IncidenceGraph",
"IncidenceList",
"IncidenceMatrix",
"IncludeAromaticBonds",
"IncludeConstantBasis",
"IncludedContexts",
"IncludeDefinitions",
"IncludeDirectories",
"IncludeFileExtension",
"IncludeGeneratorTasks",
"IncludeHydrogens",
"IncludeInflections",
"IncludeMetaInformation",
"IncludePods",
"IncludeQuantities",
"IncludeRelatedTables",
"IncludeSingularSolutions",
"IncludeSingularTerm",
"IncludeWindowTimes",
"Increment",
"IndefiniteMatrixQ",
"Indent",
"IndentingNewlineSpacings",
"IndentMaxFraction",
"IndependenceTest",
"IndependentEdgeSetQ",
"IndependentPhysicalQuantity",
"IndependentUnit",
"IndependentUnitDimension",
"IndependentVertexSetQ",
"Indeterminate",
"IndeterminateThreshold",
"IndexCreationOptions",
"Indexed",
"IndexEdgeTaggedGraph",
"IndexGraph",
"IndexTag",
"Inequality",
"InertEvaluate",
"InertExpression",
"InexactNumberQ",
"InexactNumbers",
"InfiniteFuture",
"InfiniteLine",
"InfiniteLineThrough",
"InfinitePast",
"InfinitePlane",
"Infinity",
"Infix",
"InflationAdjust",
"InflationMethod",
"Information",
"InformationData",
"InformationDataGrid",
"Inherited",
"InheritScope",
"InhomogeneousPoissonPointProcess",
"InhomogeneousPoissonProcess",
"InitialEvaluationHistory",
"Initialization",
"InitializationCell",
"InitializationCellEvaluation",
"InitializationCellWarning",
"InitializationObject",
"InitializationObjects",
"InitializationValue",
"Initialize",
"InitialSeeding",
"InlineCounterAssignments",
"InlineCounterIncrements",
"InlineRules",
"Inner",
"InnerPolygon",
"InnerPolyhedron",
"Inpaint",
"Input",
"InputAliases",
"InputAssumptions",
"InputAutoReplacements",
"InputField",
"InputFieldBox",
"InputFieldBoxOptions",
"InputForm",
"InputGrouping",
"InputNamePacket",
"InputNotebook",
"InputPacket",
"InputPorts",
"InputSettings",
"InputStream",
"InputString",
"InputStringPacket",
"InputToBoxFormPacket",
"Insert",
"InsertionFunction",
"InsertionPointObject",
"InsertLinebreaks",
"InsertResults",
"Inset",
"Inset3DBox",
"Inset3DBoxOptions",
"InsetBox",
"InsetBoxOptions",
"Insphere",
"Install",
"InstallService",
"InstanceNormalizationLayer",
"InString",
"Integer",
"IntegerDigits",
"IntegerExponent",
"IntegerLength",
"IntegerName",
"IntegerPart",
"IntegerPartitions",
"IntegerQ",
"IntegerReverse",
"Integers",
"IntegerString",
"Integral",
"Integrate",
"IntegrateChangeVariables",
"Interactive",
"InteractiveTradingChart",
"InterfaceSwitched",
"Interlaced",
"Interleaving",
"InternallyBalancedDecomposition",
"InterpolatingFunction",
"InterpolatingPolynomial",
"Interpolation",
"InterpolationOrder",
"InterpolationPoints",
"InterpolationPrecision",
"Interpretation",
"InterpretationBox",
"InterpretationBoxOptions",
"InterpretationFunction",
"Interpreter",
"InterpretTemplate",
"InterquartileRange",
"Interrupt",
"InterruptSettings",
"IntersectedEntityClass",
"IntersectingQ",
"Intersection",
"Interval",
"IntervalIntersection",
"IntervalMarkers",
"IntervalMarkersStyle",
"IntervalMemberQ",
"IntervalSlider",
"IntervalUnion",
"Into",
"Inverse",
"InverseBetaRegularized",
"InverseBilateralLaplaceTransform",
"InverseBilateralZTransform",
"InverseCDF",
"InverseChiSquareDistribution",
"InverseContinuousWaveletTransform",
"InverseDistanceTransform",
"InverseEllipticNomeQ",
"InverseErf",
"InverseErfc",
"InverseFourier",
"InverseFourierCosTransform",
"InverseFourierSequenceTransform",
"InverseFourierSinTransform",
"InverseFourierTransform",
"InverseFunction",
"InverseFunctions",
"InverseGammaDistribution",
"InverseGammaRegularized",
"InverseGaussianDistribution",
"InverseGudermannian",
"InverseHankelTransform",
"InverseHaversine",
"InverseImagePyramid",
"InverseJacobiCD",
"InverseJacobiCN",
"InverseJacobiCS",
"InverseJacobiDC",
"InverseJacobiDN",
"InverseJacobiDS",
"InverseJacobiNC",
"InverseJacobiND",
"InverseJacobiNS",
"InverseJacobiSC",
"InverseJacobiSD",
"InverseJacobiSN",
"InverseLaplaceTransform",
"InverseMellinTransform",
"InversePermutation",
"InverseRadon",
"InverseRadonTransform",
"InverseSeries",
"InverseShortTimeFourier",
"InverseSpectrogram",
"InverseSurvivalFunction",
"InverseTransformedRegion",
"InverseWaveletTransform",
"InverseWeierstrassP",
"InverseWishartMatrixDistribution",
"InverseZTransform",
"Invisible",
"InvisibleApplication",
"InvisibleTimes",
"IPAddress",
"IrreduciblePolynomialQ",
"IslandData",
"IsolatingInterval",
"IsomorphicGraphQ",
"IsomorphicSubgraphQ",
"IsotopeData",
"Italic",
"Item",
"ItemAspectRatio",
"ItemBox",
"ItemBoxOptions",
"ItemDisplayFunction",
"ItemSize",
"ItemStyle",
"ItoProcess",
"JaccardDissimilarity",
"JacobiAmplitude",
"Jacobian",
"JacobiCD",
"JacobiCN",
"JacobiCS",
"JacobiDC",
"JacobiDN",
"JacobiDS",
"JacobiEpsilon",
"JacobiNC",
"JacobiND",
"JacobiNS",
"JacobiP",
"JacobiSC",
"JacobiSD",
"JacobiSN",
"JacobiSymbol",
"JacobiZeta",
"JacobiZN",
"JankoGroupJ1",
"JankoGroupJ2",
"JankoGroupJ3",
"JankoGroupJ4",
"JarqueBeraALMTest",
"JohnsonDistribution",
"Join",
"JoinAcross",
"Joined",
"JoinedCurve",
"JoinedCurveBox",
"JoinedCurveBoxOptions",
"JoinForm",
"JordanDecomposition",
"JordanModelDecomposition",
"JulianDate",
"JuliaSetBoettcher",
"JuliaSetIterationCount",
"JuliaSetPlot",
"JuliaSetPoints",
"K",
"KagiChart",
"KaiserBesselWindow",
"KaiserWindow",
"KalmanEstimator",
"KalmanFilter",
"KarhunenLoeveDecomposition",
"KaryTree",
"KatzCentrality",
"KCoreComponents",
"KDistribution",
"KEdgeConnectedComponents",
"KEdgeConnectedGraphQ",
"KeepExistingVersion",
"KelvinBei",
"KelvinBer",
"KelvinKei",
"KelvinKer",
"KendallTau",
"KendallTauTest",
"KernelConfiguration",
"KernelExecute",
"KernelFunction",
"KernelMixtureDistribution",
"KernelObject",
"Kernels",
"Ket",
"Key",
"KeyCollisionFunction",
"KeyComplement",
"KeyDrop",
"KeyDropFrom",
"KeyExistsQ",
"KeyFreeQ",
"KeyIntersection",
"KeyMap",
"KeyMemberQ",
"KeypointStrength",
"Keys",
"KeySelect",
"KeySort",
"KeySortBy",
"KeyTake",
"KeyUnion",
"KeyValueMap",
"KeyValuePattern",
"Khinchin",
"KillProcess",
"KirchhoffGraph",
"KirchhoffMatrix",
"KleinInvariantJ",
"KnapsackSolve",
"KnightTourGraph",
"KnotData",
"KnownUnitQ",
"KochCurve",
"KolmogorovSmirnovTest",
"KroneckerDelta",
"KroneckerModelDecomposition",
"KroneckerProduct",
"KroneckerSymbol",
"KuiperTest",
"KumaraswamyDistribution",
"Kurtosis",
"KuwaharaFilter",
"KVertexConnectedComponents",
"KVertexConnectedGraphQ",
"LABColor",
"Label",
"Labeled",
"LabeledSlider",
"LabelingFunction",
"LabelingSize",
"LabelStyle",
"LabelVisibility",
"LaguerreL",
"LakeData",
"LambdaComponents",
"LambertW",
"LameC",
"LameCPrime",
"LameEigenvalueA",
"LameEigenvalueB",
"LameS",
"LameSPrime",
"LaminaData",
"LanczosWindow",
"LandauDistribution",
"Language",
"LanguageCategory",
"LanguageData",
"LanguageIdentify",
"LanguageOptions",
"LaplaceDistribution",
"LaplaceTransform",
"Laplacian",
"LaplacianFilter",
"LaplacianGaussianFilter",
"LaplacianPDETerm",
"Large",
"Larger",
"Last",
"Latitude",
"LatitudeLongitude",
"LatticeData",
"LatticeReduce",
"Launch",
"LaunchKernels",
"LayeredGraphPlot",
"LayeredGraphPlot3D",
"LayerSizeFunction",
"LayoutInformation",
"LCHColor",
"LCM",
"LeaderSize",
"LeafCount",
"LeapVariant",
"LeapYearQ",
"LearnDistribution",
"LearnedDistribution",
"LearningRate",
"LearningRateMultipliers",
"LeastSquares",
"LeastSquaresFilterKernel",
"Left",
"LeftArrow",
"LeftArrowBar",
"LeftArrowRightArrow",
"LeftDownTeeVector",
"LeftDownVector",
"LeftDownVectorBar",
"LeftRightArrow",
"LeftRightVector",
"LeftTee",
"LeftTeeArrow",
"LeftTeeVector",
"LeftTriangle",
"LeftTriangleBar",
"LeftTriangleEqual",
"LeftUpDownVector",
"LeftUpTeeVector",
"LeftUpVector",
"LeftUpVectorBar",
"LeftVector",
"LeftVectorBar",
"LegendAppearance",
"Legended",
"LegendFunction",
"LegendLabel",
"LegendLayout",
"LegendMargins",
"LegendMarkers",
"LegendMarkerSize",
"LegendreP",
"LegendreQ",
"LegendreType",
"Length",
"LengthWhile",
"LerchPhi",
"Less",
"LessEqual",
"LessEqualGreater",
"LessEqualThan",
"LessFullEqual",
"LessGreater",
"LessLess",
"LessSlantEqual",
"LessThan",
"LessTilde",
"LetterCharacter",
"LetterCounts",
"LetterNumber",
"LetterQ",
"Level",
"LeveneTest",
"LeviCivitaTensor",
"LevyDistribution",
"Lexicographic",
"LexicographicOrder",
"LexicographicSort",
"LibraryDataType",
"LibraryFunction",
"LibraryFunctionDeclaration",
"LibraryFunctionError",
"LibraryFunctionInformation",
"LibraryFunctionLoad",
"LibraryFunctionUnload",
"LibraryLoad",
"LibraryUnload",
"LicenseEntitlementObject",
"LicenseEntitlements",
"LicenseID",
"LicensingSettings",
"LiftingFilterData",
"LiftingWaveletTransform",
"LightBlue",
"LightBrown",
"LightCyan",
"Lighter",
"LightGray",
"LightGreen",
"Lighting",
"LightingAngle",
"LightMagenta",
"LightOrange",
"LightPink",
"LightPurple",
"LightRed",
"LightSources",
"LightYellow",
"Likelihood",
"Limit",
"LimitsPositioning",
"LimitsPositioningTokens",
"LindleyDistribution",
"Line",
"Line3DBox",
"Line3DBoxOptions",
"LinearFilter",
"LinearFractionalOptimization",
"LinearFractionalTransform",
"LinearGradientFilling",
"LinearGradientImage",
"LinearizingTransformationData",
"LinearLayer",
"LinearModelFit",
"LinearOffsetFunction",
"LinearOptimization",
"LinearProgramming",
"LinearRecurrence",
"LinearSolve",
"LinearSolveFunction",
"LineBox",
"LineBoxOptions",
"LineBreak",
"LinebreakAdjustments",
"LineBreakChart",
"LinebreakSemicolonWeighting",
"LineBreakWithin",
"LineColor",
"LineGraph",
"LineIndent",
"LineIndentMaxFraction",
"LineIntegralConvolutionPlot",
"LineIntegralConvolutionScale",
"LineLegend",
"LineOpacity",
"LineSpacing",
"LineWrapParts",
"LinkActivate",
"LinkClose",
"LinkConnect",
"LinkConnectedQ",
"LinkCreate",
"LinkError",
"LinkFlush",
"LinkFunction",
"LinkHost",
"LinkInterrupt",
"LinkLaunch",
"LinkMode",
"LinkObject",
"LinkOpen",
"LinkOptions",
"LinkPatterns",
"LinkProtocol",
"LinkRankCentrality",
"LinkRead",
"LinkReadHeld",
"LinkReadyQ",
"Links",
"LinkService",
"LinkWrite",
"LinkWriteHeld",
"LiouvilleLambda",
"List",
"Listable",
"ListAnimate",
"ListContourPlot",
"ListContourPlot3D",
"ListConvolve",
"ListCorrelate",
"ListCurvePathPlot",
"ListDeconvolve",
"ListDensityPlot",
"ListDensityPlot3D",
"Listen",
"ListFormat",
"ListFourierSequenceTransform",
"ListInterpolation",
"ListLineIntegralConvolutionPlot",
"ListLinePlot",
"ListLinePlot3D",
"ListLogLinearPlot",
"ListLogLogPlot",
"ListLogPlot",
"ListPicker",
"ListPickerBox",
"ListPickerBoxBackground",
"ListPickerBoxOptions",
"ListPlay",
"ListPlot",
"ListPlot3D",
"ListPointPlot3D",
"ListPolarPlot",
"ListQ",
"ListSliceContourPlot3D",
"ListSliceDensityPlot3D",
"ListSliceVectorPlot3D",
"ListStepPlot",
"ListStreamDensityPlot",
"ListStreamPlot",
"ListStreamPlot3D",
"ListSurfacePlot3D",
"ListVectorDensityPlot",
"ListVectorDisplacementPlot",
"ListVectorDisplacementPlot3D",
"ListVectorPlot",
"ListVectorPlot3D",
"ListZTransform",
"Literal",
"LiteralSearch",
"LiteralType",
"LoadCompiledComponent",
"LocalAdaptiveBinarize",
"LocalCache",
"LocalClusteringCoefficient",
"LocalEvaluate",
"LocalizeDefinitions",
"LocalizeVariables",
"LocalObject",
"LocalObjects",
"LocalResponseNormalizationLayer",
"LocalSubmit",
"LocalSymbol",
"LocalTime",
"LocalTimeZone",
"LocationEquivalenceTest",
"LocationTest",
"Locator",
"LocatorAutoCreate",
"LocatorBox",
"LocatorBoxOptions",
"LocatorCentering",
"LocatorPane",
"LocatorPaneBox",
"LocatorPaneBoxOptions",
"LocatorRegion",
"Locked",
"Log",
"Log10",
"Log2",
"LogBarnesG",
"LogGamma",
"LogGammaDistribution",
"LogicalExpand",
"LogIntegral",
"LogisticDistribution",
"LogisticSigmoid",
"LogitModelFit",
"LogLikelihood",
"LogLinearPlot",
"LogLogisticDistribution",
"LogLogPlot",
"LogMultinormalDistribution",
"LogNormalDistribution",
"LogPlot",
"LogRankTest",
"LogSeriesDistribution",
"LongEqual",
"Longest",
"LongestCommonSequence",
"LongestCommonSequencePositions",
"LongestCommonSubsequence",
"LongestCommonSubsequencePositions",
"LongestMatch",
"LongestOrderedSequence",
"LongForm",
"Longitude",
"LongLeftArrow",
"LongLeftRightArrow",
"LongRightArrow",
"LongShortTermMemoryLayer",
"Lookup",
"Loopback",
"LoopFreeGraphQ",
"Looping",
"LossFunction",
"LowerCaseQ",
"LowerLeftArrow",
"LowerRightArrow",
"LowerTriangularize",
"LowerTriangularMatrix",
"LowerTriangularMatrixQ",
"LowpassFilter",
"LQEstimatorGains",
"LQGRegulator",
"LQOutputRegulatorGains",
"LQRegulatorGains",
"LUBackSubstitution",
"LucasL",
"LuccioSamiComponents",
"LUDecomposition",
"LunarEclipse",
"LUVColor",
"LyapunovSolve",
"LyonsGroupLy",
"MachineID",
"MachineName",
"MachineNumberQ",
"MachinePrecision",
"MacintoshSystemPageSetup",
"Magenta",
"Magnification",
"Magnify",
"MailAddressValidation",
"MailExecute",
"MailFolder",
"MailItem",
"MailReceiverFunction",
"MailResponseFunction",
"MailSearch",
"MailServerConnect",
"MailServerConnection",
"MailSettings",
"MainSolve",
"MaintainDynamicCaches",
"Majority",
"MakeBoxes",
"MakeExpression",
"MakeRules",
"ManagedLibraryExpressionID",
"ManagedLibraryExpressionQ",
"MandelbrotSetBoettcher",
"MandelbrotSetDistance",
"MandelbrotSetIterationCount",
"MandelbrotSetMemberQ",
"MandelbrotSetPlot",
"MangoldtLambda",
"ManhattanDistance",
"Manipulate",
"Manipulator",
"MannedSpaceMissionData",
"MannWhitneyTest",
"MantissaExponent",
"Manual",
"Map",
"MapAll",
"MapApply",
"MapAt",
"MapIndexed",
"MAProcess",
"MapThread",
"MarchenkoPasturDistribution",
"MarcumQ",
"MardiaCombinedTest",
"MardiaKurtosisTest",
"MardiaSkewnessTest",
"MarginalDistribution",
"MarkovProcessProperties",
"Masking",
"MassConcentrationCondition",
"MassFluxValue",
"MassImpermeableBoundaryValue",
"MassOutflowValue",
"MassSymmetryValue",
"MassTransferValue",
"MassTransportPDEComponent",
"MatchingDissimilarity",
"MatchLocalNameQ",
"MatchLocalNames",
"MatchQ",
"Material",
"MaterialShading",
"MaternPointProcess",
"MathematicalFunctionData",
"MathematicaNotation",
"MathieuC",
"MathieuCharacteristicA",
"MathieuCharacteristicB",
"MathieuCharacteristicExponent",
"MathieuCPrime",
"MathieuGroupM11",
"MathieuGroupM12",
"MathieuGroupM22",
"MathieuGroupM23",
"MathieuGroupM24",
"MathieuS",
"MathieuSPrime",
"MathMLForm",
"MathMLText",
"Matrices",
"MatrixExp",
"MatrixForm",
"MatrixFunction",
"MatrixLog",
"MatrixNormalDistribution",
"MatrixPlot",
"MatrixPower",
"MatrixPropertyDistribution",
"MatrixQ",
"MatrixRank",
"MatrixTDistribution",
"Max",
"MaxBend",
"MaxCellMeasure",
"MaxColorDistance",
"MaxDate",
"MaxDetect",
"MaxDisplayedChildren",
"MaxDuration",
"MaxExtraBandwidths",
"MaxExtraConditions",
"MaxFeatureDisplacement",
"MaxFeatures",
"MaxFilter",
"MaximalBy",
"Maximize",
"MaxItems",
"MaxIterations",
"MaxLimit",
"MaxMemoryUsed",
"MaxMixtureKernels",
"MaxOverlapFraction",
"MaxPlotPoints",
"MaxPoints",
"MaxRecursion",
"MaxStableDistribution",
"MaxStepFraction",
"MaxSteps",
"MaxStepSize",
"MaxTrainingRounds",
"MaxValue",
"MaxwellDistribution",
"MaxWordGap",
"McLaughlinGroupMcL",
"Mean",
"MeanAbsoluteLossLayer",
"MeanAround",
"MeanClusteringCoefficient",
"MeanDegreeConnectivity",
"MeanDeviation",
"MeanFilter",
"MeanGraphDistance",
"MeanNeighborDegree",
"MeanPointDensity",
"MeanShift",
"MeanShiftFilter",
"MeanSquaredLossLayer",
"Median",
"MedianDeviation",
"MedianFilter",
"MedicalTestData",
"Medium",
"MeijerG",
"MeijerGReduce",
"MeixnerDistribution",
"MellinConvolve",
"MellinTransform",
"MemberQ",
"MemoryAvailable",
"MemoryConstrained",
"MemoryConstraint",
"MemoryInUse",
"MengerMesh",
"Menu",
"MenuAppearance",
"MenuCommandKey",
"MenuEvaluator",
"MenuItem",
"MenuList",
"MenuPacket",
"MenuSortingValue",
"MenuStyle",
"MenuView",
"Merge",
"MergeDifferences",
"MergingFunction",
"MersennePrimeExponent",
"MersennePrimeExponentQ",
"Mesh",
"MeshCellCentroid",
"MeshCellCount",
"MeshCellHighlight",
"MeshCellIndex",
"MeshCellLabel",
"MeshCellMarker",
"MeshCellMeasure",
"MeshCellQuality",
"MeshCells",
"MeshCellShapeFunction",
"MeshCellStyle",
"MeshConnectivityGraph",
"MeshCoordinates",
"MeshFunctions",
"MeshPrimitives",
"MeshQualityGoal",
"MeshRange",
"MeshRefinementFunction",
"MeshRegion",
"MeshRegionQ",
"MeshShading",
"MeshStyle",
"Message",
"MessageDialog",
"MessageList",
"MessageName",
"MessageObject",
"MessageOptions",
"MessagePacket",
"Messages",
"MessagesNotebook",
"MetaCharacters",
"MetaInformation",
"MeteorShowerData",
"Method",
"MethodOptions",
"MexicanHatWavelet",
"MeyerWavelet",
"Midpoint",
"MIMETypeToFormatList",
"Min",
"MinColorDistance",
"MinDate",
"MinDetect",
"MineralData",
"MinFilter",
"MinimalBy",
"MinimalPolynomial",
"MinimalStateSpaceModel",
"Minimize",
"MinimumTimeIncrement",
"MinIntervalSize",
"MinkowskiQuestionMark",
"MinLimit",
"MinMax",
"MinorPlanetData",
"Minors",
"MinPointSeparation",
"MinRecursion",
"MinSize",
"MinStableDistribution",
"Minus",
"MinusPlus",
"MinValue",
"Missing",
"MissingBehavior",
"MissingDataMethod",
"MissingDataRules",
"MissingQ",
"MissingString",
"MissingStyle",
"MissingValuePattern",
"MissingValueSynthesis",
"MittagLefflerE",
"MixedFractionParts",
"MixedGraphQ",
"MixedMagnitude",
"MixedRadix",
"MixedRadixQuantity",
"MixedUnit",
"MixtureDistribution",
"Mod",
"Modal",
"Mode",
"ModelPredictiveController",
"Modular",
"ModularInverse",
"ModularLambda",
"Module",
"Modulus",
"MoebiusMu",
"Molecule",
"MoleculeAlign",
"MoleculeContainsQ",
"MoleculeDraw",
"MoleculeEquivalentQ",
"MoleculeFreeQ",
"MoleculeGraph",
"MoleculeMatchQ",
"MoleculeMaximumCommonSubstructure",
"MoleculeModify",
"MoleculeName",
"MoleculePattern",
"MoleculePlot",
"MoleculePlot3D",
"MoleculeProperty",
"MoleculeQ",
"MoleculeRecognize",
"MoleculeSubstructureCount",
"MoleculeValue",
"Moment",
"MomentConvert",
"MomentEvaluate",
"MomentGeneratingFunction",
"MomentOfInertia",
"Monday",
"Monitor",
"MonomialList",
"MonomialOrder",
"MonsterGroupM",
"MoonPhase",
"MoonPosition",
"MorletWavelet",
"MorphologicalBinarize",
"MorphologicalBranchPoints",
"MorphologicalComponents",
"MorphologicalEulerNumber",
"MorphologicalGraph",
"MorphologicalPerimeter",
"MorphologicalTransform",
"MortalityData",
"Most",
"MountainData",
"MouseAnnotation",
"MouseAppearance",
"MouseAppearanceTag",
"MouseButtons",
"Mouseover",
"MousePointerNote",
"MousePosition",
"MovieData",
"MovingAverage",
"MovingMap",
"MovingMedian",
"MoyalDistribution",
"MultiaxisArrangement",
"Multicolumn",
"MultiedgeStyle",
"MultigraphQ",
"MultilaunchWarning",
"MultiLetterItalics",
"MultiLetterStyle",
"MultilineFunction",
"Multinomial",
"MultinomialDistribution",
"MultinormalDistribution",
"MultiplicativeOrder",
"Multiplicity",
"MultiplySides",
"MultiscriptBoxOptions",
"Multiselection",
"MultivariateHypergeometricDistribution",
"MultivariatePoissonDistribution",
"MultivariateTDistribution",
"N",
"NakagamiDistribution",
"NameQ",
"Names",
"NamespaceBox",
"NamespaceBoxOptions",
"Nand",
"NArgMax",
"NArgMin",
"NBernoulliB",
"NBodySimulation",
"NBodySimulationData",
"NCache",
"NCaputoD",
"NDEigensystem",
"NDEigenvalues",
"NDSolve",
"NDSolveValue",
"Nearest",
"NearestFunction",
"NearestMeshCells",
"NearestNeighborG",
"NearestNeighborGraph",
"NearestTo",
"NebulaData",
"NeedlemanWunschSimilarity",
"Needs",
"Negative",
"NegativeBinomialDistribution",
"NegativeDefiniteMatrixQ",
"NegativeIntegers",
"NegativelyOrientedPoints",
"NegativeMultinomialDistribution",
"NegativeRationals",
"NegativeReals",
"NegativeSemidefiniteMatrixQ",
"NeighborhoodData",
"NeighborhoodGraph",
"Nest",
"NestedGreaterGreater",
"NestedLessLess",
"NestedScriptRules",
"NestGraph",
"NestList",
"NestTree",
"NestWhile",
"NestWhileList",
"NetAppend",
"NetArray",
"NetArrayLayer",
"NetBidirectionalOperator",
"NetChain",
"NetDecoder",
"NetDelete",
"NetDrop",
"NetEncoder",
"NetEvaluationMode",
"NetExternalObject",
"NetExtract",
"NetFlatten",
"NetFoldOperator",
"NetGANOperator",
"NetGraph",
"NetInformation",
"NetInitialize",
"NetInsert",
"NetInsertSharedArrays",
"NetJoin",
"NetMapOperator",
"NetMapThreadOperator",
"NetMeasurements",
"NetModel",
"NetNestOperator",
"NetPairEmbeddingOperator",
"NetPort",
"NetPortGradient",
"NetPrepend",
"NetRename",
"NetReplace",
"NetReplacePart",
"NetSharedArray",
"NetStateObject",
"NetTake",
"NetTrain",
"NetTrainResultsObject",
"NetUnfold",
"NetworkPacketCapture",
"NetworkPacketRecording",
"NetworkPacketRecordingDuring",
"NetworkPacketTrace",
"NeumannValue",
"NevilleThetaC",
"NevilleThetaD",
"NevilleThetaN",
"NevilleThetaS",
"NewPrimitiveStyle",
"NExpectation",
"Next",
"NextCell",
"NextDate",
"NextPrime",
"NextScheduledTaskTime",
"NeymanScottPointProcess",
"NFractionalD",
"NHoldAll",
"NHoldFirst",
"NHoldRest",
"NicholsGridLines",
"NicholsPlot",
"NightHemisphere",
"NIntegrate",
"NMaximize",
"NMaxValue",
"NMinimize",
"NMinValue",
"NominalScale",
"NominalVariables",
"NonAssociative",
"NoncentralBetaDistribution",
"NoncentralChiSquareDistribution",
"NoncentralFRatioDistribution",
"NoncentralStudentTDistribution",
"NonCommutativeMultiply",
"NonConstants",
"NondimensionalizationTransform",
"None",
"NoneTrue",
"NonlinearModelFit",
"NonlinearStateSpaceModel",
"NonlocalMeansFilter",
"NonNegative",
"NonNegativeIntegers",
"NonNegativeRationals",
"NonNegativeReals",
"NonPositive",
"NonPositiveIntegers",
"NonPositiveRationals",
"NonPositiveReals",
"Nor",
"NorlundB",
"Norm",
"Normal",
"NormalDistribution",
"NormalGrouping",
"NormalizationLayer",
"Normalize",
"Normalized",
"NormalizedSquaredEuclideanDistance",
"NormalMatrixQ",
"NormalsFunction",
"NormFunction",
"Not",
"NotCongruent",
"NotCupCap",
"NotDoubleVerticalBar",
"Notebook",
"NotebookApply",
"NotebookAutoSave",
"NotebookBrowseDirectory",
"NotebookClose",
"NotebookConvertSettings",
"NotebookCreate",
"NotebookDefault",
"NotebookDelete",
"NotebookDirectory",
"NotebookDynamicExpression",
"NotebookEvaluate",
"NotebookEventActions",
"NotebookFileName",
"NotebookFind",
"NotebookGet",
"NotebookImport",
"NotebookInformation",
"NotebookInterfaceObject",
"NotebookLocate",
"NotebookObject",
"NotebookOpen",
"NotebookPath",
"NotebookPrint",
"NotebookPut",
"NotebookRead",
"Notebooks",
"NotebookSave",
"NotebookSelection",
"NotebooksMenu",
"NotebookTemplate",
"NotebookWrite",
"NotElement",
"NotEqualTilde",
"NotExists",
"NotGreater",
"NotGreaterEqual",
"NotGreaterFullEqual",
"NotGreaterGreater",
"NotGreaterLess",
"NotGreaterSlantEqual",
"NotGreaterTilde",
"Nothing",
"NotHumpDownHump",
"NotHumpEqual",
"NotificationFunction",
"NotLeftTriangle",
"NotLeftTriangleBar",
"NotLeftTriangleEqual",
"NotLess",
"NotLessEqual",
"NotLessFullEqual",
"NotLessGreater",
"NotLessLess",
"NotLessSlantEqual",
"NotLessTilde",
"NotNestedGreaterGreater",
"NotNestedLessLess",
"NotPrecedes",
"NotPrecedesEqual",
"NotPrecedesSlantEqual",
"NotPrecedesTilde",
"NotReverseElement",
"NotRightTriangle",
"NotRightTriangleBar",
"NotRightTriangleEqual",
"NotSquareSubset",
"NotSquareSubsetEqual",
"NotSquareSuperset",
"NotSquareSupersetEqual",
"NotSubset",
"NotSubsetEqual",
"NotSucceeds",
"NotSucceedsEqual",
"NotSucceedsSlantEqual",
"NotSucceedsTilde",
"NotSuperset",
"NotSupersetEqual",
"NotTilde",
"NotTildeEqual",
"NotTildeFullEqual",
"NotTildeTilde",
"NotVerticalBar",
"Now",
"NoWhitespace",
"NProbability",
"NProduct",
"NProductFactors",
"NRoots",
"NSolve",
"NSolveValues",
"NSum",
"NSumTerms",
"NuclearExplosionData",
"NuclearReactorData",
"Null",
"NullRecords",
"NullSpace",
"NullWords",
"Number",
"NumberCompose",
"NumberDecompose",
"NumberDigit",
"NumberExpand",
"NumberFieldClassNumber",
"NumberFieldDiscriminant",
"NumberFieldFundamentalUnits",
"NumberFieldIntegralBasis",
"NumberFieldNormRepresentatives",
"NumberFieldRegulator",
"NumberFieldRootsOfUnity",
"NumberFieldSignature",
"NumberForm",
"NumberFormat",
"NumberLinePlot",
"NumberMarks",
"NumberMultiplier",
"NumberPadding",
"NumberPoint",
"NumberQ",
"NumberSeparator",
"NumberSigns",
"NumberString",
"Numerator",
"NumeratorDenominator",
"NumericalOrder",
"NumericalSort",
"NumericArray",
"NumericArrayQ",
"NumericArrayType",
"NumericFunction",
"NumericQ",
"NuttallWindow",
"NValues",
"NyquistGridLines",
"NyquistPlot",
"O",
"ObjectExistsQ",
"ObservabilityGramian",
"ObservabilityMatrix",
"ObservableDecomposition",
"ObservableModelQ",
"OceanData",
"Octahedron",
"OddQ",
"Off",
"Offset",
"OLEData",
"On",
"ONanGroupON",
"Once",
"OneIdentity",
"Opacity",
"OpacityFunction",
"OpacityFunctionScaling",
"Open",
"OpenAppend",
"Opener",
"OpenerBox",
"OpenerBoxOptions",
"OpenerView",
"OpenFunctionInspectorPacket",
"Opening",
"OpenRead",
"OpenSpecialOptions",
"OpenTemporary",
"OpenWrite",
"Operate",
"OperatingSystem",
"OperatorApplied",
"OptimumFlowData",
"Optional",
"OptionalElement",
"OptionInspectorSettings",
"OptionQ",
"Options",
"OptionsPacket",
"OptionsPattern",
"OptionValue",
"OptionValueBox",
"OptionValueBoxOptions",
"Or",
"Orange",
"Order",
"OrderDistribution",
"OrderedQ",
"Ordering",
"OrderingBy",
"OrderingLayer",
"Orderless",
"OrderlessPatternSequence",
"OrdinalScale",
"OrnsteinUhlenbeckProcess",
"Orthogonalize",
"OrthogonalMatrixQ",
"Out",
"Outer",
"OuterPolygon",
"OuterPolyhedron",
"OutputAutoOverwrite",
"OutputControllabilityMatrix",
"OutputControllableModelQ",
"OutputForm",
"OutputFormData",
"OutputGrouping",
"OutputMathEditExpression",
"OutputNamePacket",
"OutputPorts",
"OutputResponse",
"OutputSizeLimit",
"OutputStream",
"Over",
"OverBar",
"OverDot",
"Overflow",
"OverHat",
"Overlaps",
"Overlay",
"OverlayBox",
"OverlayBoxOptions",
"OverlayVideo",
"Overscript",
"OverscriptBox",
"OverscriptBoxOptions",
"OverTilde",
"OverVector",
"OverwriteTarget",
"OwenT",
"OwnValues",
"Package",
"PackingMethod",
"PackPaclet",
"PacletDataRebuild",
"PacletDirectoryAdd",
"PacletDirectoryLoad",
"PacletDirectoryRemove",
"PacletDirectoryUnload",
"PacletDisable",
"PacletEnable",
"PacletFind",
"PacletFindRemote",
"PacletInformation",
"PacletInstall",
"PacletInstallSubmit",
"PacletNewerQ",
"PacletObject",
"PacletObjectQ",
"PacletSite",
"PacletSiteObject",
"PacletSiteRegister",
"PacletSites",
"PacletSiteUnregister",
"PacletSiteUpdate",
"PacletSymbol",
"PacletUninstall",
"PacletUpdate",
"PaddedForm",
"Padding",
"PaddingLayer",
"PaddingSize",
"PadeApproximant",
"PadLeft",
"PadRight",
"PageBreakAbove",
"PageBreakBelow",
"PageBreakWithin",
"PageFooterLines",
"PageFooters",
"PageHeaderLines",
"PageHeaders",
"PageHeight",
"PageRankCentrality",
"PageTheme",
"PageWidth",
"Pagination",
"PairCorrelationG",
"PairedBarChart",
"PairedHistogram",
"PairedSmoothHistogram",
"PairedTTest",
"PairedZTest",
"PaletteNotebook",
"PalettePath",
"PalettesMenuSettings",
"PalindromeQ",
"Pane",
"PaneBox",
"PaneBoxOptions",
"Panel",
"PanelBox",
"PanelBoxOptions",
"Paneled",
"PaneSelector",
"PaneSelectorBox",
"PaneSelectorBoxOptions",
"PaperWidth",
"ParabolicCylinderD",
"ParagraphIndent",
"ParagraphSpacing",
"ParallelArray",
"ParallelAxisPlot",
"ParallelCombine",
"ParallelDo",
"Parallelepiped",
"ParallelEvaluate",
"Parallelization",
"Parallelize",
"ParallelKernels",
"ParallelMap",
"ParallelNeeds",
"Parallelogram",
"ParallelProduct",
"ParallelSubmit",
"ParallelSum",
"ParallelTable",
"ParallelTry",
"Parameter",
"ParameterEstimator",
"ParameterMixtureDistribution",
"ParameterVariables",
"ParametricConvexOptimization",
"ParametricFunction",
"ParametricNDSolve",
"ParametricNDSolveValue",
"ParametricPlot",
"ParametricPlot3D",
"ParametricRampLayer",
"ParametricRegion",
"ParentBox",
"ParentCell",
"ParentConnect",
"ParentDirectory",
"ParentEdgeLabel",
"ParentEdgeLabelFunction",
"ParentEdgeLabelStyle",
"ParentEdgeShapeFunction",
"ParentEdgeStyle",
"ParentEdgeStyleFunction",
"ParentForm",
"Parenthesize",
"ParentList",
"ParentNotebook",
"ParetoDistribution",
"ParetoPickandsDistribution",
"ParkData",
"Part",
"PartBehavior",
"PartialCorrelationFunction",
"PartialD",
"ParticleAcceleratorData",
"ParticleData",
"Partition",
"PartitionGranularity",
"PartitionsP",
"PartitionsQ",
"PartLayer",
"PartOfSpeech",
"PartProtection",
"ParzenWindow",
"PascalDistribution",
"PassEventsDown",
"PassEventsUp",
"Paste",
"PasteAutoQuoteCharacters",
"PasteBoxFormInlineCells",
"PasteButton",
"Path",
"PathGraph",
"PathGraphQ",
"Pattern",
"PatternFilling",
"PatternReaction",
"PatternSequence",
"PatternTest",
"PauliMatrix",
"PaulWavelet",
"Pause",
"PausedTime",
"PDF",
"PeakDetect",
"PeanoCurve",
"PearsonChiSquareTest",
"PearsonCorrelationTest",
"PearsonDistribution",
"PenttinenPointProcess",
"PercentForm",
"PerfectNumber",
"PerfectNumberQ",
"PerformanceGoal",
"Perimeter",
"PeriodicBoundaryCondition",
"PeriodicInterpolation",
"Periodogram",
"PeriodogramArray",
"Permanent",
"Permissions",
"PermissionsGroup",
"PermissionsGroupMemberQ",
"PermissionsGroups",
"PermissionsKey",
"PermissionsKeys",
"PermutationCycles",
"PermutationCyclesQ",
"PermutationGroup",
"PermutationLength",
"PermutationList",
"PermutationListQ",
"PermutationMatrix",
"PermutationMax",
"PermutationMin",
"PermutationOrder",
"PermutationPower",
"PermutationProduct",
"PermutationReplace",
"Permutations",
"PermutationSupport",
"Permute",
"PeronaMalikFilter",
"Perpendicular",
"PerpendicularBisector",
"PersistenceLocation",
"PersistenceTime",
"PersistentObject",
"PersistentObjects",
"PersistentSymbol",
"PersistentValue",
"PersonData",
"PERTDistribution",
"PetersenGraph",
"PhaseMargins",
"PhaseRange",
"PhongShading",
"PhysicalSystemData",
"Pi",
"Pick",
"PickedElements",
"PickMode",
"PIDData",
"PIDDerivativeFilter",
"PIDFeedforward",
"PIDTune",
"Piecewise",
"PiecewiseExpand",
"PieChart",
"PieChart3D",
"PillaiTrace",
"PillaiTraceTest",
"PingTime",
"Pink",
"PitchRecognize",
"Pivoting",
"PixelConstrained",
"PixelValue",
"PixelValuePositions",
"Placed",
"Placeholder",
"PlaceholderLayer",
"PlaceholderReplace",
"Plain",
"PlanarAngle",
"PlanarFaceList",
"PlanarGraph",
"PlanarGraphQ",
"PlanckRadiationLaw",
"PlaneCurveData",
"PlanetaryMoonData",
"PlanetData",
"PlantData",
"Play",
"PlaybackSettings",
"PlayRange",
"Plot",
"Plot3D",
"Plot3Matrix",
"PlotDivision",
"PlotJoined",
"PlotLabel",
"PlotLabels",
"PlotLayout",
"PlotLegends",
"PlotMarkers",
"PlotPoints",
"PlotRange",
"PlotRangeClipping",
"PlotRangeClipPlanesStyle",
"PlotRangePadding",
"PlotRegion",
"PlotStyle",
"PlotTheme",
"Pluralize",
"Plus",
"PlusMinus",
"Pochhammer",
"PodStates",
"PodWidth",
"Point",
"Point3DBox",
"Point3DBoxOptions",
"PointBox",
"PointBoxOptions",
"PointCountDistribution",
"PointDensity",
"PointDensityFunction",
"PointFigureChart",
"PointLegend",
"PointLight",
"PointProcessEstimator",
"PointProcessFitTest",
"PointProcessParameterAssumptions",
"PointProcessParameterQ",
"PointSize",
"PointStatisticFunction",
"PointValuePlot",
"PoissonConsulDistribution",
"PoissonDistribution",
"PoissonPDEComponent",
"PoissonPointProcess",
"PoissonProcess",
"PoissonWindow",
"PolarAxes",
"PolarAxesOrigin",
"PolarGridLines",
"PolarPlot",
"PolarTicks",
"PoleZeroMarkers",
"PolyaAeppliDistribution",
"PolyGamma",
"Polygon",
"Polygon3DBox",
"Polygon3DBoxOptions",
"PolygonalNumber",
"PolygonAngle",
"PolygonBox",
"PolygonBoxOptions",
"PolygonCoordinates",
"PolygonDecomposition",
"PolygonHoleScale",
"PolygonIntersections",
"PolygonScale",
"Polyhedron",
"PolyhedronAngle",
"PolyhedronBox",
"PolyhedronBoxOptions",
"PolyhedronCoordinates",
"PolyhedronData",
"PolyhedronDecomposition",
"PolyhedronGenus",
"PolyLog",
"PolynomialExpressionQ",
"PolynomialExtendedGCD",
"PolynomialForm",
"PolynomialGCD",
"PolynomialLCM",
"PolynomialMod",
"PolynomialQ",
"PolynomialQuotient",
"PolynomialQuotientRemainder",
"PolynomialReduce",
"PolynomialRemainder",
"Polynomials",
"PolynomialSumOfSquaresList",
"PoolingLayer",
"PopupMenu",
"PopupMenuBox",
"PopupMenuBoxOptions",
"PopupView",
"PopupWindow",
"Position",
"PositionIndex",
"PositionLargest",
"PositionSmallest",
"Positive",
"PositiveDefiniteMatrixQ",
"PositiveIntegers",
"PositivelyOrientedPoints",
"PositiveRationals",
"PositiveReals",
"PositiveSemidefiniteMatrixQ",
"PossibleZeroQ",
"Postfix",
"PostScript",
"Power",
"PowerDistribution",
"PowerExpand",
"PowerMod",
"PowerModList",
"PowerRange",
"PowerSpectralDensity",
"PowersRepresentations",
"PowerSymmetricPolynomial",
"Precedence",
"PrecedenceForm",
"Precedes",
"PrecedesEqual",
"PrecedesSlantEqual",
"PrecedesTilde",
"Precision",
"PrecisionGoal",
"PreDecrement",
"Predict",
"PredictionRoot",
"PredictorFunction",
"PredictorInformation",
"PredictorMeasurements",
"PredictorMeasurementsObject",
"PreemptProtect",
"PreferencesPath",
"PreferencesSettings",
"Prefix",
"PreIncrement",
"Prepend",
"PrependLayer",
"PrependTo",
"PreprocessingRules",
"PreserveColor",
"PreserveImageOptions",
"Previous",
"PreviousCell",
"PreviousDate",
"PriceGraphDistribution",
"PrimaryPlaceholder",
"Prime",
"PrimeNu",
"PrimeOmega",
"PrimePi",
"PrimePowerQ",
"PrimeQ",
"Primes",
"PrimeZetaP",
"PrimitivePolynomialQ",
"PrimitiveRoot",
"PrimitiveRootList",
"PrincipalComponents",
"PrincipalValue",
"Print",
"PrintableASCIIQ",
"PrintAction",
"PrintForm",
"PrintingCopies",
"PrintingOptions",
"PrintingPageRange",
"PrintingStartingPageNumber",
"PrintingStyleEnvironment",
"Printout3D",
"Printout3DPreviewer",
"PrintPrecision",
"PrintTemporary",
"Prism",
"PrismBox",
"PrismBoxOptions",
"PrivateCellOptions",
"PrivateEvaluationOptions",
"PrivateFontOptions",
"PrivateFrontEndOptions",
"PrivateKey",
"PrivateNotebookOptions",
"PrivatePaths",
"Probability",
"ProbabilityDistribution",
"ProbabilityPlot",
"ProbabilityPr",
"ProbabilityScalePlot",
"ProbitModelFit",
"ProcessConnection",
"ProcessDirectory",
"ProcessEnvironment",
"Processes",
"ProcessEstimator",
"ProcessInformation",
"ProcessObject",
"ProcessParameterAssumptions",
"ProcessParameterQ",
"ProcessStateDomain",
"ProcessStatus",
"ProcessTimeDomain",
"Product",
"ProductDistribution",
"ProductLog",
"ProgressIndicator",
"ProgressIndicatorBox",
"ProgressIndicatorBoxOptions",
"ProgressReporting",
"Projection",
"Prolog",
"PromptForm",
"ProofObject",
"PropagateAborts",
"Properties",
"Property",
"PropertyList",
"PropertyValue",
"Proportion",
"Proportional",
"Protect",
"Protected",
"ProteinData",
"Pruning",
"PseudoInverse",
"PsychrometricPropertyData",
"PublicKey",
"PublisherID",
"PulsarData",
"PunctuationCharacter",
"Purple",
"Put",
"PutAppend",
"Pyramid",
"PyramidBox",
"PyramidBoxOptions",
"QBinomial",
"QFactorial",
"QGamma",
"QHypergeometricPFQ",
"QnDispersion",
"QPochhammer",
"QPolyGamma",
"QRDecomposition",
"QuadraticIrrationalQ",
"QuadraticOptimization",
"Quantile",
"QuantilePlot",
"Quantity",
"QuantityArray",
"QuantityDistribution",
"QuantityForm",
"QuantityMagnitude",
"QuantityQ",
"QuantityUnit",
"QuantityVariable",
"QuantityVariableCanonicalUnit",
"QuantityVariableDimensions",
"QuantityVariableIdentifier",
"QuantityVariablePhysicalQuantity",
"Quartics",
"QuartileDeviation",
"Quartiles",
"QuartileSkewness",
"Query",
"QuestionGenerator",
"QuestionInterface",
"QuestionObject",
"QuestionSelector",
"QueueingNetworkProcess",
"QueueingProcess",
"QueueProperties",
"Quiet",
"QuietEcho",
"Quit",
"Quotient",
"QuotientRemainder",
"RadialAxisPlot",
"RadialGradientFilling",
"RadialGradientImage",
"RadialityCentrality",
"RadicalBox",
"RadicalBoxOptions",
"RadioButton",
"RadioButtonBar",
"RadioButtonBox",
"RadioButtonBoxOptions",
"Radon",
"RadonTransform",
"RamanujanTau",
"RamanujanTauL",
"RamanujanTauTheta",
"RamanujanTauZ",
"Ramp",
"Random",
"RandomArrayLayer",
"RandomChoice",
"RandomColor",
"RandomComplex",
"RandomDate",
"RandomEntity",
"RandomFunction",
"RandomGeneratorState",
"RandomGeoPosition",
"RandomGraph",
"RandomImage",
"RandomInstance",
"RandomInteger",
"RandomPermutation",
"RandomPoint",
"RandomPointConfiguration",
"RandomPolygon",
"RandomPolyhedron",
"RandomPrime",
"RandomReal",
"RandomSample",
"RandomSeed",
"RandomSeeding",
"RandomTime",
"RandomTree",
"RandomVariate",
"RandomWalkProcess",
"RandomWord",
"Range",
"RangeFilter",
"RangeSpecification",
"RankedMax",
"RankedMin",
"RarerProbability",
"Raster",
"Raster3D",
"Raster3DBox",
"Raster3DBoxOptions",
"RasterArray",
"RasterBox",
"RasterBoxOptions",
"Rasterize",
"RasterSize",
"Rational",
"RationalExpressionQ",
"RationalFunctions",
"Rationalize",
"Rationals",
"Ratios",
"RawArray",
"RawBoxes",
"RawData",
"RawMedium",
"RayleighDistribution",
"Re",
"ReactionBalance",
"ReactionBalancedQ",
"ReactionPDETerm",
"Read",
"ReadByteArray",
"ReadLine",
"ReadList",
"ReadProtected",
"ReadString",
"Real",
"RealAbs",
"RealBlockDiagonalForm",
"RealDigits",
"RealExponent",
"Reals",
"RealSign",
"Reap",
"RebuildPacletData",
"RecalibrationFunction",
"RecognitionPrior",
"RecognitionThreshold",
"ReconstructionMesh",
"Record",
"RecordLists",
"RecordSeparators",
"Rectangle",
"RectangleBox",
"RectangleBoxOptions",
"RectangleChart",
"RectangleChart3D",
"RectangularRepeatingElement",
"RecurrenceFilter",
"RecurrenceTable",
"RecurringDigitsForm",
"Red",
"Reduce",
"RefBox",
"ReferenceLineStyle",
"ReferenceMarkers",
"ReferenceMarkerStyle",
"Refine",
"ReflectionMatrix",
"ReflectionTransform",
"Refresh",
"RefreshRate",
"Region",
"RegionBinarize",
"RegionBoundary",
"RegionBoundaryStyle",
"RegionBounds",
"RegionCentroid",
"RegionCongruent",
"RegionConvert",
"RegionDifference",
"RegionDilation",
"RegionDimension",
"RegionDisjoint",
"RegionDistance",
"RegionDistanceFunction",
"RegionEmbeddingDimension",
"RegionEqual",
"RegionErosion",
"RegionFillingStyle",
"RegionFit",
"RegionFunction",
"RegionImage",
"RegionIntersection",
"RegionMeasure",
"RegionMember",
"RegionMemberFunction",
"RegionMoment",
"RegionNearest",
"RegionNearestFunction",
"RegionPlot",
"RegionPlot3D",
"RegionProduct",
"RegionQ",
"RegionResize",
"RegionSimilar",
"RegionSize",
"RegionSymmetricDifference",
"RegionUnion",
"RegionWithin",
"RegisterExternalEvaluator",
"RegularExpression",
"Regularization",
"RegularlySampledQ",
"RegularPolygon",
"ReIm",
"ReImLabels",
"ReImPlot",
"ReImStyle",
"Reinstall",
"RelationalDatabase",
"RelationGraph",
"Release",
"ReleaseHold",
"ReliabilityDistribution",
"ReliefImage",
"ReliefPlot",
"RemoteAuthorizationCaching",
"RemoteBatchJobAbort",
"RemoteBatchJobObject",
"RemoteBatchJobs",
"RemoteBatchMapSubmit",
"RemoteBatchSubmissionEnvironment",
"RemoteBatchSubmit",
"RemoteConnect",
"RemoteConnectionObject",
"RemoteEvaluate",
"RemoteFile",
"RemoteInputFiles",
"RemoteKernelObject",
"RemoteProviderSettings",
"RemoteRun",
"RemoteRunProcess",
"RemovalConditions",
"Remove",
"RemoveAlphaChannel",
"RemoveAsynchronousTask",
"RemoveAudioStream",
"RemoveBackground",
"RemoveChannelListener",
"RemoveChannelSubscribers",
"Removed",
"RemoveDiacritics",
"RemoveInputStreamMethod",
"RemoveOutputStreamMethod",
"RemoveProperty",
"RemoveScheduledTask",
"RemoveUsers",
"RemoveVideoStream",
"RenameDirectory",
"RenameFile",
"RenderAll",
"RenderingOptions",
"RenewalProcess",
"RenkoChart",
"RepairMesh",
"Repeated",
"RepeatedNull",
"RepeatedString",
"RepeatedTiming",
"RepeatingElement",
"Replace",
"ReplaceAll",
"ReplaceAt",
"ReplaceHeldPart",
"ReplaceImageValue",
"ReplaceList",
"ReplacePart",
"ReplacePixelValue",
"ReplaceRepeated",
"ReplicateLayer",
"RequiredPhysicalQuantities",
"Resampling",
"ResamplingAlgorithmData",
"ResamplingMethod",
"Rescale",
"RescalingTransform",
"ResetDirectory",
"ResetScheduledTask",
"ReshapeLayer",
"Residue",
"ResidueSum",
"ResizeLayer",
"Resolve",
"ResolveContextAliases",
"ResourceAcquire",
"ResourceData",
"ResourceFunction",
"ResourceObject",
"ResourceRegister",
"ResourceRemove",
"ResourceSearch",
"ResourceSubmissionObject",
"ResourceSubmit",
"ResourceSystemBase",
"ResourceSystemPath",
"ResourceUpdate",
"ResourceVersion",
"ResponseForm",
"Rest",
"RestartInterval",
"Restricted",
"Resultant",
"ResumePacket",
"Return",
"ReturnCreatesNewCell",
"ReturnEntersInput",
"ReturnExpressionPacket",
"ReturnInputFormPacket",
"ReturnPacket",
"ReturnReceiptFunction",
"ReturnTextPacket",
"Reverse",
"ReverseApplied",
"ReverseBiorthogonalSplineWavelet",
"ReverseElement",
"ReverseEquilibrium",
"ReverseGraph",
"ReverseSort",
"ReverseSortBy",
"ReverseUpEquilibrium",
"RevolutionAxis",
"RevolutionPlot3D",
"RGBColor",
"RiccatiSolve",
"RiceDistribution",
"RidgeFilter",
"RiemannR",
"RiemannSiegelTheta",
"RiemannSiegelZ",
"RiemannXi",
"Riffle",
"Right",
"RightArrow",
"RightArrowBar",
"RightArrowLeftArrow",
"RightComposition",
"RightCosetRepresentative",
"RightDownTeeVector",
"RightDownVector",
"RightDownVectorBar",
"RightTee",
"RightTeeArrow",
"RightTeeVector",
"RightTriangle",
"RightTriangleBar",
"RightTriangleEqual",
"RightUpDownVector",
"RightUpTeeVector",
"RightUpVector",
"RightUpVectorBar",
"RightVector",
"RightVectorBar",
"RipleyK",
"RipleyRassonRegion",
"RiskAchievementImportance",
"RiskReductionImportance",
"RobustConvexOptimization",
"RogersTanimotoDissimilarity",
"RollPitchYawAngles",
"RollPitchYawMatrix",
"RomanNumeral",
"Root",
"RootApproximant",
"RootIntervals",
"RootLocusPlot",
"RootMeanSquare",
"RootOfUnityQ",
"RootReduce",
"Roots",
"RootSum",
"RootTree",
"Rotate",
"RotateLabel",
"RotateLeft",
"RotateRight",
"RotationAction",
"RotationBox",
"RotationBoxOptions",
"RotationMatrix",
"RotationTransform",
"Round",
"RoundImplies",
"RoundingRadius",
"Row",
"RowAlignments",
"RowBackgrounds",
"RowBox",
"RowHeights",
"RowLines",
"RowMinHeight",
"RowReduce",
"RowsEqual",
"RowSpacings",
"RSolve",
"RSolveValue",
"RudinShapiro",
"RudvalisGroupRu",
"Rule",
"RuleCondition",
"RuleDelayed",
"RuleForm",
"RulePlot",
"RulerUnits",
"RulesTree",
"Run",
"RunProcess",
"RunScheduledTask",
"RunThrough",
"RuntimeAttributes",
"RuntimeOptions",
"RussellRaoDissimilarity",
"SameAs",
"SameQ",
"SameTest",
"SameTestProperties",
"SampledEntityClass",
"SampleDepth",
"SampledSoundFunction",
"SampledSoundList",
"SampleRate",
"SamplingPeriod",
"SARIMAProcess",
"SARMAProcess",
"SASTriangle",
"SatelliteData",
"SatisfiabilityCount",
"SatisfiabilityInstances",
"SatisfiableQ",
"Saturday",
"Save",
"Saveable",
"SaveAutoDelete",
"SaveConnection",
"SaveDefinitions",
"SavitzkyGolayMatrix",
"SawtoothWave",
"Scale",
"Scaled",
"ScaleDivisions",
"ScaledMousePosition",
"ScaleOrigin",
"ScalePadding",
"ScaleRanges",
"ScaleRangeStyle",
"ScalingFunctions",
"ScalingMatrix",
"ScalingTransform",
"Scan",
"ScheduledTask",
"ScheduledTaskActiveQ",
"ScheduledTaskInformation",
"ScheduledTaskInformationData",
"ScheduledTaskObject",
"ScheduledTasks",
"SchurDecomposition",
"ScientificForm",
"ScientificNotationThreshold",
"ScorerGi",
"ScorerGiPrime",
"ScorerHi",
"ScorerHiPrime",
"ScreenRectangle",
"ScreenStyleEnvironment",
"ScriptBaselineShifts",
"ScriptForm",
"ScriptLevel",
"ScriptMinSize",
"ScriptRules",
"ScriptSizeMultipliers",
"Scrollbars",
"ScrollingOptions",
"ScrollPosition",
"SearchAdjustment",
"SearchIndexObject",
"SearchIndices",
"SearchQueryString",
"SearchResultObject",
"Sec",
"Sech",
"SechDistribution",
"SecondOrderConeOptimization",
"SectionGrouping",
"SectorChart",
"SectorChart3D",
"SectorOrigin",
"SectorSpacing",
"SecuredAuthenticationKey",
"SecuredAuthenticationKeys",
"SecurityCertificate",
"SeedRandom",
"Select",
"Selectable",
"SelectComponents",
"SelectedCells",
"SelectedNotebook",
"SelectFirst",
"Selection",
"SelectionAnimate",
"SelectionCell",
"SelectionCellCreateCell",
"SelectionCellDefaultStyle",
"SelectionCellParentStyle",
"SelectionCreateCell",
"SelectionDebuggerTag",
"SelectionEvaluate",
"SelectionEvaluateCreateCell",
"SelectionMove",
"SelectionPlaceholder",
"SelectWithContents",
"SelfLoops",
"SelfLoopStyle",
"SemanticImport",
"SemanticImportString",
"SemanticInterpretation",
"SemialgebraicComponentInstances",
"SemidefiniteOptimization",
"SendMail",
"SendMessage",
"Sequence",
"SequenceAlignment",
"SequenceAttentionLayer",
"SequenceCases",
"SequenceCount",
"SequenceFold",
"SequenceFoldList",
"SequenceForm",
"SequenceHold",
"SequenceIndicesLayer",
"SequenceLastLayer",
"SequenceMostLayer",
"SequencePosition",
"SequencePredict",
"SequencePredictorFunction",
"SequenceReplace",
"SequenceRestLayer",
"SequenceReverseLayer",
"SequenceSplit",
"Series",
"SeriesCoefficient",
"SeriesData",
"SeriesTermGoal",
"ServiceConnect",
"ServiceDisconnect",
"ServiceExecute",
"ServiceObject",
"ServiceRequest",
"ServiceResponse",
"ServiceSubmit",
"SessionSubmit",
"SessionTime",
"Set",
"SetAccuracy",
"SetAlphaChannel",
"SetAttributes",
"Setbacks",
"SetCloudDirectory",
"SetCookies",
"SetDelayed",
"SetDirectory",
"SetEnvironment",
"SetFileDate",
"SetFileFormatProperties",
"SetOptions",
"SetOptionsPacket",
"SetPermissions",
"SetPrecision",
"SetProperty",
"SetSecuredAuthenticationKey",
"SetSelectedNotebook",
"SetSharedFunction",
"SetSharedVariable",
"SetStreamPosition",
"SetSystemModel",
"SetSystemOptions",
"Setter",
"SetterBar",
"SetterBox",
"SetterBoxOptions",
"Setting",
"SetUsers",
"Shading",
"Shallow",
"ShannonWavelet",
"ShapiroWilkTest",
"Share",
"SharingList",
"Sharpen",
"ShearingMatrix",
"ShearingTransform",
"ShellRegion",
"ShenCastanMatrix",
"ShiftedGompertzDistribution",
"ShiftRegisterSequence",
"Short",
"ShortDownArrow",
"Shortest",
"ShortestMatch",
"ShortestPathFunction",
"ShortLeftArrow",
"ShortRightArrow",
"ShortTimeFourier",
"ShortTimeFourierData",
"ShortUpArrow",
"Show",
"ShowAutoConvert",
"ShowAutoSpellCheck",
"ShowAutoStyles",
"ShowCellBracket",
"ShowCellLabel",
"ShowCellTags",
"ShowClosedCellArea",
"ShowCodeAssist",
"ShowContents",
"ShowControls",
"ShowCursorTracker",
"ShowGroupOpenCloseIcon",
"ShowGroupOpener",
"ShowInvisibleCharacters",
"ShowPageBreaks",
"ShowPredictiveInterface",
"ShowSelection",
"ShowShortBoxForm",
"ShowSpecialCharacters",
"ShowStringCharacters",
"ShowSyntaxStyles",
"ShrinkingDelay",
"ShrinkWrapBoundingBox",
"SiderealTime",
"SiegelTheta",
"SiegelTukeyTest",
"SierpinskiCurve",
"SierpinskiMesh",
"Sign",
"Signature",
"SignedRankTest",
"SignedRegionDistance",
"SignificanceLevel",
"SignPadding",
"SignTest",
"SimilarityRules",
"SimpleGraph",
"SimpleGraphQ",
"SimplePolygonQ",
"SimplePolyhedronQ",
"Simplex",
"Simplify",
"Sin",
"Sinc",
"SinghMaddalaDistribution",
"SingleEvaluation",
"SingleLetterItalics",
"SingleLetterStyle",
"SingularValueDecomposition",
"SingularValueList",
"SingularValuePlot",
"SingularValues",
"Sinh",
"SinhIntegral",
"SinIntegral",
"SixJSymbol",
"Skeleton",
"SkeletonTransform",
"SkellamDistribution",
"Skewness",
"SkewNormalDistribution",
"SkinStyle",
"Skip",
"SliceContourPlot3D",
"SliceDensityPlot3D",
"SliceDistribution",
"SliceVectorPlot3D",
"Slider",
"Slider2D",
"Slider2DBox",
"Slider2DBoxOptions",
"SliderBox",
"SliderBoxOptions",
"SlideShowVideo",
"SlideView",
"Slot",
"SlotSequence",
"Small",
"SmallCircle",
"Smaller",
"SmithDecomposition",
"SmithDelayCompensator",
"SmithWatermanSimilarity",
"SmoothDensityHistogram",
"SmoothHistogram",
"SmoothHistogram3D",
"SmoothKernelDistribution",
"SmoothPointDensity",
"SnDispersion",
"Snippet",
"SnippetsVideo",
"SnubPolyhedron",
"SocialMediaData",
"Socket",
"SocketConnect",
"SocketListen",
"SocketListener",
"SocketObject",
"SocketOpen",
"SocketReadMessage",
"SocketReadyQ",
"Sockets",
"SocketWaitAll",
"SocketWaitNext",
"SoftmaxLayer",
"SokalSneathDissimilarity",
"SolarEclipse",
"SolarSystemFeatureData",
"SolarTime",
"SolidAngle",
"SolidBoundaryLoadValue",
"SolidData",
"SolidDisplacementCondition",
"SolidFixedCondition",
"SolidMechanicsPDEComponent",
"SolidMechanicsStrain",
"SolidMechanicsStress",
"SolidRegionQ",
"Solve",
"SolveAlways",
"SolveDelayed",
"SolveValues",
"Sort",
"SortBy",
"SortedBy",
"SortedEntityClass",
"Sound",
"SoundAndGraphics",
"SoundNote",
"SoundVolume",
"SourceLink",
"SourcePDETerm",
"Sow",
"Space",
"SpaceCurveData",
"SpaceForm",
"Spacer",
"Spacings",
"Span",
"SpanAdjustments",
"SpanCharacterRounding",
"SpanFromAbove",
"SpanFromBoth",
"SpanFromLeft",
"SpanLineThickness",
"SpanMaxSize",
"SpanMinSize",
"SpanningCharacters",
"SpanSymmetric",
"SparseArray",
"SparseArrayQ",
"SpatialBinnedPointData",
"SpatialBoundaryCorrection",
"SpatialEstimate",
"SpatialEstimatorFunction",
"SpatialGraphDistribution",
"SpatialJ",
"SpatialMedian",
"SpatialNoiseLevel",
"SpatialObservationRegionQ",
"SpatialPointData",
"SpatialPointSelect",
"SpatialRandomnessTest",
"SpatialTransformationLayer",
"SpatialTrendFunction",
"Speak",
"SpeakerMatchQ",
"SpearmanRankTest",
"SpearmanRho",
"SpeciesData",
"SpecificityGoal",
"SpectralLineData",
"Spectrogram",
"SpectrogramArray",
"Specularity",
"SpeechCases",
"SpeechInterpreter",
"SpeechRecognize",
"SpeechSynthesize",
"SpellingCorrection",
"SpellingCorrectionList",
"SpellingDictionaries",
"SpellingDictionariesPath",
"SpellingOptions",
"Sphere",
"SphereBox",
"SphereBoxOptions",
"SpherePoints",
"SphericalBesselJ",
"SphericalBesselY",
"SphericalHankelH1",
"SphericalHankelH2",
"SphericalHarmonicY",
"SphericalPlot3D",
"SphericalRegion",
"SphericalShell",
"SpheroidalEigenvalue",
"SpheroidalJoiningFactor",
"SpheroidalPS",
"SpheroidalPSPrime",
"SpheroidalQS",
"SpheroidalQSPrime",
"SpheroidalRadialFactor",
"SpheroidalS1",
"SpheroidalS1Prime",
"SpheroidalS2",
"SpheroidalS2Prime",
"Splice",
"SplicedDistribution",
"SplineClosed",
"SplineDegree",
"SplineKnots",
"SplineWeights",
"Split",
"SplitBy",
"SpokenString",
"SpotLight",
"Sqrt",
"SqrtBox",
"SqrtBoxOptions",
"Square",
"SquaredEuclideanDistance",
"SquareFreeQ",
"SquareIntersection",
"SquareMatrixQ",
"SquareRepeatingElement",
"SquaresR",
"SquareSubset",
"SquareSubsetEqual",
"SquareSuperset",
"SquareSupersetEqual",
"SquareUnion",
"SquareWave",
"SSSTriangle",
"StabilityMargins",
"StabilityMarginsStyle",
"StableDistribution",
"Stack",
"StackBegin",
"StackComplete",
"StackedDateListPlot",
"StackedListPlot",
"StackInhibit",
"StadiumShape",
"StandardAtmosphereData",
"StandardDeviation",
"StandardDeviationFilter",
"StandardForm",
"Standardize",
"Standardized",
"StandardOceanData",
"StandbyDistribution",
"Star",
"StarClusterData",
"StarData",
"StarGraph",
"StartAsynchronousTask",
"StartExternalSession",
"StartingStepSize",
"StartOfLine",
"StartOfString",
"StartProcess",
"StartScheduledTask",
"StartupSound",
"StartWebSession",
"StateDimensions",
"StateFeedbackGains",
"StateOutputEstimator",
"StateResponse",
"StateSpaceModel",
"StateSpaceRealization",
"StateSpaceTransform",
"StateTransformationLinearize",
"StationaryDistribution",
"StationaryWaveletPacketTransform",
"StationaryWaveletTransform",
"StatusArea",
"StatusCentrality",
"StepMonitor",
"StereochemistryElements",
"StieltjesGamma",
"StippleShading",
"StirlingS1",
"StirlingS2",
"StopAsynchronousTask",
"StoppingPowerData",
"StopScheduledTask",
"StrataVariables",
"StratonovichProcess",
"StraussHardcorePointProcess",
"StraussPointProcess",
"StreamColorFunction",
"StreamColorFunctionScaling",
"StreamDensityPlot",
"StreamMarkers",
"StreamPlot",
"StreamPlot3D",
"StreamPoints",
"StreamPosition",
"Streams",
"StreamScale",
"StreamStyle",
"StrictInequalities",
"String",
"StringBreak",
"StringByteCount",
"StringCases",
"StringContainsQ",
"StringCount",
"StringDelete",
"StringDrop",
"StringEndsQ",
"StringExpression",
"StringExtract",
"StringForm",
"StringFormat",
"StringFormatQ",
"StringFreeQ",
"StringInsert",
"StringJoin",
"StringLength",
"StringMatchQ",
"StringPadLeft",
"StringPadRight",
"StringPart",
"StringPartition",
"StringPosition",
"StringQ",
"StringRepeat",
"StringReplace",
"StringReplaceList",
"StringReplacePart",
"StringReverse",
"StringRiffle",
"StringRotateLeft",
"StringRotateRight",
"StringSkeleton",
"StringSplit",
"StringStartsQ",
"StringTake",
"StringTakeDrop",
"StringTemplate",
"StringToByteArray",
"StringToStream",
"StringTrim",
"StripBoxes",
"StripOnInput",
"StripStyleOnPaste",
"StripWrapperBoxes",
"StrokeForm",
"Struckthrough",
"StructuralImportance",
"StructuredArray",
"StructuredArrayHeadQ",
"StructuredSelection",
"StruveH",
"StruveL",
"Stub",
"StudentTDistribution",
"Style",
"StyleBox",
"StyleBoxAutoDelete",
"StyleData",
"StyleDefinitions",
"StyleForm",
"StyleHints",
"StyleKeyMapping",
"StyleMenuListing",
"StyleNameDialogSettings",
"StyleNames",
"StylePrint",
"StyleSheetPath",
"Subdivide",
"Subfactorial",
"Subgraph",
"SubMinus",
"SubPlus",
"SubresultantPolynomialRemainders",
"SubresultantPolynomials",
"Subresultants",
"Subscript",
"SubscriptBox",
"SubscriptBoxOptions",
"Subscripted",
"Subsequences",
"Subset",
"SubsetCases",
"SubsetCount",
"SubsetEqual",
"SubsetMap",
"SubsetPosition",
"SubsetQ",
"SubsetReplace",
"Subsets",
"SubStar",
"SubstitutionSystem",
"Subsuperscript",
"SubsuperscriptBox",
"SubsuperscriptBoxOptions",
"SubtitleEncoding",
"SubtitleTrackSelection",
"Subtract",
"SubtractFrom",
"SubtractSides",
"SubValues",
"Succeeds",
"SucceedsEqual",
"SucceedsSlantEqual",
"SucceedsTilde",
"Success",
"SuchThat",
"Sum",
"SumConvergence",
"SummationLayer",
"Sunday",
"SunPosition",
"Sunrise",
"Sunset",
"SuperDagger",
"SuperMinus",
"SupernovaData",
"SuperPlus",
"Superscript",
"SuperscriptBox",
"SuperscriptBoxOptions",
"Superset",
"SupersetEqual",
"SuperStar",
"Surd",
"SurdForm",
"SurfaceAppearance",
"SurfaceArea",
"SurfaceColor",
"SurfaceData",
"SurfaceGraphics",
"SurvivalDistribution",
"SurvivalFunction",
"SurvivalModel",
"SurvivalModelFit",
"SuspendPacket",
"SuzukiDistribution",
"SuzukiGroupSuz",
"SwatchLegend",
"Switch",
"Symbol",
"SymbolName",
"SymletWavelet",
"Symmetric",
"SymmetricDifference",
"SymmetricGroup",
"SymmetricKey",
"SymmetricMatrixQ",
"SymmetricPolynomial",
"SymmetricReduction",
"Symmetrize",
"SymmetrizedArray",
"SymmetrizedArrayRules",
"SymmetrizedDependentComponents",
"SymmetrizedIndependentComponents",
"SymmetrizedReplacePart",
"SynchronousInitialization",
"SynchronousUpdating",
"Synonyms",
"Syntax",
"SyntaxForm",
"SyntaxInformation",
"SyntaxLength",
"SyntaxPacket",
"SyntaxQ",
"SynthesizeMissingValues",
"SystemCredential",
"SystemCredentialData",
"SystemCredentialKey",
"SystemCredentialKeys",
"SystemCredentialStoreObject",
"SystemDialogInput",
"SystemException",
"SystemGet",
"SystemHelpPath",
"SystemInformation",
"SystemInformationData",
"SystemInstall",
"SystemModel",
"SystemModeler",
"SystemModelExamples",
"SystemModelLinearize",
"SystemModelMeasurements",
"SystemModelParametricSimulate",
"SystemModelPlot",
"SystemModelProgressReporting",
"SystemModelReliability",
"SystemModels",
"SystemModelSimulate",
"SystemModelSimulateSensitivity",
"SystemModelSimulationData",
"SystemOpen",
"SystemOptions",
"SystemProcessData",
"SystemProcesses",
"SystemsConnectionsModel",
"SystemsModelControllerData",
"SystemsModelDelay",
"SystemsModelDelayApproximate",
"SystemsModelDelete",
"SystemsModelDimensions",
"SystemsModelExtract",
"SystemsModelFeedbackConnect",
"SystemsModelLabels",
"SystemsModelLinearity",
"SystemsModelMerge",
"SystemsModelOrder",
"SystemsModelParallelConnect",
"SystemsModelSeriesConnect",
"SystemsModelStateFeedbackConnect",
"SystemsModelVectorRelativeOrders",
"SystemStub",
"SystemTest",
"Tab",
"TabFilling",
"Table",
"TableAlignments",
"TableDepth",
"TableDirections",
"TableForm",
"TableHeadings",
"TableSpacing",
"TableView",
"TableViewBox",
"TableViewBoxAlignment",
"TableViewBoxBackground",
"TableViewBoxHeaders",
"TableViewBoxItemSize",
"TableViewBoxItemStyle",
"TableViewBoxOptions",
"TabSpacings",
"TabView",
"TabViewBox",
"TabViewBoxOptions",
"TagBox",
"TagBoxNote",
"TagBoxOptions",
"TaggingRules",
"TagSet",
"TagSetDelayed",
"TagStyle",
"TagUnset",
"Take",
"TakeDrop",
"TakeLargest",
"TakeLargestBy",
"TakeList",
"TakeSmallest",
"TakeSmallestBy",
"TakeWhile",
"Tally",
"Tan",
"Tanh",
"TargetDevice",
"TargetFunctions",
"TargetSystem",
"TargetUnits",
"TaskAbort",
"TaskExecute",
"TaskObject",
"TaskRemove",
"TaskResume",
"Tasks",
"TaskSuspend",
"TaskWait",
"TautologyQ",
"TelegraphProcess",
"TemplateApply",
"TemplateArgBox",
"TemplateBox",
"TemplateBoxOptions",
"TemplateEvaluate",
"TemplateExpression",
"TemplateIf",
"TemplateObject",
"TemplateSequence",
"TemplateSlot",
"TemplateSlotSequence",
"TemplateUnevaluated",
"TemplateVerbatim",
"TemplateWith",
"TemporalData",
"TemporalRegularity",
"Temporary",
"TemporaryVariable",
"TensorContract",
"TensorDimensions",
"TensorExpand",
"TensorProduct",
"TensorQ",
"TensorRank",
"TensorReduce",
"TensorSymmetry",
"TensorTranspose",
"TensorWedge",
"TerminatedEvaluation",
"TernaryListPlot",
"TernaryPlotCorners",
"TestID",
"TestReport",
"TestReportObject",
"TestResultObject",
"Tetrahedron",
"TetrahedronBox",
"TetrahedronBoxOptions",
"TeXForm",
"TeXSave",
"Text",
"Text3DBox",
"Text3DBoxOptions",
"TextAlignment",
"TextBand",
"TextBoundingBox",
"TextBox",
"TextCases",
"TextCell",
"TextClipboardType",
"TextContents",
"TextData",
"TextElement",
"TextForm",
"TextGrid",
"TextJustification",
"TextLine",
"TextPacket",
"TextParagraph",
"TextPosition",
"TextRecognize",
"TextSearch",
"TextSearchReport",
"TextSentences",
"TextString",
"TextStructure",
"TextStyle",
"TextTranslation",
"Texture",
"TextureCoordinateFunction",
"TextureCoordinateScaling",
"TextWords",
"Therefore",
"ThermodynamicData",
"ThermometerGauge",
"Thick",
"Thickness",
"Thin",
"Thinning",
"ThisLink",
"ThomasPointProcess",
"ThompsonGroupTh",
"Thread",
"Threaded",
"ThreadingLayer",
"ThreeJSymbol",
"Threshold",
"Through",
"Throw",
"ThueMorse",
"Thumbnail",
"Thursday",
"TickDirection",
"TickLabelOrientation",
"TickLabelPositioning",
"TickLabels",
"TickLengths",
"TickPositions",
"Ticks",
"TicksStyle",
"TideData",
"Tilde",
"TildeEqual",
"TildeFullEqual",
"TildeTilde",
"TimeConstrained",
"TimeConstraint",
"TimeDirection",
"TimeFormat",
"TimeGoal",
"TimelinePlot",
"TimeObject",
"TimeObjectQ",
"TimeRemaining",
"Times",
"TimesBy",
"TimeSeries",
"TimeSeriesAggregate",
"TimeSeriesForecast",
"TimeSeriesInsert",
"TimeSeriesInvertibility",
"TimeSeriesMap",
"TimeSeriesMapThread",
"TimeSeriesModel",
"TimeSeriesModelFit",
"TimeSeriesResample",
"TimeSeriesRescale",
"TimeSeriesShift",
"TimeSeriesThread",
"TimeSeriesWindow",
"TimeSystem",
"TimeSystemConvert",
"TimeUsed",
"TimeValue",
"TimeWarpingCorrespondence",
"TimeWarpingDistance",
"TimeZone",
"TimeZoneConvert",
"TimeZoneOffset",
"Timing",
"Tiny",
"TitleGrouping",
"TitsGroupT",
"ToBoxes",
"ToCharacterCode",
"ToColor",
"ToContinuousTimeModel",
"ToDate",
"Today",
"ToDiscreteTimeModel",
"ToEntity",
"ToeplitzMatrix",
"ToExpression",
"ToFileName",
"Together",
"Toggle",
"ToggleFalse",
"Toggler",
"TogglerBar",
"TogglerBox",
"TogglerBoxOptions",
"ToHeldExpression",
"ToInvertibleTimeSeries",
"TokenWords",
"Tolerance",
"ToLowerCase",
"Tomorrow",
"ToNumberField",
"TooBig",
"Tooltip",
"TooltipBox",
"TooltipBoxOptions",
"TooltipDelay",
"TooltipStyle",
"ToonShading",
"Top",
"TopHatTransform",
"ToPolarCoordinates",
"TopologicalSort",
"ToRadicals",
"ToRawPointer",
"ToRules",
"Torus",
"TorusGraph",
"ToSphericalCoordinates",
"ToString",
"Total",
"TotalHeight",
"TotalLayer",
"TotalVariationFilter",
"TotalWidth",
"TouchPosition",
"TouchscreenAutoZoom",
"TouchscreenControlPlacement",
"ToUpperCase",
"TourVideo",
"Tr",
"Trace",
"TraceAbove",
"TraceAction",
"TraceBackward",
"TraceDepth",
"TraceDialog",
"TraceForward",
"TraceInternal",
"TraceLevel",
"TraceOff",
"TraceOn",
"TraceOriginal",
"TracePrint",
"TraceScan",
"TrackCellChangeTimes",
"TrackedSymbols",
"TrackingFunction",
"TracyWidomDistribution",
"TradingChart",
"TraditionalForm",
"TraditionalFunctionNotation",
"TraditionalNotation",
"TraditionalOrder",
"TrainImageContentDetector",
"TrainingProgressCheckpointing",
"TrainingProgressFunction",
"TrainingProgressMeasurements",
"TrainingProgressReporting",
"TrainingStoppingCriterion",
"TrainingUpdateSchedule",
"TrainTextContentDetector",
"TransferFunctionCancel",
"TransferFunctionExpand",
"TransferFunctionFactor",
"TransferFunctionModel",
"TransferFunctionPoles",
"TransferFunctionTransform",
"TransferFunctionZeros",
"TransformationClass",
"TransformationFunction",
"TransformationFunctions",
"TransformationMatrix",
"TransformedDistribution",
"TransformedField",
"TransformedProcess",
"TransformedRegion",
"TransitionDirection",
"TransitionDuration",
"TransitionEffect",
"TransitiveClosureGraph",
"TransitiveReductionGraph",
"Translate",
"TranslationOptions",
"TranslationTransform",
"Transliterate",
"Transparent",
"TransparentColor",
"Transpose",
"TransposeLayer",
"TrapEnterKey",
"TrapSelection",
"TravelDirections",
"TravelDirectionsData",
"TravelDistance",
"TravelDistanceList",
"TravelMethod",
"TravelTime",
"Tree",
"TreeCases",
"TreeChildren",
"TreeCount",
"TreeData",
"TreeDelete",
"TreeDepth",
"TreeElementCoordinates",
"TreeElementLabel",
"TreeElementLabelFunction",
"TreeElementLabelStyle",
"TreeElementShape",
"TreeElementShapeFunction",
"TreeElementSize",
"TreeElementSizeFunction",
"TreeElementStyle",
"TreeElementStyleFunction",
"TreeExpression",
"TreeExtract",
"TreeFold",
"TreeForm",
"TreeGraph",
"TreeGraphQ",
"TreeInsert",
"TreeLayout",
"TreeLeafCount",
"TreeLeafQ",
"TreeLeaves",
"TreeLevel",
"TreeMap",
"TreeMapAt",
"TreeOutline",
"TreePlot",
"TreePosition",
"TreeQ",
"TreeReplacePart",
"TreeRules",
"TreeScan",
"TreeSelect",
"TreeSize",
"TreeTraversalOrder",
"TrendStyle",
"Triangle",
"TriangleCenter",
"TriangleConstruct",
"TriangleMeasurement",
"TriangleWave",
"TriangularDistribution",
"TriangulateMesh",
"Trig",
"TrigExpand",
"TrigFactor",
"TrigFactorList",
"Trigger",
"TrigReduce",
"TrigToExp",
"TrimmedMean",
"TrimmedVariance",
"TropicalStormData",
"True",
"TrueQ",
"TruncatedDistribution",
"TruncatedPolyhedron",
"TsallisQExponentialDistribution",
"TsallisQGaussianDistribution",
"TTest",
"Tube",
"TubeBezierCurveBox",
"TubeBezierCurveBoxOptions",
"TubeBox",
"TubeBoxOptions",
"TubeBSplineCurveBox",
"TubeBSplineCurveBoxOptions",
"Tuesday",
"TukeyLambdaDistribution",
"TukeyWindow",
"TunnelData",
"Tuples",
"TuranGraph",
"TuringMachine",
"TuttePolynomial",
"TwoWayRule",
"Typed",
"TypeDeclaration",
"TypeEvaluate",
"TypeHint",
"TypeOf",
"TypeSpecifier",
"UnateQ",
"Uncompress",
"UnconstrainedParameters",
"Undefined",
"UnderBar",
"Underflow",
"Underlined",
"Underoverscript",
"UnderoverscriptBox",
"UnderoverscriptBoxOptions",
"Underscript",
"UnderscriptBox",
"UnderscriptBoxOptions",
"UnderseaFeatureData",
"UndirectedEdge",
"UndirectedGraph",
"UndirectedGraphQ",
"UndoOptions",
"UndoTrackedVariables",
"Unequal",
"UnequalTo",
"Unevaluated",
"UniformDistribution",
"UniformGraphDistribution",
"UniformPolyhedron",
"UniformSumDistribution",
"Uninstall",
"Union",
"UnionedEntityClass",
"UnionPlus",
"Unique",
"UniqueElements",
"UnitaryMatrixQ",
"UnitBox",
"UnitConvert",
"UnitDimensions",
"Unitize",
"UnitRootTest",
"UnitSimplify",
"UnitStep",
"UnitSystem",
"UnitTriangle",
"UnitVector",
"UnitVectorLayer",
"UnityDimensions",
"UniverseModelData",
"UniversityData",
"UnixTime",
"UnlabeledTree",
"UnmanageObject",
"Unprotect",
"UnregisterExternalEvaluator",
"UnsameQ",
"UnsavedVariables",
"Unset",
"UnsetShared",
"Until",
"UntrackedVariables",
"Up",
"UpArrow",
"UpArrowBar",
"UpArrowDownArrow",
"Update",
"UpdateDynamicObjects",
"UpdateDynamicObjectsSynchronous",
"UpdateInterval",
"UpdatePacletSites",
"UpdateSearchIndex",
"UpDownArrow",
"UpEquilibrium",
"UpperCaseQ",
"UpperLeftArrow",
"UpperRightArrow",
"UpperTriangularize",
"UpperTriangularMatrix",
"UpperTriangularMatrixQ",
"Upsample",
"UpSet",
"UpSetDelayed",
"UpTee",
"UpTeeArrow",
"UpTo",
"UpValues",
"URL",
"URLBuild",
"URLDecode",
"URLDispatcher",
"URLDownload",
"URLDownloadSubmit",
"URLEncode",
"URLExecute",
"URLExpand",
"URLFetch",
"URLFetchAsynchronous",
"URLParse",
"URLQueryDecode",
"URLQueryEncode",
"URLRead",
"URLResponseTime",
"URLSave",
"URLSaveAsynchronous",
"URLShorten",
"URLSubmit",
"UseEmbeddedLibrary",
"UseGraphicsRange",
"UserDefinedWavelet",
"Using",
"UsingFrontEnd",
"UtilityFunction",
"V2Get",
"ValenceErrorHandling",
"ValenceFilling",
"ValidationLength",
"ValidationSet",
"ValueBox",
"ValueBoxOptions",
"ValueDimensions",
"ValueForm",
"ValuePreprocessingFunction",
"ValueQ",
"Values",
"ValuesData",
"VandermondeMatrix",
"Variables",
"Variance",
"VarianceEquivalenceTest",
"VarianceEstimatorFunction",
"VarianceGammaDistribution",
"VarianceGammaPointProcess",
"VarianceTest",
"VariogramFunction",
"VariogramModel",
"VectorAngle",
"VectorAround",
"VectorAspectRatio",
"VectorColorFunction",
"VectorColorFunctionScaling",
"VectorDensityPlot",
"VectorDisplacementPlot",
"VectorDisplacementPlot3D",
"VectorGlyphData",
"VectorGreater",
"VectorGreaterEqual",
"VectorLess",
"VectorLessEqual",
"VectorMarkers",
"VectorPlot",
"VectorPlot3D",
"VectorPoints",
"VectorQ",
"VectorRange",
"Vectors",
"VectorScale",
"VectorScaling",
"VectorSizes",
"VectorStyle",
"Vee",
"Verbatim",
"Verbose",
"VerificationTest",
"VerifyConvergence",
"VerifyDerivedKey",
"VerifyDigitalSignature",
"VerifyFileSignature",
"VerifyInterpretation",
"VerifySecurityCertificates",
"VerifySolutions",
"VerifyTestAssumptions",
"VersionedPreferences",
"VertexAdd",
"VertexCapacity",
"VertexChromaticNumber",
"VertexColors",
"VertexComponent",
"VertexConnectivity",
"VertexContract",
"VertexCoordinateRules",
"VertexCoordinates",
"VertexCorrelationSimilarity",
"VertexCosineSimilarity",
"VertexCount",
"VertexCoverQ",
"VertexDataCoordinates",
"VertexDegree",
"VertexDelete",
"VertexDiceSimilarity",
"VertexEccentricity",
"VertexInComponent",
"VertexInComponentGraph",
"VertexInDegree",
"VertexIndex",
"VertexJaccardSimilarity",
"VertexLabeling",
"VertexLabels",
"VertexLabelStyle",
"VertexList",
"VertexNormals",
"VertexOutComponent",
"VertexOutComponentGraph",
"VertexOutDegree",
"VertexQ",
"VertexRenderingFunction",
"VertexReplace",
"VertexShape",
"VertexShapeFunction",
"VertexSize",
"VertexStyle",
"VertexTextureCoordinates",
"VertexTransitiveGraphQ",
"VertexWeight",
"VertexWeightedGraphQ",
"Vertical",
"VerticalBar",
"VerticalForm",
"VerticalGauge",
"VerticalSeparator",
"VerticalSlider",
"VerticalTilde",
"Video",
"VideoCapture",
"VideoCombine",
"VideoDelete",
"VideoEncoding",
"VideoExtractFrames",
"VideoFrameList",
"VideoFrameMap",
"VideoGenerator",
"VideoInsert",
"VideoIntervals",
"VideoJoin",
"VideoMap",
"VideoMapList",
"VideoMapTimeSeries",
"VideoPadding",
"VideoPause",
"VideoPlay",
"VideoQ",
"VideoRecord",
"VideoReplace",
"VideoScreenCapture",
"VideoSplit",
"VideoStop",
"VideoStream",
"VideoStreams",
"VideoTimeStretch",
"VideoTrackSelection",
"VideoTranscode",
"VideoTransparency",
"VideoTrim",
"ViewAngle",
"ViewCenter",
"ViewMatrix",
"ViewPoint",
"ViewPointSelectorSettings",
"ViewPort",
"ViewProjection",
"ViewRange",
"ViewVector",
"ViewVertical",
"VirtualGroupData",
"Visible",
"VisibleCell",
"VoiceStyleData",
"VoigtDistribution",
"VolcanoData",
"Volume",
"VonMisesDistribution",
"VoronoiMesh",
"WaitAll",
"WaitAsynchronousTask",
"WaitNext",
"WaitUntil",
"WakebyDistribution",
"WalleniusHypergeometricDistribution",
"WaringYuleDistribution",
"WarpingCorrespondence",
"WarpingDistance",
"WatershedComponents",
"WatsonUSquareTest",
"WattsStrogatzGraphDistribution",
"WaveletBestBasis",
"WaveletFilterCoefficients",
"WaveletImagePlot",
"WaveletListPlot",
"WaveletMapIndexed",
"WaveletMatrixPlot",
"WaveletPhi",
"WaveletPsi",
"WaveletScale",
"WaveletScalogram",
"WaveletThreshold",
"WavePDEComponent",
"WeaklyConnectedComponents",
"WeaklyConnectedGraphComponents",
"WeaklyConnectedGraphQ",
"WeakStationarity",
"WeatherData",
"WeatherForecastData",
"WebAudioSearch",
"WebColumn",
"WebElementObject",
"WeberE",
"WebExecute",
"WebImage",
"WebImageSearch",
"WebItem",
"WebPageMetaInformation",
"WebRow",
"WebSearch",
"WebSessionObject",
"WebSessions",
"WebWindowObject",
"Wedge",
"Wednesday",
"WeibullDistribution",
"WeierstrassE1",
"WeierstrassE2",
"WeierstrassE3",
"WeierstrassEta1",
"WeierstrassEta2",
"WeierstrassEta3",
"WeierstrassHalfPeriods",
"WeierstrassHalfPeriodW1",
"WeierstrassHalfPeriodW2",
"WeierstrassHalfPeriodW3",
"WeierstrassInvariantG2",
"WeierstrassInvariantG3",
"WeierstrassInvariants",
"WeierstrassP",
"WeierstrassPPrime",
"WeierstrassSigma",
"WeierstrassZeta",
"WeightedAdjacencyGraph",
"WeightedAdjacencyMatrix",
"WeightedData",
"WeightedGraphQ",
"Weights",
"WelchWindow",
"WheelGraph",
"WhenEvent",
"Which",
"While",
"White",
"WhiteNoiseProcess",
"WhitePoint",
"Whitespace",
"WhitespaceCharacter",
"WhittakerM",
"WhittakerW",
"WholeCellGroupOpener",
"WienerFilter",
"WienerProcess",
"WignerD",
"WignerSemicircleDistribution",
"WikidataData",
"WikidataSearch",
"WikipediaData",
"WikipediaSearch",
"WilksW",
"WilksWTest",
"WindDirectionData",
"WindingCount",
"WindingPolygon",
"WindowClickSelect",
"WindowElements",
"WindowFloating",
"WindowFrame",
"WindowFrameElements",
"WindowMargins",
"WindowMovable",
"WindowOpacity",
"WindowPersistentStyles",
"WindowSelected",
"WindowSize",
"WindowStatusArea",
"WindowTitle",
"WindowToolbars",
"WindowWidth",
"WindSpeedData",
"WindVectorData",
"WinsorizedMean",
"WinsorizedVariance",
"WishartMatrixDistribution",
"With",
"WithCleanup",
"WithLock",
"WolframAlpha",
"WolframAlphaDate",
"WolframAlphaQuantity",
"WolframAlphaResult",
"WolframCloudSettings",
"WolframLanguageData",
"Word",
"WordBoundary",
"WordCharacter",
"WordCloud",
"WordCount",
"WordCounts",
"WordData",
"WordDefinition",
"WordFrequency",
"WordFrequencyData",
"WordList",
"WordOrientation",
"WordSearch",
"WordSelectionFunction",
"WordSeparators",
"WordSpacings",
"WordStem",
"WordTranslation",
"WorkingPrecision",
"WrapAround",
"Write",
"WriteLine",
"WriteString",
"Wronskian",
"XMLElement",
"XMLObject",
"XMLTemplate",
"Xnor",
"Xor",
"XYZColor",
"Yellow",
"Yesterday",
"YuleDissimilarity",
"ZernikeR",
"ZeroSymmetric",
"ZeroTest",
"ZeroWidthTimes",
"Zeta",
"ZetaZero",
"ZIPCodeData",
"ZipfDistribution",
"ZoomCenter",
"ZoomFactor",
"ZTest",
"ZTransform",
"$Aborted",
"$ActivationGroupID",
"$ActivationKey",
"$ActivationUserRegistered",
"$AddOnsDirectory",
"$AllowDataUpdates",
"$AllowExternalChannelFunctions",
"$AllowInternet",
"$AssertFunction",
"$Assumptions",
"$AsynchronousTask",
"$AudioDecoders",
"$AudioEncoders",
"$AudioInputDevices",
"$AudioOutputDevices",
"$BaseDirectory",
"$BasePacletsDirectory",
"$BatchInput",
"$BatchOutput",
"$BlockchainBase",
"$BoxForms",
"$ByteOrdering",
"$CacheBaseDirectory",
"$Canceled",
"$ChannelBase",
"$CharacterEncoding",
"$CharacterEncodings",
"$CloudAccountName",
"$CloudBase",
"$CloudConnected",
"$CloudConnection",
"$CloudCreditsAvailable",
"$CloudEvaluation",
"$CloudExpressionBase",
"$CloudObjectNameFormat",
"$CloudObjectURLType",
"$CloudRootDirectory",
"$CloudSymbolBase",
"$CloudUserID",
"$CloudUserUUID",
"$CloudVersion",
"$CloudVersionNumber",
"$CloudWolframEngineVersionNumber",
"$CommandLine",
"$CompilationTarget",
"$CompilerEnvironment",
"$ConditionHold",
"$ConfiguredKernels",
"$Context",
"$ContextAliases",
"$ContextPath",
"$ControlActiveSetting",
"$Cookies",
"$CookieStore",
"$CreationDate",
"$CryptographicEllipticCurveNames",
"$CurrentLink",
"$CurrentTask",
"$CurrentWebSession",
"$DataStructures",
"$DateStringFormat",
"$DefaultAudioInputDevice",
"$DefaultAudioOutputDevice",
"$DefaultFont",
"$DefaultFrontEnd",
"$DefaultImagingDevice",
"$DefaultKernels",
"$DefaultLocalBase",
"$DefaultLocalKernel",
"$DefaultMailbox",
"$DefaultNetworkInterface",
"$DefaultPath",
"$DefaultProxyRules",
"$DefaultRemoteBatchSubmissionEnvironment",
"$DefaultRemoteKernel",
"$DefaultSystemCredentialStore",
"$Display",
"$DisplayFunction",
"$DistributedContexts",
"$DynamicEvaluation",
"$Echo",
"$EmbedCodeEnvironments",
"$EmbeddableServices",
"$EntityStores",
"$Epilog",
"$EvaluationCloudBase",
"$EvaluationCloudObject",
"$EvaluationEnvironment",
"$ExportFormats",
"$ExternalIdentifierTypes",
"$ExternalStorageBase",
"$Failed",
"$FinancialDataSource",
"$FontFamilies",
"$FormatType",
"$FrontEnd",
"$FrontEndSession",
"$GeneratedAssetLocation",
"$GeoEntityTypes",
"$GeoLocation",
"$GeoLocationCity",
"$GeoLocationCountry",
"$GeoLocationPrecision",
"$GeoLocationSource",
"$HistoryLength",
"$HomeDirectory",
"$HTMLExportRules",
"$HTTPCookies",
"$HTTPRequest",
"$IgnoreEOF",
"$ImageFormattingWidth",
"$ImageResolution",
"$ImagingDevice",
"$ImagingDevices",
"$ImportFormats",
"$IncomingMailSettings",
"$InitialDirectory",
"$Initialization",
"$InitializationContexts",
"$Input",
"$InputFileName",
"$InputStreamMethods",
"$Inspector",
"$InstallationDate",
"$InstallationDirectory",
"$InterfaceEnvironment",
"$InterpreterTypes",
"$IterationLimit",
"$KernelCount",
"$KernelID",
"$Language",
"$LaunchDirectory",
"$LibraryPath",
"$LicenseExpirationDate",
"$LicenseID",
"$LicenseProcesses",
"$LicenseServer",
"$LicenseSubprocesses",
"$LicenseType",
"$Line",
"$Linked",
"$LinkSupported",
"$LoadedFiles",
"$LocalBase",
"$LocalSymbolBase",
"$MachineAddresses",
"$MachineDomain",
"$MachineDomains",
"$MachineEpsilon",
"$MachineID",
"$MachineName",
"$MachinePrecision",
"$MachineType",
"$MaxDisplayedChildren",
"$MaxExtraPrecision",
"$MaxLicenseProcesses",
"$MaxLicenseSubprocesses",
"$MaxMachineNumber",
"$MaxNumber",
"$MaxPiecewiseCases",
"$MaxPrecision",
"$MaxRootDegree",
"$MessageGroups",
"$MessageList",
"$MessagePrePrint",
"$Messages",
"$MinMachineNumber",
"$MinNumber",
"$MinorReleaseNumber",
"$MinPrecision",
"$MobilePhone",
"$ModuleNumber",
"$NetworkConnected",
"$NetworkInterfaces",
"$NetworkLicense",
"$NewMessage",
"$NewSymbol",
"$NotebookInlineStorageLimit",
"$Notebooks",
"$NoValue",
"$NumberMarks",
"$Off",
"$OperatingSystem",
"$Output",
"$OutputForms",
"$OutputSizeLimit",
"$OutputStreamMethods",
"$Packages",
"$ParentLink",
"$ParentProcessID",
"$PasswordFile",
"$PatchLevelID",
"$Path",
"$PathnameSeparator",
"$PerformanceGoal",
"$Permissions",
"$PermissionsGroupBase",
"$PersistenceBase",
"$PersistencePath",
"$PipeSupported",
"$PlotTheme",
"$Post",
"$Pre",
"$PreferencesDirectory",
"$PreInitialization",
"$PrePrint",
"$PreRead",
"$PrintForms",
"$PrintLiteral",
"$Printout3DPreviewer",
"$ProcessID",
"$ProcessorCount",
"$ProcessorType",
"$ProductInformation",
"$ProgramName",
"$ProgressReporting",
"$PublisherID",
"$RandomGeneratorState",
"$RandomState",
"$RecursionLimit",
"$RegisteredDeviceClasses",
"$RegisteredUserName",
"$ReleaseNumber",
"$RequesterAddress",
"$RequesterCloudUserID",
"$RequesterCloudUserUUID",
"$RequesterWolframID",
"$RequesterWolframUUID",
"$ResourceSystemBase",
"$ResourceSystemPath",
"$RootDirectory",
"$ScheduledTask",
"$ScriptCommandLine",
"$ScriptInputString",
"$SecuredAuthenticationKeyTokens",
"$ServiceCreditsAvailable",
"$Services",
"$SessionID",
"$SetParentLink",
"$SharedFunctions",
"$SharedVariables",
"$SoundDisplay",
"$SoundDisplayFunction",
"$SourceLink",
"$SSHAuthentication",
"$SubtitleDecoders",
"$SubtitleEncoders",
"$SummaryBoxDataSizeLimit",
"$SuppressInputFormHeads",
"$SynchronousEvaluation",
"$SyntaxHandler",
"$System",
"$SystemCharacterEncoding",
"$SystemCredentialStore",
"$SystemID",
"$SystemMemory",
"$SystemShell",
"$SystemTimeZone",
"$SystemWordLength",
"$TargetSystems",
"$TemplatePath",
"$TemporaryDirectory",
"$TemporaryPrefix",
"$TestFileName",
"$TextStyle",
"$TimedOut",
"$TimeUnit",
"$TimeZone",
"$TimeZoneEntity",
"$TopDirectory",
"$TraceOff",
"$TraceOn",
"$TracePattern",
"$TracePostAction",
"$TracePreAction",
"$UnitSystem",
"$Urgent",
"$UserAddOnsDirectory",
"$UserAgentLanguages",
"$UserAgentMachine",
"$UserAgentName",
"$UserAgentOperatingSystem",
"$UserAgentString",
"$UserAgentVersion",
"$UserBaseDirectory",
"$UserBasePacletsDirectory",
"$UserDocumentsDirectory",
"$Username",
"$UserName",
"$UserURLBase",
"$Version",
"$VersionNumber",
"$VideoDecoders",
"$VideoEncoders",
"$VoiceStyles",
"$WolframDocumentsDirectory",
"$WolframID",
"$WolframUUID"
];
/*
Language: Wolfram Language
Description: The Wolfram Language is the programming language used in Wolfram Mathematica, a modern technical computing system spanning most areas of technical computing.
Authors: Patrick Scheibe <patrick@halirutan.de>, Robert Jacobson <robertjacobson@acm.org>
Website: https://www.wolfram.com/mathematica/
Category: scientific
*/
/** @type LanguageFn */
function mathematica(hljs) {
const regex = hljs.regex;
/*
This rather scary looking matching of Mathematica numbers is carefully explained by Robert Jacobson here:
https://wltools.github.io/LanguageSpec/Specification/Syntax/Number-representations/
*/
const BASE_RE = /([2-9]|[1-2]\d|[3][0-5])\^\^/;
const BASE_DIGITS_RE = /(\w*\.\w+|\w+\.\w*|\w+)/;
const NUMBER_RE = /(\d*\.\d+|\d+\.\d*|\d+)/;
const BASE_NUMBER_RE = regex.either(regex.concat(BASE_RE, BASE_DIGITS_RE), NUMBER_RE);
const ACCURACY_RE = /``[+-]?(\d*\.\d+|\d+\.\d*|\d+)/;
const PRECISION_RE = /`([+-]?(\d*\.\d+|\d+\.\d*|\d+))?/;
const APPROXIMATE_NUMBER_RE = regex.either(ACCURACY_RE, PRECISION_RE);
const SCIENTIFIC_NOTATION_RE = /\*\^[+-]?\d+/;
const MATHEMATICA_NUMBER_RE = regex.concat(
BASE_NUMBER_RE,
regex.optional(APPROXIMATE_NUMBER_RE),
regex.optional(SCIENTIFIC_NOTATION_RE)
);
const NUMBERS = {
className: 'number',
relevance: 0,
begin: MATHEMATICA_NUMBER_RE
};
const SYMBOL_RE = /[a-zA-Z$][a-zA-Z0-9$]*/;
const SYSTEM_SYMBOLS_SET = new Set(SYSTEM_SYMBOLS);
/** @type {Mode} */
const SYMBOLS = { variants: [
{
className: 'builtin-symbol',
begin: SYMBOL_RE,
// for performance out of fear of regex.either(...Mathematica.SYSTEM_SYMBOLS)
"on:begin": (match, response) => {
if (!SYSTEM_SYMBOLS_SET.has(match[0])) response.ignoreMatch();
}
},
{
className: 'symbol',
relevance: 0,
begin: SYMBOL_RE
}
] };
const NAMED_CHARACTER = {
className: 'named-character',
begin: /\\\[[$a-zA-Z][$a-zA-Z0-9]+\]/
};
const OPERATORS = {
className: 'operator',
relevance: 0,
begin: /[+\-*/,;.:@~=><&|_`'^?!%]+/
};
const PATTERNS = {
className: 'pattern',
relevance: 0,
begin: /([a-zA-Z$][a-zA-Z0-9$]*)?_+([a-zA-Z$][a-zA-Z0-9$]*)?/
};
const SLOTS = {
className: 'slot',
relevance: 0,
begin: /#[a-zA-Z$][a-zA-Z0-9$]*|#+[0-9]?/
};
const BRACES = {
className: 'brace',
relevance: 0,
begin: /[[\](){}]/
};
const MESSAGES = {
className: 'message-name',
relevance: 0,
begin: regex.concat("::", SYMBOL_RE)
};
return {
name: 'Mathematica',
aliases: [
'mma',
'wl'
],
classNameAliases: {
brace: 'punctuation',
pattern: 'type',
slot: 'type',
symbol: 'variable',
'named-character': 'variable',
'builtin-symbol': 'built_in',
'message-name': 'string'
},
contains: [
hljs.COMMENT(/\(\*/, /\*\)/, { contains: [ 'self' ] }),
PATTERNS,
SLOTS,
MESSAGES,
SYMBOLS,
NAMED_CHARACTER,
hljs.QUOTE_STRING_MODE,
NUMBERS,
OPERATORS,
BRACES
]
};
}
var mathematica_1 = mathematica;
/*
Language: Matlab
Author: Denis Bardadym <bardadymchik@gmail.com>
Contributors: Eugene Nizhibitsky <nizhibitsky@ya.ru>, Egor Rogov <e.rogov@postgrespro.ru>
Website: https://www.mathworks.com/products/matlab.html
Category: scientific
*/
/*
Formal syntax is not published, helpful link:
https://github.com/kornilova-l/matlab-IntelliJ-plugin/blob/master/src/main/grammar/Matlab.bnf
*/
function matlab(hljs) {
const TRANSPOSE_RE = '(\'|\\.\')+';
const TRANSPOSE = {
relevance: 0,
contains: [ { begin: TRANSPOSE_RE } ]
};
return {
name: 'Matlab',
keywords: {
keyword:
'arguments break case catch classdef continue else elseif end enumeration events for function '
+ 'global if methods otherwise parfor persistent properties return spmd switch try while',
built_in:
'sin sind sinh asin asind asinh cos cosd cosh acos acosd acosh tan tand tanh atan '
+ 'atand atan2 atanh sec secd sech asec asecd asech csc cscd csch acsc acscd acsch cot '
+ 'cotd coth acot acotd acoth hypot exp expm1 log log1p log10 log2 pow2 realpow reallog '
+ 'realsqrt sqrt nthroot nextpow2 abs angle complex conj imag real unwrap isreal '
+ 'cplxpair fix floor ceil round mod rem sign airy besselj bessely besselh besseli '
+ 'besselk beta betainc betaln ellipj ellipke erf erfc erfcx erfinv expint gamma '
+ 'gammainc gammaln psi legendre cross dot factor isprime primes gcd lcm rat rats perms '
+ 'nchoosek factorial cart2sph cart2pol pol2cart sph2cart hsv2rgb rgb2hsv zeros ones '
+ 'eye repmat rand randn linspace logspace freqspace meshgrid accumarray size length '
+ 'ndims numel disp isempty isequal isequalwithequalnans cat reshape diag blkdiag tril '
+ 'triu fliplr flipud flipdim rot90 find sub2ind ind2sub bsxfun ndgrid permute ipermute '
+ 'shiftdim circshift squeeze isscalar isvector ans eps realmax realmin pi i|0 inf nan '
+ 'isnan isinf isfinite j|0 why compan gallery hadamard hankel hilb invhilb magic pascal '
+ 'rosser toeplitz vander wilkinson max min nanmax nanmin mean nanmean type table '
+ 'readtable writetable sortrows sort figure plot plot3 scatter scatter3 cellfun '
+ 'legend intersect ismember procrustes hold num2cell '
},
illegal: '(//|"|#|/\\*|\\s+/\\w+)',
contains: [
{
className: 'function',
beginKeywords: 'function',
end: '$',
contains: [
hljs.UNDERSCORE_TITLE_MODE,
{
className: 'params',
variants: [
{
begin: '\\(',
end: '\\)'
},
{
begin: '\\[',
end: '\\]'
}
]
}
]
},
{
className: 'built_in',
begin: /true|false/,
relevance: 0,
starts: TRANSPOSE
},
{
begin: '[a-zA-Z][a-zA-Z_0-9]*' + TRANSPOSE_RE,
relevance: 0
},
{
className: 'number',
begin: hljs.C_NUMBER_RE,
relevance: 0,
starts: TRANSPOSE
},
{
className: 'string',
begin: '\'',
end: '\'',
contains: [ { begin: '\'\'' } ]
},
{
begin: /\]|\}|\)/,
relevance: 0,
starts: TRANSPOSE
},
{
className: 'string',
begin: '"',
end: '"',
contains: [ { begin: '""' } ],
starts: TRANSPOSE
},
hljs.COMMENT('^\\s*%\\{\\s*$', '^\\s*%\\}\\s*$'),
hljs.COMMENT('%', '$')
]
};
}
var matlab_1 = matlab;
/*
Language: Maxima
Author: Robert Dodier <robert.dodier@gmail.com>
Website: http://maxima.sourceforge.net
Category: scientific
*/
function maxima(hljs) {
const KEYWORDS =
'if then else elseif for thru do while unless step in and or not';
const LITERALS =
'true false unknown inf minf ind und %e %i %pi %phi %gamma';
const BUILTIN_FUNCTIONS =
' abasep abs absint absolute_real_time acos acosh acot acoth acsc acsch activate'
+ ' addcol add_edge add_edges addmatrices addrow add_vertex add_vertices adjacency_matrix'
+ ' adjoin adjoint af agd airy airy_ai airy_bi airy_dai airy_dbi algsys alg_type'
+ ' alias allroots alphacharp alphanumericp amortization %and annuity_fv'
+ ' annuity_pv antid antidiff AntiDifference append appendfile apply apply1 apply2'
+ ' applyb1 apropos args arit_amortization arithmetic arithsum array arrayapply'
+ ' arrayinfo arraymake arraysetapply ascii asec asech asin asinh askinteger'
+ ' asksign assoc assoc_legendre_p assoc_legendre_q assume assume_external_byte_order'
+ ' asympa at atan atan2 atanh atensimp atom atvalue augcoefmatrix augmented_lagrangian_method'
+ ' av average_degree backtrace bars barsplot barsplot_description base64 base64_decode'
+ ' bashindices batch batchload bc2 bdvac belln benefit_cost bern bernpoly bernstein_approx'
+ ' bernstein_expand bernstein_poly bessel bessel_i bessel_j bessel_k bessel_simplify'
+ ' bessel_y beta beta_incomplete beta_incomplete_generalized beta_incomplete_regularized'
+ ' bezout bfallroots bffac bf_find_root bf_fmin_cobyla bfhzeta bfloat bfloatp'
+ ' bfpsi bfpsi0 bfzeta biconnected_components bimetric binomial bipartition'
+ ' block blockmatrixp bode_gain bode_phase bothcoef box boxplot boxplot_description'
+ ' break bug_report build_info|10 buildq build_sample burn cabs canform canten'
+ ' cardinality carg cartan cartesian_product catch cauchy_matrix cbffac cdf_bernoulli'
+ ' cdf_beta cdf_binomial cdf_cauchy cdf_chi2 cdf_continuous_uniform cdf_discrete_uniform'
+ ' cdf_exp cdf_f cdf_gamma cdf_general_finite_discrete cdf_geometric cdf_gumbel'
+ ' cdf_hypergeometric cdf_laplace cdf_logistic cdf_lognormal cdf_negative_binomial'
+ ' cdf_noncentral_chi2 cdf_noncentral_student_t cdf_normal cdf_pareto cdf_poisson'
+ ' cdf_rank_sum cdf_rayleigh cdf_signed_rank cdf_student_t cdf_weibull cdisplay'
+ ' ceiling central_moment cequal cequalignore cf cfdisrep cfexpand cgeodesic'
+ ' cgreaterp cgreaterpignore changename changevar chaosgame charat charfun charfun2'
+ ' charlist charp charpoly chdir chebyshev_t chebyshev_u checkdiv check_overlaps'
+ ' chinese cholesky christof chromatic_index chromatic_number cint circulant_graph'
+ ' clear_edge_weight clear_rules clear_vertex_label clebsch_gordan clebsch_graph'
+ ' clessp clesspignore close closefile cmetric coeff coefmatrix cograd col collapse'
+ ' collectterms columnop columnspace columnswap columnvector combination combine'
+ ' comp2pui compare compfile compile compile_file complement_graph complete_bipartite_graph'
+ ' complete_graph complex_number_p components compose_functions concan concat'
+ ' conjugate conmetderiv connected_components connect_vertices cons constant'
+ ' constantp constituent constvalue cont2part content continuous_freq contortion'
+ ' contour_plot contract contract_edge contragrad contrib_ode convert coord'
+ ' copy copy_file copy_graph copylist copymatrix cor cos cosh cot coth cov cov1'
+ ' covdiff covect covers crc24sum create_graph create_list csc csch csetup cspline'
+ ' ctaylor ct_coordsys ctransform ctranspose cube_graph cuboctahedron_graph'
+ ' cunlisp cv cycle_digraph cycle_graph cylindrical days360 dblint deactivate'
+ ' declare declare_constvalue declare_dimensions declare_fundamental_dimensions'
+ ' declare_fundamental_units declare_qty declare_translated declare_unit_conversion'
+ ' declare_units declare_weights decsym defcon define define_alt_display define_variable'
+ ' defint defmatch defrule defstruct deftaylor degree_sequence del delete deleten'
+ ' delta demo demoivre denom depends derivdegree derivlist describe desolve'
+ ' determinant dfloat dgauss_a dgauss_b dgeev dgemm dgeqrf dgesv dgesvd diag'
+ ' diagmatrix diag_matrix diagmatrixp diameter diff digitcharp dimacs_export'
+ ' dimacs_import dimension dimensionless dimensions dimensions_as_list direct'
+ ' directory discrete_freq disjoin disjointp disolate disp dispcon dispform'
+ ' dispfun dispJordan display disprule dispterms distrib divide divisors divsum'
+ ' dkummer_m dkummer_u dlange dodecahedron_graph dotproduct dotsimp dpart'
+ ' draw draw2d draw3d drawdf draw_file draw_graph dscalar echelon edge_coloring'
+ ' edge_connectivity edges eigens_by_jacobi eigenvalues eigenvectors eighth'
+ ' einstein eivals eivects elapsed_real_time elapsed_run_time ele2comp ele2polynome'
+ ' ele2pui elem elementp elevation_grid elim elim_allbut eliminate eliminate_using'
+ ' ellipse elliptic_e elliptic_ec elliptic_eu elliptic_f elliptic_kc elliptic_pi'
+ ' ematrix empty_graph emptyp endcons entermatrix entertensor entier equal equalp'
+ ' equiv_classes erf erfc erf_generalized erfi errcatch error errormsg errors'
+ ' euler ev eval_string evenp every evolution evolution2d evundiff example exp'
+ ' expand expandwrt expandwrt_factored expint expintegral_chi expintegral_ci'
+ ' expintegral_e expintegral_e1 expintegral_ei expintegral_e_simplify expintegral_li'
+ ' expintegral_shi expintegral_si explicit explose exponentialize express expt'
+ ' exsec extdiff extract_linear_equations extremal_subset ezgcd %f f90 facsum'
+ ' factcomb factor factorfacsum factorial factorout factorsum facts fast_central_elements'
+ ' fast_linsolve fasttimes featurep fernfale fft fib fibtophi fifth filename_merge'
+ ' file_search file_type fillarray findde find_root find_root_abs find_root_error'
+ ' find_root_rel first fix flatten flength float floatnump floor flower_snark'
+ ' flush flush1deriv flushd flushnd flush_output fmin_cobyla forget fortran'
+ ' fourcos fourexpand fourier fourier_elim fourint fourintcos fourintsin foursimp'
+ ' foursin fourth fposition frame_bracket freeof freshline fresnel_c fresnel_s'
+ ' from_adjacency_matrix frucht_graph full_listify fullmap fullmapl fullratsimp'
+ ' fullratsubst fullsetify funcsolve fundamental_dimensions fundamental_units'
+ ' fundef funmake funp fv g0 g1 gamma gamma_greek gamma_incomplete gamma_incomplete_generalized'
+ ' gamma_incomplete_regularized gauss gauss_a gauss_b gaussprob gcd gcdex gcdivide'
+ ' gcfac gcfactor gd generalized_lambert_w genfact gen_laguerre genmatrix gensym'
+ ' geo_amortization geo_annuity_fv geo_annuity_pv geomap geometric geometric_mean'
+ ' geosum get getcurrentdirectory get_edge_weight getenv get_lu_factors get_output_stream_string'
+ ' get_pixel get_plot_option get_tex_environment get_tex_environment_default'
+ ' get_vertex_label gfactor gfactorsum ggf girth global_variances gn gnuplot_close'
+ ' gnuplot_replot gnuplot_reset gnuplot_restart gnuplot_start go Gosper GosperSum'
+ ' gr2d gr3d gradef gramschmidt graph6_decode graph6_encode graph6_export graph6_import'
+ ' graph_center graph_charpoly graph_eigenvalues graph_flow graph_order graph_periphery'
+ ' graph_product graph_size graph_union great_rhombicosidodecahedron_graph great_rhombicuboctahedron_graph'
+ ' grid_graph grind grobner_basis grotzch_graph hamilton_cycle hamilton_path'
+ ' hankel hankel_1 hankel_2 harmonic harmonic_mean hav heawood_graph hermite'
+ ' hessian hgfred hilbertmap hilbert_matrix hipow histogram histogram_description'
+ ' hodge horner hypergeometric i0 i1 %ibes ic1 ic2 ic_convert ichr1 ichr2 icosahedron_graph'
+ ' icosidodecahedron_graph icurvature ident identfor identity idiff idim idummy'
+ ' ieqn %if ifactors iframes ifs igcdex igeodesic_coords ilt image imagpart'
+ ' imetric implicit implicit_derivative implicit_plot indexed_tensor indices'
+ ' induced_subgraph inferencep inference_result infix info_display init_atensor'
+ ' init_ctensor in_neighbors innerproduct inpart inprod inrt integerp integer_partitions'
+ ' integrate intersect intersection intervalp intopois intosum invariant1 invariant2'
+ ' inverse_fft inverse_jacobi_cd inverse_jacobi_cn inverse_jacobi_cs inverse_jacobi_dc'
+ ' inverse_jacobi_dn inverse_jacobi_ds inverse_jacobi_nc inverse_jacobi_nd inverse_jacobi_ns'
+ ' inverse_jacobi_sc inverse_jacobi_sd inverse_jacobi_sn invert invert_by_adjoint'
+ ' invert_by_lu inv_mod irr is is_biconnected is_bipartite is_connected is_digraph'
+ ' is_edge_in_graph is_graph is_graph_or_digraph ishow is_isomorphic isolate'
+ ' isomorphism is_planar isqrt isreal_p is_sconnected is_tree is_vertex_in_graph'
+ ' items_inference %j j0 j1 jacobi jacobian jacobi_cd jacobi_cn jacobi_cs jacobi_dc'
+ ' jacobi_dn jacobi_ds jacobi_nc jacobi_nd jacobi_ns jacobi_p jacobi_sc jacobi_sd'
+ ' jacobi_sn JF jn join jordan julia julia_set julia_sin %k kdels kdelta kill'
+ ' killcontext kostka kron_delta kronecker_product kummer_m kummer_u kurtosis'
+ ' kurtosis_bernoulli kurtosis_beta kurtosis_binomial kurtosis_chi2 kurtosis_continuous_uniform'
+ ' kurtosis_discrete_uniform kurtosis_exp kurtosis_f kurtosis_gamma kurtosis_general_finite_discrete'
+ ' kurtosis_geometric kurtosis_gumbel kurtosis_hypergeometric kurtosis_laplace'
+ ' kurtosis_logistic kurtosis_lognormal kurtosis_negative_binomial kurtosis_noncentral_chi2'
+ ' kurtosis_noncentral_student_t kurtosis_normal kurtosis_pareto kurtosis_poisson'
+ ' kurtosis_rayleigh kurtosis_student_t kurtosis_weibull label labels lagrange'
+ ' laguerre lambda lambert_w laplace laplacian_matrix last lbfgs lc2kdt lcharp'
+ ' lc_l lcm lc_u ldefint ldisp ldisplay legendre_p legendre_q leinstein length'
+ ' let letrules letsimp levi_civita lfreeof lgtreillis lhs li liediff limit'
+ ' Lindstedt linear linearinterpol linear_program linear_regression line_graph'
+ ' linsolve listarray list_correlations listify list_matrix_entries list_nc_monomials'
+ ' listoftens listofvars listp lmax lmin load loadfile local locate_matrix_entry'
+ ' log logcontract log_gamma lopow lorentz_gauge lowercasep lpart lratsubst'
+ ' lreduce lriemann lsquares_estimates lsquares_estimates_approximate lsquares_estimates_exact'
+ ' lsquares_mse lsquares_residual_mse lsquares_residuals lsum ltreillis lu_backsub'
+ ' lucas lu_factor %m macroexpand macroexpand1 make_array makebox makefact makegamma'
+ ' make_graph make_level_picture makelist makeOrders make_poly_continent make_poly_country'
+ ' make_polygon make_random_state make_rgb_picture makeset make_string_input_stream'
+ ' make_string_output_stream make_transform mandelbrot mandelbrot_set map mapatom'
+ ' maplist matchdeclare matchfix mat_cond mat_fullunblocker mat_function mathml_display'
+ ' mat_norm matrix matrixmap matrixp matrix_size mattrace mat_trace mat_unblocker'
+ ' max max_clique max_degree max_flow maximize_lp max_independent_set max_matching'
+ ' maybe md5sum mean mean_bernoulli mean_beta mean_binomial mean_chi2 mean_continuous_uniform'
+ ' mean_deviation mean_discrete_uniform mean_exp mean_f mean_gamma mean_general_finite_discrete'
+ ' mean_geometric mean_gumbel mean_hypergeometric mean_laplace mean_logistic'
+ ' mean_lognormal mean_negative_binomial mean_noncentral_chi2 mean_noncentral_student_t'
+ ' mean_normal mean_pareto mean_poisson mean_rayleigh mean_student_t mean_weibull'
+ ' median median_deviation member mesh metricexpandall mgf1_sha1 min min_degree'
+ ' min_edge_cut minfactorial minimalPoly minimize_lp minimum_spanning_tree minor'
+ ' minpack_lsquares minpack_solve min_vertex_cover min_vertex_cut mkdir mnewton'
+ ' mod mode_declare mode_identity ModeMatrix moebius mon2schur mono monomial_dimensions'
+ ' multibernstein_poly multi_display_for_texinfo multi_elem multinomial multinomial_coeff'
+ ' multi_orbit multiplot_mode multi_pui multsym multthru mycielski_graph nary'
+ ' natural_unit nc_degree ncexpt ncharpoly negative_picture neighbors new newcontext'
+ ' newdet new_graph newline newton new_variable next_prime nicedummies niceindices'
+ ' ninth nofix nonarray noncentral_moment nonmetricity nonnegintegerp nonscalarp'
+ ' nonzeroandfreeof notequal nounify nptetrad npv nroots nterms ntermst'
+ ' nthroot nullity nullspace num numbered_boundaries numberp number_to_octets'
+ ' num_distinct_partitions numerval numfactor num_partitions nusum nzeta nzetai'
+ ' nzetar octets_to_number octets_to_oid odd_girth oddp ode2 ode_check odelin'
+ ' oid_to_octets op opena opena_binary openr openr_binary openw openw_binary'
+ ' operatorp opsubst optimize %or orbit orbits ordergreat ordergreatp orderless'
+ ' orderlessp orthogonal_complement orthopoly_recur orthopoly_weight outermap'
+ ' out_neighbors outofpois pade parabolic_cylinder_d parametric parametric_surface'
+ ' parg parGosper parse_string parse_timedate part part2cont partfrac partition'
+ ' partition_set partpol path_digraph path_graph pathname_directory pathname_name'
+ ' pathname_type pdf_bernoulli pdf_beta pdf_binomial pdf_cauchy pdf_chi2 pdf_continuous_uniform'
+ ' pdf_discrete_uniform pdf_exp pdf_f pdf_gamma pdf_general_finite_discrete'
+ ' pdf_geometric pdf_gumbel pdf_hypergeometric pdf_laplace pdf_logistic pdf_lognormal'
+ ' pdf_negative_binomial pdf_noncentral_chi2 pdf_noncentral_student_t pdf_normal'
+ ' pdf_pareto pdf_poisson pdf_rank_sum pdf_rayleigh pdf_signed_rank pdf_student_t'
+ ' pdf_weibull pearson_skewness permanent permut permutation permutations petersen_graph'
+ ' petrov pickapart picture_equalp picturep piechart piechart_description planar_embedding'
+ ' playback plog plot2d plot3d plotdf ploteq plsquares pochhammer points poisdiff'
+ ' poisexpt poisint poismap poisplus poissimp poissubst poistimes poistrim polar'
+ ' polarform polartorect polar_to_xy poly_add poly_buchberger poly_buchberger_criterion'
+ ' poly_colon_ideal poly_content polydecomp poly_depends_p poly_elimination_ideal'
+ ' poly_exact_divide poly_expand poly_expt poly_gcd polygon poly_grobner poly_grobner_equal'
+ ' poly_grobner_member poly_grobner_subsetp poly_ideal_intersection poly_ideal_polysaturation'
+ ' poly_ideal_polysaturation1 poly_ideal_saturation poly_ideal_saturation1 poly_lcm'
+ ' poly_minimization polymod poly_multiply polynome2ele polynomialp poly_normal_form'
+ ' poly_normalize poly_normalize_list poly_polysaturation_extension poly_primitive_part'
+ ' poly_pseudo_divide poly_reduced_grobner poly_reduction poly_saturation_extension'
+ ' poly_s_polynomial poly_subtract polytocompanion pop postfix potential power_mod'
+ ' powerseries powerset prefix prev_prime primep primes principal_components'
+ ' print printf printfile print_graph printpois printprops prodrac product properties'
+ ' propvars psi psubst ptriangularize pui pui2comp pui2ele pui2polynome pui_direct'
+ ' puireduc push put pv qput qrange qty quad_control quad_qag quad_qagi quad_qagp'
+ ' quad_qags quad_qawc quad_qawf quad_qawo quad_qaws quadrilateral quantile'
+ ' quantile_bernoulli quantile_beta quantile_binomial quantile_cauchy quantile_chi2'
+ ' quantile_continuous_uniform quantile_discrete_uniform quantile_exp quantile_f'
+ ' quantile_gamma quantile_general_finite_discrete quantile_geometric quantile_gumbel'
+ ' quantile_hypergeometric quantile_laplace quantile_logistic quantile_lognormal'
+ ' quantile_negative_binomial quantile_noncentral_chi2 quantile_noncentral_student_t'
+ ' quantile_normal quantile_pareto quantile_poisson quantile_rayleigh quantile_student_t'
+ ' quantile_weibull quartile_skewness quit qunit quotient racah_v racah_w radcan'
+ ' radius random random_bernoulli random_beta random_binomial random_bipartite_graph'
+ ' random_cauchy random_chi2 random_continuous_uniform random_digraph random_discrete_uniform'
+ ' random_exp random_f random_gamma random_general_finite_discrete random_geometric'
+ ' random_graph random_graph1 random_gumbel random_hypergeometric random_laplace'
+ ' random_logistic random_lognormal random_negative_binomial random_network'
+ ' random_noncentral_chi2 random_noncentral_student_t random_normal random_pareto'
+ ' random_permutation random_poisson random_rayleigh random_regular_graph random_student_t'
+ ' random_tournament random_tree random_weibull range rank rat ratcoef ratdenom'
+ ' ratdiff ratdisrep ratexpand ratinterpol rational rationalize ratnumer ratnump'
+ ' ratp ratsimp ratsubst ratvars ratweight read read_array read_binary_array'
+ ' read_binary_list read_binary_matrix readbyte readchar read_hashed_array readline'
+ ' read_list read_matrix read_nested_list readonly read_xpm real_imagpart_to_conjugate'
+ ' realpart realroots rearray rectangle rectform rectform_log_if_constant recttopolar'
+ ' rediff reduce_consts reduce_order region region_boundaries region_boundaries_plus'
+ ' rem remainder remarray rembox remcomps remcon remcoord remfun remfunction'
+ ' remlet remove remove_constvalue remove_dimensions remove_edge remove_fundamental_dimensions'
+ ' remove_fundamental_units remove_plot_option remove_vertex rempart remrule'
+ ' remsym remvalue rename rename_file reset reset_displays residue resolvante'
+ ' resolvante_alternee1 resolvante_bipartite resolvante_diedrale resolvante_klein'
+ ' resolvante_klein3 resolvante_produit_sym resolvante_unitaire resolvante_vierer'
+ ' rest resultant return reveal reverse revert revert2 rgb2level rhs ricci riemann'
+ ' rinvariant risch rk rmdir rncombine romberg room rootscontract round row'
+ ' rowop rowswap rreduce run_testsuite %s save saving scalarp scaled_bessel_i'
+ ' scaled_bessel_i0 scaled_bessel_i1 scalefactors scanmap scatterplot scatterplot_description'
+ ' scene schur2comp sconcat scopy scsimp scurvature sdowncase sec sech second'
+ ' sequal sequalignore set_alt_display setdifference set_draw_defaults set_edge_weight'
+ ' setelmx setequalp setify setp set_partitions set_plot_option set_prompt set_random_state'
+ ' set_tex_environment set_tex_environment_default setunits setup_autoload set_up_dot_simplifications'
+ ' set_vertex_label seventh sexplode sf sha1sum sha256sum shortest_path shortest_weighted_path'
+ ' show showcomps showratvars sierpinskiale sierpinskimap sign signum similaritytransform'
+ ' simp_inequality simplify_sum simplode simpmetderiv simtran sin sinh sinsert'
+ ' sinvertcase sixth skewness skewness_bernoulli skewness_beta skewness_binomial'
+ ' skewness_chi2 skewness_continuous_uniform skewness_discrete_uniform skewness_exp'
+ ' skewness_f skewness_gamma skewness_general_finite_discrete skewness_geometric'
+ ' skewness_gumbel skewness_hypergeometric skewness_laplace skewness_logistic'
+ ' skewness_lognormal skewness_negative_binomial skewness_noncentral_chi2 skewness_noncentral_student_t'
+ ' skewness_normal skewness_pareto skewness_poisson skewness_rayleigh skewness_student_t'
+ ' skewness_weibull slength smake small_rhombicosidodecahedron_graph small_rhombicuboctahedron_graph'
+ ' smax smin smismatch snowmap snub_cube_graph snub_dodecahedron_graph solve'
+ ' solve_rec solve_rec_rat some somrac sort sparse6_decode sparse6_encode sparse6_export'
+ ' sparse6_import specint spherical spherical_bessel_j spherical_bessel_y spherical_hankel1'
+ ' spherical_hankel2 spherical_harmonic spherical_to_xyz splice split sposition'
+ ' sprint sqfr sqrt sqrtdenest sremove sremovefirst sreverse ssearch ssort sstatus'
+ ' ssubst ssubstfirst staircase standardize standardize_inverse_trig starplot'
+ ' starplot_description status std std1 std_bernoulli std_beta std_binomial'
+ ' std_chi2 std_continuous_uniform std_discrete_uniform std_exp std_f std_gamma'
+ ' std_general_finite_discrete std_geometric std_gumbel std_hypergeometric std_laplace'
+ ' std_logistic std_lognormal std_negative_binomial std_noncentral_chi2 std_noncentral_student_t'
+ ' std_normal std_pareto std_poisson std_rayleigh std_student_t std_weibull'
+ ' stemplot stirling stirling1 stirling2 strim striml strimr string stringout'
+ ' stringp strong_components struve_h struve_l sublis sublist sublist_indices'
+ ' submatrix subsample subset subsetp subst substinpart subst_parallel substpart'
+ ' substring subvar subvarp sum sumcontract summand_to_rec supcase supcontext'
+ ' symbolp symmdifference symmetricp system take_channel take_inference tan'
+ ' tanh taylor taylorinfo taylorp taylor_simplifier taytorat tcl_output tcontract'
+ ' tellrat tellsimp tellsimpafter tentex tenth test_mean test_means_difference'
+ ' test_normality test_proportion test_proportions_difference test_rank_sum'
+ ' test_sign test_signed_rank test_variance test_variance_ratio tex tex1 tex_display'
+ ' texput %th third throw time timedate timer timer_info tldefint tlimit todd_coxeter'
+ ' toeplitz tokens to_lisp topological_sort to_poly to_poly_solve totaldisrep'
+ ' totalfourier totient tpartpol trace tracematrix trace_options transform_sample'
+ ' translate translate_file transpose treefale tree_reduce treillis treinat'
+ ' triangle triangularize trigexpand trigrat trigreduce trigsimp trunc truncate'
+ ' truncated_cube_graph truncated_dodecahedron_graph truncated_icosahedron_graph'
+ ' truncated_tetrahedron_graph tr_warnings_get tube tutte_graph ueivects uforget'
+ ' ultraspherical underlying_graph undiff union unique uniteigenvectors unitp'
+ ' units unit_step unitvector unorder unsum untellrat untimer'
+ ' untrace uppercasep uricci uriemann uvect vandermonde_matrix var var1 var_bernoulli'
+ ' var_beta var_binomial var_chi2 var_continuous_uniform var_discrete_uniform'
+ ' var_exp var_f var_gamma var_general_finite_discrete var_geometric var_gumbel'
+ ' var_hypergeometric var_laplace var_logistic var_lognormal var_negative_binomial'
+ ' var_noncentral_chi2 var_noncentral_student_t var_normal var_pareto var_poisson'
+ ' var_rayleigh var_student_t var_weibull vector vectorpotential vectorsimp'
+ ' verbify vers vertex_coloring vertex_connectivity vertex_degree vertex_distance'
+ ' vertex_eccentricity vertex_in_degree vertex_out_degree vertices vertices_to_cycle'
+ ' vertices_to_path %w weyl wheel_graph wiener_index wigner_3j wigner_6j'
+ ' wigner_9j with_stdout write_binary_data writebyte write_data writefile wronskian'
+ ' xreduce xthru %y Zeilberger zeroequiv zerofor zeromatrix zeromatrixp zeta'
+ ' zgeev zheev zlange zn_add_table zn_carmichael_lambda zn_characteristic_factors'
+ ' zn_determinant zn_factor_generators zn_invert_by_lu zn_log zn_mult_table'
+ ' absboxchar activecontexts adapt_depth additive adim aform algebraic'
+ ' algepsilon algexact aliases allbut all_dotsimp_denoms allocation allsym alphabetic'
+ ' animation antisymmetric arrays askexp assume_pos assume_pos_pred assumescalar'
+ ' asymbol atomgrad atrig1 axes axis_3d axis_bottom axis_left axis_right axis_top'
+ ' azimuth background background_color backsubst berlefact bernstein_explicit'
+ ' besselexpand beta_args_sum_to_integer beta_expand bftorat bftrunc bindtest'
+ ' border boundaries_array box boxchar breakup %c capping cauchysum cbrange'
+ ' cbtics center cflength cframe_flag cnonmet_flag color color_bar color_bar_tics'
+ ' colorbox columns commutative complex cone context contexts contour contour_levels'
+ ' cosnpiflag ctaypov ctaypt ctayswitch ctayvar ct_coords ctorsion_flag ctrgsimp'
+ ' cube current_let_rule_package cylinder data_file_name debugmode decreasing'
+ ' default_let_rule_package delay dependencies derivabbrev derivsubst detout'
+ ' diagmetric diff dim dimensions dispflag display2d|10 display_format_internal'
+ ' distribute_over doallmxops domain domxexpt domxmxops domxnctimes dontfactor'
+ ' doscmxops doscmxplus dot0nscsimp dot0simp dot1simp dotassoc dotconstrules'
+ ' dotdistrib dotexptsimp dotident dotscrules draw_graph_program draw_realpart'
+ ' edge_color edge_coloring edge_partition edge_type edge_width %edispflag'
+ ' elevation %emode endphi endtheta engineering_format_floats enhanced3d %enumer'
+ ' epsilon_lp erfflag erf_representation errormsg error_size error_syms error_type'
+ ' %e_to_numlog eval even evenfun evflag evfun ev_point expandwrt_denom expintexpand'
+ ' expintrep expon expop exptdispflag exptisolate exptsubst facexpand facsum_combine'
+ ' factlim factorflag factorial_expand factors_only fb feature features'
+ ' file_name file_output_append file_search_demo file_search_lisp file_search_maxima|10'
+ ' file_search_tests file_search_usage file_type_lisp file_type_maxima|10 fill_color'
+ ' fill_density filled_func fixed_vertices flipflag float2bf font font_size'
+ ' fortindent fortspaces fpprec fpprintprec functions gamma_expand gammalim'
+ ' gdet genindex gensumnum GGFCFMAX GGFINFINITY globalsolve gnuplot_command'
+ ' gnuplot_curve_styles gnuplot_curve_titles gnuplot_default_term_command gnuplot_dumb_term_command'
+ ' gnuplot_file_args gnuplot_file_name gnuplot_out_file gnuplot_pdf_term_command'
+ ' gnuplot_pm3d gnuplot_png_term_command gnuplot_postamble gnuplot_preamble'
+ ' gnuplot_ps_term_command gnuplot_svg_term_command gnuplot_term gnuplot_view_args'
+ ' Gosper_in_Zeilberger gradefs grid grid2d grind halfangles head_angle head_both'
+ ' head_length head_type height hypergeometric_representation %iargs ibase'
+ ' icc1 icc2 icounter idummyx ieqnprint ifb ifc1 ifc2 ifg ifgi ifr iframe_bracket_form'
+ ' ifri igeowedge_flag ikt1 ikt2 imaginary inchar increasing infeval'
+ ' infinity inflag infolists inm inmc1 inmc2 intanalysis integer integervalued'
+ ' integrate_use_rootsof integration_constant integration_constant_counter interpolate_color'
+ ' intfaclim ip_grid ip_grid_in irrational isolate_wrt_times iterations itr'
+ ' julia_parameter %k1 %k2 keepfloat key key_pos kinvariant kt label label_alignment'
+ ' label_orientation labels lassociative lbfgs_ncorrections lbfgs_nfeval_max'
+ ' leftjust legend letrat let_rule_packages lfg lg lhospitallim limsubst linear'
+ ' linear_solver linechar linel|10 linenum line_type linewidth line_width linsolve_params'
+ ' linsolvewarn lispdisp listarith listconstvars listdummyvars lmxchar load_pathname'
+ ' loadprint logabs logarc logcb logconcoeffp logexpand lognegint logsimp logx'
+ ' logx_secondary logy logy_secondary logz lriem m1pbranch macroexpansion macros'
+ ' mainvar manual_demo maperror mapprint matrix_element_add matrix_element_mult'
+ ' matrix_element_transpose maxapplydepth maxapplyheight maxima_tempdir|10 maxima_userdir|10'
+ ' maxnegex MAX_ORD maxposex maxpsifracdenom maxpsifracnum maxpsinegint maxpsiposint'
+ ' maxtayorder mesh_lines_color method mod_big_prime mode_check_errorp'
+ ' mode_checkp mode_check_warnp mod_test mod_threshold modular_linear_solver'
+ ' modulus multiplicative multiplicities myoptions nary negdistrib negsumdispflag'
+ ' newline newtonepsilon newtonmaxiter nextlayerfactor niceindicespref nm nmc'
+ ' noeval nolabels nonegative_lp noninteger nonscalar noun noundisp nouns np'
+ ' npi nticks ntrig numer numer_pbranch obase odd oddfun opacity opproperties'
+ ' opsubst optimprefix optionset orientation origin orthopoly_returns_intervals'
+ ' outative outchar packagefile palette partswitch pdf_file pfeformat phiresolution'
+ ' %piargs piece pivot_count_sx pivot_max_sx plot_format plot_options plot_realpart'
+ ' png_file pochhammer_max_index points pointsize point_size points_joined point_type'
+ ' poislim poisson poly_coefficient_ring poly_elimination_order polyfactor poly_grobner_algorithm'
+ ' poly_grobner_debug poly_monomial_order poly_primary_elimination_order poly_return_term_list'
+ ' poly_secondary_elimination_order poly_top_reduction_only posfun position'
+ ' powerdisp pred prederror primep_number_of_tests product_use_gamma program'
+ ' programmode promote_float_to_bigfloat prompt proportional_axes props psexpand'
+ ' ps_file radexpand radius radsubstflag rassociative ratalgdenom ratchristof'
+ ' ratdenomdivide rateinstein ratepsilon ratfac rational ratmx ratprint ratriemann'
+ ' ratsimpexpons ratvarswitch ratweights ratweyl ratwtlvl real realonly redraw'
+ ' refcheck resolution restart resultant ric riem rmxchar %rnum_list rombergabs'
+ ' rombergit rombergmin rombergtol rootsconmode rootsepsilon run_viewer same_xy'
+ ' same_xyz savedef savefactors scalar scalarmatrixp scale scale_lp setcheck'
+ ' setcheckbreak setval show_edge_color show_edges show_edge_type show_edge_width'
+ ' show_id show_label showtime show_vertex_color show_vertex_size show_vertex_type'
+ ' show_vertices show_weight simp simplified_output simplify_products simpproduct'
+ ' simpsum sinnpiflag solvedecomposes solveexplicit solvefactors solvenullwarn'
+ ' solveradcan solvetrigwarn space sparse sphere spring_embedding_depth sqrtdispflag'
+ ' stardisp startphi starttheta stats_numer stringdisp structures style sublis_apply_lambda'
+ ' subnumsimp sumexpand sumsplitfact surface surface_hide svg_file symmetric'
+ ' tab taylordepth taylor_logexpand taylor_order_coefficients taylor_truncate_polynomials'
+ ' tensorkill terminal testsuite_files thetaresolution timer_devalue title tlimswitch'
+ ' tr track transcompile transform transform_xy translate_fast_arrays transparent'
+ ' transrun tr_array_as_ref tr_bound_function_applyp tr_file_tty_messagesp tr_float_can_branch_complex'
+ ' tr_function_call_default trigexpandplus trigexpandtimes triginverses trigsign'
+ ' trivial_solutions tr_numer tr_optimize_max_loop tr_semicompile tr_state_vars'
+ ' tr_warn_bad_function_calls tr_warn_fexpr tr_warn_meval tr_warn_mode'
+ ' tr_warn_undeclared tr_warn_undefined_variable tstep ttyoff tube_extremes'
+ ' ufg ug %unitexpand unit_vectors uric uriem use_fast_arrays user_preamble'
+ ' usersetunits values vect_cross verbose vertex_color vertex_coloring vertex_partition'
+ ' vertex_size vertex_type view warnings weyl width windowname windowtitle wired_surface'
+ ' wireframe xaxis xaxis_color xaxis_secondary xaxis_type xaxis_width xlabel'
+ ' xlabel_secondary xlength xrange xrange_secondary xtics xtics_axis xtics_rotate'
+ ' xtics_rotate_secondary xtics_secondary xtics_secondary_axis xu_grid x_voxel'
+ ' xy_file xyplane xy_scale yaxis yaxis_color yaxis_secondary yaxis_type yaxis_width'
+ ' ylabel ylabel_secondary ylength yrange yrange_secondary ytics ytics_axis'
+ ' ytics_rotate ytics_rotate_secondary ytics_secondary ytics_secondary_axis'
+ ' yv_grid y_voxel yx_ratio zaxis zaxis_color zaxis_type zaxis_width zeroa zerob'
+ ' zerobern zeta%pi zlabel zlabel_rotate zlength zmin zn_primroot_limit zn_primroot_pretest';
const SYMBOLS = '_ __ %|0 %%|0';
return {
name: 'Maxima',
keywords: {
$pattern: '[A-Za-z_%][0-9A-Za-z_%]*',
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILTIN_FUNCTIONS,
symbol: SYMBOLS
},
contains: [
{
className: 'comment',
begin: '/\\*',
end: '\\*/',
contains: [ 'self' ]
},
hljs.QUOTE_STRING_MODE,
{
className: 'number',
relevance: 0,
variants: [
{
// float number w/ exponent
// hmm, I wonder if we ought to include other exponent markers?
begin: '\\b(\\d+|\\d+\\.|\\.\\d+|\\d+\\.\\d+)[Ee][-+]?\\d+\\b' },
{
// bigfloat number
begin: '\\b(\\d+|\\d+\\.|\\.\\d+|\\d+\\.\\d+)[Bb][-+]?\\d+\\b',
relevance: 10
},
{
// float number w/out exponent
// Doesn't seem to recognize floats which start with '.'
begin: '\\b(\\.\\d+|\\d+\\.\\d+)\\b' },
{
// integer in base up to 36
// Doesn't seem to recognize integers which end with '.'
begin: '\\b(\\d+|0[0-9A-Za-z]+)\\.?\\b' }
]
}
],
illegal: /@/
};
}
var maxima_1 = maxima;
/*
Language: MEL
Description: Maya Embedded Language
Author: Shuen-Huei Guan <drake.guan@gmail.com>
Website: http://www.autodesk.com/products/autodesk-maya/overview
Category: graphics
*/
function mel(hljs) {
return {
name: 'MEL',
keywords:
'int float string vector matrix if else switch case default while do for in break '
+ 'continue global proc return about abs addAttr addAttributeEditorNodeHelp addDynamic '
+ 'addNewShelfTab addPP addPanelCategory addPrefixToName advanceToNextDrivenKey '
+ 'affectedNet affects aimConstraint air alias aliasAttr align alignCtx alignCurve '
+ 'alignSurface allViewFit ambientLight angle angleBetween animCone animCurveEditor '
+ 'animDisplay animView annotate appendStringArray applicationName applyAttrPreset '
+ 'applyTake arcLenDimContext arcLengthDimension arclen arrayMapper art3dPaintCtx '
+ 'artAttrCtx artAttrPaintVertexCtx artAttrSkinPaintCtx artAttrTool artBuildPaintMenu '
+ 'artFluidAttrCtx artPuttyCtx artSelectCtx artSetPaintCtx artUserPaintCtx assignCommand '
+ 'assignInputDevice assignViewportFactories attachCurve attachDeviceAttr attachSurface '
+ 'attrColorSliderGrp attrCompatibility attrControlGrp attrEnumOptionMenu '
+ 'attrEnumOptionMenuGrp attrFieldGrp attrFieldSliderGrp attrNavigationControlGrp '
+ 'attrPresetEditWin attributeExists attributeInfo attributeMenu attributeQuery '
+ 'autoKeyframe autoPlace bakeClip bakeFluidShading bakePartialHistory bakeResults '
+ 'bakeSimulation basename basenameEx batchRender bessel bevel bevelPlus binMembership '
+ 'bindSkin blend2 blendShape blendShapeEditor blendShapePanel blendTwoAttr blindDataType '
+ 'boneLattice boundary boxDollyCtx boxZoomCtx bufferCurve buildBookmarkMenu '
+ 'buildKeyframeMenu button buttonManip CBG cacheFile cacheFileCombine cacheFileMerge '
+ 'cacheFileTrack camera cameraView canCreateManip canvas capitalizeString catch '
+ 'catchQuiet ceil changeSubdivComponentDisplayLevel changeSubdivRegion channelBox '
+ 'character characterMap characterOutlineEditor characterize chdir checkBox checkBoxGrp '
+ 'checkDefaultRenderGlobals choice circle circularFillet clamp clear clearCache clip '
+ 'clipEditor clipEditorCurrentTimeCtx clipSchedule clipSchedulerOutliner clipTrimBefore '
+ 'closeCurve closeSurface cluster cmdFileOutput cmdScrollFieldExecuter '
+ 'cmdScrollFieldReporter cmdShell coarsenSubdivSelectionList collision color '
+ 'colorAtPoint colorEditor colorIndex colorIndexSliderGrp colorSliderButtonGrp '
+ 'colorSliderGrp columnLayout commandEcho commandLine commandPort compactHairSystem '
+ 'componentEditor compositingInterop computePolysetVolume condition cone confirmDialog '
+ 'connectAttr connectControl connectDynamic connectJoint connectionInfo constrain '
+ 'constrainValue constructionHistory container containsMultibyte contextInfo control '
+ 'convertFromOldLayers convertIffToPsd convertLightmap convertSolidTx convertTessellation '
+ 'convertUnit copyArray copyFlexor copyKey copySkinWeights cos cpButton cpCache '
+ 'cpClothSet cpCollision cpConstraint cpConvClothToMesh cpForces cpGetSolverAttr cpPanel '
+ 'cpProperty cpRigidCollisionFilter cpSeam cpSetEdit cpSetSolverAttr cpSolver '
+ 'cpSolverTypes cpTool cpUpdateClothUVs createDisplayLayer createDrawCtx createEditor '
+ 'createLayeredPsdFile createMotionField createNewShelf createNode createRenderLayer '
+ 'createSubdivRegion cross crossProduct ctxAbort ctxCompletion ctxEditMode ctxTraverse '
+ 'currentCtx currentTime currentTimeCtx currentUnit curve curveAddPtCtx '
+ 'curveCVCtx curveEPCtx curveEditorCtx curveIntersect curveMoveEPCtx curveOnSurface '
+ 'curveSketchCtx cutKey cycleCheck cylinder dagPose date defaultLightListCheckBox '
+ 'defaultNavigation defineDataServer defineVirtualDevice deformer deg_to_rad delete '
+ 'deleteAttr deleteShadingGroupsAndMaterials deleteShelfTab deleteUI deleteUnusedBrushes '
+ 'delrandstr detachCurve detachDeviceAttr detachSurface deviceEditor devicePanel dgInfo '
+ 'dgdirty dgeval dgtimer dimWhen directKeyCtx directionalLight dirmap dirname disable '
+ 'disconnectAttr disconnectJoint diskCache displacementToPoly displayAffected '
+ 'displayColor displayCull displayLevelOfDetail displayPref displayRGBColor '
+ 'displaySmoothness displayStats displayString displaySurface distanceDimContext '
+ 'distanceDimension doBlur dolly dollyCtx dopeSheetEditor dot dotProduct '
+ 'doubleProfileBirailSurface drag dragAttrContext draggerContext dropoffLocator '
+ 'duplicate duplicateCurve duplicateSurface dynCache dynControl dynExport dynExpression '
+ 'dynGlobals dynPaintEditor dynParticleCtx dynPref dynRelEdPanel dynRelEditor '
+ 'dynamicLoad editAttrLimits editDisplayLayerGlobals editDisplayLayerMembers '
+ 'editRenderLayerAdjustment editRenderLayerGlobals editRenderLayerMembers editor '
+ 'editorTemplate effector emit emitter enableDevice encodeString endString endsWith env '
+ 'equivalent equivalentTol erf error eval evalDeferred evalEcho event '
+ 'exactWorldBoundingBox exclusiveLightCheckBox exec executeForEachObject exists exp '
+ 'expression expressionEditorListen extendCurve extendSurface extrude fcheck fclose feof '
+ 'fflush fgetline fgetword file fileBrowserDialog fileDialog fileExtension fileInfo '
+ 'filetest filletCurve filter filterCurve filterExpand filterStudioImport '
+ 'findAllIntersections findAnimCurves findKeyframe findMenuItem findRelatedSkinCluster '
+ 'finder firstParentOf fitBspline flexor floatEq floatField floatFieldGrp floatScrollBar '
+ 'floatSlider floatSlider2 floatSliderButtonGrp floatSliderGrp floor flow fluidCacheInfo '
+ 'fluidEmitter fluidVoxelInfo flushUndo fmod fontDialog fopen formLayout format fprint '
+ 'frameLayout fread freeFormFillet frewind fromNativePath fwrite gamma gauss '
+ 'geometryConstraint getApplicationVersionAsFloat getAttr getClassification '
+ 'getDefaultBrush getFileList getFluidAttr getInputDeviceRange getMayaPanelTypes '
+ 'getModifiers getPanel getParticleAttr getPluginResource getenv getpid glRender '
+ 'glRenderEditor globalStitch gmatch goal gotoBindPose grabColor gradientControl '
+ 'gradientControlNoAttr graphDollyCtx graphSelectContext graphTrackCtx gravity grid '
+ 'gridLayout group groupObjectsByName HfAddAttractorToAS HfAssignAS HfBuildEqualMap '
+ 'HfBuildFurFiles HfBuildFurImages HfCancelAFR HfConnectASToHF HfCreateAttractor '
+ 'HfDeleteAS HfEditAS HfPerformCreateAS HfRemoveAttractorFromAS HfSelectAttached '
+ 'HfSelectAttractors HfUnAssignAS hardenPointCurve hardware hardwareRenderPanel '
+ 'headsUpDisplay headsUpMessage help helpLine hermite hide hilite hitTest hotBox hotkey '
+ 'hotkeyCheck hsv_to_rgb hudButton hudSlider hudSliderButton hwReflectionMap hwRender '
+ 'hwRenderLoad hyperGraph hyperPanel hyperShade hypot iconTextButton iconTextCheckBox '
+ 'iconTextRadioButton iconTextRadioCollection iconTextScrollList iconTextStaticLabel '
+ 'ikHandle ikHandleCtx ikHandleDisplayScale ikSolver ikSplineHandleCtx ikSystem '
+ 'ikSystemInfo ikfkDisplayMethod illustratorCurves image imfPlugins inheritTransform '
+ 'insertJoint insertJointCtx insertKeyCtx insertKnotCurve insertKnotSurface instance '
+ 'instanceable instancer intField intFieldGrp intScrollBar intSlider intSliderGrp '
+ 'interToUI internalVar intersect iprEngine isAnimCurve isConnected isDirty isParentOf '
+ 'isSameObject isTrue isValidObjectName isValidString isValidUiName isolateSelect '
+ 'itemFilter itemFilterAttr itemFilterRender itemFilterType joint jointCluster jointCtx '
+ 'jointDisplayScale jointLattice keyTangent keyframe keyframeOutliner '
+ 'keyframeRegionCurrentTimeCtx keyframeRegionDirectKeyCtx keyframeRegionDollyCtx '
+ 'keyframeRegionInsertKeyCtx keyframeRegionMoveKeyCtx keyframeRegionScaleKeyCtx '
+ 'keyframeRegionSelectKeyCtx keyframeRegionSetKeyCtx keyframeRegionTrackCtx '
+ 'keyframeStats lassoContext lattice latticeDeformKeyCtx launch launchImageEditor '
+ 'layerButton layeredShaderPort layeredTexturePort layout layoutDialog lightList '
+ 'lightListEditor lightListPanel lightlink lineIntersection linearPrecision linstep '
+ 'listAnimatable listAttr listCameras listConnections listDeviceAttachments listHistory '
+ 'listInputDeviceAxes listInputDeviceButtons listInputDevices listMenuAnnotation '
+ 'listNodeTypes listPanelCategories listRelatives listSets listTransforms '
+ 'listUnselected listerEditor loadFluid loadNewShelf loadPlugin '
+ 'loadPluginLanguageResources loadPrefObjects localizedPanelLabel lockNode loft log '
+ 'longNameOf lookThru ls lsThroughFilter lsType lsUI Mayatomr mag makeIdentity makeLive '
+ 'makePaintable makeRoll makeSingleSurface makeTubeOn makebot manipMoveContext '
+ 'manipMoveLimitsCtx manipOptions manipRotateContext manipRotateLimitsCtx '
+ 'manipScaleContext manipScaleLimitsCtx marker match max memory menu menuBarLayout '
+ 'menuEditor menuItem menuItemToShelf menuSet menuSetPref messageLine min minimizeApp '
+ 'mirrorJoint modelCurrentTimeCtx modelEditor modelPanel mouse movIn movOut move '
+ 'moveIKtoFK moveKeyCtx moveVertexAlongDirection multiProfileBirailSurface mute '
+ 'nParticle nameCommand nameField namespace namespaceInfo newPanelItems newton nodeCast '
+ 'nodeIconButton nodeOutliner nodePreset nodeType noise nonLinear normalConstraint '
+ 'normalize nurbsBoolean nurbsCopyUVSet nurbsCube nurbsEditUV nurbsPlane nurbsSelect '
+ 'nurbsSquare nurbsToPoly nurbsToPolygonsPref nurbsToSubdiv nurbsToSubdivPref '
+ 'nurbsUVSet nurbsViewDirectionVector objExists objectCenter objectLayer objectType '
+ 'objectTypeUI obsoleteProc oceanNurbsPreviewPlane offsetCurve offsetCurveOnSurface '
+ 'offsetSurface openGLExtension openMayaPref optionMenu optionMenuGrp optionVar orbit '
+ 'orbitCtx orientConstraint outlinerEditor outlinerPanel overrideModifier '
+ 'paintEffectsDisplay pairBlend palettePort paneLayout panel panelConfiguration '
+ 'panelHistory paramDimContext paramDimension paramLocator parent parentConstraint '
+ 'particle particleExists particleInstancer particleRenderInfo partition pasteKey '
+ 'pathAnimation pause pclose percent performanceOptions pfxstrokes pickWalk picture '
+ 'pixelMove planarSrf plane play playbackOptions playblast plugAttr plugNode pluginInfo '
+ 'pluginResourceUtil pointConstraint pointCurveConstraint pointLight pointMatrixMult '
+ 'pointOnCurve pointOnSurface pointPosition poleVectorConstraint polyAppend '
+ 'polyAppendFacetCtx polyAppendVertex polyAutoProjection polyAverageNormal '
+ 'polyAverageVertex polyBevel polyBlendColor polyBlindData polyBoolOp polyBridgeEdge '
+ 'polyCacheMonitor polyCheck polyChipOff polyClipboard polyCloseBorder polyCollapseEdge '
+ 'polyCollapseFacet polyColorBlindData polyColorDel polyColorPerVertex polyColorSet '
+ 'polyCompare polyCone polyCopyUV polyCrease polyCreaseCtx polyCreateFacet '
+ 'polyCreateFacetCtx polyCube polyCut polyCutCtx polyCylinder polyCylindricalProjection '
+ 'polyDelEdge polyDelFacet polyDelVertex polyDuplicateAndConnect polyDuplicateEdge '
+ 'polyEditUV polyEditUVShell polyEvaluate polyExtrudeEdge polyExtrudeFacet '
+ 'polyExtrudeVertex polyFlipEdge polyFlipUV polyForceUV polyGeoSampler polyHelix '
+ 'polyInfo polyInstallAction polyLayoutUV polyListComponentConversion polyMapCut '
+ 'polyMapDel polyMapSew polyMapSewMove polyMergeEdge polyMergeEdgeCtx polyMergeFacet '
+ 'polyMergeFacetCtx polyMergeUV polyMergeVertex polyMirrorFace polyMoveEdge '
+ 'polyMoveFacet polyMoveFacetUV polyMoveUV polyMoveVertex polyNormal polyNormalPerVertex '
+ 'polyNormalizeUV polyOptUvs polyOptions polyOutput polyPipe polyPlanarProjection '
+ 'polyPlane polyPlatonicSolid polyPoke polyPrimitive polyPrism polyProjection '
+ 'polyPyramid polyQuad polyQueryBlindData polyReduce polySelect polySelectConstraint '
+ 'polySelectConstraintMonitor polySelectCtx polySelectEditCtx polySeparate '
+ 'polySetToFaceNormal polySewEdge polyShortestPathCtx polySmooth polySoftEdge '
+ 'polySphere polySphericalProjection polySplit polySplitCtx polySplitEdge polySplitRing '
+ 'polySplitVertex polyStraightenUVBorder polySubdivideEdge polySubdivideFacet '
+ 'polyToSubdiv polyTorus polyTransfer polyTriangulate polyUVSet polyUnite polyWedgeFace '
+ 'popen popupMenu pose pow preloadRefEd print progressBar progressWindow projFileViewer '
+ 'projectCurve projectTangent projectionContext projectionManip promptDialog propModCtx '
+ 'propMove psdChannelOutliner psdEditTextureFile psdExport psdTextureFile putenv pwd '
+ 'python querySubdiv quit rad_to_deg radial radioButton radioButtonGrp radioCollection '
+ 'radioMenuItemCollection rampColorPort rand randomizeFollicles randstate rangeControl '
+ 'readTake rebuildCurve rebuildSurface recordAttr recordDevice redo reference '
+ 'referenceEdit referenceQuery refineSubdivSelectionList refresh refreshAE '
+ 'registerPluginResource rehash reloadImage removeJoint removeMultiInstance '
+ 'removePanelCategory rename renameAttr renameSelectionList renameUI render '
+ 'renderGlobalsNode renderInfo renderLayerButton renderLayerParent '
+ 'renderLayerPostProcess renderLayerUnparent renderManip renderPartition '
+ 'renderQualityNode renderSettings renderThumbnailUpdate renderWindowEditor '
+ 'renderWindowSelectContext renderer reorder reorderDeformers requires reroot '
+ 'resampleFluid resetAE resetPfxToPolyCamera resetTool resolutionNode retarget '
+ 'reverseCurve reverseSurface revolve rgb_to_hsv rigidBody rigidSolver roll rollCtx '
+ 'rootOf rot rotate rotationInterpolation roundConstantRadius rowColumnLayout rowLayout '
+ 'runTimeCommand runup sampleImage saveAllShelves saveAttrPreset saveFluid saveImage '
+ 'saveInitialState saveMenu savePrefObjects savePrefs saveShelf saveToolSettings scale '
+ 'scaleBrushBrightness scaleComponents scaleConstraint scaleKey scaleKeyCtx sceneEditor '
+ 'sceneUIReplacement scmh scriptCtx scriptEditorInfo scriptJob scriptNode scriptTable '
+ 'scriptToShelf scriptedPanel scriptedPanelType scrollField scrollLayout sculpt '
+ 'searchPathArray seed selLoadSettings select selectContext selectCurveCV selectKey '
+ 'selectKeyCtx selectKeyframeRegionCtx selectMode selectPref selectPriority selectType '
+ 'selectedNodes selectionConnection separator setAttr setAttrEnumResource '
+ 'setAttrMapping setAttrNiceNameResource setConstraintRestPosition '
+ 'setDefaultShadingGroup setDrivenKeyframe setDynamic setEditCtx setEditor setFluidAttr '
+ 'setFocus setInfinity setInputDeviceMapping setKeyCtx setKeyPath setKeyframe '
+ 'setKeyframeBlendshapeTargetWts setMenuMode setNodeNiceNameResource setNodeTypeFlag '
+ 'setParent setParticleAttr setPfxToPolyCamera setPluginResource setProject '
+ 'setStampDensity setStartupMessage setState setToolTo setUITemplate setXformManip sets '
+ 'shadingConnection shadingGeometryRelCtx shadingLightRelCtx shadingNetworkCompare '
+ 'shadingNode shapeCompare shelfButton shelfLayout shelfTabLayout shellField '
+ 'shortNameOf showHelp showHidden showManipCtx showSelectionInTitle '
+ 'showShadingGroupAttrEditor showWindow sign simplify sin singleProfileBirailSurface '
+ 'size sizeBytes skinCluster skinPercent smoothCurve smoothTangentSurface smoothstep '
+ 'snap2to2 snapKey snapMode snapTogetherCtx snapshot soft softMod softModCtx sort sound '
+ 'soundControl source spaceLocator sphere sphrand spotLight spotLightPreviewPort '
+ 'spreadSheetEditor spring sqrt squareSurface srtContext stackTrace startString '
+ 'startsWith stitchAndExplodeShell stitchSurface stitchSurfacePoints strcmp '
+ 'stringArrayCatenate stringArrayContains stringArrayCount stringArrayInsertAtIndex '
+ 'stringArrayIntersector stringArrayRemove stringArrayRemoveAtIndex '
+ 'stringArrayRemoveDuplicates stringArrayRemoveExact stringArrayToString '
+ 'stringToStringArray strip stripPrefixFromName stroke subdAutoProjection '
+ 'subdCleanTopology subdCollapse subdDuplicateAndConnect subdEditUV '
+ 'subdListComponentConversion subdMapCut subdMapSewMove subdMatchTopology subdMirror '
+ 'subdToBlind subdToPoly subdTransferUVsToCache subdiv subdivCrease '
+ 'subdivDisplaySmoothness substitute substituteAllString substituteGeometry substring '
+ 'surface surfaceSampler surfaceShaderList swatchDisplayPort switchTable symbolButton '
+ 'symbolCheckBox sysFile system tabLayout tan tangentConstraint texLatticeDeformContext '
+ 'texManipContext texMoveContext texMoveUVShellContext texRotateContext texScaleContext '
+ 'texSelectContext texSelectShortestPathCtx texSmudgeUVContext texWinToolCtx text '
+ 'textCurves textField textFieldButtonGrp textFieldGrp textManip textScrollList '
+ 'textToShelf textureDisplacePlane textureHairColor texturePlacementContext '
+ 'textureWindow threadCount threePointArcCtx timeControl timePort timerX toNativePath '
+ 'toggle toggleAxis toggleWindowVisibility tokenize tokenizeList tolerance tolower '
+ 'toolButton toolCollection toolDropped toolHasOptions toolPropertyWindow torus toupper '
+ 'trace track trackCtx transferAttributes transformCompare transformLimits translator '
+ 'trim trunc truncateFluidCache truncateHairCache tumble tumbleCtx turbulence '
+ 'twoPointArcCtx uiRes uiTemplate unassignInputDevice undo undoInfo ungroup uniform unit '
+ 'unloadPlugin untangleUV untitledFileName untrim upAxis updateAE userCtx uvLink '
+ 'uvSnapshot validateShelfName vectorize view2dToolCtx viewCamera viewClipPlane '
+ 'viewFit viewHeadOn viewLookAt viewManip viewPlace viewSet visor volumeAxis vortex '
+ 'waitCursor warning webBrowser webBrowserPrefs whatIs window windowPref wire '
+ 'wireContext workspace wrinkle wrinkleContext writeTake xbmLangPathList xform',
illegal: '</',
contains: [
hljs.C_NUMBER_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '`',
end: '`',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{ // eats variables
begin: /[$%@](\^\w\b|#\w+|[^\s\w{]|\{\w+\}|\w+)/ },
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
}
var mel_1 = mel;
/*
Language: Mercury
Author: mucaho <mkucko@gmail.com>
Description: Mercury is a logic/functional programming language which combines the clarity and expressiveness of declarative programming with advanced static analysis and error detection features.
Website: https://www.mercurylang.org
*/
function mercury(hljs) {
const KEYWORDS = {
keyword:
'module use_module import_module include_module end_module initialise '
+ 'mutable initialize finalize finalise interface implementation pred '
+ 'mode func type inst solver any_pred any_func is semidet det nondet '
+ 'multi erroneous failure cc_nondet cc_multi typeclass instance where '
+ 'pragma promise external trace atomic or_else require_complete_switch '
+ 'require_det require_semidet require_multi require_nondet '
+ 'require_cc_multi require_cc_nondet require_erroneous require_failure',
meta:
// pragma
'inline no_inline type_spec source_file fact_table obsolete memo '
+ 'loop_check minimal_model terminates does_not_terminate '
+ 'check_termination promise_equivalent_clauses '
// preprocessor
+ 'foreign_proc foreign_decl foreign_code foreign_type '
+ 'foreign_import_module foreign_export_enum foreign_export '
+ 'foreign_enum may_call_mercury will_not_call_mercury thread_safe '
+ 'not_thread_safe maybe_thread_safe promise_pure promise_semipure '
+ 'tabled_for_io local untrailed trailed attach_to_io_state '
+ 'can_pass_as_mercury_type stable will_not_throw_exception '
+ 'may_modify_trail will_not_modify_trail may_duplicate '
+ 'may_not_duplicate affects_liveness does_not_affect_liveness '
+ 'doesnt_affect_liveness no_sharing unknown_sharing sharing',
built_in:
'some all not if then else true fail false try catch catch_any '
+ 'semidet_true semidet_false semidet_fail impure_true impure semipure'
};
const COMMENT = hljs.COMMENT('%', '$');
const NUMCODE = {
className: 'number',
begin: "0'.\\|0[box][0-9a-fA-F]*"
};
const ATOM = hljs.inherit(hljs.APOS_STRING_MODE, { relevance: 0 });
const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, { relevance: 0 });
const STRING_FMT = {
className: 'subst',
begin: '\\\\[abfnrtv]\\|\\\\x[0-9a-fA-F]*\\\\\\|%[-+# *.0-9]*[dioxXucsfeEgGp]',
relevance: 0
};
STRING.contains = STRING.contains.slice(); // we need our own copy of contains
STRING.contains.push(STRING_FMT);
const IMPLICATION = {
className: 'built_in',
variants: [
{ begin: '<=>' },
{
begin: '<=',
relevance: 0
},
{
begin: '=>',
relevance: 0
},
{ begin: '/\\\\' },
{ begin: '\\\\/' }
]
};
const HEAD_BODY_CONJUNCTION = {
className: 'built_in',
variants: [
{ begin: ':-\\|-->' },
{
begin: '=',
relevance: 0
}
]
};
return {
name: 'Mercury',
aliases: [
'm',
'moo'
],
keywords: KEYWORDS,
contains: [
IMPLICATION,
HEAD_BODY_CONJUNCTION,
COMMENT,
hljs.C_BLOCK_COMMENT_MODE,
NUMCODE,
hljs.NUMBER_MODE,
ATOM,
STRING,
{ // relevance booster
begin: /:-/ },
{ // relevance booster
begin: /\.$/ }
]
};
}
var mercury_1 = mercury;
/*
Language: MIPS Assembly
Author: Nebuleon Fumika <nebuleon.fumika@gmail.com>
Description: MIPS Assembly (up to MIPS32R2)
Website: https://en.wikipedia.org/wiki/MIPS_architecture
Category: assembler
*/
function mipsasm(hljs) {
// local labels: %?[FB]?[AT]?\d{1,2}\w+
return {
name: 'MIPS Assembly',
case_insensitive: true,
aliases: [ 'mips' ],
keywords: {
$pattern: '\\.?' + hljs.IDENT_RE,
meta:
// GNU preprocs
'.2byte .4byte .align .ascii .asciz .balign .byte .code .data .else .end .endif .endm .endr .equ .err .exitm .extern .global .hword .if .ifdef .ifndef .include .irp .long .macro .rept .req .section .set .skip .space .text .word .ltorg ',
built_in:
'$0 $1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 ' // integer registers
+ '$16 $17 $18 $19 $20 $21 $22 $23 $24 $25 $26 $27 $28 $29 $30 $31 ' // integer registers
+ 'zero at v0 v1 a0 a1 a2 a3 a4 a5 a6 a7 ' // integer register aliases
+ 't0 t1 t2 t3 t4 t5 t6 t7 t8 t9 s0 s1 s2 s3 s4 s5 s6 s7 s8 ' // integer register aliases
+ 'k0 k1 gp sp fp ra ' // integer register aliases
+ '$f0 $f1 $f2 $f2 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15 ' // floating-point registers
+ '$f16 $f17 $f18 $f19 $f20 $f21 $f22 $f23 $f24 $f25 $f26 $f27 $f28 $f29 $f30 $f31 ' // floating-point registers
+ 'Context Random EntryLo0 EntryLo1 Context PageMask Wired EntryHi ' // Coprocessor 0 registers
+ 'HWREna BadVAddr Count Compare SR IntCtl SRSCtl SRSMap Cause EPC PRId ' // Coprocessor 0 registers
+ 'EBase Config Config1 Config2 Config3 LLAddr Debug DEPC DESAVE CacheErr ' // Coprocessor 0 registers
+ 'ECC ErrorEPC TagLo DataLo TagHi DataHi WatchLo WatchHi PerfCtl PerfCnt ' // Coprocessor 0 registers
},
contains: [
{
className: 'keyword',
begin: '\\b(' // mnemonics
// 32-bit integer instructions
+ 'addi?u?|andi?|b(al)?|beql?|bgez(al)?l?|bgtzl?|blezl?|bltz(al)?l?|'
+ 'bnel?|cl[oz]|divu?|ext|ins|j(al)?|jalr(\\.hb)?|jr(\\.hb)?|lbu?|lhu?|'
+ 'll|lui|lw[lr]?|maddu?|mfhi|mflo|movn|movz|move|msubu?|mthi|mtlo|mul|'
+ 'multu?|nop|nor|ori?|rotrv?|sb|sc|se[bh]|sh|sllv?|slti?u?|srav?|'
+ 'srlv?|subu?|sw[lr]?|xori?|wsbh|'
// floating-point instructions
+ 'abs\\.[sd]|add\\.[sd]|alnv.ps|bc1[ft]l?|'
+ 'c\\.(s?f|un|u?eq|[ou]lt|[ou]le|ngle?|seq|l[et]|ng[et])\\.[sd]|'
+ '(ceil|floor|round|trunc)\\.[lw]\\.[sd]|cfc1|cvt\\.d\\.[lsw]|'
+ 'cvt\\.l\\.[dsw]|cvt\\.ps\\.s|cvt\\.s\\.[dlw]|cvt\\.s\\.p[lu]|cvt\\.w\\.[dls]|'
+ 'div\\.[ds]|ldx?c1|luxc1|lwx?c1|madd\\.[sd]|mfc1|mov[fntz]?\\.[ds]|'
+ 'msub\\.[sd]|mth?c1|mul\\.[ds]|neg\\.[ds]|nmadd\\.[ds]|nmsub\\.[ds]|'
+ 'p[lu][lu]\\.ps|recip\\.fmt|r?sqrt\\.[ds]|sdx?c1|sub\\.[ds]|suxc1|'
+ 'swx?c1|'
// system control instructions
+ 'break|cache|d?eret|[de]i|ehb|mfc0|mtc0|pause|prefx?|rdhwr|'
+ 'rdpgpr|sdbbp|ssnop|synci?|syscall|teqi?|tgei?u?|tlb(p|r|w[ir])|'
+ 'tlti?u?|tnei?|wait|wrpgpr'
+ ')',
end: '\\s'
},
// lines ending with ; or # aren't really comments, probably auto-detect fail
hljs.COMMENT('[;#](?!\\s*$)', '$'),
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '\'',
end: '[^\\\\]\'',
relevance: 0
},
{
className: 'title',
begin: '\\|',
end: '\\|',
illegal: '\\n',
relevance: 0
},
{
className: 'number',
variants: [
{ // hex
begin: '0x[0-9a-f]+' },
{ // bare number
begin: '\\b-?\\d+' }
],
relevance: 0
},
{
className: 'symbol',
variants: [
{ // GNU MIPS syntax
begin: '^\\s*[a-z_\\.\\$][a-z0-9_\\.\\$]+:' },
{ // numbered local labels
begin: '^\\s*[0-9]+:' },
{ // number local label reference (backwards, forwards)
begin: '[0-9]+[bf]' }
],
relevance: 0
}
],
// forward slashes are not allowed
illegal: /\//
};
}
var mipsasm_1 = mipsasm;
/*
Language: Mizar
Description: The Mizar Language is a formal language derived from the mathematical vernacular.
Author: Kelley van Evert <kelleyvanevert@gmail.com>
Website: http://mizar.org/language/
Category: scientific
*/
function mizar(hljs) {
return {
name: 'Mizar',
keywords:
'environ vocabularies notations constructors definitions '
+ 'registrations theorems schemes requirements begin end definition '
+ 'registration cluster existence pred func defpred deffunc theorem '
+ 'proof let take assume then thus hence ex for st holds consider '
+ 'reconsider such that and in provided of as from be being by means '
+ 'equals implies iff redefine define now not or attr is mode '
+ 'suppose per cases set thesis contradiction scheme reserve struct '
+ 'correctness compatibility coherence symmetry assymetry '
+ 'reflexivity irreflexivity connectedness uniqueness commutativity '
+ 'idempotence involutiveness projectivity',
contains: [ hljs.COMMENT('::', '$') ]
};
}
var mizar_1 = mizar;
/*
Language: Perl
Author: Peter Leonov <gojpeg@yandex.ru>
Website: https://www.perl.org
Category: common
*/
/** @type LanguageFn */
function perl(hljs) {
const regex = hljs.regex;
const KEYWORDS = [
'abs',
'accept',
'alarm',
'and',
'atan2',
'bind',
'binmode',
'bless',
'break',
'caller',
'chdir',
'chmod',
'chomp',
'chop',
'chown',
'chr',
'chroot',
'close',
'closedir',
'connect',
'continue',
'cos',
'crypt',
'dbmclose',
'dbmopen',
'defined',
'delete',
'die',
'do',
'dump',
'each',
'else',
'elsif',
'endgrent',
'endhostent',
'endnetent',
'endprotoent',
'endpwent',
'endservent',
'eof',
'eval',
'exec',
'exists',
'exit',
'exp',
'fcntl',
'fileno',
'flock',
'for',
'foreach',
'fork',
'format',
'formline',
'getc',
'getgrent',
'getgrgid',
'getgrnam',
'gethostbyaddr',
'gethostbyname',
'gethostent',
'getlogin',
'getnetbyaddr',
'getnetbyname',
'getnetent',
'getpeername',
'getpgrp',
'getpriority',
'getprotobyname',
'getprotobynumber',
'getprotoent',
'getpwent',
'getpwnam',
'getpwuid',
'getservbyname',
'getservbyport',
'getservent',
'getsockname',
'getsockopt',
'given',
'glob',
'gmtime',
'goto',
'grep',
'gt',
'hex',
'if',
'index',
'int',
'ioctl',
'join',
'keys',
'kill',
'last',
'lc',
'lcfirst',
'length',
'link',
'listen',
'local',
'localtime',
'log',
'lstat',
'lt',
'ma',
'map',
'mkdir',
'msgctl',
'msgget',
'msgrcv',
'msgsnd',
'my',
'ne',
'next',
'no',
'not',
'oct',
'open',
'opendir',
'or',
'ord',
'our',
'pack',
'package',
'pipe',
'pop',
'pos',
'print',
'printf',
'prototype',
'push',
'q|0',
'qq',
'quotemeta',
'qw',
'qx',
'rand',
'read',
'readdir',
'readline',
'readlink',
'readpipe',
'recv',
'redo',
'ref',
'rename',
'require',
'reset',
'return',
'reverse',
'rewinddir',
'rindex',
'rmdir',
'say',
'scalar',
'seek',
'seekdir',
'select',
'semctl',
'semget',
'semop',
'send',
'setgrent',
'sethostent',
'setnetent',
'setpgrp',
'setpriority',
'setprotoent',
'setpwent',
'setservent',
'setsockopt',
'shift',
'shmctl',
'shmget',
'shmread',
'shmwrite',
'shutdown',
'sin',
'sleep',
'socket',
'socketpair',
'sort',
'splice',
'split',
'sprintf',
'sqrt',
'srand',
'stat',
'state',
'study',
'sub',
'substr',
'symlink',
'syscall',
'sysopen',
'sysread',
'sysseek',
'system',
'syswrite',
'tell',
'telldir',
'tie',
'tied',
'time',
'times',
'tr',
'truncate',
'uc',
'ucfirst',
'umask',
'undef',
'unless',
'unlink',
'unpack',
'unshift',
'untie',
'until',
'use',
'utime',
'values',
'vec',
'wait',
'waitpid',
'wantarray',
'warn',
'when',
'while',
'write',
'x|0',
'xor',
'y|0'
];
// https://perldoc.perl.org/perlre#Modifiers
const REGEX_MODIFIERS = /[dualxmsipngr]{0,12}/; // aa and xx are valid, making max length 12
const PERL_KEYWORDS = {
$pattern: /[\w.]+/,
keyword: KEYWORDS.join(" ")
};
const SUBST = {
className: 'subst',
begin: '[$@]\\{',
end: '\\}',
keywords: PERL_KEYWORDS
};
const METHOD = {
begin: /->\{/,
end: /\}/
// contains defined later
};
const VAR = { variants: [
{ begin: /\$\d/ },
{ begin: regex.concat(
/[$%@](\^\w\b|#\w+(::\w+)*|\{\w+\}|\w+(::\w*)*)/,
// negative look-ahead tries to avoid matching patterns that are not
// Perl at all like $ident$, @ident@, etc.
`(?![A-Za-z])(?![@$%])`
) },
{
begin: /[$%@][^\s\w{]/,
relevance: 0
}
] };
const STRING_CONTAINS = [
hljs.BACKSLASH_ESCAPE,
SUBST,
VAR
];
const REGEX_DELIMS = [
/!/,
/\//,
/\|/,
/\?/,
/'/,
/"/, // valid but infrequent and weird
/#/ // valid but infrequent and weird
];
/**
* @param {string|RegExp} prefix
* @param {string|RegExp} open
* @param {string|RegExp} close
*/
const PAIRED_DOUBLE_RE = (prefix, open, close = '\\1') => {
const middle = (close === '\\1')
? close
: regex.concat(close, open);
return regex.concat(
regex.concat("(?:", prefix, ")"),
open,
/(?:\\.|[^\\\/])*?/,
middle,
/(?:\\.|[^\\\/])*?/,
close,
REGEX_MODIFIERS
);
};
/**
* @param {string|RegExp} prefix
* @param {string|RegExp} open
* @param {string|RegExp} close
*/
const PAIRED_RE = (prefix, open, close) => {
return regex.concat(
regex.concat("(?:", prefix, ")"),
open,
/(?:\\.|[^\\\/])*?/,
close,
REGEX_MODIFIERS
);
};
const PERL_DEFAULT_CONTAINS = [
VAR,
hljs.HASH_COMMENT_MODE,
hljs.COMMENT(
/^=\w/,
/=cut/,
{ endsWithParent: true }
),
METHOD,
{
className: 'string',
contains: STRING_CONTAINS,
variants: [
{
begin: 'q[qwxr]?\\s*\\(',
end: '\\)',
relevance: 5
},
{
begin: 'q[qwxr]?\\s*\\[',
end: '\\]',
relevance: 5
},
{
begin: 'q[qwxr]?\\s*\\{',
end: '\\}',
relevance: 5
},
{
begin: 'q[qwxr]?\\s*\\|',
end: '\\|',
relevance: 5
},
{
begin: 'q[qwxr]?\\s*<',
end: '>',
relevance: 5
},
{
begin: 'qw\\s+q',
end: 'q',
relevance: 5
},
{
begin: '\'',
end: '\'',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '"',
end: '"'
},
{
begin: '`',
end: '`',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /\{\w+\}/,
relevance: 0
},
{
begin: '-?\\w+\\s*=>',
relevance: 0
}
]
},
{
className: 'number',
begin: '(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b',
relevance: 0
},
{ // regexp container
begin: '(\\/\\/|' + hljs.RE_STARTERS_RE + '|\\b(split|return|print|reverse|grep)\\b)\\s*',
keywords: 'split return print reverse grep',
relevance: 0,
contains: [
hljs.HASH_COMMENT_MODE,
{
className: 'regexp',
variants: [
// allow matching common delimiters
{ begin: PAIRED_DOUBLE_RE("s|tr|y", regex.either(...REGEX_DELIMS, { capture: true })) },
// and then paired delmis
{ begin: PAIRED_DOUBLE_RE("s|tr|y", "\\(", "\\)") },
{ begin: PAIRED_DOUBLE_RE("s|tr|y", "\\[", "\\]") },
{ begin: PAIRED_DOUBLE_RE("s|tr|y", "\\{", "\\}") }
],
relevance: 2
},
{
className: 'regexp',
variants: [
{
// could be a comment in many languages so do not count
// as relevant
begin: /(m|qr)\/\//,
relevance: 0
},
// prefix is optional with /regex/
{ begin: PAIRED_RE("(?:m|qr)?", /\//, /\//) },
// allow matching common delimiters
{ begin: PAIRED_RE("m|qr", regex.either(...REGEX_DELIMS, { capture: true }), /\1/) },
// allow common paired delmins
{ begin: PAIRED_RE("m|qr", /\(/, /\)/) },
{ begin: PAIRED_RE("m|qr", /\[/, /\]/) },
{ begin: PAIRED_RE("m|qr", /\{/, /\}/) }
]
}
]
},
{
className: 'function',
beginKeywords: 'sub',
end: '(\\s*\\(.*?\\))?[;{]',
excludeEnd: true,
relevance: 5,
contains: [ hljs.TITLE_MODE ]
},
{
begin: '-\\w\\b',
relevance: 0
},
{
begin: "^__DATA__$",
end: "^__END__$",
subLanguage: 'mojolicious',
contains: [
{
begin: "^@@.*",
end: "$",
className: "comment"
}
]
}
];
SUBST.contains = PERL_DEFAULT_CONTAINS;
METHOD.contains = PERL_DEFAULT_CONTAINS;
return {
name: 'Perl',
aliases: [
'pl',
'pm'
],
keywords: PERL_KEYWORDS,
contains: PERL_DEFAULT_CONTAINS
};
}
var perl_1 = perl;
/*
Language: Mojolicious
Requires: xml.js, perl.js
Author: Dotan Dimet <dotan@corky.net>
Description: Mojolicious .ep (Embedded Perl) templates
Website: https://mojolicious.org
Category: template
*/
function mojolicious(hljs) {
return {
name: 'Mojolicious',
subLanguage: 'xml',
contains: [
{
className: 'meta',
begin: '^__(END|DATA)__$'
},
// mojolicious line
{
begin: "^\\s*%{1,2}={0,2}",
end: '$',
subLanguage: 'perl'
},
// mojolicious block
{
begin: "<%{1,2}={0,2}",
end: "={0,1}%>",
subLanguage: 'perl',
excludeBegin: true,
excludeEnd: true
}
]
};
}
var mojolicious_1 = mojolicious;
/*
Language: Monkey
Description: Monkey2 is an easy to use, cross platform, games oriented programming language from Blitz Research.
Author: Arthur Bikmullin <devolonter@gmail.com>
Website: https://blitzresearch.itch.io/monkey2
*/
function monkey(hljs) {
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
{ begin: '[$][a-fA-F0-9]+' },
hljs.NUMBER_MODE
]
};
const FUNC_DEFINITION = {
variants: [
{ match: [
/(function|method)/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE,
] },
],
scope: {
1: "keyword",
3: "title.function"
}
};
const CLASS_DEFINITION = {
variants: [
{ match: [
/(class|interface|extends|implements)/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE,
] },
],
scope: {
1: "keyword",
3: "title.class"
}
};
const BUILT_INS = [
"DebugLog",
"DebugStop",
"Error",
"Print",
"ACos",
"ACosr",
"ASin",
"ASinr",
"ATan",
"ATan2",
"ATan2r",
"ATanr",
"Abs",
"Abs",
"Ceil",
"Clamp",
"Clamp",
"Cos",
"Cosr",
"Exp",
"Floor",
"Log",
"Max",
"Max",
"Min",
"Min",
"Pow",
"Sgn",
"Sgn",
"Sin",
"Sinr",
"Sqrt",
"Tan",
"Tanr",
"Seed",
"PI",
"HALFPI",
"TWOPI"
];
const LITERALS = [
"true",
"false",
"null"
];
const KEYWORDS = [
"public",
"private",
"property",
"continue",
"exit",
"extern",
"new",
"try",
"catch",
"eachin",
"not",
"abstract",
"final",
"select",
"case",
"default",
"const",
"local",
"global",
"field",
"end",
"if",
"then",
"else",
"elseif",
"endif",
"while",
"wend",
"repeat",
"until",
"forever",
"for",
"to",
"step",
"next",
"return",
"module",
"inline",
"throw",
"import",
// not positive, but these are not literals
"and",
"or",
"shl",
"shr",
"mod"
];
return {
name: 'Monkey',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS,
literal: LITERALS
},
illegal: /\/\*/,
contains: [
hljs.COMMENT('#rem', '#end'),
hljs.COMMENT(
"'",
'$',
{ relevance: 0 }
),
FUNC_DEFINITION,
CLASS_DEFINITION,
{
className: 'variable.language',
begin: /\b(self|super)\b/
},
{
className: 'meta',
begin: /\s*#/,
end: '$',
keywords: { keyword: 'if else elseif endif end then' }
},
{
match: [
/^\s*/,
/strict\b/
],
scope: { 2: "meta" }
},
{
beginKeywords: 'alias',
end: '=',
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
},
hljs.QUOTE_STRING_MODE,
NUMBER
]
};
}
var monkey_1 = monkey;
/*
Language: MoonScript
Author: Billy Quith <chinbillybilbo@gmail.com>
Description: MoonScript is a programming language that transcompiles to Lua.
Origin: coffeescript.js
Website: http://moonscript.org/
Category: scripting
*/
function moonscript(hljs) {
const KEYWORDS = {
keyword:
// Moonscript keywords
'if then not for in while do return else elseif break continue switch and or '
+ 'unless when class extends super local import export from using',
literal:
'true false nil',
built_in:
'_G _VERSION assert collectgarbage dofile error getfenv getmetatable ipairs load '
+ 'loadfile loadstring module next pairs pcall print rawequal rawget rawset require '
+ 'select setfenv setmetatable tonumber tostring type unpack xpcall coroutine debug '
+ 'io math os package string table'
};
const JS_IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';
const SUBST = {
className: 'subst',
begin: /#\{/,
end: /\}/,
keywords: KEYWORDS
};
const EXPRESSIONS = [
hljs.inherit(hljs.C_NUMBER_MODE,
{ starts: {
end: '(\\s*/)?',
relevance: 0
} }), // a number tries to eat the following slash to prevent treating it as a regexp
{
className: 'string',
variants: [
{
begin: /'/,
end: /'/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
}
]
},
{
className: 'built_in',
begin: '@__' + hljs.IDENT_RE
},
{ begin: '@' + hljs.IDENT_RE // relevance booster on par with CoffeeScript
},
{ begin: hljs.IDENT_RE + '\\\\' + hljs.IDENT_RE // inst\method
}
];
SUBST.contains = EXPRESSIONS;
const TITLE = hljs.inherit(hljs.TITLE_MODE, { begin: JS_IDENT_RE });
const POSSIBLE_PARAMS_RE = '(\\(.*\\)\\s*)?\\B[-=]>';
const PARAMS = {
className: 'params',
begin: '\\([^\\(]',
returnBegin: true,
/* We need another contained nameless mode to not have every nested
pair of parens to be called "params" */
contains: [
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [ 'self' ].concat(EXPRESSIONS)
}
]
};
return {
name: 'MoonScript',
aliases: [ 'moon' ],
keywords: KEYWORDS,
illegal: /\/\*/,
contains: EXPRESSIONS.concat([
hljs.COMMENT('--', '$'),
{
className: 'function', // function: -> =>
begin: '^\\s*' + JS_IDENT_RE + '\\s*=\\s*' + POSSIBLE_PARAMS_RE,
end: '[-=]>',
returnBegin: true,
contains: [
TITLE,
PARAMS
]
},
{
begin: /[\(,:=]\s*/, // anonymous function start
relevance: 0,
contains: [
{
className: 'function',
begin: POSSIBLE_PARAMS_RE,
end: '[-=]>',
returnBegin: true,
contains: [ PARAMS ]
}
]
},
{
className: 'class',
beginKeywords: 'class',
end: '$',
illegal: /[:="\[\]]/,
contains: [
{
beginKeywords: 'extends',
endsWithParent: true,
illegal: /[:="\[\]]/,
contains: [ TITLE ]
},
TITLE
]
},
{
className: 'name', // table
begin: JS_IDENT_RE + ':',
end: ':',
returnBegin: true,
returnEnd: true,
relevance: 0
}
])
};
}
var moonscript_1 = moonscript;
/*
Language: N1QL
Author: Andres Täht <andres.taht@gmail.com>
Contributors: Rene Saarsoo <nene@triin.net>
Description: Couchbase query language
Website: https://www.couchbase.com/products/n1ql
*/
function n1ql(hljs) {
// Taken from http://developer.couchbase.com/documentation/server/current/n1ql/n1ql-language-reference/reservedwords.html
const KEYWORDS = [
"all",
"alter",
"analyze",
"and",
"any",
"array",
"as",
"asc",
"begin",
"between",
"binary",
"boolean",
"break",
"bucket",
"build",
"by",
"call",
"case",
"cast",
"cluster",
"collate",
"collection",
"commit",
"connect",
"continue",
"correlate",
"cover",
"create",
"database",
"dataset",
"datastore",
"declare",
"decrement",
"delete",
"derived",
"desc",
"describe",
"distinct",
"do",
"drop",
"each",
"element",
"else",
"end",
"every",
"except",
"exclude",
"execute",
"exists",
"explain",
"fetch",
"first",
"flatten",
"for",
"force",
"from",
"function",
"grant",
"group",
"gsi",
"having",
"if",
"ignore",
"ilike",
"in",
"include",
"increment",
"index",
"infer",
"inline",
"inner",
"insert",
"intersect",
"into",
"is",
"join",
"key",
"keys",
"keyspace",
"known",
"last",
"left",
"let",
"letting",
"like",
"limit",
"lsm",
"map",
"mapping",
"matched",
"materialized",
"merge",
"minus",
"namespace",
"nest",
"not",
"number",
"object",
"offset",
"on",
"option",
"or",
"order",
"outer",
"over",
"parse",
"partition",
"password",
"path",
"pool",
"prepare",
"primary",
"private",
"privilege",
"procedure",
"public",
"raw",
"realm",
"reduce",
"rename",
"return",
"returning",
"revoke",
"right",
"role",
"rollback",
"satisfies",
"schema",
"select",
"self",
"semi",
"set",
"show",
"some",
"start",
"statistics",
"string",
"system",
"then",
"to",
"transaction",
"trigger",
"truncate",
"under",
"union",
"unique",
"unknown",
"unnest",
"unset",
"update",
"upsert",
"use",
"user",
"using",
"validate",
"value",
"valued",
"values",
"via",
"view",
"when",
"where",
"while",
"with",
"within",
"work",
"xor"
];
// Taken from http://developer.couchbase.com/documentation/server/4.5/n1ql/n1ql-language-reference/literals.html
const LITERALS = [
"true",
"false",
"null",
"missing|5"
];
// Taken from http://developer.couchbase.com/documentation/server/4.5/n1ql/n1ql-language-reference/functions.html
const BUILT_INS = [
"array_agg",
"array_append",
"array_concat",
"array_contains",
"array_count",
"array_distinct",
"array_ifnull",
"array_length",
"array_max",
"array_min",
"array_position",
"array_prepend",
"array_put",
"array_range",
"array_remove",
"array_repeat",
"array_replace",
"array_reverse",
"array_sort",
"array_sum",
"avg",
"count",
"max",
"min",
"sum",
"greatest",
"least",
"ifmissing",
"ifmissingornull",
"ifnull",
"missingif",
"nullif",
"ifinf",
"ifnan",
"ifnanorinf",
"naninf",
"neginfif",
"posinfif",
"clock_millis",
"clock_str",
"date_add_millis",
"date_add_str",
"date_diff_millis",
"date_diff_str",
"date_part_millis",
"date_part_str",
"date_trunc_millis",
"date_trunc_str",
"duration_to_str",
"millis",
"str_to_millis",
"millis_to_str",
"millis_to_utc",
"millis_to_zone_name",
"now_millis",
"now_str",
"str_to_duration",
"str_to_utc",
"str_to_zone_name",
"decode_json",
"encode_json",
"encoded_size",
"poly_length",
"base64",
"base64_encode",
"base64_decode",
"meta",
"uuid",
"abs",
"acos",
"asin",
"atan",
"atan2",
"ceil",
"cos",
"degrees",
"e",
"exp",
"ln",
"log",
"floor",
"pi",
"power",
"radians",
"random",
"round",
"sign",
"sin",
"sqrt",
"tan",
"trunc",
"object_length",
"object_names",
"object_pairs",
"object_inner_pairs",
"object_values",
"object_inner_values",
"object_add",
"object_put",
"object_remove",
"object_unwrap",
"regexp_contains",
"regexp_like",
"regexp_position",
"regexp_replace",
"contains",
"initcap",
"length",
"lower",
"ltrim",
"position",
"repeat",
"replace",
"rtrim",
"split",
"substr",
"title",
"trim",
"upper",
"isarray",
"isatom",
"isboolean",
"isnumber",
"isobject",
"isstring",
"type",
"toarray",
"toatom",
"toboolean",
"tonumber",
"toobject",
"tostring"
];
return {
name: 'N1QL',
case_insensitive: true,
contains: [
{
beginKeywords:
'build create index delete drop explain infer|10 insert merge prepare select update upsert|10',
end: /;/,
keywords: {
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILT_INS
},
contains: [
{
className: 'string',
begin: '\'',
end: '\'',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
className: 'string',
begin: '"',
end: '"',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
className: 'symbol',
begin: '`',
end: '`',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
hljs.C_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
hljs.C_BLOCK_COMMENT_MODE
]
};
}
var n1ql_1 = n1ql;
/*
Language: NestedText
Description: NestedText is a file format for holding data that is to be entered, edited, or viewed by people.
Website: https://nestedtext.org/
Category: config
*/
/** @type LanguageFn */
function nestedtext(hljs) {
const NESTED = {
match: [
/^\s*(?=\S)/, // have to look forward here to avoid polynomial backtracking
/[^:]+/,
/:\s*/,
/$/
],
className: {
2: "attribute",
3: "punctuation"
}
};
const DICTIONARY_ITEM = {
match: [
/^\s*(?=\S)/, // have to look forward here to avoid polynomial backtracking
/[^:]*[^: ]/,
/[ ]*:/,
/[ ]/,
/.*$/
],
className: {
2: "attribute",
3: "punctuation",
5: "string"
}
};
const STRING = {
match: [
/^\s*/,
/>/,
/[ ]/,
/.*$/
],
className: {
2: "punctuation",
4: "string"
}
};
const LIST_ITEM = {
variants: [
{ match: [
/^\s*/,
/-/,
/[ ]/,
/.*$/
] },
{ match: [
/^\s*/,
/-$/
] }
],
className: {
2: "bullet",
4: "string"
}
};
return {
name: 'Nested Text',
aliases: [ 'nt' ],
contains: [
hljs.inherit(hljs.HASH_COMMENT_MODE, {
begin: /^\s*(?=#)/,
excludeBegin: true
}),
LIST_ITEM,
STRING,
NESTED,
DICTIONARY_ITEM
]
};
}
var nestedtext_1 = nestedtext;
/*
Language: Nginx config
Author: Peter Leonov <gojpeg@yandex.ru>
Contributors: Ivan Sagalaev <maniac@softwaremaniacs.org>
Category: config, web
Website: https://www.nginx.com
*/
/** @type LanguageFn */
function nginx(hljs) {
const regex = hljs.regex;
const VAR = {
className: 'variable',
variants: [
{ begin: /\$\d+/ },
{ begin: /\$\{\w+\}/ },
{ begin: regex.concat(/[$@]/, hljs.UNDERSCORE_IDENT_RE) }
]
};
const LITERALS = [
"on",
"off",
"yes",
"no",
"true",
"false",
"none",
"blocked",
"debug",
"info",
"notice",
"warn",
"error",
"crit",
"select",
"break",
"last",
"permanent",
"redirect",
"kqueue",
"rtsig",
"epoll",
"poll",
"/dev/poll"
];
const DEFAULT = {
endsWithParent: true,
keywords: {
$pattern: /[a-z_]{2,}|\/dev\/poll/,
literal: LITERALS
},
relevance: 0,
illegal: '=>',
contains: [
hljs.HASH_COMMENT_MODE,
{
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
VAR
],
variants: [
{
begin: /"/,
end: /"/
},
{
begin: /'/,
end: /'/
}
]
},
// this swallows entire URLs to avoid detecting numbers within
{
begin: '([a-z]+):/',
end: '\\s',
endsWithParent: true,
excludeEnd: true,
contains: [ VAR ]
},
{
className: 'regexp',
contains: [
hljs.BACKSLASH_ESCAPE,
VAR
],
variants: [
{
begin: "\\s\\^",
end: "\\s|\\{|;",
returnEnd: true
},
// regexp locations (~, ~*)
{
begin: "~\\*?\\s+",
end: "\\s|\\{|;",
returnEnd: true
},
// *.example.com
{ begin: "\\*(\\.[a-z\\-]+)+" },
// sub.example.*
{ begin: "([a-z\\-]+\\.)+\\*" }
]
},
// IP
{
className: 'number',
begin: '\\b\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}(:\\d{1,5})?\\b'
},
// units
{
className: 'number',
begin: '\\b\\d+[kKmMgGdshdwy]?\\b',
relevance: 0
},
VAR
]
};
return {
name: 'Nginx config',
aliases: [ 'nginxconf' ],
contains: [
hljs.HASH_COMMENT_MODE,
{
beginKeywords: "upstream location",
end: /;|\{/,
contains: DEFAULT.contains,
keywords: { section: "upstream location" }
},
{
className: 'section',
begin: regex.concat(hljs.UNDERSCORE_IDENT_RE + regex.lookahead(/\s+\{/)),
relevance: 0
},
{
begin: regex.lookahead(hljs.UNDERSCORE_IDENT_RE + '\\s'),
end: ';|\\{',
contains: [
{
className: 'attribute',
begin: hljs.UNDERSCORE_IDENT_RE,
starts: DEFAULT
}
],
relevance: 0
}
],
illegal: '[^\\s\\}\\{]'
};
}
var nginx_1 = nginx;
/*
Language: Nim
Description: Nim is a statically typed compiled systems programming language.
Website: https://nim-lang.org
Category: system
*/
function nim(hljs) {
const TYPES = [
"int",
"int8",
"int16",
"int32",
"int64",
"uint",
"uint8",
"uint16",
"uint32",
"uint64",
"float",
"float32",
"float64",
"bool",
"char",
"string",
"cstring",
"pointer",
"expr",
"stmt",
"void",
"auto",
"any",
"range",
"array",
"openarray",
"varargs",
"seq",
"set",
"clong",
"culong",
"cchar",
"cschar",
"cshort",
"cint",
"csize",
"clonglong",
"cfloat",
"cdouble",
"clongdouble",
"cuchar",
"cushort",
"cuint",
"culonglong",
"cstringarray",
"semistatic"
];
const KEYWORDS = [
"addr",
"and",
"as",
"asm",
"bind",
"block",
"break",
"case",
"cast",
"const",
"continue",
"converter",
"discard",
"distinct",
"div",
"do",
"elif",
"else",
"end",
"enum",
"except",
"export",
"finally",
"for",
"from",
"func",
"generic",
"guarded",
"if",
"import",
"in",
"include",
"interface",
"is",
"isnot",
"iterator",
"let",
"macro",
"method",
"mixin",
"mod",
"nil",
"not",
"notin",
"object",
"of",
"or",
"out",
"proc",
"ptr",
"raise",
"ref",
"return",
"shared",
"shl",
"shr",
"static",
"template",
"try",
"tuple",
"type",
"using",
"var",
"when",
"while",
"with",
"without",
"xor",
"yield"
];
const BUILT_INS = [
"stdin",
"stdout",
"stderr",
"result"
];
const LITERALS = [
"true",
"false"
];
return {
name: 'Nim',
keywords: {
keyword: KEYWORDS,
literal: LITERALS,
type: TYPES,
built_in: BUILT_INS
},
contains: [
{
className: 'meta', // Actually pragma
begin: /\{\./,
end: /\.\}/,
relevance: 10
},
{
className: 'string',
begin: /[a-zA-Z]\w*"/,
end: /"/,
contains: [ { begin: /""/ } ]
},
{
className: 'string',
begin: /([a-zA-Z]\w*)?"""/,
end: /"""/
},
hljs.QUOTE_STRING_MODE,
{
className: 'type',
begin: /\b[A-Z]\w+\b/,
relevance: 0
},
{
className: 'number',
relevance: 0,
variants: [
{ begin: /\b(0[xX][0-9a-fA-F][_0-9a-fA-F]*)('?[iIuU](8|16|32|64))?/ },
{ begin: /\b(0o[0-7][_0-7]*)('?[iIuUfF](8|16|32|64))?/ },
{ begin: /\b(0(b|B)[01][_01]*)('?[iIuUfF](8|16|32|64))?/ },
{ begin: /\b(\d[_\d]*)('?[iIuUfF](8|16|32|64))?/ }
]
},
hljs.HASH_COMMENT_MODE
]
};
}
var nim_1 = nim;
/*
Language: Nix
Author: Domen Kožar <domen@dev.si>
Description: Nix functional language
Website: http://nixos.org/nix
*/
function nix(hljs) {
const KEYWORDS = {
keyword: [
"rec",
"with",
"let",
"in",
"inherit",
"assert",
"if",
"else",
"then"
],
literal: [
"true",
"false",
"or",
"and",
"null"
],
built_in: [
"import",
"abort",
"baseNameOf",
"dirOf",
"isNull",
"builtins",
"map",
"removeAttrs",
"throw",
"toString",
"derivation"
]
};
const ANTIQUOTE = {
className: 'subst',
begin: /\$\{/,
end: /\}/,
keywords: KEYWORDS
};
const ESCAPED_DOLLAR = {
className: 'char.escape',
begin: /''\$/,
};
const ATTRS = {
begin: /[a-zA-Z0-9-_]+(\s*=)/,
returnBegin: true,
relevance: 0,
contains: [
{
className: 'attr',
begin: /\S+/,
relevance: 0.2
}
]
};
const STRING = {
className: 'string',
contains: [ ESCAPED_DOLLAR, ANTIQUOTE ],
variants: [
{
begin: "''",
end: "''"
},
{
begin: '"',
end: '"'
}
]
};
const EXPRESSIONS = [
hljs.NUMBER_MODE,
hljs.HASH_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRING,
ATTRS
];
ANTIQUOTE.contains = EXPRESSIONS;
return {
name: 'Nix',
aliases: [ "nixos" ],
keywords: KEYWORDS,
contains: EXPRESSIONS
};
}
var nix_1 = nix;
/*
Language: Node REPL
Requires: javascript.js
Author: Marat Nagayev <nagaevmt@yandex.ru>
Category: scripting
*/
/** @type LanguageFn */
function nodeRepl(hljs) {
return {
name: 'Node REPL',
contains: [
{
className: 'meta.prompt',
starts: {
// a space separates the REPL prefix from the actual code
// this is purely for cleaner HTML output
end: / |$/,
starts: {
end: '$',
subLanguage: 'javascript'
}
},
variants: [
{ begin: /^>(?=[ ]|$)/ },
{ begin: /^\.\.\.(?=[ ]|$)/ }
]
}
]
};
}
var nodeRepl_1 = nodeRepl;
/*
Language: NSIS
Description: Nullsoft Scriptable Install System
Author: Jan T. Sott <jan.sott@gmail.com>
Website: https://nsis.sourceforge.io/Main_Page
*/
function nsis(hljs) {
const regex = hljs.regex;
const LANGUAGE_CONSTANTS = [
"ADMINTOOLS",
"APPDATA",
"CDBURN_AREA",
"CMDLINE",
"COMMONFILES32",
"COMMONFILES64",
"COMMONFILES",
"COOKIES",
"DESKTOP",
"DOCUMENTS",
"EXEDIR",
"EXEFILE",
"EXEPATH",
"FAVORITES",
"FONTS",
"HISTORY",
"HWNDPARENT",
"INSTDIR",
"INTERNET_CACHE",
"LANGUAGE",
"LOCALAPPDATA",
"MUSIC",
"NETHOOD",
"OUTDIR",
"PICTURES",
"PLUGINSDIR",
"PRINTHOOD",
"PROFILE",
"PROGRAMFILES32",
"PROGRAMFILES64",
"PROGRAMFILES",
"QUICKLAUNCH",
"RECENT",
"RESOURCES_LOCALIZED",
"RESOURCES",
"SENDTO",
"SMPROGRAMS",
"SMSTARTUP",
"STARTMENU",
"SYSDIR",
"TEMP",
"TEMPLATES",
"VIDEOS",
"WINDIR"
];
const PARAM_NAMES = [
"ARCHIVE",
"FILE_ATTRIBUTE_ARCHIVE",
"FILE_ATTRIBUTE_NORMAL",
"FILE_ATTRIBUTE_OFFLINE",
"FILE_ATTRIBUTE_READONLY",
"FILE_ATTRIBUTE_SYSTEM",
"FILE_ATTRIBUTE_TEMPORARY",
"HKCR",
"HKCU",
"HKDD",
"HKEY_CLASSES_ROOT",
"HKEY_CURRENT_CONFIG",
"HKEY_CURRENT_USER",
"HKEY_DYN_DATA",
"HKEY_LOCAL_MACHINE",
"HKEY_PERFORMANCE_DATA",
"HKEY_USERS",
"HKLM",
"HKPD",
"HKU",
"IDABORT",
"IDCANCEL",
"IDIGNORE",
"IDNO",
"IDOK",
"IDRETRY",
"IDYES",
"MB_ABORTRETRYIGNORE",
"MB_DEFBUTTON1",
"MB_DEFBUTTON2",
"MB_DEFBUTTON3",
"MB_DEFBUTTON4",
"MB_ICONEXCLAMATION",
"MB_ICONINFORMATION",
"MB_ICONQUESTION",
"MB_ICONSTOP",
"MB_OK",
"MB_OKCANCEL",
"MB_RETRYCANCEL",
"MB_RIGHT",
"MB_RTLREADING",
"MB_SETFOREGROUND",
"MB_TOPMOST",
"MB_USERICON",
"MB_YESNO",
"NORMAL",
"OFFLINE",
"READONLY",
"SHCTX",
"SHELL_CONTEXT",
"SYSTEM|TEMPORARY",
];
const COMPILER_FLAGS = [
"addincludedir",
"addplugindir",
"appendfile",
"assert",
"cd",
"define",
"delfile",
"echo",
"else",
"endif",
"error",
"execute",
"finalize",
"getdllversion",
"gettlbversion",
"if",
"ifdef",
"ifmacrodef",
"ifmacrondef",
"ifndef",
"include",
"insertmacro",
"macro",
"macroend",
"makensis",
"packhdr",
"searchparse",
"searchreplace",
"system",
"tempfile",
"undef",
"uninstfinalize",
"verbose",
"warning",
];
const CONSTANTS = {
className: 'variable.constant',
begin: regex.concat(/\$/, regex.either(...LANGUAGE_CONSTANTS))
};
const DEFINES = {
// ${defines}
className: 'variable',
begin: /\$+\{[\!\w.:-]+\}/
};
const VARIABLES = {
// $variables
className: 'variable',
begin: /\$+\w[\w\.]*/,
illegal: /\(\)\{\}/
};
const LANGUAGES = {
// $(language_strings)
className: 'variable',
begin: /\$+\([\w^.:!-]+\)/
};
const PARAMETERS = {
// command parameters
className: 'params',
begin: regex.either(...PARAM_NAMES)
};
const COMPILER = {
// !compiler_flags
className: 'keyword',
begin: regex.concat(
/!/,
regex.either(...COMPILER_FLAGS)
)
};
const ESCAPE_CHARS = {
// $\n, $\r, $\t, $$
className: 'char.escape',
begin: /\$(\\[nrt]|\$)/
};
const PLUGINS = {
// plug::ins
className: 'title.function',
begin: /\w+::\w+/
};
const STRING = {
className: 'string',
variants: [
{
begin: '"',
end: '"'
},
{
begin: '\'',
end: '\''
},
{
begin: '`',
end: '`'
}
],
illegal: /\n/,
contains: [
ESCAPE_CHARS,
CONSTANTS,
DEFINES,
VARIABLES,
LANGUAGES
]
};
const KEYWORDS = [
"Abort",
"AddBrandingImage",
"AddSize",
"AllowRootDirInstall",
"AllowSkipFiles",
"AutoCloseWindow",
"BGFont",
"BGGradient",
"BrandingText",
"BringToFront",
"Call",
"CallInstDLL",
"Caption",
"ChangeUI",
"CheckBitmap",
"ClearErrors",
"CompletedText",
"ComponentText",
"CopyFiles",
"CRCCheck",
"CreateDirectory",
"CreateFont",
"CreateShortCut",
"Delete",
"DeleteINISec",
"DeleteINIStr",
"DeleteRegKey",
"DeleteRegValue",
"DetailPrint",
"DetailsButtonText",
"DirText",
"DirVar",
"DirVerify",
"EnableWindow",
"EnumRegKey",
"EnumRegValue",
"Exch",
"Exec",
"ExecShell",
"ExecShellWait",
"ExecWait",
"ExpandEnvStrings",
"File",
"FileBufSize",
"FileClose",
"FileErrorText",
"FileOpen",
"FileRead",
"FileReadByte",
"FileReadUTF16LE",
"FileReadWord",
"FileWriteUTF16LE",
"FileSeek",
"FileWrite",
"FileWriteByte",
"FileWriteWord",
"FindClose",
"FindFirst",
"FindNext",
"FindWindow",
"FlushINI",
"GetCurInstType",
"GetCurrentAddress",
"GetDlgItem",
"GetDLLVersion",
"GetDLLVersionLocal",
"GetErrorLevel",
"GetFileTime",
"GetFileTimeLocal",
"GetFullPathName",
"GetFunctionAddress",
"GetInstDirError",
"GetKnownFolderPath",
"GetLabelAddress",
"GetTempFileName",
"GetWinVer",
"Goto",
"HideWindow",
"Icon",
"IfAbort",
"IfErrors",
"IfFileExists",
"IfRebootFlag",
"IfRtlLanguage",
"IfShellVarContextAll",
"IfSilent",
"InitPluginsDir",
"InstallButtonText",
"InstallColors",
"InstallDir",
"InstallDirRegKey",
"InstProgressFlags",
"InstType",
"InstTypeGetText",
"InstTypeSetText",
"Int64Cmp",
"Int64CmpU",
"Int64Fmt",
"IntCmp",
"IntCmpU",
"IntFmt",
"IntOp",
"IntPtrCmp",
"IntPtrCmpU",
"IntPtrOp",
"IsWindow",
"LangString",
"LicenseBkColor",
"LicenseData",
"LicenseForceSelection",
"LicenseLangString",
"LicenseText",
"LoadAndSetImage",
"LoadLanguageFile",
"LockWindow",
"LogSet",
"LogText",
"ManifestDPIAware",
"ManifestLongPathAware",
"ManifestMaxVersionTested",
"ManifestSupportedOS",
"MessageBox",
"MiscButtonText",
"Name|0",
"Nop",
"OutFile",
"Page",
"PageCallbacks",
"PEAddResource",
"PEDllCharacteristics",
"PERemoveResource",
"PESubsysVer",
"Pop",
"Push",
"Quit",
"ReadEnvStr",
"ReadINIStr",
"ReadRegDWORD",
"ReadRegStr",
"Reboot",
"RegDLL",
"Rename",
"RequestExecutionLevel",
"ReserveFile",
"Return",
"RMDir",
"SearchPath",
"SectionGetFlags",
"SectionGetInstTypes",
"SectionGetSize",
"SectionGetText",
"SectionIn",
"SectionSetFlags",
"SectionSetInstTypes",
"SectionSetSize",
"SectionSetText",
"SendMessage",
"SetAutoClose",
"SetBrandingImage",
"SetCompress",
"SetCompressor",
"SetCompressorDictSize",
"SetCtlColors",
"SetCurInstType",
"SetDatablockOptimize",
"SetDateSave",
"SetDetailsPrint",
"SetDetailsView",
"SetErrorLevel",
"SetErrors",
"SetFileAttributes",
"SetFont",
"SetOutPath",
"SetOverwrite",
"SetRebootFlag",
"SetRegView",
"SetShellVarContext",
"SetSilent",
"ShowInstDetails",
"ShowUninstDetails",
"ShowWindow",
"SilentInstall",
"SilentUnInstall",
"Sleep",
"SpaceTexts",
"StrCmp",
"StrCmpS",
"StrCpy",
"StrLen",
"SubCaption",
"Unicode",
"UninstallButtonText",
"UninstallCaption",
"UninstallIcon",
"UninstallSubCaption",
"UninstallText",
"UninstPage",
"UnRegDLL",
"Var",
"VIAddVersionKey",
"VIFileVersion",
"VIProductVersion",
"WindowIcon",
"WriteINIStr",
"WriteRegBin",
"WriteRegDWORD",
"WriteRegExpandStr",
"WriteRegMultiStr",
"WriteRegNone",
"WriteRegStr",
"WriteUninstaller",
"XPStyle"
];
const LITERALS = [
"admin",
"all",
"auto",
"both",
"bottom",
"bzip2",
"colored",
"components",
"current",
"custom",
"directory",
"false",
"force",
"hide",
"highest",
"ifdiff",
"ifnewer",
"instfiles",
"lastused",
"leave",
"left",
"license",
"listonly",
"lzma",
"nevershow",
"none",
"normal",
"notset",
"off",
"on",
"open",
"print",
"right",
"show",
"silent",
"silentlog",
"smooth",
"textonly",
"top",
"true",
"try",
"un.components",
"un.custom",
"un.directory",
"un.instfiles",
"un.license",
"uninstConfirm",
"user",
"Win10",
"Win7",
"Win8",
"WinVista",
"zlib"
];
const FUNCTION_DEFINITION = {
match: [
/Function/,
/\s+/,
regex.concat(/(\.)?/, hljs.IDENT_RE)
],
scope: {
1: "keyword",
3: "title.function"
}
};
// Var Custom.Variable.Name.Item
// Var /GLOBAL Custom.Variable.Name.Item
const VARIABLE_NAME_RE = /[A-Za-z][\w.]*/;
const VARIABLE_DEFINITION = {
match: [
/Var/,
/\s+/,
/(?:\/GLOBAL\s+)?/,
VARIABLE_NAME_RE
],
scope: {
1: "keyword",
3: "params",
4: "variable"
}
};
return {
name: 'NSIS',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
literal: LITERALS
},
contains: [
hljs.HASH_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.COMMENT(
';',
'$',
{ relevance: 0 }
),
VARIABLE_DEFINITION,
FUNCTION_DEFINITION,
{ beginKeywords: 'Function PageEx Section SectionGroup FunctionEnd SectionEnd', },
STRING,
COMPILER,
DEFINES,
VARIABLES,
LANGUAGES,
PARAMETERS,
PLUGINS,
hljs.NUMBER_MODE
]
};
}
var nsis_1 = nsis;
/*
Language: Objective-C
Author: Valerii Hiora <valerii.hiora@gmail.com>
Contributors: Angel G. Olloqui <angelgarcia.mail@gmail.com>, Matt Diephouse <matt@diephouse.com>, Andrew Farmer <ahfarmer@gmail.com>, Minh Nguyễn <mxn@1ec5.org>
Website: https://developer.apple.com/documentation/objectivec
Category: common
*/
function objectivec(hljs) {
const API_CLASS = {
className: 'built_in',
begin: '\\b(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)\\w+'
};
const IDENTIFIER_RE = /[a-zA-Z@][a-zA-Z0-9_]*/;
const TYPES = [
"int",
"float",
"char",
"unsigned",
"signed",
"short",
"long",
"double",
"wchar_t",
"unichar",
"void",
"bool",
"BOOL",
"id|0",
"_Bool"
];
const KWS = [
"while",
"export",
"sizeof",
"typedef",
"const",
"struct",
"for",
"union",
"volatile",
"static",
"mutable",
"if",
"do",
"return",
"goto",
"enum",
"else",
"break",
"extern",
"asm",
"case",
"default",
"register",
"explicit",
"typename",
"switch",
"continue",
"inline",
"readonly",
"assign",
"readwrite",
"self",
"@synchronized",
"id",
"typeof",
"nonatomic",
"IBOutlet",
"IBAction",
"strong",
"weak",
"copy",
"in",
"out",
"inout",
"bycopy",
"byref",
"oneway",
"__strong",
"__weak",
"__block",
"__autoreleasing",
"@private",
"@protected",
"@public",
"@try",
"@property",
"@end",
"@throw",
"@catch",
"@finally",
"@autoreleasepool",
"@synthesize",
"@dynamic",
"@selector",
"@optional",
"@required",
"@encode",
"@package",
"@import",
"@defs",
"@compatibility_alias",
"__bridge",
"__bridge_transfer",
"__bridge_retained",
"__bridge_retain",
"__covariant",
"__contravariant",
"__kindof",
"_Nonnull",
"_Nullable",
"_Null_unspecified",
"__FUNCTION__",
"__PRETTY_FUNCTION__",
"__attribute__",
"getter",
"setter",
"retain",
"unsafe_unretained",
"nonnull",
"nullable",
"null_unspecified",
"null_resettable",
"class",
"instancetype",
"NS_DESIGNATED_INITIALIZER",
"NS_UNAVAILABLE",
"NS_REQUIRES_SUPER",
"NS_RETURNS_INNER_POINTER",
"NS_INLINE",
"NS_AVAILABLE",
"NS_DEPRECATED",
"NS_ENUM",
"NS_OPTIONS",
"NS_SWIFT_UNAVAILABLE",
"NS_ASSUME_NONNULL_BEGIN",
"NS_ASSUME_NONNULL_END",
"NS_REFINED_FOR_SWIFT",
"NS_SWIFT_NAME",
"NS_SWIFT_NOTHROW",
"NS_DURING",
"NS_HANDLER",
"NS_ENDHANDLER",
"NS_VALUERETURN",
"NS_VOIDRETURN"
];
const LITERALS = [
"false",
"true",
"FALSE",
"TRUE",
"nil",
"YES",
"NO",
"NULL"
];
const BUILT_INS = [
"dispatch_once_t",
"dispatch_queue_t",
"dispatch_sync",
"dispatch_async",
"dispatch_once"
];
const KEYWORDS = {
"variable.language": [
"this",
"super"
],
$pattern: IDENTIFIER_RE,
keyword: KWS,
literal: LITERALS,
built_in: BUILT_INS,
type: TYPES
};
const CLASS_KEYWORDS = {
$pattern: IDENTIFIER_RE,
keyword: [
"@interface",
"@class",
"@protocol",
"@implementation"
]
};
return {
name: 'Objective-C',
aliases: [
'mm',
'objc',
'obj-c',
'obj-c++',
'objective-c++'
],
keywords: KEYWORDS,
illegal: '</',
contains: [
API_CLASS,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
{
className: 'string',
variants: [
{
begin: '@"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
}
]
},
{
className: 'meta',
begin: /#\s*[a-z]+\b/,
end: /$/,
keywords: { keyword:
'if else elif endif define undef warning error line '
+ 'pragma ifdef ifndef include' },
contains: [
{
begin: /\\\n/,
relevance: 0
},
hljs.inherit(hljs.QUOTE_STRING_MODE, { className: 'string' }),
{
className: 'string',
begin: /<.*?>/,
end: /$/,
illegal: '\\n'
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
},
{
className: 'class',
begin: '(' + CLASS_KEYWORDS.keyword.join('|') + ')\\b',
end: /(\{|$)/,
excludeEnd: true,
keywords: CLASS_KEYWORDS,
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
},
{
begin: '\\.' + hljs.UNDERSCORE_IDENT_RE,
relevance: 0
}
]
};
}
var objectivec_1 = objectivec;
/*
Language: OCaml
Author: Mehdi Dogguy <mehdi@dogguy.org>
Contributors: Nicolas Braud-Santoni <nicolas.braud-santoni@ens-cachan.fr>, Mickael Delahaye <mickael.delahaye@gmail.com>
Description: OCaml language definition.
Website: https://ocaml.org
Category: functional
*/
function ocaml(hljs) {
/* missing support for heredoc-like string (OCaml 4.0.2+) */
return {
name: 'OCaml',
aliases: [ 'ml' ],
keywords: {
$pattern: '[a-z_]\\w*!?',
keyword:
'and as assert asr begin class constraint do done downto else end '
+ 'exception external for fun function functor if in include '
+ 'inherit! inherit initializer land lazy let lor lsl lsr lxor match method!|10 method '
+ 'mod module mutable new object of open! open or private rec sig struct '
+ 'then to try type val! val virtual when while with '
/* camlp4 */
+ 'parser value',
built_in:
/* built-in types */
'array bool bytes char exn|5 float int int32 int64 list lazy_t|5 nativeint|5 string unit '
/* (some) types in Pervasives */
+ 'in_channel out_channel ref',
literal:
'true false'
},
illegal: /\/\/|>>/,
contains: [
{
className: 'literal',
begin: '\\[(\\|\\|)?\\]|\\(\\)',
relevance: 0
},
hljs.COMMENT(
'\\(\\*',
'\\*\\)',
{ contains: [ 'self' ] }
),
{ /* type variable */
className: 'symbol',
begin: '\'[A-Za-z_](?!\')[\\w\']*'
/* the grammar is ambiguous on how 'a'b should be interpreted but not the compiler */
},
{ /* polymorphic variant */
className: 'type',
begin: '`[A-Z][\\w\']*'
},
{ /* module or constructor */
className: 'type',
begin: '\\b[A-Z][\\w\']*',
relevance: 0
},
{ /* don't color identifiers, but safely catch all identifiers with ' */
begin: '[a-z_]\\w*\'[\\w\']*',
relevance: 0
},
hljs.inherit(hljs.APOS_STRING_MODE, {
className: 'string',
relevance: 0
}),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
className: 'number',
begin:
'\\b(0[xX][a-fA-F0-9_]+[Lln]?|'
+ '0[oO][0-7_]+[Lln]?|'
+ '0[bB][01_]+[Lln]?|'
+ '[0-9][0-9_]*([Lln]|(\\.[0-9_]*)?([eE][-+]?[0-9_]+)?)?)',
relevance: 0
},
{ begin: /->/ // relevance booster
}
]
};
}
var ocaml_1 = ocaml;
/*
Language: OpenSCAD
Author: Dan Panzarella <alsoelp@gmail.com>
Description: OpenSCAD is a language for the 3D CAD modeling software of the same name.
Website: https://www.openscad.org
Category: scientific
*/
function openscad(hljs) {
const SPECIAL_VARS = {
className: 'keyword',
begin: '\\$(f[asn]|t|vp[rtd]|children)'
};
const LITERALS = {
className: 'literal',
begin: 'false|true|PI|undef'
};
const NUMBERS = {
className: 'number',
begin: '\\b\\d+(\\.\\d+)?(e-?\\d+)?', // adds 1e5, 1e-10
relevance: 0
};
const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null });
const PREPRO = {
className: 'meta',
keywords: { keyword: 'include use' },
begin: 'include|use <',
end: '>'
};
const PARAMS = {
className: 'params',
begin: '\\(',
end: '\\)',
contains: [
'self',
NUMBERS,
STRING,
SPECIAL_VARS,
LITERALS
]
};
const MODIFIERS = {
begin: '[*!#%]',
relevance: 0
};
const FUNCTIONS = {
className: 'function',
beginKeywords: 'module function',
end: /=|\{/,
contains: [
PARAMS,
hljs.UNDERSCORE_TITLE_MODE
]
};
return {
name: 'OpenSCAD',
aliases: [ 'scad' ],
keywords: {
keyword: 'function module include use for intersection_for if else \\%',
literal: 'false true PI undef',
built_in: 'circle square polygon text sphere cube cylinder polyhedron translate rotate scale resize mirror multmatrix color offset hull minkowski union difference intersection abs sign sin cos tan acos asin atan atan2 floor round ceil ln log pow sqrt exp rands min max concat lookup str chr search version version_num norm cross parent_module echo import import_dxf dxf_linear_extrude linear_extrude rotate_extrude surface projection render children dxf_cross dxf_dim let assign'
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
NUMBERS,
PREPRO,
STRING,
SPECIAL_VARS,
MODIFIERS,
FUNCTIONS
]
};
}
var openscad_1 = openscad;
/*
Language: Oxygene
Author: Carlo Kok <ck@remobjects.com>
Description: Oxygene is built on the foundation of Object Pascal, revamped and extended to be a modern language for the twenty-first century.
Website: https://www.elementscompiler.com/elements/default.aspx
*/
function oxygene(hljs) {
const OXYGENE_KEYWORDS = {
$pattern: /\.?\w+/,
keyword:
'abstract add and array as asc aspect assembly async begin break block by case class concat const copy constructor continue '
+ 'create default delegate desc distinct div do downto dynamic each else empty end ensure enum equals event except exit extension external false '
+ 'final finalize finalizer finally flags for forward from function future global group has if implementation implements implies in index inherited '
+ 'inline interface into invariants is iterator join locked locking loop matching method mod module namespace nested new nil not notify nullable of '
+ 'old on operator or order out override parallel params partial pinned private procedure property protected public queryable raise read readonly '
+ 'record reintroduce remove repeat require result reverse sealed select self sequence set shl shr skip static step soft take then to true try tuple '
+ 'type union unit unsafe until uses using var virtual raises volatile where while with write xor yield await mapped deprecated stdcall cdecl pascal '
+ 'register safecall overload library platform reference packed strict published autoreleasepool selector strong weak unretained'
};
const CURLY_COMMENT = hljs.COMMENT(
/\{/,
/\}/,
{ relevance: 0 }
);
const PAREN_COMMENT = hljs.COMMENT(
'\\(\\*',
'\\*\\)',
{ relevance: 10 }
);
const STRING = {
className: 'string',
begin: '\'',
end: '\'',
contains: [ { begin: '\'\'' } ]
};
const CHAR_STRING = {
className: 'string',
begin: '(#\\d+)+'
};
const FUNCTION = {
beginKeywords: 'function constructor destructor procedure method',
end: '[:;]',
keywords: 'function constructor|10 destructor|10 procedure|10 method|10',
contains: [
hljs.inherit(hljs.TITLE_MODE, { scope: "title.function" }),
{
className: 'params',
begin: '\\(',
end: '\\)',
keywords: OXYGENE_KEYWORDS,
contains: [
STRING,
CHAR_STRING
]
},
CURLY_COMMENT,
PAREN_COMMENT
]
};
const SEMICOLON = {
scope: "punctuation",
match: /;/,
relevance: 0
};
return {
name: 'Oxygene',
case_insensitive: true,
keywords: OXYGENE_KEYWORDS,
illegal: '("|\\$[G-Zg-z]|\\/\\*|</|=>|->)',
contains: [
CURLY_COMMENT,
PAREN_COMMENT,
hljs.C_LINE_COMMENT_MODE,
STRING,
CHAR_STRING,
hljs.NUMBER_MODE,
FUNCTION,
SEMICOLON
]
};
}
var oxygene_1 = oxygene;
/*
Language: Parser3
Requires: xml.js
Author: Oleg Volchkov <oleg@volchkov.net>
Website: https://www.parser.ru/en/
Category: template
*/
function parser3(hljs) {
const CURLY_SUBCOMMENT = hljs.COMMENT(
/\{/,
/\}/,
{ contains: [ 'self' ] }
);
return {
name: 'Parser3',
subLanguage: 'xml',
relevance: 0,
contains: [
hljs.COMMENT('^#', '$'),
hljs.COMMENT(
/\^rem\{/,
/\}/,
{
relevance: 10,
contains: [ CURLY_SUBCOMMENT ]
}
),
{
className: 'meta',
begin: '^@(?:BASE|USE|CLASS|OPTIONS)$',
relevance: 10
},
{
className: 'title',
begin: '@[\\w\\-]+\\[[\\w^;\\-]*\\](?:\\[[\\w^;\\-]*\\])?(?:.*)$'
},
{
className: 'variable',
begin: /\$\{?[\w\-.:]+\}?/
},
{
className: 'keyword',
begin: /\^[\w\-.:]+/
},
{
className: 'number',
begin: '\\^#[0-9a-fA-F]+'
},
hljs.C_NUMBER_MODE
]
};
}
var parser3_1 = parser3;
/*
Language: Packet Filter config
Description: pf.conf — packet filter configuration file (OpenBSD)
Author: Peter Piwowarski <oldlaptop654@aol.com>
Website: http://man.openbsd.org/pf.conf
Category: config
*/
function pf(hljs) {
const MACRO = {
className: 'variable',
begin: /\$[\w\d#@][\w\d_]*/,
relevance: 0
};
const TABLE = {
className: 'variable',
begin: /<(?!\/)/,
end: />/
};
return {
name: 'Packet Filter config',
aliases: [ 'pf.conf' ],
keywords: {
$pattern: /[a-z0-9_<>-]+/,
built_in: /* block match pass are "actions" in pf.conf(5), the rest are
* lexically similar top-level commands.
*/
'block match pass load anchor|5 antispoof|10 set table',
keyword:
'in out log quick on rdomain inet inet6 proto from port os to route '
+ 'allow-opts divert-packet divert-reply divert-to flags group icmp-type '
+ 'icmp6-type label once probability recieved-on rtable prio queue '
+ 'tos tag tagged user keep fragment for os drop '
+ 'af-to|10 binat-to|10 nat-to|10 rdr-to|10 bitmask least-stats random round-robin '
+ 'source-hash static-port '
+ 'dup-to reply-to route-to '
+ 'parent bandwidth default min max qlimit '
+ 'block-policy debug fingerprints hostid limit loginterface optimization '
+ 'reassemble ruleset-optimization basic none profile skip state-defaults '
+ 'state-policy timeout '
+ 'const counters persist '
+ 'no modulate synproxy state|5 floating if-bound no-sync pflow|10 sloppy '
+ 'source-track global rule max-src-nodes max-src-states max-src-conn '
+ 'max-src-conn-rate overload flush '
+ 'scrub|5 max-mss min-ttl no-df|10 random-id',
literal:
'all any no-route self urpf-failed egress|5 unknown'
},
contains: [
hljs.HASH_COMMENT_MODE,
hljs.NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
MACRO,
TABLE
]
};
}
var pf_1 = pf;
/*
Language: PostgreSQL and PL/pgSQL
Author: Egor Rogov (e.rogov@postgrespro.ru)
Website: https://www.postgresql.org/docs/11/sql.html
Description:
This language incorporates both PostgreSQL SQL dialect and PL/pgSQL language.
It is based on PostgreSQL version 11. Some notes:
- Text in double-dollar-strings is _always_ interpreted as some programming code. Text
in ordinary quotes is _never_ interpreted that way and highlighted just as a string.
- There are quite a bit "special cases". That's because many keywords are not strictly
they are keywords in some contexts and ordinary identifiers in others. Only some
of such cases are handled; you still can get some of your identifiers highlighted
wrong way.
- Function names deliberately are not highlighted. There is no way to tell function
call from other constructs, hence we can't highlight _all_ function names. And
some names highlighted while others not looks ugly.
*/
function pgsql(hljs) {
const COMMENT_MODE = hljs.COMMENT('--', '$');
const UNQUOTED_IDENT = '[a-zA-Z_][a-zA-Z_0-9$]*';
const DOLLAR_STRING = '\\$([a-zA-Z_]?|[a-zA-Z_][a-zA-Z_0-9]*)\\$';
const LABEL = '<<\\s*' + UNQUOTED_IDENT + '\\s*>>';
const SQL_KW =
// https://www.postgresql.org/docs/11/static/sql-keywords-appendix.html
// https://www.postgresql.org/docs/11/static/sql-commands.html
// SQL commands (starting words)
'ABORT ALTER ANALYZE BEGIN CALL CHECKPOINT|10 CLOSE CLUSTER COMMENT COMMIT COPY CREATE DEALLOCATE DECLARE '
+ 'DELETE DISCARD DO DROP END EXECUTE EXPLAIN FETCH GRANT IMPORT INSERT LISTEN LOAD LOCK MOVE NOTIFY '
+ 'PREPARE REASSIGN|10 REFRESH REINDEX RELEASE RESET REVOKE ROLLBACK SAVEPOINT SECURITY SELECT SET SHOW '
+ 'START TRUNCATE UNLISTEN|10 UPDATE VACUUM|10 VALUES '
// SQL commands (others)
+ 'AGGREGATE COLLATION CONVERSION|10 DATABASE DEFAULT PRIVILEGES DOMAIN TRIGGER EXTENSION FOREIGN '
+ 'WRAPPER|10 TABLE FUNCTION GROUP LANGUAGE LARGE OBJECT MATERIALIZED VIEW OPERATOR CLASS '
+ 'FAMILY POLICY PUBLICATION|10 ROLE RULE SCHEMA SEQUENCE SERVER STATISTICS SUBSCRIPTION SYSTEM '
+ 'TABLESPACE CONFIGURATION DICTIONARY PARSER TEMPLATE TYPE USER MAPPING PREPARED ACCESS '
+ 'METHOD CAST AS TRANSFORM TRANSACTION OWNED TO INTO SESSION AUTHORIZATION '
+ 'INDEX PROCEDURE ASSERTION '
// additional reserved key words
+ 'ALL ANALYSE AND ANY ARRAY ASC ASYMMETRIC|10 BOTH CASE CHECK '
+ 'COLLATE COLUMN CONCURRENTLY|10 CONSTRAINT CROSS '
+ 'DEFERRABLE RANGE '
+ 'DESC DISTINCT ELSE EXCEPT FOR FREEZE|10 FROM FULL HAVING '
+ 'ILIKE IN INITIALLY INNER INTERSECT IS ISNULL JOIN LATERAL LEADING LIKE LIMIT '
+ 'NATURAL NOT NOTNULL NULL OFFSET ON ONLY OR ORDER OUTER OVERLAPS PLACING PRIMARY '
+ 'REFERENCES RETURNING SIMILAR SOME SYMMETRIC TABLESAMPLE THEN '
+ 'TRAILING UNION UNIQUE USING VARIADIC|10 VERBOSE WHEN WHERE WINDOW WITH '
// some of non-reserved (which are used in clauses or as PL/pgSQL keyword)
+ 'BY RETURNS INOUT OUT SETOF|10 IF STRICT CURRENT CONTINUE OWNER LOCATION OVER PARTITION WITHIN '
+ 'BETWEEN ESCAPE EXTERNAL INVOKER DEFINER WORK RENAME VERSION CONNECTION CONNECT '
+ 'TABLES TEMP TEMPORARY FUNCTIONS SEQUENCES TYPES SCHEMAS OPTION CASCADE RESTRICT ADD ADMIN '
+ 'EXISTS VALID VALIDATE ENABLE DISABLE REPLICA|10 ALWAYS PASSING COLUMNS PATH '
+ 'REF VALUE OVERRIDING IMMUTABLE STABLE VOLATILE BEFORE AFTER EACH ROW PROCEDURAL '
+ 'ROUTINE NO HANDLER VALIDATOR OPTIONS STORAGE OIDS|10 WITHOUT INHERIT DEPENDS CALLED '
+ 'INPUT LEAKPROOF|10 COST ROWS NOWAIT SEARCH UNTIL ENCRYPTED|10 PASSWORD CONFLICT|10 '
+ 'INSTEAD INHERITS CHARACTERISTICS WRITE CURSOR ALSO STATEMENT SHARE EXCLUSIVE INLINE '
+ 'ISOLATION REPEATABLE READ COMMITTED SERIALIZABLE UNCOMMITTED LOCAL GLOBAL SQL PROCEDURES '
+ 'RECURSIVE SNAPSHOT ROLLUP CUBE TRUSTED|10 INCLUDE FOLLOWING PRECEDING UNBOUNDED RANGE GROUPS '
+ 'UNENCRYPTED|10 SYSID FORMAT DELIMITER HEADER QUOTE ENCODING FILTER OFF '
// some parameters of VACUUM/ANALYZE/EXPLAIN
+ 'FORCE_QUOTE FORCE_NOT_NULL FORCE_NULL COSTS BUFFERS TIMING SUMMARY DISABLE_PAGE_SKIPPING '
//
+ 'RESTART CYCLE GENERATED IDENTITY DEFERRED IMMEDIATE LEVEL LOGGED UNLOGGED '
+ 'OF NOTHING NONE EXCLUDE ATTRIBUTE '
// from GRANT (not keywords actually)
+ 'USAGE ROUTINES '
// actually literals, but look better this way (due to IS TRUE, IS FALSE, ISNULL etc)
+ 'TRUE FALSE NAN INFINITY ';
const ROLE_ATTRS = // only those not in keywrods already
'SUPERUSER NOSUPERUSER CREATEDB NOCREATEDB CREATEROLE NOCREATEROLE INHERIT NOINHERIT '
+ 'LOGIN NOLOGIN REPLICATION NOREPLICATION BYPASSRLS NOBYPASSRLS ';
const PLPGSQL_KW =
'ALIAS BEGIN CONSTANT DECLARE END EXCEPTION RETURN PERFORM|10 RAISE GET DIAGNOSTICS '
+ 'STACKED|10 FOREACH LOOP ELSIF EXIT WHILE REVERSE SLICE DEBUG LOG INFO NOTICE WARNING ASSERT '
+ 'OPEN ';
const TYPES =
// https://www.postgresql.org/docs/11/static/datatype.html
'BIGINT INT8 BIGSERIAL SERIAL8 BIT VARYING VARBIT BOOLEAN BOOL BOX BYTEA CHARACTER CHAR VARCHAR '
+ 'CIDR CIRCLE DATE DOUBLE PRECISION FLOAT8 FLOAT INET INTEGER INT INT4 INTERVAL JSON JSONB LINE LSEG|10 '
+ 'MACADDR MACADDR8 MONEY NUMERIC DEC DECIMAL PATH POINT POLYGON REAL FLOAT4 SMALLINT INT2 '
+ 'SMALLSERIAL|10 SERIAL2|10 SERIAL|10 SERIAL4|10 TEXT TIME ZONE TIMETZ|10 TIMESTAMP TIMESTAMPTZ|10 TSQUERY|10 TSVECTOR|10 '
+ 'TXID_SNAPSHOT|10 UUID XML NATIONAL NCHAR '
+ 'INT4RANGE|10 INT8RANGE|10 NUMRANGE|10 TSRANGE|10 TSTZRANGE|10 DATERANGE|10 '
// pseudotypes
+ 'ANYELEMENT ANYARRAY ANYNONARRAY ANYENUM ANYRANGE CSTRING INTERNAL '
+ 'RECORD PG_DDL_COMMAND VOID UNKNOWN OPAQUE REFCURSOR '
// spec. type
+ 'NAME '
// OID-types
+ 'OID REGPROC|10 REGPROCEDURE|10 REGOPER|10 REGOPERATOR|10 REGCLASS|10 REGTYPE|10 REGROLE|10 '
+ 'REGNAMESPACE|10 REGCONFIG|10 REGDICTIONARY|10 ';// +
const TYPES_RE =
TYPES.trim()
.split(' ')
.map(function(val) { return val.split('|')[0]; })
.join('|');
const SQL_BI =
'CURRENT_TIME CURRENT_TIMESTAMP CURRENT_USER CURRENT_CATALOG|10 CURRENT_DATE LOCALTIME LOCALTIMESTAMP '
+ 'CURRENT_ROLE|10 CURRENT_SCHEMA|10 SESSION_USER PUBLIC ';
const PLPGSQL_BI =
'FOUND NEW OLD TG_NAME|10 TG_WHEN|10 TG_LEVEL|10 TG_OP|10 TG_RELID|10 TG_RELNAME|10 '
+ 'TG_TABLE_NAME|10 TG_TABLE_SCHEMA|10 TG_NARGS|10 TG_ARGV|10 TG_EVENT|10 TG_TAG|10 '
// get diagnostics
+ 'ROW_COUNT RESULT_OID|10 PG_CONTEXT|10 RETURNED_SQLSTATE COLUMN_NAME CONSTRAINT_NAME '
+ 'PG_DATATYPE_NAME|10 MESSAGE_TEXT TABLE_NAME SCHEMA_NAME PG_EXCEPTION_DETAIL|10 '
+ 'PG_EXCEPTION_HINT|10 PG_EXCEPTION_CONTEXT|10 ';
const PLPGSQL_EXCEPTIONS =
// exceptions https://www.postgresql.org/docs/current/static/errcodes-appendix.html
'SQLSTATE SQLERRM|10 '
+ 'SUCCESSFUL_COMPLETION WARNING DYNAMIC_RESULT_SETS_RETURNED IMPLICIT_ZERO_BIT_PADDING '
+ 'NULL_VALUE_ELIMINATED_IN_SET_FUNCTION PRIVILEGE_NOT_GRANTED PRIVILEGE_NOT_REVOKED '
+ 'STRING_DATA_RIGHT_TRUNCATION DEPRECATED_FEATURE NO_DATA NO_ADDITIONAL_DYNAMIC_RESULT_SETS_RETURNED '
+ 'SQL_STATEMENT_NOT_YET_COMPLETE CONNECTION_EXCEPTION CONNECTION_DOES_NOT_EXIST CONNECTION_FAILURE '
+ 'SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION SQLSERVER_REJECTED_ESTABLISHMENT_OF_SQLCONNECTION '
+ 'TRANSACTION_RESOLUTION_UNKNOWN PROTOCOL_VIOLATION TRIGGERED_ACTION_EXCEPTION FEATURE_NOT_SUPPORTED '
+ 'INVALID_TRANSACTION_INITIATION LOCATOR_EXCEPTION INVALID_LOCATOR_SPECIFICATION INVALID_GRANTOR '
+ 'INVALID_GRANT_OPERATION INVALID_ROLE_SPECIFICATION DIAGNOSTICS_EXCEPTION '
+ 'STACKED_DIAGNOSTICS_ACCESSED_WITHOUT_ACTIVE_HANDLER CASE_NOT_FOUND CARDINALITY_VIOLATION '
+ 'DATA_EXCEPTION ARRAY_SUBSCRIPT_ERROR CHARACTER_NOT_IN_REPERTOIRE DATETIME_FIELD_OVERFLOW '
+ 'DIVISION_BY_ZERO ERROR_IN_ASSIGNMENT ESCAPE_CHARACTER_CONFLICT INDICATOR_OVERFLOW '
+ 'INTERVAL_FIELD_OVERFLOW INVALID_ARGUMENT_FOR_LOGARITHM INVALID_ARGUMENT_FOR_NTILE_FUNCTION '
+ 'INVALID_ARGUMENT_FOR_NTH_VALUE_FUNCTION INVALID_ARGUMENT_FOR_POWER_FUNCTION '
+ 'INVALID_ARGUMENT_FOR_WIDTH_BUCKET_FUNCTION INVALID_CHARACTER_VALUE_FOR_CAST '
+ 'INVALID_DATETIME_FORMAT INVALID_ESCAPE_CHARACTER INVALID_ESCAPE_OCTET INVALID_ESCAPE_SEQUENCE '
+ 'NONSTANDARD_USE_OF_ESCAPE_CHARACTER INVALID_INDICATOR_PARAMETER_VALUE INVALID_PARAMETER_VALUE '
+ 'INVALID_REGULAR_EXPRESSION INVALID_ROW_COUNT_IN_LIMIT_CLAUSE '
+ 'INVALID_ROW_COUNT_IN_RESULT_OFFSET_CLAUSE INVALID_TABLESAMPLE_ARGUMENT INVALID_TABLESAMPLE_REPEAT '
+ 'INVALID_TIME_ZONE_DISPLACEMENT_VALUE INVALID_USE_OF_ESCAPE_CHARACTER MOST_SPECIFIC_TYPE_MISMATCH '
+ 'NULL_VALUE_NOT_ALLOWED NULL_VALUE_NO_INDICATOR_PARAMETER NUMERIC_VALUE_OUT_OF_RANGE '
+ 'SEQUENCE_GENERATOR_LIMIT_EXCEEDED STRING_DATA_LENGTH_MISMATCH STRING_DATA_RIGHT_TRUNCATION '
+ 'SUBSTRING_ERROR TRIM_ERROR UNTERMINATED_C_STRING ZERO_LENGTH_CHARACTER_STRING '
+ 'FLOATING_POINT_EXCEPTION INVALID_TEXT_REPRESENTATION INVALID_BINARY_REPRESENTATION '
+ 'BAD_COPY_FILE_FORMAT UNTRANSLATABLE_CHARACTER NOT_AN_XML_DOCUMENT INVALID_XML_DOCUMENT '
+ 'INVALID_XML_CONTENT INVALID_XML_COMMENT INVALID_XML_PROCESSING_INSTRUCTION '
+ 'INTEGRITY_CONSTRAINT_VIOLATION RESTRICT_VIOLATION NOT_NULL_VIOLATION FOREIGN_KEY_VIOLATION '
+ 'UNIQUE_VIOLATION CHECK_VIOLATION EXCLUSION_VIOLATION INVALID_CURSOR_STATE '
+ 'INVALID_TRANSACTION_STATE ACTIVE_SQL_TRANSACTION BRANCH_TRANSACTION_ALREADY_ACTIVE '
+ 'HELD_CURSOR_REQUIRES_SAME_ISOLATION_LEVEL INAPPROPRIATE_ACCESS_MODE_FOR_BRANCH_TRANSACTION '
+ 'INAPPROPRIATE_ISOLATION_LEVEL_FOR_BRANCH_TRANSACTION '
+ 'NO_ACTIVE_SQL_TRANSACTION_FOR_BRANCH_TRANSACTION READ_ONLY_SQL_TRANSACTION '
+ 'SCHEMA_AND_DATA_STATEMENT_MIXING_NOT_SUPPORTED NO_ACTIVE_SQL_TRANSACTION '
+ 'IN_FAILED_SQL_TRANSACTION IDLE_IN_TRANSACTION_SESSION_TIMEOUT INVALID_SQL_STATEMENT_NAME '
+ 'TRIGGERED_DATA_CHANGE_VIOLATION INVALID_AUTHORIZATION_SPECIFICATION INVALID_PASSWORD '
+ 'DEPENDENT_PRIVILEGE_DESCRIPTORS_STILL_EXIST DEPENDENT_OBJECTS_STILL_EXIST '
+ 'INVALID_TRANSACTION_TERMINATION SQL_ROUTINE_EXCEPTION FUNCTION_EXECUTED_NO_RETURN_STATEMENT '
+ 'MODIFYING_SQL_DATA_NOT_PERMITTED PROHIBITED_SQL_STATEMENT_ATTEMPTED '
+ 'READING_SQL_DATA_NOT_PERMITTED INVALID_CURSOR_NAME EXTERNAL_ROUTINE_EXCEPTION '
+ 'CONTAINING_SQL_NOT_PERMITTED MODIFYING_SQL_DATA_NOT_PERMITTED '
+ 'PROHIBITED_SQL_STATEMENT_ATTEMPTED READING_SQL_DATA_NOT_PERMITTED '
+ 'EXTERNAL_ROUTINE_INVOCATION_EXCEPTION INVALID_SQLSTATE_RETURNED NULL_VALUE_NOT_ALLOWED '
+ 'TRIGGER_PROTOCOL_VIOLATED SRF_PROTOCOL_VIOLATED EVENT_TRIGGER_PROTOCOL_VIOLATED '
+ 'SAVEPOINT_EXCEPTION INVALID_SAVEPOINT_SPECIFICATION INVALID_CATALOG_NAME '
+ 'INVALID_SCHEMA_NAME TRANSACTION_ROLLBACK TRANSACTION_INTEGRITY_CONSTRAINT_VIOLATION '
+ 'SERIALIZATION_FAILURE STATEMENT_COMPLETION_UNKNOWN DEADLOCK_DETECTED '
+ 'SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION SYNTAX_ERROR INSUFFICIENT_PRIVILEGE CANNOT_COERCE '
+ 'GROUPING_ERROR WINDOWING_ERROR INVALID_RECURSION INVALID_FOREIGN_KEY INVALID_NAME '
+ 'NAME_TOO_LONG RESERVED_NAME DATATYPE_MISMATCH INDETERMINATE_DATATYPE COLLATION_MISMATCH '
+ 'INDETERMINATE_COLLATION WRONG_OBJECT_TYPE GENERATED_ALWAYS UNDEFINED_COLUMN '
+ 'UNDEFINED_FUNCTION UNDEFINED_TABLE UNDEFINED_PARAMETER UNDEFINED_OBJECT '
+ 'DUPLICATE_COLUMN DUPLICATE_CURSOR DUPLICATE_DATABASE DUPLICATE_FUNCTION '
+ 'DUPLICATE_PREPARED_STATEMENT DUPLICATE_SCHEMA DUPLICATE_TABLE DUPLICATE_ALIAS '
+ 'DUPLICATE_OBJECT AMBIGUOUS_COLUMN AMBIGUOUS_FUNCTION AMBIGUOUS_PARAMETER AMBIGUOUS_ALIAS '
+ 'INVALID_COLUMN_REFERENCE INVALID_COLUMN_DEFINITION INVALID_CURSOR_DEFINITION '
+ 'INVALID_DATABASE_DEFINITION INVALID_FUNCTION_DEFINITION '
+ 'INVALID_PREPARED_STATEMENT_DEFINITION INVALID_SCHEMA_DEFINITION INVALID_TABLE_DEFINITION '
+ 'INVALID_OBJECT_DEFINITION WITH_CHECK_OPTION_VIOLATION INSUFFICIENT_RESOURCES DISK_FULL '
+ 'OUT_OF_MEMORY TOO_MANY_CONNECTIONS CONFIGURATION_LIMIT_EXCEEDED PROGRAM_LIMIT_EXCEEDED '
+ 'STATEMENT_TOO_COMPLEX TOO_MANY_COLUMNS TOO_MANY_ARGUMENTS OBJECT_NOT_IN_PREREQUISITE_STATE '
+ 'OBJECT_IN_USE CANT_CHANGE_RUNTIME_PARAM LOCK_NOT_AVAILABLE OPERATOR_INTERVENTION '
+ 'QUERY_CANCELED ADMIN_SHUTDOWN CRASH_SHUTDOWN CANNOT_CONNECT_NOW DATABASE_DROPPED '
+ 'SYSTEM_ERROR IO_ERROR UNDEFINED_FILE DUPLICATE_FILE SNAPSHOT_TOO_OLD CONFIG_FILE_ERROR '
+ 'LOCK_FILE_EXISTS FDW_ERROR FDW_COLUMN_NAME_NOT_FOUND FDW_DYNAMIC_PARAMETER_VALUE_NEEDED '
+ 'FDW_FUNCTION_SEQUENCE_ERROR FDW_INCONSISTENT_DESCRIPTOR_INFORMATION '
+ 'FDW_INVALID_ATTRIBUTE_VALUE FDW_INVALID_COLUMN_NAME FDW_INVALID_COLUMN_NUMBER '
+ 'FDW_INVALID_DATA_TYPE FDW_INVALID_DATA_TYPE_DESCRIPTORS '
+ 'FDW_INVALID_DESCRIPTOR_FIELD_IDENTIFIER FDW_INVALID_HANDLE FDW_INVALID_OPTION_INDEX '
+ 'FDW_INVALID_OPTION_NAME FDW_INVALID_STRING_LENGTH_OR_BUFFER_LENGTH '
+ 'FDW_INVALID_STRING_FORMAT FDW_INVALID_USE_OF_NULL_POINTER FDW_TOO_MANY_HANDLES '
+ 'FDW_OUT_OF_MEMORY FDW_NO_SCHEMAS FDW_OPTION_NAME_NOT_FOUND FDW_REPLY_HANDLE '
+ 'FDW_SCHEMA_NOT_FOUND FDW_TABLE_NOT_FOUND FDW_UNABLE_TO_CREATE_EXECUTION '
+ 'FDW_UNABLE_TO_CREATE_REPLY FDW_UNABLE_TO_ESTABLISH_CONNECTION PLPGSQL_ERROR '
+ 'RAISE_EXCEPTION NO_DATA_FOUND TOO_MANY_ROWS ASSERT_FAILURE INTERNAL_ERROR DATA_CORRUPTED '
+ 'INDEX_CORRUPTED ';
const FUNCTIONS =
// https://www.postgresql.org/docs/11/static/functions-aggregate.html
'ARRAY_AGG AVG BIT_AND BIT_OR BOOL_AND BOOL_OR COUNT EVERY JSON_AGG JSONB_AGG JSON_OBJECT_AGG '
+ 'JSONB_OBJECT_AGG MAX MIN MODE STRING_AGG SUM XMLAGG '
+ 'CORR COVAR_POP COVAR_SAMP REGR_AVGX REGR_AVGY REGR_COUNT REGR_INTERCEPT REGR_R2 REGR_SLOPE '
+ 'REGR_SXX REGR_SXY REGR_SYY STDDEV STDDEV_POP STDDEV_SAMP VARIANCE VAR_POP VAR_SAMP '
+ 'PERCENTILE_CONT PERCENTILE_DISC '
// https://www.postgresql.org/docs/11/static/functions-window.html
+ 'ROW_NUMBER RANK DENSE_RANK PERCENT_RANK CUME_DIST NTILE LAG LEAD FIRST_VALUE LAST_VALUE NTH_VALUE '
// https://www.postgresql.org/docs/11/static/functions-comparison.html
+ 'NUM_NONNULLS NUM_NULLS '
// https://www.postgresql.org/docs/11/static/functions-math.html
+ 'ABS CBRT CEIL CEILING DEGREES DIV EXP FLOOR LN LOG MOD PI POWER RADIANS ROUND SCALE SIGN SQRT '
+ 'TRUNC WIDTH_BUCKET '
+ 'RANDOM SETSEED '
+ 'ACOS ACOSD ASIN ASIND ATAN ATAND ATAN2 ATAN2D COS COSD COT COTD SIN SIND TAN TAND '
// https://www.postgresql.org/docs/11/static/functions-string.html
+ 'BIT_LENGTH CHAR_LENGTH CHARACTER_LENGTH LOWER OCTET_LENGTH OVERLAY POSITION SUBSTRING TREAT TRIM UPPER '
+ 'ASCII BTRIM CHR CONCAT CONCAT_WS CONVERT CONVERT_FROM CONVERT_TO DECODE ENCODE INITCAP '
+ 'LEFT LENGTH LPAD LTRIM MD5 PARSE_IDENT PG_CLIENT_ENCODING QUOTE_IDENT|10 QUOTE_LITERAL|10 '
+ 'QUOTE_NULLABLE|10 REGEXP_MATCH REGEXP_MATCHES REGEXP_REPLACE REGEXP_SPLIT_TO_ARRAY '
+ 'REGEXP_SPLIT_TO_TABLE REPEAT REPLACE REVERSE RIGHT RPAD RTRIM SPLIT_PART STRPOS SUBSTR '
+ 'TO_ASCII TO_HEX TRANSLATE '
// https://www.postgresql.org/docs/11/static/functions-binarystring.html
+ 'OCTET_LENGTH GET_BIT GET_BYTE SET_BIT SET_BYTE '
// https://www.postgresql.org/docs/11/static/functions-formatting.html
+ 'TO_CHAR TO_DATE TO_NUMBER TO_TIMESTAMP '
// https://www.postgresql.org/docs/11/static/functions-datetime.html
+ 'AGE CLOCK_TIMESTAMP|10 DATE_PART DATE_TRUNC ISFINITE JUSTIFY_DAYS JUSTIFY_HOURS JUSTIFY_INTERVAL '
+ 'MAKE_DATE MAKE_INTERVAL|10 MAKE_TIME MAKE_TIMESTAMP|10 MAKE_TIMESTAMPTZ|10 NOW STATEMENT_TIMESTAMP|10 '
+ 'TIMEOFDAY TRANSACTION_TIMESTAMP|10 '
// https://www.postgresql.org/docs/11/static/functions-enum.html
+ 'ENUM_FIRST ENUM_LAST ENUM_RANGE '
// https://www.postgresql.org/docs/11/static/functions-geometry.html
+ 'AREA CENTER DIAMETER HEIGHT ISCLOSED ISOPEN NPOINTS PCLOSE POPEN RADIUS WIDTH '
+ 'BOX BOUND_BOX CIRCLE LINE LSEG PATH POLYGON '
// https://www.postgresql.org/docs/11/static/functions-net.html
+ 'ABBREV BROADCAST HOST HOSTMASK MASKLEN NETMASK NETWORK SET_MASKLEN TEXT INET_SAME_FAMILY '
+ 'INET_MERGE MACADDR8_SET7BIT '
// https://www.postgresql.org/docs/11/static/functions-textsearch.html
+ 'ARRAY_TO_TSVECTOR GET_CURRENT_TS_CONFIG NUMNODE PLAINTO_TSQUERY PHRASETO_TSQUERY WEBSEARCH_TO_TSQUERY '
+ 'QUERYTREE SETWEIGHT STRIP TO_TSQUERY TO_TSVECTOR JSON_TO_TSVECTOR JSONB_TO_TSVECTOR TS_DELETE '
+ 'TS_FILTER TS_HEADLINE TS_RANK TS_RANK_CD TS_REWRITE TSQUERY_PHRASE TSVECTOR_TO_ARRAY '
+ 'TSVECTOR_UPDATE_TRIGGER TSVECTOR_UPDATE_TRIGGER_COLUMN '
// https://www.postgresql.org/docs/11/static/functions-xml.html
+ 'XMLCOMMENT XMLCONCAT XMLELEMENT XMLFOREST XMLPI XMLROOT '
+ 'XMLEXISTS XML_IS_WELL_FORMED XML_IS_WELL_FORMED_DOCUMENT XML_IS_WELL_FORMED_CONTENT '
+ 'XPATH XPATH_EXISTS XMLTABLE XMLNAMESPACES '
+ 'TABLE_TO_XML TABLE_TO_XMLSCHEMA TABLE_TO_XML_AND_XMLSCHEMA '
+ 'QUERY_TO_XML QUERY_TO_XMLSCHEMA QUERY_TO_XML_AND_XMLSCHEMA '
+ 'CURSOR_TO_XML CURSOR_TO_XMLSCHEMA '
+ 'SCHEMA_TO_XML SCHEMA_TO_XMLSCHEMA SCHEMA_TO_XML_AND_XMLSCHEMA '
+ 'DATABASE_TO_XML DATABASE_TO_XMLSCHEMA DATABASE_TO_XML_AND_XMLSCHEMA '
+ 'XMLATTRIBUTES '
// https://www.postgresql.org/docs/11/static/functions-json.html
+ 'TO_JSON TO_JSONB ARRAY_TO_JSON ROW_TO_JSON JSON_BUILD_ARRAY JSONB_BUILD_ARRAY JSON_BUILD_OBJECT '
+ 'JSONB_BUILD_OBJECT JSON_OBJECT JSONB_OBJECT JSON_ARRAY_LENGTH JSONB_ARRAY_LENGTH JSON_EACH '
+ 'JSONB_EACH JSON_EACH_TEXT JSONB_EACH_TEXT JSON_EXTRACT_PATH JSONB_EXTRACT_PATH '
+ 'JSON_OBJECT_KEYS JSONB_OBJECT_KEYS JSON_POPULATE_RECORD JSONB_POPULATE_RECORD JSON_POPULATE_RECORDSET '
+ 'JSONB_POPULATE_RECORDSET JSON_ARRAY_ELEMENTS JSONB_ARRAY_ELEMENTS JSON_ARRAY_ELEMENTS_TEXT '
+ 'JSONB_ARRAY_ELEMENTS_TEXT JSON_TYPEOF JSONB_TYPEOF JSON_TO_RECORD JSONB_TO_RECORD JSON_TO_RECORDSET '
+ 'JSONB_TO_RECORDSET JSON_STRIP_NULLS JSONB_STRIP_NULLS JSONB_SET JSONB_INSERT JSONB_PRETTY '
// https://www.postgresql.org/docs/11/static/functions-sequence.html
+ 'CURRVAL LASTVAL NEXTVAL SETVAL '
// https://www.postgresql.org/docs/11/static/functions-conditional.html
+ 'COALESCE NULLIF GREATEST LEAST '
// https://www.postgresql.org/docs/11/static/functions-array.html
+ 'ARRAY_APPEND ARRAY_CAT ARRAY_NDIMS ARRAY_DIMS ARRAY_FILL ARRAY_LENGTH ARRAY_LOWER ARRAY_POSITION '
+ 'ARRAY_POSITIONS ARRAY_PREPEND ARRAY_REMOVE ARRAY_REPLACE ARRAY_TO_STRING ARRAY_UPPER CARDINALITY '
+ 'STRING_TO_ARRAY UNNEST '
// https://www.postgresql.org/docs/11/static/functions-range.html
+ 'ISEMPTY LOWER_INC UPPER_INC LOWER_INF UPPER_INF RANGE_MERGE '
// https://www.postgresql.org/docs/11/static/functions-srf.html
+ 'GENERATE_SERIES GENERATE_SUBSCRIPTS '
// https://www.postgresql.org/docs/11/static/functions-info.html
+ 'CURRENT_DATABASE CURRENT_QUERY CURRENT_SCHEMA|10 CURRENT_SCHEMAS|10 INET_CLIENT_ADDR INET_CLIENT_PORT '
+ 'INET_SERVER_ADDR INET_SERVER_PORT ROW_SECURITY_ACTIVE FORMAT_TYPE '
+ 'TO_REGCLASS TO_REGPROC TO_REGPROCEDURE TO_REGOPER TO_REGOPERATOR TO_REGTYPE TO_REGNAMESPACE TO_REGROLE '
+ 'COL_DESCRIPTION OBJ_DESCRIPTION SHOBJ_DESCRIPTION '
+ 'TXID_CURRENT TXID_CURRENT_IF_ASSIGNED TXID_CURRENT_SNAPSHOT TXID_SNAPSHOT_XIP TXID_SNAPSHOT_XMAX '
+ 'TXID_SNAPSHOT_XMIN TXID_VISIBLE_IN_SNAPSHOT TXID_STATUS '
// https://www.postgresql.org/docs/11/static/functions-admin.html
+ 'CURRENT_SETTING SET_CONFIG BRIN_SUMMARIZE_NEW_VALUES BRIN_SUMMARIZE_RANGE BRIN_DESUMMARIZE_RANGE '
+ 'GIN_CLEAN_PENDING_LIST '
// https://www.postgresql.org/docs/11/static/functions-trigger.html
+ 'SUPPRESS_REDUNDANT_UPDATES_TRIGGER '
// ihttps://www.postgresql.org/docs/devel/static/lo-funcs.html
+ 'LO_FROM_BYTEA LO_PUT LO_GET LO_CREAT LO_CREATE LO_UNLINK LO_IMPORT LO_EXPORT LOREAD LOWRITE '
//
+ 'GROUPING CAST ';
const FUNCTIONS_RE =
FUNCTIONS.trim()
.split(' ')
.map(function(val) { return val.split('|')[0]; })
.join('|');
return {
name: 'PostgreSQL',
aliases: [
'postgres',
'postgresql'
],
supersetOf: "sql",
case_insensitive: true,
keywords: {
keyword:
SQL_KW + PLPGSQL_KW + ROLE_ATTRS,
built_in:
SQL_BI + PLPGSQL_BI + PLPGSQL_EXCEPTIONS
},
// Forbid some cunstructs from other languages to improve autodetect. In fact
// "[a-z]:" is legal (as part of array slice), but improbabal.
illegal: /:==|\W\s*\(\*|(^|\s)\$[a-z]|\{\{|[a-z]:\s*$|\.\.\.|TO:|DO:/,
contains: [
// special handling of some words, which are reserved only in some contexts
{
className: 'keyword',
variants: [
{ begin: /\bTEXT\s*SEARCH\b/ },
{ begin: /\b(PRIMARY|FOREIGN|FOR(\s+NO)?)\s+KEY\b/ },
{ begin: /\bPARALLEL\s+(UNSAFE|RESTRICTED|SAFE)\b/ },
{ begin: /\bSTORAGE\s+(PLAIN|EXTERNAL|EXTENDED|MAIN)\b/ },
{ begin: /\bMATCH\s+(FULL|PARTIAL|SIMPLE)\b/ },
{ begin: /\bNULLS\s+(FIRST|LAST)\b/ },
{ begin: /\bEVENT\s+TRIGGER\b/ },
{ begin: /\b(MAPPING|OR)\s+REPLACE\b/ },
{ begin: /\b(FROM|TO)\s+(PROGRAM|STDIN|STDOUT)\b/ },
{ begin: /\b(SHARE|EXCLUSIVE)\s+MODE\b/ },
{ begin: /\b(LEFT|RIGHT)\s+(OUTER\s+)?JOIN\b/ },
{ begin: /\b(FETCH|MOVE)\s+(NEXT|PRIOR|FIRST|LAST|ABSOLUTE|RELATIVE|FORWARD|BACKWARD)\b/ },
{ begin: /\bPRESERVE\s+ROWS\b/ },
{ begin: /\bDISCARD\s+PLANS\b/ },
{ begin: /\bREFERENCING\s+(OLD|NEW)\b/ },
{ begin: /\bSKIP\s+LOCKED\b/ },
{ begin: /\bGROUPING\s+SETS\b/ },
{ begin: /\b(BINARY|INSENSITIVE|SCROLL|NO\s+SCROLL)\s+(CURSOR|FOR)\b/ },
{ begin: /\b(WITH|WITHOUT)\s+HOLD\b/ },
{ begin: /\bWITH\s+(CASCADED|LOCAL)\s+CHECK\s+OPTION\b/ },
{ begin: /\bEXCLUDE\s+(TIES|NO\s+OTHERS)\b/ },
{ begin: /\bFORMAT\s+(TEXT|XML|JSON|YAML)\b/ },
{ begin: /\bSET\s+((SESSION|LOCAL)\s+)?NAMES\b/ },
{ begin: /\bIS\s+(NOT\s+)?UNKNOWN\b/ },
{ begin: /\bSECURITY\s+LABEL\b/ },
{ begin: /\bSTANDALONE\s+(YES|NO|NO\s+VALUE)\b/ },
{ begin: /\bWITH\s+(NO\s+)?DATA\b/ },
{ begin: /\b(FOREIGN|SET)\s+DATA\b/ },
{ begin: /\bSET\s+(CATALOG|CONSTRAINTS)\b/ },
{ begin: /\b(WITH|FOR)\s+ORDINALITY\b/ },
{ begin: /\bIS\s+(NOT\s+)?DOCUMENT\b/ },
{ begin: /\bXML\s+OPTION\s+(DOCUMENT|CONTENT)\b/ },
{ begin: /\b(STRIP|PRESERVE)\s+WHITESPACE\b/ },
{ begin: /\bNO\s+(ACTION|MAXVALUE|MINVALUE)\b/ },
{ begin: /\bPARTITION\s+BY\s+(RANGE|LIST|HASH)\b/ },
{ begin: /\bAT\s+TIME\s+ZONE\b/ },
{ begin: /\bGRANTED\s+BY\b/ },
{ begin: /\bRETURN\s+(QUERY|NEXT)\b/ },
{ begin: /\b(ATTACH|DETACH)\s+PARTITION\b/ },
{ begin: /\bFORCE\s+ROW\s+LEVEL\s+SECURITY\b/ },
{ begin: /\b(INCLUDING|EXCLUDING)\s+(COMMENTS|CONSTRAINTS|DEFAULTS|IDENTITY|INDEXES|STATISTICS|STORAGE|ALL)\b/ },
{ begin: /\bAS\s+(ASSIGNMENT|IMPLICIT|PERMISSIVE|RESTRICTIVE|ENUM|RANGE)\b/ }
]
},
// functions named as keywords, followed by '('
{ begin: /\b(FORMAT|FAMILY|VERSION)\s*\(/
// keywords: { built_in: 'FORMAT FAMILY VERSION' }
},
// INCLUDE ( ... ) in index_parameters in CREATE TABLE
{
begin: /\bINCLUDE\s*\(/,
keywords: 'INCLUDE'
},
// not highlight RANGE if not in frame_clause (not 100% correct, but seems satisfactory)
{ begin: /\bRANGE(?!\s*(BETWEEN|UNBOUNDED|CURRENT|[-0-9]+))/ },
// disable highlighting in commands CREATE AGGREGATE/COLLATION/DATABASE/OPERTOR/TEXT SEARCH .../TYPE
// and in PL/pgSQL RAISE ... USING
{ begin: /\b(VERSION|OWNER|TEMPLATE|TABLESPACE|CONNECTION\s+LIMIT|PROCEDURE|RESTRICT|JOIN|PARSER|COPY|START|END|COLLATION|INPUT|ANALYZE|STORAGE|LIKE|DEFAULT|DELIMITER|ENCODING|COLUMN|CONSTRAINT|TABLE|SCHEMA)\s*=/ },
// PG_smth; HAS_some_PRIVILEGE
{
// className: 'built_in',
begin: /\b(PG_\w+?|HAS_[A-Z_]+_PRIVILEGE)\b/,
relevance: 10
},
// extract
{
begin: /\bEXTRACT\s*\(/,
end: /\bFROM\b/,
returnEnd: true,
keywords: {
// built_in: 'EXTRACT',
type: 'CENTURY DAY DECADE DOW DOY EPOCH HOUR ISODOW ISOYEAR MICROSECONDS '
+ 'MILLENNIUM MILLISECONDS MINUTE MONTH QUARTER SECOND TIMEZONE TIMEZONE_HOUR '
+ 'TIMEZONE_MINUTE WEEK YEAR' }
},
// xmlelement, xmlpi - special NAME
{
begin: /\b(XMLELEMENT|XMLPI)\s*\(\s*NAME/,
keywords: {
// built_in: 'XMLELEMENT XMLPI',
keyword: 'NAME' }
},
// xmlparse, xmlserialize
{
begin: /\b(XMLPARSE|XMLSERIALIZE)\s*\(\s*(DOCUMENT|CONTENT)/,
keywords: {
// built_in: 'XMLPARSE XMLSERIALIZE',
keyword: 'DOCUMENT CONTENT' }
},
// Sequences. We actually skip everything between CACHE|INCREMENT|MAXVALUE|MINVALUE and
// nearest following numeric constant. Without with trick we find a lot of "keywords"
// in 'avrasm' autodetection test...
{
beginKeywords: 'CACHE INCREMENT MAXVALUE MINVALUE',
end: hljs.C_NUMBER_RE,
returnEnd: true,
keywords: 'BY CACHE INCREMENT MAXVALUE MINVALUE'
},
// WITH|WITHOUT TIME ZONE as part of datatype
{
className: 'type',
begin: /\b(WITH|WITHOUT)\s+TIME\s+ZONE\b/
},
// INTERVAL optional fields
{
className: 'type',
begin: /\bINTERVAL\s+(YEAR|MONTH|DAY|HOUR|MINUTE|SECOND)(\s+TO\s+(MONTH|HOUR|MINUTE|SECOND))?\b/
},
// Pseudo-types which allowed only as return type
{
begin: /\bRETURNS\s+(LANGUAGE_HANDLER|TRIGGER|EVENT_TRIGGER|FDW_HANDLER|INDEX_AM_HANDLER|TSM_HANDLER)\b/,
keywords: {
keyword: 'RETURNS',
type: 'LANGUAGE_HANDLER TRIGGER EVENT_TRIGGER FDW_HANDLER INDEX_AM_HANDLER TSM_HANDLER'
}
},
// Known functions - only when followed by '('
{ begin: '\\b(' + FUNCTIONS_RE + ')\\s*\\('
// keywords: { built_in: FUNCTIONS }
},
// Types
{ begin: '\\.(' + TYPES_RE + ')\\b' // prevent highlight as type, say, 'oid' in 'pgclass.oid'
},
{
begin: '\\b(' + TYPES_RE + ')\\s+PATH\\b', // in XMLTABLE
keywords: {
keyword: 'PATH', // hopefully no one would use PATH type in XMLTABLE...
type: TYPES.replace('PATH ', '')
}
},
{
className: 'type',
begin: '\\b(' + TYPES_RE + ')\\b'
},
// Strings, see https://www.postgresql.org/docs/11/static/sql-syntax-lexical.html#SQL-SYNTAX-CONSTANTS
{
className: 'string',
begin: '\'',
end: '\'',
contains: [ { begin: '\'\'' } ]
},
{
className: 'string',
begin: '(e|E|u&|U&)\'',
end: '\'',
contains: [ { begin: '\\\\.' } ],
relevance: 10
},
hljs.END_SAME_AS_BEGIN({
begin: DOLLAR_STRING,
end: DOLLAR_STRING,
contains: [
{
// actually we want them all except SQL; listed are those with known implementations
// and XML + JSON just in case
subLanguage: [
'pgsql',
'perl',
'python',
'tcl',
'r',
'lua',
'java',
'php',
'ruby',
'bash',
'scheme',
'xml',
'json'
],
endsWithParent: true
}
]
}),
// identifiers in quotes
{
begin: '"',
end: '"',
contains: [ { begin: '""' } ]
},
// numbers
hljs.C_NUMBER_MODE,
// comments
hljs.C_BLOCK_COMMENT_MODE,
COMMENT_MODE,
// PL/pgSQL staff
// %ROWTYPE, %TYPE, $n
{
className: 'meta',
variants: [
{ // %TYPE, %ROWTYPE
begin: '%(ROW)?TYPE',
relevance: 10
},
{ // $n
begin: '\\$\\d+' },
{ // #compiler option
begin: '^#\\w',
end: '$'
}
]
},
// <<labeles>>
{
className: 'symbol',
begin: LABEL,
relevance: 10
}
]
};
}
var pgsql_1 = pgsql;
/*
Language: PHP
Author: Victor Karamzin <Victor.Karamzin@enterra-inc.com>
Contributors: Evgeny Stepanischev <imbolk@gmail.com>, Ivan Sagalaev <maniac@softwaremaniacs.org>
Website: https://www.php.net
Category: common
*/
/**
* @param {HLJSApi} hljs
* @returns {LanguageDetail}
* */
function php(hljs) {
const regex = hljs.regex;
// negative look-ahead tries to avoid matching patterns that are not
// Perl at all like $ident$, @ident@, etc.
const NOT_PERL_ETC = /(?![A-Za-z0-9])(?![$])/;
const IDENT_RE = regex.concat(
/[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/,
NOT_PERL_ETC);
// Will not detect camelCase classes
const PASCAL_CASE_CLASS_NAME_RE = regex.concat(
/(\\?[A-Z][a-z0-9_\x7f-\xff]+|\\?[A-Z]+(?=[A-Z][a-z0-9_\x7f-\xff])){1,}/,
NOT_PERL_ETC);
const VARIABLE = {
scope: 'variable',
match: '\\$+' + IDENT_RE,
};
const PREPROCESSOR = {
scope: 'meta',
variants: [
{ begin: /<\?php/, relevance: 10 }, // boost for obvious PHP
{ begin: /<\?=/ },
// less relevant per PSR-1 which says not to use short-tags
{ begin: /<\?/, relevance: 0.1 },
{ begin: /\?>/ } // end php tag
]
};
const SUBST = {
scope: 'subst',
variants: [
{ begin: /\$\w+/ },
{
begin: /\{\$/,
end: /\}/
}
]
};
const SINGLE_QUOTED = hljs.inherit(hljs.APOS_STRING_MODE, { illegal: null, });
const DOUBLE_QUOTED = hljs.inherit(hljs.QUOTE_STRING_MODE, {
illegal: null,
contains: hljs.QUOTE_STRING_MODE.contains.concat(SUBST),
});
const HEREDOC = {
begin: /<<<[ \t]*(?:(\w+)|"(\w+)")\n/,
end: /[ \t]*(\w+)\b/,
contains: hljs.QUOTE_STRING_MODE.contains.concat(SUBST),
'on:begin': (m, resp) => { resp.data._beginMatch = m[1] || m[2]; },
'on:end': (m, resp) => { if (resp.data._beginMatch !== m[1]) resp.ignoreMatch(); },
};
const NOWDOC = hljs.END_SAME_AS_BEGIN({
begin: /<<<[ \t]*'(\w+)'\n/,
end: /[ \t]*(\w+)\b/,
});
// list of valid whitespaces because non-breaking space might be part of a IDENT_RE
const WHITESPACE = '[ \t\n]';
const STRING = {
scope: 'string',
variants: [
DOUBLE_QUOTED,
SINGLE_QUOTED,
HEREDOC,
NOWDOC
]
};
const NUMBER = {
scope: 'number',
variants: [
{ begin: `\\b0[bB][01]+(?:_[01]+)*\\b` }, // Binary w/ underscore support
{ begin: `\\b0[oO][0-7]+(?:_[0-7]+)*\\b` }, // Octals w/ underscore support
{ begin: `\\b0[xX][\\da-fA-F]+(?:_[\\da-fA-F]+)*\\b` }, // Hex w/ underscore support
// Decimals w/ underscore support, with optional fragments and scientific exponent (e) suffix.
{ begin: `(?:\\b\\d+(?:_\\d+)*(\\.(?:\\d+(?:_\\d+)*))?|\\B\\.\\d+)(?:[eE][+-]?\\d+)?` }
],
relevance: 0
};
const LITERALS = [
"false",
"null",
"true"
];
const KWS = [
// Magic constants:
// <https://www.php.net/manual/en/language.constants.predefined.php>
"__CLASS__",
"__DIR__",
"__FILE__",
"__FUNCTION__",
"__COMPILER_HALT_OFFSET__",
"__LINE__",
"__METHOD__",
"__NAMESPACE__",
"__TRAIT__",
// Function that look like language construct or language construct that look like function:
// List of keywords that may not require parenthesis
"die",
"echo",
"exit",
"include",
"include_once",
"print",
"require",
"require_once",
// These are not language construct (function) but operate on the currently-executing function and can access the current symbol table
// 'compact extract func_get_arg func_get_args func_num_args get_called_class get_parent_class ' +
// Other keywords:
// <https://www.php.net/manual/en/reserved.php>
// <https://www.php.net/manual/en/language.types.type-juggling.php>
"array",
"abstract",
"and",
"as",
"binary",
"bool",
"boolean",
"break",
"callable",
"case",
"catch",
"class",
"clone",
"const",
"continue",
"declare",
"default",
"do",
"double",
"else",
"elseif",
"empty",
"enddeclare",
"endfor",
"endforeach",
"endif",
"endswitch",
"endwhile",
"enum",
"eval",
"extends",
"final",
"finally",
"float",
"for",
"foreach",
"from",
"global",
"goto",
"if",
"implements",
"instanceof",
"insteadof",
"int",
"integer",
"interface",
"isset",
"iterable",
"list",
"match|0",
"mixed",
"new",
"never",
"object",
"or",
"private",
"protected",
"public",
"readonly",
"real",
"return",
"string",
"switch",
"throw",
"trait",
"try",
"unset",
"use",
"var",
"void",
"while",
"xor",
"yield"
];
const BUILT_INS = [
// Standard PHP library:
// <https://www.php.net/manual/en/book.spl.php>
"Error|0",
"AppendIterator",
"ArgumentCountError",
"ArithmeticError",
"ArrayIterator",
"ArrayObject",
"AssertionError",
"BadFunctionCallException",
"BadMethodCallException",
"CachingIterator",
"CallbackFilterIterator",
"CompileError",
"Countable",
"DirectoryIterator",
"DivisionByZeroError",
"DomainException",
"EmptyIterator",
"ErrorException",
"Exception",
"FilesystemIterator",
"FilterIterator",
"GlobIterator",
"InfiniteIterator",
"InvalidArgumentException",
"IteratorIterator",
"LengthException",
"LimitIterator",
"LogicException",
"MultipleIterator",
"NoRewindIterator",
"OutOfBoundsException",
"OutOfRangeException",
"OuterIterator",
"OverflowException",
"ParentIterator",
"ParseError",
"RangeException",
"RecursiveArrayIterator",
"RecursiveCachingIterator",
"RecursiveCallbackFilterIterator",
"RecursiveDirectoryIterator",
"RecursiveFilterIterator",
"RecursiveIterator",
"RecursiveIteratorIterator",
"RecursiveRegexIterator",
"RecursiveTreeIterator",
"RegexIterator",
"RuntimeException",
"SeekableIterator",
"SplDoublyLinkedList",
"SplFileInfo",
"SplFileObject",
"SplFixedArray",
"SplHeap",
"SplMaxHeap",
"SplMinHeap",
"SplObjectStorage",
"SplObserver",
"SplPriorityQueue",
"SplQueue",
"SplStack",
"SplSubject",
"SplTempFileObject",
"TypeError",
"UnderflowException",
"UnexpectedValueException",
"UnhandledMatchError",
// Reserved interfaces:
// <https://www.php.net/manual/en/reserved.interfaces.php>
"ArrayAccess",
"BackedEnum",
"Closure",
"Fiber",
"Generator",
"Iterator",
"IteratorAggregate",
"Serializable",
"Stringable",
"Throwable",
"Traversable",
"UnitEnum",
"WeakReference",
"WeakMap",
// Reserved classes:
// <https://www.php.net/manual/en/reserved.classes.php>
"Directory",
"__PHP_Incomplete_Class",
"parent",
"php_user_filter",
"self",
"static",
"stdClass"
];
/** Dual-case keywords
*
* ["then","FILE"] =>
* ["then", "THEN", "FILE", "file"]
*
* @param {string[]} items */
const dualCase = (items) => {
/** @type string[] */
const result = [];
items.forEach(item => {
result.push(item);
if (item.toLowerCase() === item) {
result.push(item.toUpperCase());
} else {
result.push(item.toLowerCase());
}
});
return result;
};
const KEYWORDS = {
keyword: KWS,
literal: dualCase(LITERALS),
built_in: BUILT_INS,
};
/**
* @param {string[]} items */
const normalizeKeywords = (items) => {
return items.map(item => {
return item.replace(/\|\d+$/, "");
});
};
const CONSTRUCTOR_CALL = { variants: [
{
match: [
/new/,
regex.concat(WHITESPACE, "+"),
// to prevent built ins from being confused as the class constructor call
regex.concat("(?!", normalizeKeywords(BUILT_INS).join("\\b|"), "\\b)"),
PASCAL_CASE_CLASS_NAME_RE,
],
scope: {
1: "keyword",
4: "title.class",
},
}
] };
const CONSTANT_REFERENCE = regex.concat(IDENT_RE, "\\b(?!\\()");
const LEFT_AND_RIGHT_SIDE_OF_DOUBLE_COLON = { variants: [
{
match: [
regex.concat(
/::/,
regex.lookahead(/(?!class\b)/)
),
CONSTANT_REFERENCE,
],
scope: { 2: "variable.constant", },
},
{
match: [
/::/,
/class/,
],
scope: { 2: "variable.language", },
},
{
match: [
PASCAL_CASE_CLASS_NAME_RE,
regex.concat(
/::/,
regex.lookahead(/(?!class\b)/)
),
CONSTANT_REFERENCE,
],
scope: {
1: "title.class",
3: "variable.constant",
},
},
{
match: [
PASCAL_CASE_CLASS_NAME_RE,
regex.concat(
"::",
regex.lookahead(/(?!class\b)/)
),
],
scope: { 1: "title.class", },
},
{
match: [
PASCAL_CASE_CLASS_NAME_RE,
/::/,
/class/,
],
scope: {
1: "title.class",
3: "variable.language",
},
}
] };
const NAMED_ARGUMENT = {
scope: 'attr',
match: regex.concat(IDENT_RE, regex.lookahead(':'), regex.lookahead(/(?!::)/)),
};
const PARAMS_MODE = {
relevance: 0,
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [
NAMED_ARGUMENT,
VARIABLE,
LEFT_AND_RIGHT_SIDE_OF_DOUBLE_COLON,
hljs.C_BLOCK_COMMENT_MODE,
STRING,
NUMBER,
CONSTRUCTOR_CALL,
],
};
const FUNCTION_INVOKE = {
relevance: 0,
match: [
/\b/,
// to prevent keywords from being confused as the function title
regex.concat("(?!fn\\b|function\\b|", normalizeKeywords(KWS).join("\\b|"), "|", normalizeKeywords(BUILT_INS).join("\\b|"), "\\b)"),
IDENT_RE,
regex.concat(WHITESPACE, "*"),
regex.lookahead(/(?=\()/)
],
scope: { 3: "title.function.invoke", },
contains: [ PARAMS_MODE ]
};
PARAMS_MODE.contains.push(FUNCTION_INVOKE);
const ATTRIBUTE_CONTAINS = [
NAMED_ARGUMENT,
LEFT_AND_RIGHT_SIDE_OF_DOUBLE_COLON,
hljs.C_BLOCK_COMMENT_MODE,
STRING,
NUMBER,
CONSTRUCTOR_CALL,
];
const ATTRIBUTES = {
begin: regex.concat(/#\[\s*/, PASCAL_CASE_CLASS_NAME_RE),
beginScope: "meta",
end: /]/,
endScope: "meta",
keywords: {
literal: LITERALS,
keyword: [
'new',
'array',
]
},
contains: [
{
begin: /\[/,
end: /]/,
keywords: {
literal: LITERALS,
keyword: [
'new',
'array',
]
},
contains: [
'self',
...ATTRIBUTE_CONTAINS,
]
},
...ATTRIBUTE_CONTAINS,
{
scope: 'meta',
match: PASCAL_CASE_CLASS_NAME_RE
}
]
};
return {
case_insensitive: false,
keywords: KEYWORDS,
contains: [
ATTRIBUTES,
hljs.HASH_COMMENT_MODE,
hljs.COMMENT('//', '$'),
hljs.COMMENT(
'/\\*',
'\\*/',
{ contains: [
{
scope: 'doctag',
match: '@[A-Za-z]+'
}
] }
),
{
match: /__halt_compiler\(\);/,
keywords: '__halt_compiler',
starts: {
scope: "comment",
end: hljs.MATCH_NOTHING_RE,
contains: [
{
match: /\?>/,
scope: "meta",
endsParent: true
}
]
}
},
PREPROCESSOR,
{
scope: 'variable.language',
match: /\$this\b/
},
VARIABLE,
FUNCTION_INVOKE,
LEFT_AND_RIGHT_SIDE_OF_DOUBLE_COLON,
{
match: [
/const/,
/\s/,
IDENT_RE,
],
scope: {
1: "keyword",
3: "variable.constant",
},
},
CONSTRUCTOR_CALL,
{
scope: 'function',
relevance: 0,
beginKeywords: 'fn function',
end: /[;{]/,
excludeEnd: true,
illegal: '[$%\\[]',
contains: [
{ beginKeywords: 'use', },
hljs.UNDERSCORE_TITLE_MODE,
{
begin: '=>', // No markup, just a relevance booster
endsParent: true
},
{
scope: 'params',
begin: '\\(',
end: '\\)',
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS,
contains: [
'self',
VARIABLE,
LEFT_AND_RIGHT_SIDE_OF_DOUBLE_COLON,
hljs.C_BLOCK_COMMENT_MODE,
STRING,
NUMBER
]
},
]
},
{
scope: 'class',
variants: [
{
beginKeywords: "enum",
illegal: /[($"]/
},
{
beginKeywords: "class interface trait",
illegal: /[:($"]/
}
],
relevance: 0,
end: /\{/,
excludeEnd: true,
contains: [
{ beginKeywords: 'extends implements' },
hljs.UNDERSCORE_TITLE_MODE
]
},
// both use and namespace still use "old style" rules (vs multi-match)
// because the namespace name can include `\` and we still want each
// element to be treated as its own *individual* title
{
beginKeywords: 'namespace',
relevance: 0,
end: ';',
illegal: /[.']/,
contains: [ hljs.inherit(hljs.UNDERSCORE_TITLE_MODE, { scope: "title.class" }) ]
},
{
beginKeywords: 'use',
relevance: 0,
end: ';',
contains: [
// TODO: title.function vs title.class
{
match: /\b(as|const|function)\b/,
scope: "keyword"
},
// TODO: could be title.class or title.function
hljs.UNDERSCORE_TITLE_MODE
]
},
STRING,
NUMBER,
]
};
}
var php_1 = php;
/*
Language: PHP Template
Requires: xml.js, php.js
Author: Josh Goebel <hello@joshgoebel.com>
Website: https://www.php.net
Category: common
*/
function phpTemplate(hljs) {
return {
name: "PHP template",
subLanguage: 'xml',
contains: [
{
begin: /<\?(php|=)?/,
end: /\?>/,
subLanguage: 'php',
contains: [
// We don't want the php closing tag ?> to close the PHP block when
// inside any of the following blocks:
{
begin: '/\\*',
end: '\\*/',
skip: true
},
{
begin: 'b"',
end: '"',
skip: true
},
{
begin: 'b\'',
end: '\'',
skip: true
},
hljs.inherit(hljs.APOS_STRING_MODE, {
illegal: null,
className: null,
contains: null,
skip: true
}),
hljs.inherit(hljs.QUOTE_STRING_MODE, {
illegal: null,
className: null,
contains: null,
skip: true
})
]
}
]
};
}
var phpTemplate_1 = phpTemplate;
/*
Language: Plain text
Author: Egor Rogov (e.rogov@postgrespro.ru)
Description: Plain text without any highlighting.
Category: common
*/
function plaintext(hljs) {
return {
name: 'Plain text',
aliases: [
'text',
'txt'
],
disableAutodetect: true
};
}
var plaintext_1 = plaintext;
/*
Language: Pony
Author: Joe Eli McIlvain <joe.eli.mac@gmail.com>
Description: Pony is an open-source, object-oriented, actor-model,
capabilities-secure, high performance programming language.
Website: https://www.ponylang.io
*/
function pony(hljs) {
const KEYWORDS = {
keyword:
'actor addressof and as be break class compile_error compile_intrinsic '
+ 'consume continue delegate digestof do else elseif embed end error '
+ 'for fun if ifdef in interface is isnt lambda let match new not object '
+ 'or primitive recover repeat return struct then trait try type until '
+ 'use var where while with xor',
meta:
'iso val tag trn box ref',
literal:
'this false true'
};
const TRIPLE_QUOTE_STRING_MODE = {
className: 'string',
begin: '"""',
end: '"""',
relevance: 10
};
const QUOTE_STRING_MODE = {
className: 'string',
begin: '"',
end: '"',
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const SINGLE_QUOTE_CHAR_MODE = {
className: 'string',
begin: '\'',
end: '\'',
contains: [ hljs.BACKSLASH_ESCAPE ],
relevance: 0
};
const TYPE_NAME = {
className: 'type',
begin: '\\b_?[A-Z][\\w]*',
relevance: 0
};
const PRIMED_NAME = {
begin: hljs.IDENT_RE + '\'',
relevance: 0
};
const NUMBER_MODE = {
className: 'number',
begin: '(-?)(\\b0[xX][a-fA-F0-9]+|\\b0[bB][01]+|(\\b\\d+(_\\d+)?(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)',
relevance: 0
};
/**
* The `FUNCTION` and `CLASS` modes were intentionally removed to simplify
* highlighting and fix cases like
* ```
* interface Iterator[A: A]
* fun has_next(): Bool
* fun next(): A?
* ```
* where it is valid to have a function head without a body
*/
return {
name: 'Pony',
keywords: KEYWORDS,
contains: [
TYPE_NAME,
TRIPLE_QUOTE_STRING_MODE,
QUOTE_STRING_MODE,
SINGLE_QUOTE_CHAR_MODE,
PRIMED_NAME,
NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
}
var pony_1 = pony;
/*
Language: PowerShell
Description: PowerShell is a task-based command-line shell and scripting language built on .NET.
Author: David Mohundro <david@mohundro.com>
Contributors: Nicholas Blumhardt <nblumhardt@nblumhardt.com>, Victor Zhou <OiCMudkips@users.noreply.github.com>, Nicolas Le Gall <contact@nlegall.fr>
Website: https://docs.microsoft.com/en-us/powershell/
*/
function powershell(hljs) {
const TYPES = [
"string",
"char",
"byte",
"int",
"long",
"bool",
"decimal",
"single",
"double",
"DateTime",
"xml",
"array",
"hashtable",
"void"
];
// https://docs.microsoft.com/en-us/powershell/scripting/developer/cmdlet/approved-verbs-for-windows-powershell-commands
const VALID_VERBS =
'Add|Clear|Close|Copy|Enter|Exit|Find|Format|Get|Hide|Join|Lock|'
+ 'Move|New|Open|Optimize|Pop|Push|Redo|Remove|Rename|Reset|Resize|'
+ 'Search|Select|Set|Show|Skip|Split|Step|Switch|Undo|Unlock|'
+ 'Watch|Backup|Checkpoint|Compare|Compress|Convert|ConvertFrom|'
+ 'ConvertTo|Dismount|Edit|Expand|Export|Group|Import|Initialize|'
+ 'Limit|Merge|Mount|Out|Publish|Restore|Save|Sync|Unpublish|Update|'
+ 'Approve|Assert|Build|Complete|Confirm|Deny|Deploy|Disable|Enable|Install|Invoke|'
+ 'Register|Request|Restart|Resume|Start|Stop|Submit|Suspend|Uninstall|'
+ 'Unregister|Wait|Debug|Measure|Ping|Repair|Resolve|Test|Trace|Connect|'
+ 'Disconnect|Read|Receive|Send|Write|Block|Grant|Protect|Revoke|Unblock|'
+ 'Unprotect|Use|ForEach|Sort|Tee|Where';
const COMPARISON_OPERATORS =
'-and|-as|-band|-bnot|-bor|-bxor|-casesensitive|-ccontains|-ceq|-cge|-cgt|'
+ '-cle|-clike|-clt|-cmatch|-cne|-cnotcontains|-cnotlike|-cnotmatch|-contains|'
+ '-creplace|-csplit|-eq|-exact|-f|-file|-ge|-gt|-icontains|-ieq|-ige|-igt|'
+ '-ile|-ilike|-ilt|-imatch|-in|-ine|-inotcontains|-inotlike|-inotmatch|'
+ '-ireplace|-is|-isnot|-isplit|-join|-le|-like|-lt|-match|-ne|-not|'
+ '-notcontains|-notin|-notlike|-notmatch|-or|-regex|-replace|-shl|-shr|'
+ '-split|-wildcard|-xor';
const KEYWORDS = {
$pattern: /-?[A-z\.\-]+\b/,
keyword:
'if else foreach return do while until elseif begin for trap data dynamicparam '
+ 'end break throw param continue finally in switch exit filter try process catch '
+ 'hidden static parameter',
// "echo" relevance has been set to 0 to avoid auto-detect conflicts with shell transcripts
built_in:
'ac asnp cat cd CFS chdir clc clear clhy cli clp cls clv cnsn compare copy cp '
+ 'cpi cpp curl cvpa dbp del diff dir dnsn ebp echo|0 epal epcsv epsn erase etsn exsn fc fhx '
+ 'fl ft fw gal gbp gc gcb gci gcm gcs gdr gerr ghy gi gin gjb gl gm gmo gp gps gpv group '
+ 'gsn gsnp gsv gtz gu gv gwmi h history icm iex ihy ii ipal ipcsv ipmo ipsn irm ise iwmi '
+ 'iwr kill lp ls man md measure mi mount move mp mv nal ndr ni nmo npssc nsn nv ogv oh '
+ 'popd ps pushd pwd r rbp rcjb rcsn rd rdr ren ri rjb rm rmdir rmo rni rnp rp rsn rsnp '
+ 'rujb rv rvpa rwmi sajb sal saps sasv sbp sc scb select set shcm si sl sleep sls sort sp '
+ 'spjb spps spsv start stz sujb sv swmi tee trcm type wget where wjb write'
// TODO: 'validate[A-Z]+' can't work in keywords
};
const TITLE_NAME_RE = /\w[\w\d]*((-)[\w\d]+)*/;
const BACKTICK_ESCAPE = {
begin: '`[\\s\\S]',
relevance: 0
};
const VAR = {
className: 'variable',
variants: [
{ begin: /\$\B/ },
{
className: 'keyword',
begin: /\$this/
},
{ begin: /\$[\w\d][\w\d_:]*/ }
]
};
const LITERAL = {
className: 'literal',
begin: /\$(null|true|false)\b/
};
const QUOTE_STRING = {
className: "string",
variants: [
{
begin: /"/,
end: /"/
},
{
begin: /@"/,
end: /^"@/
}
],
contains: [
BACKTICK_ESCAPE,
VAR,
{
className: 'variable',
begin: /\$[A-z]/,
end: /[^A-z]/
}
]
};
const APOS_STRING = {
className: 'string',
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /@'/,
end: /^'@/
}
]
};
const PS_HELPTAGS = {
className: "doctag",
variants: [
/* no paramater help tags */
{ begin: /\.(synopsis|description|example|inputs|outputs|notes|link|component|role|functionality)/ },
/* one parameter help tags */
{ begin: /\.(parameter|forwardhelptargetname|forwardhelpcategory|remotehelprunspace|externalhelp)\s+\S+/ }
]
};
const PS_COMMENT = hljs.inherit(
hljs.COMMENT(null, null),
{
variants: [
/* single-line comment */
{
begin: /#/,
end: /$/
},
/* multi-line comment */
{
begin: /<#/,
end: /#>/
}
],
contains: [ PS_HELPTAGS ]
}
);
const CMDLETS = {
className: 'built_in',
variants: [ { begin: '('.concat(VALID_VERBS, ')+(-)[\\w\\d]+') } ]
};
const PS_CLASS = {
className: 'class',
beginKeywords: 'class enum',
end: /\s*[{]/,
excludeEnd: true,
relevance: 0,
contains: [ hljs.TITLE_MODE ]
};
const PS_FUNCTION = {
className: 'function',
begin: /function\s+/,
end: /\s*\{|$/,
excludeEnd: true,
returnBegin: true,
relevance: 0,
contains: [
{
begin: "function",
relevance: 0,
className: "keyword"
},
{
className: "title",
begin: TITLE_NAME_RE,
relevance: 0
},
{
begin: /\(/,
end: /\)/,
className: "params",
relevance: 0,
contains: [ VAR ]
}
// CMDLETS
]
};
// Using statment, plus type, plus assembly name.
const PS_USING = {
begin: /using\s/,
end: /$/,
returnBegin: true,
contains: [
QUOTE_STRING,
APOS_STRING,
{
className: 'keyword',
begin: /(using|assembly|command|module|namespace|type)/
}
]
};
// Comperison operators & function named parameters.
const PS_ARGUMENTS = { variants: [
// PS literals are pretty verbose so it's a good idea to accent them a bit.
{
className: 'operator',
begin: '('.concat(COMPARISON_OPERATORS, ')\\b')
},
{
className: 'literal',
begin: /(-){1,2}[\w\d-]+/,
relevance: 0
}
] };
const HASH_SIGNS = {
className: 'selector-tag',
begin: /@\B/,
relevance: 0
};
// It's a very general rule so I'll narrow it a bit with some strict boundaries
// to avoid any possible false-positive collisions!
const PS_METHODS = {
className: 'function',
begin: /\[.*\]\s*[\w]+[ ]??\(/,
end: /$/,
returnBegin: true,
relevance: 0,
contains: [
{
className: 'keyword',
begin: '('.concat(
KEYWORDS.keyword.toString().replace(/\s/g, '|'
), ')\\b'),
endsParent: true,
relevance: 0
},
hljs.inherit(hljs.TITLE_MODE, { endsParent: true })
]
};
const GENTLEMANS_SET = [
// STATIC_MEMBER,
PS_METHODS,
PS_COMMENT,
BACKTICK_ESCAPE,
hljs.NUMBER_MODE,
QUOTE_STRING,
APOS_STRING,
// PS_NEW_OBJECT_TYPE,
CMDLETS,
VAR,
LITERAL,
HASH_SIGNS
];
const PS_TYPE = {
begin: /\[/,
end: /\]/,
excludeBegin: true,
excludeEnd: true,
relevance: 0,
contains: [].concat(
'self',
GENTLEMANS_SET,
{
begin: "(" + TYPES.join("|") + ")",
className: "built_in",
relevance: 0
},
{
className: 'type',
begin: /[\.\w\d]+/,
relevance: 0
}
)
};
PS_METHODS.contains.unshift(PS_TYPE);
return {
name: 'PowerShell',
aliases: [
"pwsh",
"ps",
"ps1"
],
case_insensitive: true,
keywords: KEYWORDS,
contains: GENTLEMANS_SET.concat(
PS_CLASS,
PS_FUNCTION,
PS_USING,
PS_ARGUMENTS,
PS_TYPE
)
};
}
var powershell_1 = powershell;
/*
Language: Processing
Description: Processing is a flexible software sketchbook and a language for learning how to code within the context of the visual arts.
Author: Erik Paluka <erik.paluka@gmail.com>
Website: https://processing.org
Category: graphics
*/
function processing(hljs) {
const regex = hljs.regex;
const BUILT_INS = [
"displayHeight",
"displayWidth",
"mouseY",
"mouseX",
"mousePressed",
"pmouseX",
"pmouseY",
"key",
"keyCode",
"pixels",
"focused",
"frameCount",
"frameRate",
"height",
"width",
"size",
"createGraphics",
"beginDraw",
"createShape",
"loadShape",
"PShape",
"arc",
"ellipse",
"line",
"point",
"quad",
"rect",
"triangle",
"bezier",
"bezierDetail",
"bezierPoint",
"bezierTangent",
"curve",
"curveDetail",
"curvePoint",
"curveTangent",
"curveTightness",
"shape",
"shapeMode",
"beginContour",
"beginShape",
"bezierVertex",
"curveVertex",
"endContour",
"endShape",
"quadraticVertex",
"vertex",
"ellipseMode",
"noSmooth",
"rectMode",
"smooth",
"strokeCap",
"strokeJoin",
"strokeWeight",
"mouseClicked",
"mouseDragged",
"mouseMoved",
"mousePressed",
"mouseReleased",
"mouseWheel",
"keyPressed",
"keyPressedkeyReleased",
"keyTyped",
"print",
"println",
"save",
"saveFrame",
"day",
"hour",
"millis",
"minute",
"month",
"second",
"year",
"background",
"clear",
"colorMode",
"fill",
"noFill",
"noStroke",
"stroke",
"alpha",
"blue",
"brightness",
"color",
"green",
"hue",
"lerpColor",
"red",
"saturation",
"modelX",
"modelY",
"modelZ",
"screenX",
"screenY",
"screenZ",
"ambient",
"emissive",
"shininess",
"specular",
"add",
"createImage",
"beginCamera",
"camera",
"endCamera",
"frustum",
"ortho",
"perspective",
"printCamera",
"printProjection",
"cursor",
"frameRate",
"noCursor",
"exit",
"loop",
"noLoop",
"popStyle",
"pushStyle",
"redraw",
"binary",
"boolean",
"byte",
"char",
"float",
"hex",
"int",
"str",
"unbinary",
"unhex",
"join",
"match",
"matchAll",
"nf",
"nfc",
"nfp",
"nfs",
"split",
"splitTokens",
"trim",
"append",
"arrayCopy",
"concat",
"expand",
"reverse",
"shorten",
"sort",
"splice",
"subset",
"box",
"sphere",
"sphereDetail",
"createInput",
"createReader",
"loadBytes",
"loadJSONArray",
"loadJSONObject",
"loadStrings",
"loadTable",
"loadXML",
"open",
"parseXML",
"saveTable",
"selectFolder",
"selectInput",
"beginRaw",
"beginRecord",
"createOutput",
"createWriter",
"endRaw",
"endRecord",
"PrintWritersaveBytes",
"saveJSONArray",
"saveJSONObject",
"saveStream",
"saveStrings",
"saveXML",
"selectOutput",
"popMatrix",
"printMatrix",
"pushMatrix",
"resetMatrix",
"rotate",
"rotateX",
"rotateY",
"rotateZ",
"scale",
"shearX",
"shearY",
"translate",
"ambientLight",
"directionalLight",
"lightFalloff",
"lights",
"lightSpecular",
"noLights",
"normal",
"pointLight",
"spotLight",
"image",
"imageMode",
"loadImage",
"noTint",
"requestImage",
"tint",
"texture",
"textureMode",
"textureWrap",
"blend",
"copy",
"filter",
"get",
"loadPixels",
"set",
"updatePixels",
"blendMode",
"loadShader",
"PShaderresetShader",
"shader",
"createFont",
"loadFont",
"text",
"textFont",
"textAlign",
"textLeading",
"textMode",
"textSize",
"textWidth",
"textAscent",
"textDescent",
"abs",
"ceil",
"constrain",
"dist",
"exp",
"floor",
"lerp",
"log",
"mag",
"map",
"max",
"min",
"norm",
"pow",
"round",
"sq",
"sqrt",
"acos",
"asin",
"atan",
"atan2",
"cos",
"degrees",
"radians",
"sin",
"tan",
"noise",
"noiseDetail",
"noiseSeed",
"random",
"randomGaussian",
"randomSeed"
];
const IDENT = hljs.IDENT_RE;
const FUNC_NAME = { variants: [
{
match: regex.concat(regex.either(...BUILT_INS), regex.lookahead(/\s*\(/)),
className: "built_in"
},
{
relevance: 0,
match: regex.concat(
/\b(?!for|if|while)/,
IDENT, regex.lookahead(/\s*\(/)),
className: "title.function"
}
] };
const NEW_CLASS = {
match: [
/new\s+/,
IDENT
],
className: {
1: "keyword",
2: "class.title"
}
};
const PROPERTY = {
relevance: 0,
match: [
/\./,
IDENT
],
className: { 2: "property" }
};
const CLASS = {
variants: [
{ match: [
/class/,
/\s+/,
IDENT,
/\s+/,
/extends/,
/\s+/,
IDENT
] },
{ match: [
/class/,
/\s+/,
IDENT
] }
],
className: {
1: "keyword",
3: "title.class",
5: "keyword",
7: "title.class.inherited"
}
};
const TYPES = [
"boolean",
"byte",
"char",
"color",
"double",
"float",
"int",
"long",
"short",
];
const CLASSES = [
"BufferedReader",
"PVector",
"PFont",
"PImage",
"PGraphics",
"HashMap",
"String",
"Array",
"FloatDict",
"ArrayList",
"FloatList",
"IntDict",
"IntList",
"JSONArray",
"JSONObject",
"Object",
"StringDict",
"StringList",
"Table",
"TableRow",
"XML"
];
const JAVA_KEYWORDS = [
"abstract",
"assert",
"break",
"case",
"catch",
"const",
"continue",
"default",
"else",
"enum",
"final",
"finally",
"for",
"if",
"import",
"instanceof",
"long",
"native",
"new",
"package",
"private",
"private",
"protected",
"protected",
"public",
"public",
"return",
"static",
"strictfp",
"switch",
"synchronized",
"throw",
"throws",
"transient",
"try",
"void",
"volatile",
"while"
];
return {
name: 'Processing',
aliases: [ 'pde' ],
keywords: {
keyword: [ ...JAVA_KEYWORDS ],
literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI null true false',
title: 'setup draw',
variable: "super this",
built_in: [
...BUILT_INS,
...CLASSES
],
type: TYPES
},
contains: [
CLASS,
NEW_CLASS,
FUNC_NAME,
PROPERTY,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE
]
};
}
var processing_1 = processing;
/*
Language: Python profiler
Description: Python profiler results
Author: Brian Beck <exogen@gmail.com>
*/
function profile(hljs) {
return {
name: 'Python profiler',
contains: [
hljs.C_NUMBER_MODE,
{
begin: '[a-zA-Z_][\\da-zA-Z_]+\\.[\\da-zA-Z_]{1,3}',
end: ':',
excludeEnd: true
},
{
begin: '(ncalls|tottime|cumtime)',
end: '$',
keywords: 'ncalls tottime|10 cumtime|10 filename',
relevance: 10
},
{
begin: 'function calls',
end: '$',
contains: [ hljs.C_NUMBER_MODE ],
relevance: 10
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '\\(',
end: '\\)$',
excludeBegin: true,
excludeEnd: true,
relevance: 0
}
]
};
}
var profile_1 = profile;
/*
Language: Prolog
Description: Prolog is a general purpose logic programming language associated with artificial intelligence and computational linguistics.
Author: Raivo Laanemets <raivo@infdot.com>
Website: https://en.wikipedia.org/wiki/Prolog
*/
function prolog(hljs) {
const ATOM = {
begin: /[a-z][A-Za-z0-9_]*/,
relevance: 0
};
const VAR = {
className: 'symbol',
variants: [
{ begin: /[A-Z][a-zA-Z0-9_]*/ },
{ begin: /_[A-Za-z0-9_]*/ }
],
relevance: 0
};
const PARENTED = {
begin: /\(/,
end: /\)/,
relevance: 0
};
const LIST = {
begin: /\[/,
end: /\]/
};
const LINE_COMMENT = {
className: 'comment',
begin: /%/,
end: /$/,
contains: [ hljs.PHRASAL_WORDS_MODE ]
};
const BACKTICK_STRING = {
className: 'string',
begin: /`/,
end: /`/,
contains: [ hljs.BACKSLASH_ESCAPE ]
};
const CHAR_CODE = {
className: 'string', // 0'a etc.
begin: /0'(\\'|.)/
};
const SPACE_CODE = {
className: 'string',
begin: /0'\\s/ // 0'\s
};
const PRED_OP = { // relevance booster
begin: /:-/ };
const inner = [
ATOM,
VAR,
PARENTED,
PRED_OP,
LIST,
LINE_COMMENT,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
BACKTICK_STRING,
CHAR_CODE,
SPACE_CODE,
hljs.C_NUMBER_MODE
];
PARENTED.contains = inner;
LIST.contains = inner;
return {
name: 'Prolog',
contains: inner.concat([
{ // relevance booster
begin: /\.$/ }
])
};
}
var prolog_1 = prolog;
/*
Language: .properties
Contributors: Valentin Aitken <valentin@nalisbg.com>, Egor Rogov <e.rogov@postgrespro.ru>
Website: https://en.wikipedia.org/wiki/.properties
Category: config
*/
/** @type LanguageFn */
function properties(hljs) {
// whitespaces: space, tab, formfeed
const WS0 = '[ \\t\\f]*';
const WS1 = '[ \\t\\f]+';
// delimiter
const EQUAL_DELIM = WS0 + '[:=]' + WS0;
const WS_DELIM = WS1;
const DELIM = '(' + EQUAL_DELIM + '|' + WS_DELIM + ')';
const KEY = '([^\\\\:= \\t\\f\\n]|\\\\.)+';
const DELIM_AND_VALUE = {
// skip DELIM
end: DELIM,
relevance: 0,
starts: {
// value: everything until end of line (again, taking into account backslashes)
className: 'string',
end: /$/,
relevance: 0,
contains: [
{ begin: '\\\\\\\\' },
{ begin: '\\\\\\n' }
]
}
};
return {
name: '.properties',
disableAutodetect: true,
case_insensitive: true,
illegal: /\S/,
contains: [
hljs.COMMENT('^\\s*[!#]', '$'),
// key: everything until whitespace or = or : (taking into account backslashes)
// case of a key-value pair
{
returnBegin: true,
variants: [
{ begin: KEY + EQUAL_DELIM },
{ begin: KEY + WS_DELIM }
],
contains: [
{
className: 'attr',
begin: KEY,
endsParent: true
}
],
starts: DELIM_AND_VALUE
},
// case of an empty key
{
className: 'attr',
begin: KEY + WS0 + '$'
}
]
};
}
var properties_1 = properties;
/*
Language: Protocol Buffers
Author: Dan Tao <daniel.tao@gmail.com>
Description: Protocol buffer message definition format
Website: https://developers.google.com/protocol-buffers/docs/proto3
Category: protocols
*/
function protobuf(hljs) {
const KEYWORDS = [
"package",
"import",
"option",
"optional",
"required",
"repeated",
"group",
"oneof"
];
const TYPES = [
"double",
"float",
"int32",
"int64",
"uint32",
"uint64",
"sint32",
"sint64",
"fixed32",
"fixed64",
"sfixed32",
"sfixed64",
"bool",
"string",
"bytes"
];
const CLASS_DEFINITION = {
match: [
/(message|enum|service)\s+/,
hljs.IDENT_RE
],
scope: {
1: "keyword",
2: "title.class"
}
};
return {
name: 'Protocol Buffers',
aliases: ['proto'],
keywords: {
keyword: KEYWORDS,
type: TYPES,
literal: [
'true',
'false'
]
},
contains: [
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
CLASS_DEFINITION,
{
className: 'function',
beginKeywords: 'rpc',
end: /[{;]/,
excludeEnd: true,
keywords: 'rpc returns'
},
{ // match enum items (relevance)
// BLAH = ...;
begin: /^\s*[A-Z_]+(?=\s*=[^\n]+;$)/ }
]
};
}
var protobuf_1 = protobuf;
/*
Language: Puppet
Author: Jose Molina Colmenero <gaudy41@gmail.com>
Website: https://puppet.com/docs
Category: config
*/
function puppet(hljs) {
const PUPPET_KEYWORDS = {
keyword:
/* language keywords */
'and case default else elsif false if in import enherits node or true undef unless main settings $string ',
literal:
/* metaparameters */
'alias audit before loglevel noop require subscribe tag '
/* normal attributes */
+ 'owner ensure group mode name|0 changes context force incl lens load_path onlyif provider returns root show_diff type_check '
+ 'en_address ip_address realname command environment hour monute month monthday special target weekday '
+ 'creates cwd ogoutput refresh refreshonly tries try_sleep umask backup checksum content ctime force ignore '
+ 'links mtime purge recurse recurselimit replace selinux_ignore_defaults selrange selrole seltype seluser source '
+ 'souirce_permissions sourceselect validate_cmd validate_replacement allowdupe attribute_membership auth_membership forcelocal gid '
+ 'ia_load_module members system host_aliases ip allowed_trunk_vlans description device_url duplex encapsulation etherchannel '
+ 'native_vlan speed principals allow_root auth_class auth_type authenticate_user k_of_n mechanisms rule session_owner shared options '
+ 'device fstype enable hasrestart directory present absent link atboot blockdevice device dump pass remounts poller_tag use '
+ 'message withpath adminfile allow_virtual allowcdrom category configfiles flavor install_options instance package_settings platform '
+ 'responsefile status uninstall_options vendor unless_system_user unless_uid binary control flags hasstatus manifest pattern restart running '
+ 'start stop allowdupe auths expiry gid groups home iterations key_membership keys managehome membership password password_max_age '
+ 'password_min_age profile_membership profiles project purge_ssh_keys role_membership roles salt shell uid baseurl cost descr enabled '
+ 'enablegroups exclude failovermethod gpgcheck gpgkey http_caching include includepkgs keepalive metadata_expire metalink mirrorlist '
+ 'priority protect proxy proxy_password proxy_username repo_gpgcheck s3_enabled skip_if_unavailable sslcacert sslclientcert sslclientkey '
+ 'sslverify mounted',
built_in:
/* core facts */
'architecture augeasversion blockdevices boardmanufacturer boardproductname boardserialnumber cfkey dhcp_servers '
+ 'domain ec2_ ec2_userdata facterversion filesystems ldom fqdn gid hardwareisa hardwaremodel hostname id|0 interfaces '
+ 'ipaddress ipaddress_ ipaddress6 ipaddress6_ iphostnumber is_virtual kernel kernelmajversion kernelrelease kernelversion '
+ 'kernelrelease kernelversion lsbdistcodename lsbdistdescription lsbdistid lsbdistrelease lsbmajdistrelease lsbminordistrelease '
+ 'lsbrelease macaddress macaddress_ macosx_buildversion macosx_productname macosx_productversion macosx_productverson_major '
+ 'macosx_productversion_minor manufacturer memoryfree memorysize netmask metmask_ network_ operatingsystem operatingsystemmajrelease '
+ 'operatingsystemrelease osfamily partitions path physicalprocessorcount processor processorcount productname ps puppetversion '
+ 'rubysitedir rubyversion selinux selinux_config_mode selinux_config_policy selinux_current_mode selinux_current_mode selinux_enforced '
+ 'selinux_policyversion serialnumber sp_ sshdsakey sshecdsakey sshrsakey swapencrypted swapfree swapsize timezone type uniqueid uptime '
+ 'uptime_days uptime_hours uptime_seconds uuid virtual vlans xendomains zfs_version zonenae zones zpool_version'
};
const COMMENT = hljs.COMMENT('#', '$');
const IDENT_RE = '([A-Za-z_]|::)(\\w|::)*';
const TITLE = hljs.inherit(hljs.TITLE_MODE, { begin: IDENT_RE });
const VARIABLE = {
className: 'variable',
begin: '\\$' + IDENT_RE
};
const STRING = {
className: 'string',
contains: [
hljs.BACKSLASH_ESCAPE,
VARIABLE
],
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
}
]
};
return {
name: 'Puppet',
aliases: [ 'pp' ],
contains: [
COMMENT,
VARIABLE,
STRING,
{
beginKeywords: 'class',
end: '\\{|;',
illegal: /=/,
contains: [
TITLE,
COMMENT
]
},
{
beginKeywords: 'define',
end: /\{/,
contains: [
{
className: 'section',
begin: hljs.IDENT_RE,
endsParent: true
}
]
},
{
begin: hljs.IDENT_RE + '\\s+\\{',
returnBegin: true,
end: /\S/,
contains: [
{
className: 'keyword',
begin: hljs.IDENT_RE,
relevance: 0.2
},
{
begin: /\{/,
end: /\}/,
keywords: PUPPET_KEYWORDS,
relevance: 0,
contains: [
STRING,
COMMENT,
{
begin: '[a-zA-Z_]+\\s*=>',
returnBegin: true,
end: '=>',
contains: [
{
className: 'attr',
begin: hljs.IDENT_RE
}
]
},
{
className: 'number',
begin: '(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b',
relevance: 0
},
VARIABLE
]
}
],
relevance: 0
}
]
};
}
var puppet_1 = puppet;
/*
Language: PureBASIC
Author: Tristano Ajmone <tajmone@gmail.com>
Description: Syntax highlighting for PureBASIC (v.5.00-5.60). No inline ASM highlighting. (v.1.2, May 2017)
Credits: I've taken inspiration from the PureBasic language file for GeSHi, created by Gustavo Julio Fiorenza (GuShH).
Website: https://www.purebasic.com
*/
// Base deafult colors in PB IDE: background: #FFFFDF; foreground: #000000;
function purebasic(hljs) {
const STRINGS = { // PB IDE color: #0080FF (Azure Radiance)
className: 'string',
begin: '(~)?"',
end: '"',
illegal: '\\n'
};
const CONSTANTS = { // PB IDE color: #924B72 (Cannon Pink)
// "#" + a letter or underscore + letters, digits or underscores + (optional) "$"
className: 'symbol',
begin: '#[a-zA-Z_]\\w*\\$?'
};
return {
name: 'PureBASIC',
aliases: [
'pb',
'pbi'
],
keywords: // PB IDE color: #006666 (Blue Stone) + Bold
// Keywords from all version of PureBASIC 5.00 upward ...
'Align And Array As Break CallDebugger Case CompilerCase CompilerDefault '
+ 'CompilerElse CompilerElseIf CompilerEndIf CompilerEndSelect CompilerError '
+ 'CompilerIf CompilerSelect CompilerWarning Continue Data DataSection Debug '
+ 'DebugLevel Declare DeclareC DeclareCDLL DeclareDLL DeclareModule Default '
+ 'Define Dim DisableASM DisableDebugger DisableExplicit Else ElseIf EnableASM '
+ 'EnableDebugger EnableExplicit End EndDataSection EndDeclareModule EndEnumeration '
+ 'EndIf EndImport EndInterface EndMacro EndModule EndProcedure EndSelect '
+ 'EndStructure EndStructureUnion EndWith Enumeration EnumerationBinary Extends '
+ 'FakeReturn For ForEach ForEver Global Gosub Goto If Import ImportC '
+ 'IncludeBinary IncludeFile IncludePath Interface List Macro MacroExpandedCount '
+ 'Map Module NewList NewMap Next Not Or Procedure ProcedureC '
+ 'ProcedureCDLL ProcedureDLL ProcedureReturn Protected Prototype PrototypeC ReDim '
+ 'Read Repeat Restore Return Runtime Select Shared Static Step Structure '
+ 'StructureUnion Swap Threaded To UndefineMacro Until Until UnuseModule '
+ 'UseModule Wend While With XIncludeFile XOr',
contains: [
// COMMENTS | PB IDE color: #00AAAA (Persian Green)
hljs.COMMENT(';', '$', { relevance: 0 }),
{ // PROCEDURES DEFINITIONS
className: 'function',
begin: '\\b(Procedure|Declare)(C|CDLL|DLL)?\\b',
end: '\\(',
excludeEnd: true,
returnBegin: true,
contains: [
{ // PROCEDURE KEYWORDS | PB IDE color: #006666 (Blue Stone) + Bold
className: 'keyword',
begin: '(Procedure|Declare)(C|CDLL|DLL)?',
excludeEnd: true
},
{ // PROCEDURE RETURN TYPE SETTING | PB IDE color: #000000 (Black)
className: 'type',
begin: '\\.\\w*'
// end: ' ',
},
hljs.UNDERSCORE_TITLE_MODE // PROCEDURE NAME | PB IDE color: #006666 (Blue Stone)
]
},
STRINGS,
CONSTANTS
]
};
}
/* ==============================================================================
CHANGELOG
==============================================================================
- v.1.2 (2017-05-12)
-- BUG-FIX: Some keywords were accidentally joyned together. Now fixed.
- v.1.1 (2017-04-30)
-- Updated to PureBASIC 5.60.
-- Keywords list now built by extracting them from the PureBASIC SDK's
"SyntaxHilighting.dll" (from each PureBASIC version). Tokens from each
version are added to the list, and renamed or removed tokens are kept
for the sake of covering all versions of the language from PureBASIC
v5.00 upward. (NOTE: currently, there are no renamed or deprecated
tokens in the keywords list). For more info, see:
-- http://www.purebasic.fr/english/viewtopic.php?&p=506269
-- https://github.com/tajmone/purebasic-archives/tree/master/syntax-highlighting/guidelines
- v.1.0 (April 2016)
-- First release
-- Keywords list taken and adapted from GuShH's (Gustavo Julio Fiorenza)
PureBasic language file for GeSHi:
-- https://github.com/easybook/geshi/blob/master/geshi/purebasic.php
*/
var purebasic_1 = purebasic;
/*
Language: Python
Description: Python is an interpreted, object-oriented, high-level programming language with dynamic semantics.
Website: https://www.python.org
Category: common
*/
function python(hljs) {
const regex = hljs.regex;
const IDENT_RE = /[\p{XID_Start}_]\p{XID_Continue}*/u;
const RESERVED_WORDS = [
'and',
'as',
'assert',
'async',
'await',
'break',
'case',
'class',
'continue',
'def',
'del',
'elif',
'else',
'except',
'finally',
'for',
'from',
'global',
'if',
'import',
'in',
'is',
'lambda',
'match',
'nonlocal|10',
'not',
'or',
'pass',
'raise',
'return',
'try',
'while',
'with',
'yield'
];
const BUILT_INS = [
'__import__',
'abs',
'all',
'any',
'ascii',
'bin',
'bool',
'breakpoint',
'bytearray',
'bytes',
'callable',
'chr',
'classmethod',
'compile',
'complex',
'delattr',
'dict',
'dir',
'divmod',
'enumerate',
'eval',
'exec',
'filter',
'float',
'format',
'frozenset',
'getattr',
'globals',
'hasattr',
'hash',
'help',
'hex',
'id',
'input',
'int',
'isinstance',
'issubclass',
'iter',
'len',
'list',
'locals',
'map',
'max',
'memoryview',
'min',
'next',
'object',
'oct',
'open',
'ord',
'pow',
'print',
'property',
'range',
'repr',
'reversed',
'round',
'set',
'setattr',
'slice',
'sorted',
'staticmethod',
'str',
'sum',
'super',
'tuple',
'type',
'vars',
'zip'
];
const LITERALS = [
'__debug__',
'Ellipsis',
'False',
'None',
'NotImplemented',
'True'
];
// https://docs.python.org/3/library/typing.html
// TODO: Could these be supplemented by a CamelCase matcher in certain
// contexts, leaving these remaining only for relevance hinting?
const TYPES = [
"Any",
"Callable",
"Coroutine",
"Dict",
"List",
"Literal",
"Generic",
"Optional",
"Sequence",
"Set",
"Tuple",
"Type",
"Union"
];
const KEYWORDS = {
$pattern: /[A-Za-z]\w+|__\w+__/,
keyword: RESERVED_WORDS,
built_in: BUILT_INS,
literal: LITERALS,
type: TYPES
};
const PROMPT = {
className: 'meta',
begin: /^(>>>|\.\.\.) /
};
const SUBST = {
className: 'subst',
begin: /\{/,
end: /\}/,
keywords: KEYWORDS,
illegal: /#/
};
const LITERAL_BRACKET = {
begin: /\{\{/,
relevance: 0
};
const STRING = {
className: 'string',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
{
begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,
end: /'''/,
contains: [
hljs.BACKSLASH_ESCAPE,
PROMPT
],
relevance: 10
},
{
begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,
end: /"""/,
contains: [
hljs.BACKSLASH_ESCAPE,
PROMPT
],
relevance: 10
},
{
begin: /([fF][rR]|[rR][fF]|[fF])'''/,
end: /'''/,
contains: [
hljs.BACKSLASH_ESCAPE,
PROMPT,
LITERAL_BRACKET,
SUBST
]
},
{
begin: /([fF][rR]|[rR][fF]|[fF])"""/,
end: /"""/,
contains: [
hljs.BACKSLASH_ESCAPE,
PROMPT,
LITERAL_BRACKET,
SUBST
]
},
{
begin: /([uU]|[rR])'/,
end: /'/,
relevance: 10
},
{
begin: /([uU]|[rR])"/,
end: /"/,
relevance: 10
},
{
begin: /([bB]|[bB][rR]|[rR][bB])'/,
end: /'/
},
{
begin: /([bB]|[bB][rR]|[rR][bB])"/,
end: /"/
},
{
begin: /([fF][rR]|[rR][fF]|[fF])'/,
end: /'/,
contains: [
hljs.BACKSLASH_ESCAPE,
LITERAL_BRACKET,
SUBST
]
},
{
begin: /([fF][rR]|[rR][fF]|[fF])"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
LITERAL_BRACKET,
SUBST
]
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
};
// https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals
const digitpart = '[0-9](_?[0-9])*';
const pointfloat = `(\\b(${digitpart}))?\\.(${digitpart})|\\b(${digitpart})\\.`;
// Whitespace after a number (or any lexical token) is needed only if its absence
// would change the tokenization
// https://docs.python.org/3.9/reference/lexical_analysis.html#whitespace-between-tokens
// We deviate slightly, requiring a word boundary or a keyword
// to avoid accidentally recognizing *prefixes* (e.g., `0` in `0x41` or `08` or `0__1`)
const lookahead = `\\b|${RESERVED_WORDS.join('|')}`;
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
// exponentfloat, pointfloat
// https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals
// optionally imaginary
// https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals
// Note: no leading \b because floats can start with a decimal point
// and we don't want to mishandle e.g. `fn(.5)`,
// no trailing \b for pointfloat because it can end with a decimal point
// and we don't want to mishandle e.g. `0..hex()`; this should be safe
// because both MUST contain a decimal point and so cannot be confused with
// the interior part of an identifier
{
begin: `(\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?(?=${lookahead})`
},
{
begin: `(${pointfloat})[jJ]?`
},
// decinteger, bininteger, octinteger, hexinteger
// https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals
// optionally "long" in Python 2
// https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals
// decinteger is optionally imaginary
// https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals
{
begin: `\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${lookahead})`
},
{
begin: `\\b0[bB](_?[01])+[lL]?(?=${lookahead})`
},
{
begin: `\\b0[oO](_?[0-7])+[lL]?(?=${lookahead})`
},
{
begin: `\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${lookahead})`
},
// imagnumber (digitpart-based)
// https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals
{
begin: `\\b(${digitpart})[jJ](?=${lookahead})`
}
]
};
const COMMENT_TYPE = {
className: "comment",
begin: regex.lookahead(/# type:/),
end: /$/,
keywords: KEYWORDS,
contains: [
{ // prevent keywords from coloring `type`
begin: /# type:/
},
// comment within a datatype comment includes no keywords
{
begin: /#/,
end: /\b\B/,
endsWithParent: true
}
]
};
const PARAMS = {
className: 'params',
variants: [
// Exclude params in functions without params
{
className: "",
begin: /\(\s*\)/,
skip: true
},
{
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS,
contains: [
'self',
PROMPT,
NUMBER,
STRING,
hljs.HASH_COMMENT_MODE
]
}
]
};
SUBST.contains = [
STRING,
NUMBER,
PROMPT
];
return {
name: 'Python',
aliases: [
'py',
'gyp',
'ipython'
],
unicodeRegex: true,
keywords: KEYWORDS,
illegal: /(<\/|\?)|=>/,
contains: [
PROMPT,
NUMBER,
{
// very common convention
begin: /\bself\b/
},
{
// eat "if" prior to string so that it won't accidentally be
// labeled as an f-string
beginKeywords: "if",
relevance: 0
},
STRING,
COMMENT_TYPE,
hljs.HASH_COMMENT_MODE,
{
match: [
/\bdef/, /\s+/,
IDENT_RE,
],
scope: {
1: "keyword",
3: "title.function"
},
contains: [ PARAMS ]
},
{
variants: [
{
match: [
/\bclass/, /\s+/,
IDENT_RE, /\s*/,
/\(\s*/, IDENT_RE,/\s*\)/
],
},
{
match: [
/\bclass/, /\s+/,
IDENT_RE
],
}
],
scope: {
1: "keyword",
3: "title.class",
6: "title.class.inherited",
}
},
{
className: 'meta',
begin: /^[\t ]*@/,
end: /(?=#)|$/,
contains: [
NUMBER,
PARAMS,
STRING
]
}
]
};
}
var python_1 = python;
/*
Language: Python REPL
Requires: python.js
Author: Josh Goebel <hello@joshgoebel.com>
Category: common
*/
function pythonRepl(hljs) {
return {
aliases: [ 'pycon' ],
contains: [
{
className: 'meta.prompt',
starts: {
// a space separates the REPL prefix from the actual code
// this is purely for cleaner HTML output
end: / |$/,
starts: {
end: '$',
subLanguage: 'python'
}
},
variants: [
{ begin: /^>>>(?=[ ]|$)/ },
{ begin: /^\.\.\.(?=[ ]|$)/ }
]
}
]
};
}
var pythonRepl_1 = pythonRepl;
/*
Language: Q
Description: Q is a vector-based functional paradigm programming language built into the kdb+ database.
(K/Q/Kdb+ from Kx Systems)
Author: Sergey Vidyuk <svidyuk@gmail.com>
Website: https://kx.com/connect-with-us/developers/
*/
function q(hljs) {
const KEYWORDS = {
$pattern: /(`?)[A-Za-z0-9_]+\b/,
keyword:
'do while select delete by update from',
literal:
'0b 1b',
built_in:
'neg not null string reciprocal floor ceiling signum mod xbar xlog and or each scan over prior mmu lsq inv md5 ltime gtime count first var dev med cov cor all any rand sums prds mins maxs fills deltas ratios avgs differ prev next rank reverse iasc idesc asc desc msum mcount mavg mdev xrank mmin mmax xprev rotate distinct group where flip type key til get value attr cut set upsert raze union inter except cross sv vs sublist enlist read0 read1 hopen hclose hdel hsym hcount peach system ltrim rtrim trim lower upper ssr view tables views cols xcols keys xkey xcol xasc xdesc fkeys meta lj aj aj0 ij pj asof uj ww wj wj1 fby xgroup ungroup ej save load rsave rload show csv parse eval min max avg wavg wsum sin cos tan sum',
type:
'`float `double int `timestamp `timespan `datetime `time `boolean `symbol `char `byte `short `long `real `month `date `minute `second `guid'
};
return {
name: 'Q',
aliases: [
'k',
'kdb'
],
keywords: KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE
]
};
}
var q_1 = q;
/*
Language: QML
Requires: javascript.js, xml.js
Author: John Foster <jfoster@esri.com>
Description: Syntax highlighting for the Qt Quick QML scripting language, based mostly off
the JavaScript parser.
Website: https://doc.qt.io/qt-5/qmlapplications.html
Category: scripting
*/
function qml(hljs) {
const regex = hljs.regex;
const KEYWORDS = {
keyword:
'in of on if for while finally var new function do return void else break catch '
+ 'instanceof with throw case default try this switch continue typeof delete '
+ 'let yield const export super debugger as async await import',
literal:
'true false null undefined NaN Infinity',
built_in:
'eval isFinite isNaN parseFloat parseInt decodeURI decodeURIComponent '
+ 'encodeURI encodeURIComponent escape unescape Object Function Boolean Error '
+ 'EvalError InternalError RangeError ReferenceError StopIteration SyntaxError '
+ 'TypeError URIError Number Math Date String RegExp Array Float32Array '
+ 'Float64Array Int16Array Int32Array Int8Array Uint16Array Uint32Array '
+ 'Uint8Array Uint8ClampedArray ArrayBuffer DataView JSON Intl arguments require '
+ 'module console window document Symbol Set Map WeakSet WeakMap Proxy Reflect '
+ 'Behavior bool color coordinate date double enumeration font geocircle georectangle '
+ 'geoshape int list matrix4x4 parent point quaternion real rect '
+ 'size string url variant vector2d vector3d vector4d '
+ 'Promise'
};
const QML_IDENT_RE = '[a-zA-Z_][a-zA-Z0-9\\._]*';
// Isolate property statements. Ends at a :, =, ;, ,, a comment or end of line.
// Use property class.
const PROPERTY = {
className: 'keyword',
begin: '\\bproperty\\b',
starts: {
className: 'string',
end: '(:|=|;|,|//|/\\*|$)',
returnEnd: true
}
};
// Isolate signal statements. Ends at a ) a comment or end of line.
// Use property class.
const SIGNAL = {
className: 'keyword',
begin: '\\bsignal\\b',
starts: {
className: 'string',
end: '(\\(|:|=|;|,|//|/\\*|$)',
returnEnd: true
}
};
// id: is special in QML. When we see id: we want to mark the id: as attribute and
// emphasize the token following.
const ID_ID = {
className: 'attribute',
begin: '\\bid\\s*:',
starts: {
className: 'string',
end: QML_IDENT_RE,
returnEnd: false
}
};
// Find QML object attribute. An attribute is a QML identifier followed by :.
// Unfortunately it's hard to know where it ends, as it may contain scalars,
// objects, object definitions, or javascript. The true end is either when the parent
// ends or the next attribute is detected.
const QML_ATTRIBUTE = {
begin: QML_IDENT_RE + '\\s*:',
returnBegin: true,
contains: [
{
className: 'attribute',
begin: QML_IDENT_RE,
end: '\\s*:',
excludeEnd: true,
relevance: 0
}
],
relevance: 0
};
// Find QML object. A QML object is a QML identifier followed by { and ends at the matching }.
// All we really care about is finding IDENT followed by { and just mark up the IDENT and ignore the {.
const QML_OBJECT = {
begin: regex.concat(QML_IDENT_RE, /\s*\{/),
end: /\{/,
returnBegin: true,
relevance: 0,
contains: [ hljs.inherit(hljs.TITLE_MODE, { begin: QML_IDENT_RE }) ]
};
return {
name: 'QML',
aliases: [ 'qt' ],
case_insensitive: false,
keywords: KEYWORDS,
contains: [
{
className: 'meta',
begin: /^\s*['"]use (strict|asm)['"]/
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{ // template string
className: 'string',
begin: '`',
end: '`',
contains: [
hljs.BACKSLASH_ESCAPE,
{
className: 'subst',
begin: '\\$\\{',
end: '\\}'
}
]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'number',
variants: [
{ begin: '\\b(0[bB][01]+)' },
{ begin: '\\b(0[oO][0-7]+)' },
{ begin: hljs.C_NUMBER_RE }
],
relevance: 0
},
{ // "value" container
begin: '(' + hljs.RE_STARTERS_RE + '|\\b(case|return|throw)\\b)\\s*',
keywords: 'return throw case',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.REGEXP_MODE,
{ // E4X / JSX
begin: /</,
end: />\s*[);\]]/,
relevance: 0,
subLanguage: 'xml'
}
],
relevance: 0
},
SIGNAL,
PROPERTY,
{
className: 'function',
beginKeywords: 'function',
end: /\{/,
excludeEnd: true,
contains: [
hljs.inherit(hljs.TITLE_MODE, { begin: /[A-Za-z$_][0-9A-Za-z$_]*/ }),
{
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
}
],
illegal: /\[|%/
},
{
// hack: prevents detection of keywords after dots
begin: '\\.' + hljs.IDENT_RE,
relevance: 0
},
ID_ID,
QML_ATTRIBUTE,
QML_OBJECT
],
illegal: /#/
};
}
var qml_1 = qml;
/*
Language: R
Description: R is a free software environment for statistical computing and graphics.
Author: Joe Cheng <joe@rstudio.org>
Contributors: Konrad Rudolph <konrad.rudolph@gmail.com>
Website: https://www.r-project.org
Category: common,scientific
*/
/** @type LanguageFn */
function r(hljs) {
const regex = hljs.regex;
// Identifiers in R cannot start with `_`, but they can start with `.` if it
// is not immediately followed by a digit.
// R also supports quoted identifiers, which are near-arbitrary sequences
// delimited by backticks (`…`), which may contain escape sequences. These are
// handled in a separate mode. See `test/markup/r/names.txt` for examples.
// FIXME: Support Unicode identifiers.
const IDENT_RE = /(?:(?:[a-zA-Z]|\.[._a-zA-Z])[._a-zA-Z0-9]*)|\.(?!\d)/;
const NUMBER_TYPES_RE = regex.either(
// Special case: only hexadecimal binary powers can contain fractions
/0[xX][0-9a-fA-F]+\.[0-9a-fA-F]*[pP][+-]?\d+i?/,
// Hexadecimal numbers without fraction and optional binary power
/0[xX][0-9a-fA-F]+(?:[pP][+-]?\d+)?[Li]?/,
// Decimal numbers
/(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?[Li]?/
);
const OPERATORS_RE = /[=!<>:]=|\|\||&&|:::?|<-|<<-|->>|->|\|>|[-+*\/?!$&|:<=>@^~]|\*\*/;
const PUNCTUATION_RE = regex.either(
/[()]/,
/[{}]/,
/\[\[/,
/[[\]]/,
/\\/,
/,/
);
return {
name: 'R',
keywords: {
$pattern: IDENT_RE,
keyword:
'function if in break next repeat else for while',
literal:
'NULL NA TRUE FALSE Inf NaN NA_integer_|10 NA_real_|10 '
+ 'NA_character_|10 NA_complex_|10',
built_in:
// Builtin constants
'LETTERS letters month.abb month.name pi T F '
// Primitive functions
// These are all the functions in `base` that are implemented as a
// `.Primitive`, minus those functions that are also keywords.
+ 'abs acos acosh all any anyNA Arg as.call as.character '
+ 'as.complex as.double as.environment as.integer as.logical '
+ 'as.null.default as.numeric as.raw asin asinh atan atanh attr '
+ 'attributes baseenv browser c call ceiling class Conj cos cosh '
+ 'cospi cummax cummin cumprod cumsum digamma dim dimnames '
+ 'emptyenv exp expression floor forceAndCall gamma gc.time '
+ 'globalenv Im interactive invisible is.array is.atomic is.call '
+ 'is.character is.complex is.double is.environment is.expression '
+ 'is.finite is.function is.infinite is.integer is.language '
+ 'is.list is.logical is.matrix is.na is.name is.nan is.null '
+ 'is.numeric is.object is.pairlist is.raw is.recursive is.single '
+ 'is.symbol lazyLoadDBfetch length lgamma list log max min '
+ 'missing Mod names nargs nzchar oldClass on.exit pos.to.env '
+ 'proc.time prod quote range Re rep retracemem return round '
+ 'seq_along seq_len seq.int sign signif sin sinh sinpi sqrt '
+ 'standardGeneric substitute sum switch tan tanh tanpi tracemem '
+ 'trigamma trunc unclass untracemem UseMethod xtfrm',
},
contains: [
// Roxygen comments
hljs.COMMENT(
/#'/,
/$/,
{ contains: [
{
// Handle `@examples` separately to cause all subsequent code
// until the next `@`-tag on its own line to be kept as-is,
// preventing highlighting. This code is example R code, so nested
// doctags shouldnt be treated as such. See
// `test/markup/r/roxygen.txt` for an example.
scope: 'doctag',
match: /@examples/,
starts: {
end: regex.lookahead(regex.either(
// end if another doc comment
/\n^#'\s*(?=@[a-zA-Z]+)/,
// or a line with no comment
/\n^(?!#')/
)),
endsParent: true
}
},
{
// Handle `@param` to highlight the parameter name following
// after.
scope: 'doctag',
begin: '@param',
end: /$/,
contains: [
{
scope: 'variable',
variants: [
{ match: IDENT_RE },
{ match: /`(?:\\.|[^`\\])+`/ }
],
endsParent: true
}
]
},
{
scope: 'doctag',
match: /@[a-zA-Z]+/
},
{
scope: 'keyword',
match: /\\[a-zA-Z]+/
}
] }
),
hljs.HASH_COMMENT_MODE,
{
scope: 'string',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
hljs.END_SAME_AS_BEGIN({
begin: /[rR]"(-*)\(/,
end: /\)(-*)"/
}),
hljs.END_SAME_AS_BEGIN({
begin: /[rR]"(-*)\{/,
end: /\}(-*)"/
}),
hljs.END_SAME_AS_BEGIN({
begin: /[rR]"(-*)\[/,
end: /\](-*)"/
}),
hljs.END_SAME_AS_BEGIN({
begin: /[rR]'(-*)\(/,
end: /\)(-*)'/
}),
hljs.END_SAME_AS_BEGIN({
begin: /[rR]'(-*)\{/,
end: /\}(-*)'/
}),
hljs.END_SAME_AS_BEGIN({
begin: /[rR]'(-*)\[/,
end: /\](-*)'/
}),
{
begin: '"',
end: '"',
relevance: 0
},
{
begin: "'",
end: "'",
relevance: 0
}
],
},
// Matching numbers immediately following punctuation and operators is
// tricky since we need to look at the character ahead of a number to
// ensure the number is not part of an identifier, and we cannot use
// negative look-behind assertions. So instead we explicitly handle all
// possible combinations of (operator|punctuation), number.
// TODO: replace with negative look-behind when available
// { begin: /(?<![a-zA-Z0-9._])0[xX][0-9a-fA-F]+\.[0-9a-fA-F]*[pP][+-]?\d+i?/ },
// { begin: /(?<![a-zA-Z0-9._])0[xX][0-9a-fA-F]+([pP][+-]?\d+)?[Li]?/ },
// { begin: /(?<![a-zA-Z0-9._])(\d+(\.\d*)?|\.\d+)([eE][+-]?\d+)?[Li]?/ }
{
relevance: 0,
variants: [
{
scope: {
1: 'operator',
2: 'number'
},
match: [
OPERATORS_RE,
NUMBER_TYPES_RE
]
},
{
scope: {
1: 'operator',
2: 'number'
},
match: [
/%[^%]*%/,
NUMBER_TYPES_RE
]
},
{
scope: {
1: 'punctuation',
2: 'number'
},
match: [
PUNCTUATION_RE,
NUMBER_TYPES_RE
]
},
{
scope: { 2: 'number' },
match: [
/[^a-zA-Z0-9._]|^/, // not part of an identifier, or start of document
NUMBER_TYPES_RE
]
}
]
},
// Operators/punctuation when they're not directly followed by numbers
{
// Relevance boost for the most common assignment form.
scope: { 3: 'operator' },
match: [
IDENT_RE,
/\s+/,
/<-/,
/\s+/
]
},
{
scope: 'operator',
relevance: 0,
variants: [
{ match: OPERATORS_RE },
{ match: /%[^%]*%/ }
]
},
{
scope: 'punctuation',
relevance: 0,
match: PUNCTUATION_RE
},
{
// Escaped identifier
begin: '`',
end: '`',
contains: [ { begin: /\\./ } ]
}
]
};
}
var r_1 = r;
/*
Language: ReasonML
Description: Reason lets you write simple, fast and quality type safe code while leveraging both the JavaScript & OCaml ecosystems.
Website: https://reasonml.github.io
Author: Gidi Meir Morris <oss@gidi.io>
Category: functional
*/
function reasonml(hljs) {
const BUILT_IN_TYPES = [
"array",
"bool",
"bytes",
"char",
"exn|5",
"float",
"int",
"int32",
"int64",
"list",
"lazy_t|5",
"nativeint|5",
"ref",
"string",
"unit",
];
return {
name: 'ReasonML',
aliases: [ 're' ],
keywords: {
$pattern: /[a-z_]\w*!?/,
keyword: [
"and",
"as",
"asr",
"assert",
"begin",
"class",
"constraint",
"do",
"done",
"downto",
"else",
"end",
"esfun",
"exception",
"external",
"for",
"fun",
"function",
"functor",
"if",
"in",
"include",
"inherit",
"initializer",
"land",
"lazy",
"let",
"lor",
"lsl",
"lsr",
"lxor",
"mod",
"module",
"mutable",
"new",
"nonrec",
"object",
"of",
"open",
"or",
"pri",
"pub",
"rec",
"sig",
"struct",
"switch",
"then",
"to",
"try",
"type",
"val",
"virtual",
"when",
"while",
"with",
],
built_in: BUILT_IN_TYPES,
literal: ["true", "false"],
},
illegal: /(:-|:=|\$\{|\+=)/,
contains: [
{
scope: 'literal',
match: /\[(\|\|)?\]|\(\)/,
relevance: 0
},
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT(/\/\*/, /\*\//, { illegal: /^(#,\/\/)/ }),
{ /* type variable */
scope: 'symbol',
match: /\'[A-Za-z_](?!\')[\w\']*/
/* the grammar is ambiguous on how 'a'b should be interpreted but not the compiler */
},
{ /* polymorphic variant */
scope: 'type',
match: /`[A-Z][\w\']*/
},
{ /* module or constructor */
scope: 'type',
match: /\b[A-Z][\w\']*/,
relevance: 0
},
{ /* don't color identifiers, but safely catch all identifiers with ' */
match: /[a-z_]\w*\'[\w\']*/,
relevance: 0
},
{
scope: 'operator',
match: /\s+(\|\||\+[\+\.]?|\*[\*\/\.]?|\/[\.]?|\.\.\.|\|>|&&|===?)\s+/,
relevance: 0
},
hljs.inherit(hljs.APOS_STRING_MODE, {
scope: 'string',
relevance: 0
}),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
scope: 'number',
variants: [
{ match: /\b0[xX][a-fA-F0-9_]+[Lln]?/ },
{ match: /\b0[oO][0-7_]+[Lln]?/ },
{ match: /\b0[bB][01_]+[Lln]?/ },
{ match: /\b[0-9][0-9_]*([Lln]|(\.[0-9_]*)?([eE][-+]?[0-9_]+)?)/ },
],
relevance: 0
},
]
};
}
var reasonml_1 = reasonml;
/*
Language: RenderMan RIB
Author: Konstantin Evdokimenko <qewerty@gmail.com>
Contributors: Shuen-Huei Guan <drake.guan@gmail.com>
Website: https://renderman.pixar.com/resources/RenderMan_20/ribBinding.html
Category: graphics
*/
function rib(hljs) {
return {
name: 'RenderMan RIB',
keywords:
'ArchiveRecord AreaLightSource Atmosphere Attribute AttributeBegin AttributeEnd Basis '
+ 'Begin Blobby Bound Clipping ClippingPlane Color ColorSamples ConcatTransform Cone '
+ 'CoordinateSystem CoordSysTransform CropWindow Curves Cylinder DepthOfField Detail '
+ 'DetailRange Disk Displacement Display End ErrorHandler Exposure Exterior Format '
+ 'FrameAspectRatio FrameBegin FrameEnd GeneralPolygon GeometricApproximation Geometry '
+ 'Hider Hyperboloid Identity Illuminate Imager Interior LightSource '
+ 'MakeCubeFaceEnvironment MakeLatLongEnvironment MakeShadow MakeTexture Matte '
+ 'MotionBegin MotionEnd NuPatch ObjectBegin ObjectEnd ObjectInstance Opacity Option '
+ 'Orientation Paraboloid Patch PatchMesh Perspective PixelFilter PixelSamples '
+ 'PixelVariance Points PointsGeneralPolygons PointsPolygons Polygon Procedural Projection '
+ 'Quantize ReadArchive RelativeDetail ReverseOrientation Rotate Scale ScreenWindow '
+ 'ShadingInterpolation ShadingRate Shutter Sides Skew SolidBegin SolidEnd Sphere '
+ 'SubdivisionMesh Surface TextureCoordinates Torus Transform TransformBegin TransformEnd '
+ 'TransformPoints Translate TrimCurve WorldBegin WorldEnd',
illegal: '</',
contains: [
hljs.HASH_COMMENT_MODE,
hljs.C_NUMBER_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
};
}
var rib_1 = rib;
/*
Language: Roboconf
Author: Vincent Zurczak <vzurczak@linagora.com>
Description: Syntax highlighting for Roboconf's DSL
Website: http://roboconf.net
Category: config
*/
function roboconf(hljs) {
const IDENTIFIER = '[a-zA-Z-_][^\\n{]+\\{';
const PROPERTY = {
className: 'attribute',
begin: /[a-zA-Z-_]+/,
end: /\s*:/,
excludeEnd: true,
starts: {
end: ';',
relevance: 0,
contains: [
{
className: 'variable',
begin: /\.[a-zA-Z-_]+/
},
{
className: 'keyword',
begin: /\(optional\)/
}
]
}
};
return {
name: 'Roboconf',
aliases: [
'graph',
'instances'
],
case_insensitive: true,
keywords: 'import',
contains: [
// Facet sections
{
begin: '^facet ' + IDENTIFIER,
end: /\}/,
keywords: 'facet',
contains: [
PROPERTY,
hljs.HASH_COMMENT_MODE
]
},
// Instance sections
{
begin: '^\\s*instance of ' + IDENTIFIER,
end: /\}/,
keywords: 'name count channels instance-data instance-state instance of',
illegal: /\S/,
contains: [
'self',
PROPERTY,
hljs.HASH_COMMENT_MODE
]
},
// Component sections
{
begin: '^' + IDENTIFIER,
end: /\}/,
contains: [
PROPERTY,
hljs.HASH_COMMENT_MODE
]
},
// Comments
hljs.HASH_COMMENT_MODE
]
};
}
var roboconf_1 = roboconf;
/*
Language: MikroTik RouterOS script
Author: Ivan Dementev <ivan_div@mail.ru>
Description: Scripting host provides a way to automate some router maintenance tasks by means of executing user-defined scripts bounded to some event occurrence
Website: https://wiki.mikrotik.com/wiki/Manual:Scripting
*/
// Colors from RouterOS terminal:
// green - #0E9A00
// teal - #0C9A9A
// purple - #99069A
// light-brown - #9A9900
function routeros(hljs) {
const STATEMENTS = 'foreach do while for if from to step else on-error and or not in';
// Global commands: Every global command should start with ":" token, otherwise it will be treated as variable.
const GLOBAL_COMMANDS = 'global local beep delay put len typeof pick log time set find environment terminal error execute parse resolve toarray tobool toid toip toip6 tonum tostr totime';
// Common commands: Following commands available from most sub-menus:
const COMMON_COMMANDS = 'add remove enable disable set get print export edit find run debug error info warning';
const LITERALS = 'true false yes no nothing nil null';
const OBJECTS = 'traffic-flow traffic-generator firewall scheduler aaa accounting address-list address align area bandwidth-server bfd bgp bridge client clock community config connection console customer default dhcp-client dhcp-server discovery dns e-mail ethernet filter firmware gps graphing group hardware health hotspot identity igmp-proxy incoming instance interface ip ipsec ipv6 irq l2tp-server lcd ldp logging mac-server mac-winbox mangle manual mirror mme mpls nat nd neighbor network note ntp ospf ospf-v3 ovpn-server page peer pim ping policy pool port ppp pppoe-client pptp-server prefix profile proposal proxy queue radius resource rip ripng route routing screen script security-profiles server service service-port settings shares smb sms sniffer snmp snooper socks sstp-server system tool tracking type upgrade upnp user-manager users user vlan secret vrrp watchdog web-access wireless pptp pppoe lan wan layer7-protocol lease simple raw';
const VAR = {
className: 'variable',
variants: [
{ begin: /\$[\w\d#@][\w\d_]*/ },
{ begin: /\$\{(.*?)\}/ }
]
};
const QUOTE_STRING = {
className: 'string',
begin: /"/,
end: /"/,
contains: [
hljs.BACKSLASH_ESCAPE,
VAR,
{
className: 'variable',
begin: /\$\(/,
end: /\)/,
contains: [ hljs.BACKSLASH_ESCAPE ]
}
]
};
const APOS_STRING = {
className: 'string',
begin: /'/,
end: /'/
};
return {
name: 'MikroTik RouterOS script',
aliases: [ 'mikrotik' ],
case_insensitive: true,
keywords: {
$pattern: /:?[\w-]+/,
literal: LITERALS,
keyword: STATEMENTS + ' :' + STATEMENTS.split(' ').join(' :') + ' :' + GLOBAL_COMMANDS.split(' ').join(' :')
},
contains: [
{ // illegal syntax
variants: [
{ // -- comment
begin: /\/\*/,
end: /\*\//
},
{ // Stan comment
begin: /\/\//,
end: /$/
},
{ // HTML tags
begin: /<\//,
end: />/
}
],
illegal: /./
},
hljs.COMMENT('^#', '$'),
QUOTE_STRING,
APOS_STRING,
VAR,
// attribute=value
{
// > is to avoid matches with => in other grammars
begin: /[\w-]+=([^\s{}[\]()>]+)/,
relevance: 0,
returnBegin: true,
contains: [
{
className: 'attribute',
begin: /[^=]+/
},
{
begin: /=/,
endsWithParent: true,
relevance: 0,
contains: [
QUOTE_STRING,
APOS_STRING,
VAR,
{
className: 'literal',
begin: '\\b(' + LITERALS.split(' ').join('|') + ')\\b'
},
{
// Do not format unclassified values. Needed to exclude highlighting of values as built_in.
begin: /("[^"]*"|[^\s{}[\]]+)/ }
/*
{
// IPv4 addresses and subnets
className: 'number',
variants: [
{begin: IPADDR_wBITMASK+'(,'+IPADDR_wBITMASK+')*'}, //192.168.0.0/24,1.2.3.0/24
{begin: IPADDR+'-'+IPADDR}, // 192.168.0.1-192.168.0.3
{begin: IPADDR+'(,'+IPADDR+')*'}, // 192.168.0.1,192.168.0.34,192.168.24.1,192.168.0.1
]
},
{
// MAC addresses and DHCP Client IDs
className: 'number',
begin: /\b(1:)?([0-9A-Fa-f]{1,2}[:-]){5}([0-9A-Fa-f]){1,2}\b/,
},
*/
]
}
]
},
{
// HEX values
className: 'number',
begin: /\*[0-9a-fA-F]+/
},
{
begin: '\\b(' + COMMON_COMMANDS.split(' ').join('|') + ')([\\s[(\\]|])',
returnBegin: true,
contains: [
{
className: 'built_in', // 'function',
begin: /\w+/
}
]
},
{
className: 'built_in',
variants: [
{ begin: '(\\.\\./|/|\\s)((' + OBJECTS.split(' ').join('|') + ');?\\s)+' },
{
begin: /\.\./,
relevance: 0
}
]
}
]
};
}
var routeros_1 = routeros;
/*
Language: RenderMan RSL
Author: Konstantin Evdokimenko <qewerty@gmail.com>
Contributors: Shuen-Huei Guan <drake.guan@gmail.com>
Website: https://renderman.pixar.com/resources/RenderMan_20/shadingLanguage.html
Category: graphics
*/
function rsl(hljs) {
const BUILT_INS = [
"abs",
"acos",
"ambient",
"area",
"asin",
"atan",
"atmosphere",
"attribute",
"calculatenormal",
"ceil",
"cellnoise",
"clamp",
"comp",
"concat",
"cos",
"degrees",
"depth",
"Deriv",
"diffuse",
"distance",
"Du",
"Dv",
"environment",
"exp",
"faceforward",
"filterstep",
"floor",
"format",
"fresnel",
"incident",
"length",
"lightsource",
"log",
"match",
"max",
"min",
"mod",
"noise",
"normalize",
"ntransform",
"opposite",
"option",
"phong",
"pnoise",
"pow",
"printf",
"ptlined",
"radians",
"random",
"reflect",
"refract",
"renderinfo",
"round",
"setcomp",
"setxcomp",
"setycomp",
"setzcomp",
"shadow",
"sign",
"sin",
"smoothstep",
"specular",
"specularbrdf",
"spline",
"sqrt",
"step",
"tan",
"texture",
"textureinfo",
"trace",
"transform",
"vtransform",
"xcomp",
"ycomp",
"zcomp"
];
const TYPES = [
"matrix",
"float",
"color",
"point",
"normal",
"vector"
];
const KEYWORDS = [
"while",
"for",
"if",
"do",
"return",
"else",
"break",
"extern",
"continue"
];
const CLASS_DEFINITION = {
match: [
/(surface|displacement|light|volume|imager)/,
/\s+/,
hljs.IDENT_RE,
],
scope: {
1: "keyword",
3: "title.class",
}
};
return {
name: 'RenderMan RSL',
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS,
type: TYPES
},
illegal: '</',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '#',
end: '$'
},
CLASS_DEFINITION,
{
beginKeywords: 'illuminate illuminance gather',
end: '\\('
}
]
};
}
var rsl_1 = rsl;
/*
Language: Oracle Rules Language
Author: Jason Jacobson <jason.a.jacobson@gmail.com>
Description: The Oracle Utilities Rules Language is used to program the Oracle Utilities Applications acquired from LODESTAR Corporation. The products include Billing Component, LPSS, Pricing Component etc. through version 1.6.1.
Website: https://docs.oracle.com/cd/E17904_01/dev.1111/e10227/rlref.htm
Category: enterprise
*/
function ruleslanguage(hljs) {
return {
name: 'Oracle Rules Language',
keywords: {
keyword:
'BILL_PERIOD BILL_START BILL_STOP RS_EFFECTIVE_START RS_EFFECTIVE_STOP RS_JURIS_CODE RS_OPCO_CODE '
+ 'INTDADDATTRIBUTE|5 INTDADDVMSG|5 INTDBLOCKOP|5 INTDBLOCKOPNA|5 INTDCLOSE|5 INTDCOUNT|5 '
+ 'INTDCOUNTSTATUSCODE|5 INTDCREATEMASK|5 INTDCREATEDAYMASK|5 INTDCREATEFACTORMASK|5 '
+ 'INTDCREATEHANDLE|5 INTDCREATEOVERRIDEDAYMASK|5 INTDCREATEOVERRIDEMASK|5 '
+ 'INTDCREATESTATUSCODEMASK|5 INTDCREATETOUPERIOD|5 INTDDELETE|5 INTDDIPTEST|5 INTDEXPORT|5 '
+ 'INTDGETERRORCODE|5 INTDGETERRORMESSAGE|5 INTDISEQUAL|5 INTDJOIN|5 INTDLOAD|5 INTDLOADACTUALCUT|5 '
+ 'INTDLOADDATES|5 INTDLOADHIST|5 INTDLOADLIST|5 INTDLOADLISTDATES|5 INTDLOADLISTENERGY|5 '
+ 'INTDLOADLISTHIST|5 INTDLOADRELATEDCHANNEL|5 INTDLOADSP|5 INTDLOADSTAGING|5 INTDLOADUOM|5 '
+ 'INTDLOADUOMDATES|5 INTDLOADUOMHIST|5 INTDLOADVERSION|5 INTDOPEN|5 INTDREADFIRST|5 INTDREADNEXT|5 '
+ 'INTDRECCOUNT|5 INTDRELEASE|5 INTDREPLACE|5 INTDROLLAVG|5 INTDROLLPEAK|5 INTDSCALAROP|5 INTDSCALE|5 '
+ 'INTDSETATTRIBUTE|5 INTDSETDSTPARTICIPANT|5 INTDSETSTRING|5 INTDSETVALUE|5 INTDSETVALUESTATUS|5 '
+ 'INTDSHIFTSTARTTIME|5 INTDSMOOTH|5 INTDSORT|5 INTDSPIKETEST|5 INTDSUBSET|5 INTDTOU|5 '
+ 'INTDTOURELEASE|5 INTDTOUVALUE|5 INTDUPDATESTATS|5 INTDVALUE|5 STDEV INTDDELETEEX|5 '
+ 'INTDLOADEXACTUAL|5 INTDLOADEXCUT|5 INTDLOADEXDATES|5 INTDLOADEX|5 INTDLOADEXRELATEDCHANNEL|5 '
+ 'INTDSAVEEX|5 MVLOAD|5 MVLOADACCT|5 MVLOADACCTDATES|5 MVLOADACCTHIST|5 MVLOADDATES|5 MVLOADHIST|5 '
+ 'MVLOADLIST|5 MVLOADLISTDATES|5 MVLOADLISTHIST|5 IF FOR NEXT DONE SELECT END CALL ABORT CLEAR CHANNEL FACTOR LIST NUMBER '
+ 'OVERRIDE SET WEEK DISTRIBUTIONNODE ELSE WHEN THEN OTHERWISE IENUM CSV INCLUDE LEAVE RIDER SAVE DELETE '
+ 'NOVALUE SECTION WARN SAVE_UPDATE DETERMINANT LABEL REPORT REVENUE EACH '
+ 'IN FROM TOTAL CHARGE BLOCK AND OR CSV_FILE RATE_CODE AUXILIARY_DEMAND '
+ 'UIDACCOUNT RS BILL_PERIOD_SELECT HOURS_PER_MONTH INTD_ERROR_STOP SEASON_SCHEDULE_NAME '
+ 'ACCOUNTFACTOR ARRAYUPPERBOUND CALLSTOREDPROC GETADOCONNECTION GETCONNECT GETDATASOURCE '
+ 'GETQUALIFIER GETUSERID HASVALUE LISTCOUNT LISTOP LISTUPDATE LISTVALUE PRORATEFACTOR RSPRORATE '
+ 'SETBINPATH SETDBMONITOR WQ_OPEN BILLINGHOURS DATE DATEFROMFLOAT DATETIMEFROMSTRING '
+ 'DATETIMETOSTRING DATETOFLOAT DAY DAYDIFF DAYNAME DBDATETIME HOUR MINUTE MONTH MONTHDIFF '
+ 'MONTHHOURS MONTHNAME ROUNDDATE SAMEWEEKDAYLASTYEAR SECOND WEEKDAY WEEKDIFF YEAR YEARDAY '
+ 'YEARSTR COMPSUM HISTCOUNT HISTMAX HISTMIN HISTMINNZ HISTVALUE MAXNRANGE MAXRANGE MINRANGE '
+ 'COMPIKVA COMPKVA COMPKVARFROMKQKW COMPLF IDATTR FLAG LF2KW LF2KWH MAXKW POWERFACTOR '
+ 'READING2USAGE AVGSEASON MAXSEASON MONTHLYMERGE SEASONVALUE SUMSEASON ACCTREADDATES '
+ 'ACCTTABLELOAD CONFIGADD CONFIGGET CREATEOBJECT CREATEREPORT EMAILCLIENT EXPBLKMDMUSAGE '
+ 'EXPMDMUSAGE EXPORT_USAGE FACTORINEFFECT GETUSERSPECIFIEDSTOP INEFFECT ISHOLIDAY RUNRATE '
+ 'SAVE_PROFILE SETREPORTTITLE USEREXIT WATFORRUNRATE TO TABLE ACOS ASIN ATAN ATAN2 BITAND CEIL '
+ 'COS COSECANT COSH COTANGENT DIVQUOT DIVREM EXP FABS FLOOR FMOD FREPM FREXPN LOG LOG10 MAX MAXN '
+ 'MIN MINNZ MODF POW ROUND ROUND2VALUE ROUNDINT SECANT SIN SINH SQROOT TAN TANH FLOAT2STRING '
+ 'FLOAT2STRINGNC INSTR LEFT LEN LTRIM MID RIGHT RTRIM STRING STRINGNC TOLOWER TOUPPER TRIM '
+ 'NUMDAYS READ_DATE STAGING',
built_in:
'IDENTIFIER OPTIONS XML_ELEMENT XML_OP XML_ELEMENT_OF DOMDOCCREATE DOMDOCLOADFILE DOMDOCLOADXML '
+ 'DOMDOCSAVEFILE DOMDOCGETROOT DOMDOCADDPI DOMNODEGETNAME DOMNODEGETTYPE DOMNODEGETVALUE DOMNODEGETCHILDCT '
+ 'DOMNODEGETFIRSTCHILD DOMNODEGETSIBLING DOMNODECREATECHILDELEMENT DOMNODESETATTRIBUTE '
+ 'DOMNODEGETCHILDELEMENTCT DOMNODEGETFIRSTCHILDELEMENT DOMNODEGETSIBLINGELEMENT DOMNODEGETATTRIBUTECT '
+ 'DOMNODEGETATTRIBUTEI DOMNODEGETATTRIBUTEBYNAME DOMNODEGETBYNAME'
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'literal',
variants: [
{ // looks like #-comment
begin: '#\\s+',
relevance: 0
},
{ begin: '#[a-zA-Z .]+' }
]
}
]
};
}
var ruleslanguage_1 = ruleslanguage;
/*
Language: Rust
Author: Andrey Vlasovskikh <andrey.vlasovskikh@gmail.com>
Contributors: Roman Shmatov <romanshmatov@gmail.com>, Kasper Andersen <kma_untrusted@protonmail.com>
Website: https://www.rust-lang.org
Category: common, system
*/
/** @type LanguageFn */
function rust(hljs) {
const regex = hljs.regex;
const FUNCTION_INVOKE = {
className: "title.function.invoke",
relevance: 0,
begin: regex.concat(
/\b/,
/(?!let|for|while|if|else|match\b)/,
hljs.IDENT_RE,
regex.lookahead(/\s*\(/))
};
const NUMBER_SUFFIX = '([ui](8|16|32|64|128|size)|f(32|64))\?';
const KEYWORDS = [
"abstract",
"as",
"async",
"await",
"become",
"box",
"break",
"const",
"continue",
"crate",
"do",
"dyn",
"else",
"enum",
"extern",
"false",
"final",
"fn",
"for",
"if",
"impl",
"in",
"let",
"loop",
"macro",
"match",
"mod",
"move",
"mut",
"override",
"priv",
"pub",
"ref",
"return",
"self",
"Self",
"static",
"struct",
"super",
"trait",
"true",
"try",
"type",
"typeof",
"unsafe",
"unsized",
"use",
"virtual",
"where",
"while",
"yield"
];
const LITERALS = [
"true",
"false",
"Some",
"None",
"Ok",
"Err"
];
const BUILTINS = [
// functions
'drop ',
// traits
"Copy",
"Send",
"Sized",
"Sync",
"Drop",
"Fn",
"FnMut",
"FnOnce",
"ToOwned",
"Clone",
"Debug",
"PartialEq",
"PartialOrd",
"Eq",
"Ord",
"AsRef",
"AsMut",
"Into",
"From",
"Default",
"Iterator",
"Extend",
"IntoIterator",
"DoubleEndedIterator",
"ExactSizeIterator",
"SliceConcatExt",
"ToString",
// macros
"assert!",
"assert_eq!",
"bitflags!",
"bytes!",
"cfg!",
"col!",
"concat!",
"concat_idents!",
"debug_assert!",
"debug_assert_eq!",
"env!",
"eprintln!",
"panic!",
"file!",
"format!",
"format_args!",
"include_bytes!",
"include_str!",
"line!",
"local_data_key!",
"module_path!",
"option_env!",
"print!",
"println!",
"select!",
"stringify!",
"try!",
"unimplemented!",
"unreachable!",
"vec!",
"write!",
"writeln!",
"macro_rules!",
"assert_ne!",
"debug_assert_ne!"
];
const TYPES = [
"i8",
"i16",
"i32",
"i64",
"i128",
"isize",
"u8",
"u16",
"u32",
"u64",
"u128",
"usize",
"f32",
"f64",
"str",
"char",
"bool",
"Box",
"Option",
"Result",
"String",
"Vec"
];
return {
name: 'Rust',
aliases: [ 'rs' ],
keywords: {
$pattern: hljs.IDENT_RE + '!?',
type: TYPES,
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILTINS
},
illegal: '</',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT('/\\*', '\\*/', { contains: [ 'self' ] }),
hljs.inherit(hljs.QUOTE_STRING_MODE, {
begin: /b?"/,
illegal: null
}),
{
className: 'string',
variants: [
{ begin: /b?r(#*)"(.|\n)*?"\1(?!#)/ },
{ begin: /b?'\\?(x\w{2}|u\w{4}|U\w{8}|.)'/ }
]
},
{
className: 'symbol',
begin: /'[a-zA-Z_][a-zA-Z0-9_]*/
},
{
className: 'number',
variants: [
{ begin: '\\b0b([01_]+)' + NUMBER_SUFFIX },
{ begin: '\\b0o([0-7_]+)' + NUMBER_SUFFIX },
{ begin: '\\b0x([A-Fa-f0-9_]+)' + NUMBER_SUFFIX },
{ begin: '\\b(\\d[\\d_]*(\\.[0-9_]+)?([eE][+-]?[0-9_]+)?)'
+ NUMBER_SUFFIX }
],
relevance: 0
},
{
begin: [
/fn/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE
],
className: {
1: "keyword",
3: "title.function"
}
},
{
className: 'meta',
begin: '#!?\\[',
end: '\\]',
contains: [
{
className: 'string',
begin: /"/,
end: /"/
}
]
},
{
begin: [
/let/,
/\s+/,
/(?:mut\s+)?/,
hljs.UNDERSCORE_IDENT_RE
],
className: {
1: "keyword",
3: "keyword",
4: "variable"
}
},
// must come before impl/for rule later
{
begin: [
/for/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE,
/\s+/,
/in/
],
className: {
1: "keyword",
3: "variable",
5: "keyword"
}
},
{
begin: [
/type/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE
],
className: {
1: "keyword",
3: "title.class"
}
},
{
begin: [
/(?:trait|enum|struct|union|impl|for)/,
/\s+/,
hljs.UNDERSCORE_IDENT_RE
],
className: {
1: "keyword",
3: "title.class"
}
},
{
begin: hljs.IDENT_RE + '::',
keywords: {
keyword: "Self",
built_in: BUILTINS,
type: TYPES
}
},
{
className: "punctuation",
begin: '->'
},
FUNCTION_INVOKE
]
};
}
var rust_1 = rust;
/*
Language: SAS
Author: Mauricio Caceres <mauricio.caceres.bravo@gmail.com>
Description: Syntax Highlighting for SAS
*/
/** @type LanguageFn */
function sas(hljs) {
const regex = hljs.regex;
// Data step and PROC SQL statements
const SAS_KEYWORDS = [
"do",
"if",
"then",
"else",
"end",
"until",
"while",
"abort",
"array",
"attrib",
"by",
"call",
"cards",
"cards4",
"catname",
"continue",
"datalines",
"datalines4",
"delete",
"delim",
"delimiter",
"display",
"dm",
"drop",
"endsas",
"error",
"file",
"filename",
"footnote",
"format",
"goto",
"in",
"infile",
"informat",
"input",
"keep",
"label",
"leave",
"length",
"libname",
"link",
"list",
"lostcard",
"merge",
"missing",
"modify",
"options",
"output",
"out",
"page",
"put",
"redirect",
"remove",
"rename",
"replace",
"retain",
"return",
"select",
"set",
"skip",
"startsas",
"stop",
"title",
"update",
"waitsas",
"where",
"window",
"x|0",
"systask",
"add",
"and",
"alter",
"as",
"cascade",
"check",
"create",
"delete",
"describe",
"distinct",
"drop",
"foreign",
"from",
"group",
"having",
"index",
"insert",
"into",
"in",
"key",
"like",
"message",
"modify",
"msgtype",
"not",
"null",
"on",
"or",
"order",
"primary",
"references",
"reset",
"restrict",
"select",
"set",
"table",
"unique",
"update",
"validate",
"view",
"where"
];
// Built-in SAS functions
const FUNCTIONS = [
"abs",
"addr",
"airy",
"arcos",
"arsin",
"atan",
"attrc",
"attrn",
"band",
"betainv",
"blshift",
"bnot",
"bor",
"brshift",
"bxor",
"byte",
"cdf",
"ceil",
"cexist",
"cinv",
"close",
"cnonct",
"collate",
"compbl",
"compound",
"compress",
"cos",
"cosh",
"css",
"curobs",
"cv",
"daccdb",
"daccdbsl",
"daccsl",
"daccsyd",
"dacctab",
"dairy",
"date",
"datejul",
"datepart",
"datetime",
"day",
"dclose",
"depdb",
"depdbsl",
"depdbsl",
"depsl",
"depsl",
"depsyd",
"depsyd",
"deptab",
"deptab",
"dequote",
"dhms",
"dif",
"digamma",
"dim",
"dinfo",
"dnum",
"dopen",
"doptname",
"doptnum",
"dread",
"dropnote",
"dsname",
"erf",
"erfc",
"exist",
"exp",
"fappend",
"fclose",
"fcol",
"fdelete",
"fetch",
"fetchobs",
"fexist",
"fget",
"fileexist",
"filename",
"fileref",
"finfo",
"finv",
"fipname",
"fipnamel",
"fipstate",
"floor",
"fnonct",
"fnote",
"fopen",
"foptname",
"foptnum",
"fpoint",
"fpos",
"fput",
"fread",
"frewind",
"frlen",
"fsep",
"fuzz",
"fwrite",
"gaminv",
"gamma",
"getoption",
"getvarc",
"getvarn",
"hbound",
"hms",
"hosthelp",
"hour",
"ibessel",
"index",
"indexc",
"indexw",
"input",
"inputc",
"inputn",
"int",
"intck",
"intnx",
"intrr",
"irr",
"jbessel",
"juldate",
"kurtosis",
"lag",
"lbound",
"left",
"length",
"lgamma",
"libname",
"libref",
"log",
"log10",
"log2",
"logpdf",
"logpmf",
"logsdf",
"lowcase",
"max",
"mdy",
"mean",
"min",
"minute",
"mod",
"month",
"mopen",
"mort",
"n",
"netpv",
"nmiss",
"normal",
"note",
"npv",
"open",
"ordinal",
"pathname",
"pdf",
"peek",
"peekc",
"pmf",
"point",
"poisson",
"poke",
"probbeta",
"probbnml",
"probchi",
"probf",
"probgam",
"probhypr",
"probit",
"probnegb",
"probnorm",
"probt",
"put",
"putc",
"putn",
"qtr",
"quote",
"ranbin",
"rancau",
"ranexp",
"rangam",
"range",
"rank",
"rannor",
"ranpoi",
"rantbl",
"rantri",
"ranuni",
"repeat",
"resolve",
"reverse",
"rewind",
"right",
"round",
"saving",
"scan",
"sdf",
"second",
"sign",
"sin",
"sinh",
"skewness",
"soundex",
"spedis",
"sqrt",
"std",
"stderr",
"stfips",
"stname",
"stnamel",
"substr",
"sum",
"symget",
"sysget",
"sysmsg",
"sysprod",
"sysrc",
"system",
"tan",
"tanh",
"time",
"timepart",
"tinv",
"tnonct",
"today",
"translate",
"tranwrd",
"trigamma",
"trim",
"trimn",
"trunc",
"uniform",
"upcase",
"uss",
"var",
"varfmt",
"varinfmt",
"varlabel",
"varlen",
"varname",
"varnum",
"varray",
"varrayx",
"vartype",
"verify",
"vformat",
"vformatd",
"vformatdx",
"vformatn",
"vformatnx",
"vformatw",
"vformatwx",
"vformatx",
"vinarray",
"vinarrayx",
"vinformat",
"vinformatd",
"vinformatdx",
"vinformatn",
"vinformatnx",
"vinformatw",
"vinformatwx",
"vinformatx",
"vlabel",
"vlabelx",
"vlength",
"vlengthx",
"vname",
"vnamex",
"vtype",
"vtypex",
"weekday",
"year",
"yyq",
"zipfips",
"zipname",
"zipnamel",
"zipstate"
];
// Built-in macro functions
const MACRO_FUNCTIONS = [
"bquote",
"nrbquote",
"cmpres",
"qcmpres",
"compstor",
"datatyp",
"display",
"do",
"else",
"end",
"eval",
"global",
"goto",
"if",
"index",
"input",
"keydef",
"label",
"left",
"length",
"let",
"local",
"lowcase",
"macro",
"mend",
"nrbquote",
"nrquote",
"nrstr",
"put",
"qcmpres",
"qleft",
"qlowcase",
"qscan",
"qsubstr",
"qsysfunc",
"qtrim",
"quote",
"qupcase",
"scan",
"str",
"substr",
"superq",
"syscall",
"sysevalf",
"sysexec",
"sysfunc",
"sysget",
"syslput",
"sysprod",
"sysrc",
"sysrput",
"then",
"to",
"trim",
"unquote",
"until",
"upcase",
"verify",
"while",
"window"
];
const LITERALS = [
"null",
"missing",
"_all_",
"_automatic_",
"_character_",
"_infile_",
"_n_",
"_name_",
"_null_",
"_numeric_",
"_user_",
"_webout_"
];
return {
name: 'SAS',
case_insensitive: true,
keywords: {
literal: LITERALS,
keyword: SAS_KEYWORDS
},
contains: [
{
// Distinct highlight for proc <proc>, data, run, quit
className: 'keyword',
begin: /^\s*(proc [\w\d_]+|data|run|quit)[\s;]/
},
{
// Macro variables
className: 'variable',
begin: /&[a-zA-Z_&][a-zA-Z0-9_]*\.?/
},
{
begin: [
/^\s*/,
/datalines;|cards;/,
/(?:.*\n)+/,
/^\s*;\s*$/
],
className: {
2: "keyword",
3: "string"
}
},
{
begin: [
/%mend|%macro/,
/\s+/,
/[a-zA-Z_&][a-zA-Z0-9_]*/
],
className: {
1: "built_in",
3: "title.function"
}
},
{ // Built-in macro variables
className: 'built_in',
begin: '%' + regex.either(...MACRO_FUNCTIONS)
},
{
// User-defined macro functions
className: 'title.function',
begin: /%[a-zA-Z_][a-zA-Z_0-9]*/
},
{
// TODO: this is most likely an incorrect classification
// built_in may need more nuance
// https://github.com/highlightjs/highlight.js/issues/2521
className: 'meta',
begin: regex.either(...FUNCTIONS) + '(?=\\()'
},
{
className: 'string',
variants: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
},
hljs.COMMENT('\\*', ';'),
hljs.C_BLOCK_COMMENT_MODE
]
};
}
var sas_1 = sas;
/*
Language: Scala
Category: functional
Author: Jan Berkel <jan.berkel@gmail.com>
Contributors: Erik Osheim <d_m@plastic-idolatry.com>
Website: https://www.scala-lang.org
*/
function scala(hljs) {
const regex = hljs.regex;
const ANNOTATION = {
className: 'meta',
begin: '@[A-Za-z]+'
};
// used in strings for escaping/interpolation/substitution
const SUBST = {
className: 'subst',
variants: [
{ begin: '\\$[A-Za-z0-9_]+' },
{
begin: /\$\{/,
end: /\}/
}
]
};
const STRING = {
className: 'string',
variants: [
{
begin: '"""',
end: '"""'
},
{
begin: '"',
end: '"',
illegal: '\\n',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
begin: '[a-z]+"',
end: '"',
illegal: '\\n',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
},
{
className: 'string',
begin: '[a-z]+"""',
end: '"""',
contains: [ SUBST ],
relevance: 10
}
]
};
const TYPE = {
className: 'type',
begin: '\\b[A-Z][A-Za-z0-9_]*',
relevance: 0
};
const NAME = {
className: 'title',
begin: /[^0-9\n\t "'(),.`{}\[\]:;][^\n\t "'(),.`{}\[\]:;]+|[^0-9\n\t "'(),.`{}\[\]:;=]/,
relevance: 0
};
const CLASS = {
className: 'class',
beginKeywords: 'class object trait type',
end: /[:={\[\n;]/,
excludeEnd: true,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
beginKeywords: 'extends with',
relevance: 10
},
{
begin: /\[/,
end: /\]/,
excludeBegin: true,
excludeEnd: true,
relevance: 0,
contains: [
TYPE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
]
},
{
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
relevance: 0,
contains: [
TYPE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
]
},
NAME
]
};
const METHOD = {
className: 'function',
beginKeywords: 'def',
end: regex.lookahead(/[:={\[(\n;]/),
contains: [ NAME ]
};
const EXTENSION = {
begin: [
/^\s*/, // Is first token on the line
'extension',
/\s+(?=[[(])/, // followed by at least one space and `[` or `(`
],
beginScope: { 2: "keyword", }
};
const END = {
begin: [
/^\s*/, // Is first token on the line
/end/,
/\s+/,
/(extension\b)?/, // `extension` is the only marker that follows an `end` that cannot be captured by another rule.
],
beginScope: {
2: "keyword",
4: "keyword",
}
};
// TODO: use negative look-behind in future
// /(?<!\.)\binline(?=\s)/
const INLINE_MODES = [
{ match: /\.inline\b/ },
{
begin: /\binline(?=\s)/,
keywords: 'inline'
}
];
const USING_PARAM_CLAUSE = {
begin: [
/\(\s*/, // Opening `(` of a parameter or argument list
/using/,
/\s+(?!\))/, // Spaces not followed by `)`
],
beginScope: { 2: "keyword", }
};
// glob all non-whitespace characters as a "string"
// sourced from https://github.com/scala/docs.scala-lang/pull/2845
const DIRECTIVE_VALUE = {
className: 'string',
begin: /\S+/,
};
// directives
// sourced from https://github.com/scala/docs.scala-lang/pull/2845
const USING_DIRECTIVE = {
begin: [
'//>',
/\s+/,
/using/,
/\s+/,
/\S+/
],
beginScope: {
1: "comment",
3: "keyword",
5: "type"
},
end: /$/,
contains: [
DIRECTIVE_VALUE,
]
};
return {
name: 'Scala',
keywords: {
literal: 'true false null',
keyword: 'type yield lazy override def with val var sealed abstract private trait object if then forSome for while do throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit export enum given transparent'
},
contains: [
USING_DIRECTIVE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
STRING,
TYPE,
METHOD,
CLASS,
hljs.C_NUMBER_MODE,
EXTENSION,
END,
...INLINE_MODES,
USING_PARAM_CLAUSE,
ANNOTATION
]
};
}
var scala_1 = scala;
/*
Language: Scheme
Description: Scheme is a programming language in the Lisp family.
(keywords based on http://community.schemewiki.org/?scheme-keywords)
Author: JP Verkamp <me@jverkamp.com>
Contributors: Ivan Sagalaev <maniac@softwaremaniacs.org>
Origin: clojure.js
Website: http://community.schemewiki.org/?what-is-scheme
Category: lisp
*/
function scheme(hljs) {
const SCHEME_IDENT_RE = '[^\\(\\)\\[\\]\\{\\}",\'`;#|\\\\\\s]+';
const SCHEME_SIMPLE_NUMBER_RE = '(-|\\+)?\\d+([./]\\d+)?';
const SCHEME_COMPLEX_NUMBER_RE = SCHEME_SIMPLE_NUMBER_RE + '[+\\-]' + SCHEME_SIMPLE_NUMBER_RE + 'i';
const KEYWORDS = {
$pattern: SCHEME_IDENT_RE,
built_in:
'case-lambda call/cc class define-class exit-handler field import '
+ 'inherit init-field interface let*-values let-values let/ec mixin '
+ 'opt-lambda override protect provide public rename require '
+ 'require-for-syntax syntax syntax-case syntax-error unit/sig unless '
+ 'when with-syntax and begin call-with-current-continuation '
+ 'call-with-input-file call-with-output-file case cond define '
+ 'define-syntax delay do dynamic-wind else for-each if lambda let let* '
+ 'let-syntax letrec letrec-syntax map or syntax-rules \' * + , ,@ - ... / '
+ '; < <= = => > >= ` abs acos angle append apply asin assoc assq assv atan '
+ 'boolean? caar cadr call-with-input-file call-with-output-file '
+ 'call-with-values car cdddar cddddr cdr ceiling char->integer '
+ 'char-alphabetic? char-ci<=? char-ci<? char-ci=? char-ci>=? char-ci>? '
+ 'char-downcase char-lower-case? char-numeric? char-ready? char-upcase '
+ 'char-upper-case? char-whitespace? char<=? char<? char=? char>=? char>? '
+ 'char? close-input-port close-output-port complex? cons cos '
+ 'current-input-port current-output-port denominator display eof-object? '
+ 'eq? equal? eqv? eval even? exact->inexact exact? exp expt floor '
+ 'force gcd imag-part inexact->exact inexact? input-port? integer->char '
+ 'integer? interaction-environment lcm length list list->string '
+ 'list->vector list-ref list-tail list? load log magnitude make-polar '
+ 'make-rectangular make-string make-vector max member memq memv min '
+ 'modulo negative? newline not null-environment null? number->string '
+ 'number? numerator odd? open-input-file open-output-file output-port? '
+ 'pair? peek-char port? positive? procedure? quasiquote quote quotient '
+ 'rational? rationalize read read-char real-part real? remainder reverse '
+ 'round scheme-report-environment set! set-car! set-cdr! sin sqrt string '
+ 'string->list string->number string->symbol string-append string-ci<=? '
+ 'string-ci<? string-ci=? string-ci>=? string-ci>? string-copy '
+ 'string-fill! string-length string-ref string-set! string<=? string<? '
+ 'string=? string>=? string>? string? substring symbol->string symbol? '
+ 'tan transcript-off transcript-on truncate values vector '
+ 'vector->list vector-fill! vector-length vector-ref vector-set! '
+ 'with-input-from-file with-output-to-file write write-char zero?'
};
const LITERAL = {
className: 'literal',
begin: '(#t|#f|#\\\\' + SCHEME_IDENT_RE + '|#\\\\.)'
};
const NUMBER = {
className: 'number',
variants: [
{
begin: SCHEME_SIMPLE_NUMBER_RE,
relevance: 0
},
{
begin: SCHEME_COMPLEX_NUMBER_RE,
relevance: 0
},
{ begin: '#b[0-1]+(/[0-1]+)?' },
{ begin: '#o[0-7]+(/[0-7]+)?' },
{ begin: '#x[0-9a-f]+(/[0-9a-f]+)?' }
]
};
const STRING = hljs.QUOTE_STRING_MODE;
const COMMENT_MODES = [
hljs.COMMENT(
';',
'$',
{ relevance: 0 }
),
hljs.COMMENT('#\\|', '\\|#')
];
const IDENT = {
begin: SCHEME_IDENT_RE,
relevance: 0
};
const QUOTED_IDENT = {
className: 'symbol',
begin: '\'' + SCHEME_IDENT_RE
};
const BODY = {
endsWithParent: true,
relevance: 0
};
const QUOTED_LIST = {
variants: [
{ begin: /'/ },
{ begin: '`' }
],
contains: [
{
begin: '\\(',
end: '\\)',
contains: [
'self',
LITERAL,
STRING,
NUMBER,
IDENT,
QUOTED_IDENT
]
}
]
};
const NAME = {
className: 'name',
relevance: 0,
begin: SCHEME_IDENT_RE,
keywords: KEYWORDS
};
const LAMBDA = {
begin: /lambda/,
endsWithParent: true,
returnBegin: true,
contains: [
NAME,
{
endsParent: true,
variants: [
{
begin: /\(/,
end: /\)/
},
{
begin: /\[/,
end: /\]/
}
],
contains: [ IDENT ]
}
]
};
const LIST = {
variants: [
{
begin: '\\(',
end: '\\)'
},
{
begin: '\\[',
end: '\\]'
}
],
contains: [
LAMBDA,
NAME,
BODY
]
};
BODY.contains = [
LITERAL,
NUMBER,
STRING,
IDENT,
QUOTED_IDENT,
QUOTED_LIST,
LIST
].concat(COMMENT_MODES);
return {
name: 'Scheme',
aliases: ['scm'],
illegal: /\S/,
contains: [
hljs.SHEBANG(),
NUMBER,
STRING,
QUOTED_IDENT,
QUOTED_LIST,
LIST
].concat(COMMENT_MODES)
};
}
var scheme_1 = scheme;
/*
Language: Scilab
Author: Sylvestre Ledru <sylvestre.ledru@scilab-enterprises.com>
Origin: matlab.js
Description: Scilab is a port from Matlab
Website: https://www.scilab.org
Category: scientific
*/
function scilab(hljs) {
const COMMON_CONTAINS = [
hljs.C_NUMBER_MODE,
{
className: 'string',
begin: '\'|\"',
end: '\'|\"',
contains: [
hljs.BACKSLASH_ESCAPE,
{ begin: '\'\'' }
]
}
];
return {
name: 'Scilab',
aliases: [ 'sci' ],
keywords: {
$pattern: /%?\w+/,
keyword: 'abort break case clear catch continue do elseif else endfunction end for function '
+ 'global if pause return resume select try then while',
literal:
'%f %F %t %T %pi %eps %inf %nan %e %i %z %s',
built_in: // Scilab has more than 2000 functions. Just list the most commons
'abs and acos asin atan ceil cd chdir clearglobal cosh cos cumprod deff disp error '
+ 'exec execstr exists exp eye gettext floor fprintf fread fsolve imag isdef isempty '
+ 'isinfisnan isvector lasterror length load linspace list listfiles log10 log2 log '
+ 'max min msprintf mclose mopen ones or pathconvert poly printf prod pwd rand real '
+ 'round sinh sin size gsort sprintf sqrt strcat strcmps tring sum system tanh tan '
+ 'type typename warning zeros matrix'
},
illegal: '("|#|/\\*|\\s+/\\w+)',
contains: [
{
className: 'function',
beginKeywords: 'function',
end: '$',
contains: [
hljs.UNDERSCORE_TITLE_MODE,
{
className: 'params',
begin: '\\(',
end: '\\)'
}
]
},
// seems to be a guard against [ident]' or [ident].
// perhaps to prevent attributes from flagging as keywords?
{
begin: '[a-zA-Z_][a-zA-Z_0-9]*[\\.\']+',
relevance: 0
},
{
begin: '\\[',
end: '\\][\\.\']*',
relevance: 0,
contains: COMMON_CONTAINS
},
hljs.COMMENT('//', '$')
].concat(COMMON_CONTAINS)
};
}
var scilab_1 = scilab;
const MODES$1 = (hljs) => {
return {
IMPORTANT: {
scope: 'meta',
begin: '!important'
},
BLOCK_COMMENT: hljs.C_BLOCK_COMMENT_MODE,
HEXCOLOR: {
scope: 'number',
begin: /#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/
},
FUNCTION_DISPATCH: {
className: "built_in",
begin: /[\w-]+(?=\()/
},
ATTRIBUTE_SELECTOR_MODE: {
scope: 'selector-attr',
begin: /\[/,
end: /\]/,
illegal: '$',
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
},
CSS_NUMBER_MODE: {
scope: 'number',
begin: hljs.NUMBER_RE + '(' +
'%|em|ex|ch|rem' +
'|vw|vh|vmin|vmax' +
'|cm|mm|in|pt|pc|px' +
'|deg|grad|rad|turn' +
'|s|ms' +
'|Hz|kHz' +
'|dpi|dpcm|dppx' +
')?',
relevance: 0
},
CSS_VARIABLE: {
className: "attr",
begin: /--[A-Za-z_][A-Za-z0-9_-]*/
}
};
};
const TAGS$1 = [
'a',
'abbr',
'address',
'article',
'aside',
'audio',
'b',
'blockquote',
'body',
'button',
'canvas',
'caption',
'cite',
'code',
'dd',
'del',
'details',
'dfn',
'div',
'dl',
'dt',
'em',
'fieldset',
'figcaption',
'figure',
'footer',
'form',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'header',
'hgroup',
'html',
'i',
'iframe',
'img',
'input',
'ins',
'kbd',
'label',
'legend',
'li',
'main',
'mark',
'menu',
'nav',
'object',
'ol',
'p',
'q',
'quote',
'samp',
'section',
'span',
'strong',
'summary',
'sup',
'table',
'tbody',
'td',
'textarea',
'tfoot',
'th',
'thead',
'time',
'tr',
'ul',
'var',
'video'
];
const MEDIA_FEATURES$1 = [
'any-hover',
'any-pointer',
'aspect-ratio',
'color',
'color-gamut',
'color-index',
'device-aspect-ratio',
'device-height',
'device-width',
'display-mode',
'forced-colors',
'grid',
'height',
'hover',
'inverted-colors',
'monochrome',
'orientation',
'overflow-block',
'overflow-inline',
'pointer',
'prefers-color-scheme',
'prefers-contrast',
'prefers-reduced-motion',
'prefers-reduced-transparency',
'resolution',
'scan',
'scripting',
'update',
'width',
// TODO: find a better solution?
'min-width',
'max-width',
'min-height',
'max-height'
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-classes
const PSEUDO_CLASSES$1 = [
'active',
'any-link',
'blank',
'checked',
'current',
'default',
'defined',
'dir', // dir()
'disabled',
'drop',
'empty',
'enabled',
'first',
'first-child',
'first-of-type',
'fullscreen',
'future',
'focus',
'focus-visible',
'focus-within',
'has', // has()
'host', // host or host()
'host-context', // host-context()
'hover',
'indeterminate',
'in-range',
'invalid',
'is', // is()
'lang', // lang()
'last-child',
'last-of-type',
'left',
'link',
'local-link',
'not', // not()
'nth-child', // nth-child()
'nth-col', // nth-col()
'nth-last-child', // nth-last-child()
'nth-last-col', // nth-last-col()
'nth-last-of-type', //nth-last-of-type()
'nth-of-type', //nth-of-type()
'only-child',
'only-of-type',
'optional',
'out-of-range',
'past',
'placeholder-shown',
'read-only',
'read-write',
'required',
'right',
'root',
'scope',
'target',
'target-within',
'user-invalid',
'valid',
'visited',
'where' // where()
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-elements
const PSEUDO_ELEMENTS$1 = [
'after',
'backdrop',
'before',
'cue',
'cue-region',
'first-letter',
'first-line',
'grammar-error',
'marker',
'part',
'placeholder',
'selection',
'slotted',
'spelling-error'
];
const ATTRIBUTES$1 = [
'align-content',
'align-items',
'align-self',
'all',
'animation',
'animation-delay',
'animation-direction',
'animation-duration',
'animation-fill-mode',
'animation-iteration-count',
'animation-name',
'animation-play-state',
'animation-timing-function',
'backface-visibility',
'background',
'background-attachment',
'background-blend-mode',
'background-clip',
'background-color',
'background-image',
'background-origin',
'background-position',
'background-repeat',
'background-size',
'block-size',
'border',
'border-block',
'border-block-color',
'border-block-end',
'border-block-end-color',
'border-block-end-style',
'border-block-end-width',
'border-block-start',
'border-block-start-color',
'border-block-start-style',
'border-block-start-width',
'border-block-style',
'border-block-width',
'border-bottom',
'border-bottom-color',
'border-bottom-left-radius',
'border-bottom-right-radius',
'border-bottom-style',
'border-bottom-width',
'border-collapse',
'border-color',
'border-image',
'border-image-outset',
'border-image-repeat',
'border-image-slice',
'border-image-source',
'border-image-width',
'border-inline',
'border-inline-color',
'border-inline-end',
'border-inline-end-color',
'border-inline-end-style',
'border-inline-end-width',
'border-inline-start',
'border-inline-start-color',
'border-inline-start-style',
'border-inline-start-width',
'border-inline-style',
'border-inline-width',
'border-left',
'border-left-color',
'border-left-style',
'border-left-width',
'border-radius',
'border-right',
'border-right-color',
'border-right-style',
'border-right-width',
'border-spacing',
'border-style',
'border-top',
'border-top-color',
'border-top-left-radius',
'border-top-right-radius',
'border-top-style',
'border-top-width',
'border-width',
'bottom',
'box-decoration-break',
'box-shadow',
'box-sizing',
'break-after',
'break-before',
'break-inside',
'caption-side',
'caret-color',
'clear',
'clip',
'clip-path',
'clip-rule',
'color',
'column-count',
'column-fill',
'column-gap',
'column-rule',
'column-rule-color',
'column-rule-style',
'column-rule-width',
'column-span',
'column-width',
'columns',
'contain',
'content',
'content-visibility',
'counter-increment',
'counter-reset',
'cue',
'cue-after',
'cue-before',
'cursor',
'direction',
'display',
'empty-cells',
'filter',
'flex',
'flex-basis',
'flex-direction',
'flex-flow',
'flex-grow',
'flex-shrink',
'flex-wrap',
'float',
'flow',
'font',
'font-display',
'font-family',
'font-feature-settings',
'font-kerning',
'font-language-override',
'font-size',
'font-size-adjust',
'font-smoothing',
'font-stretch',
'font-style',
'font-synthesis',
'font-variant',
'font-variant-caps',
'font-variant-east-asian',
'font-variant-ligatures',
'font-variant-numeric',
'font-variant-position',
'font-variation-settings',
'font-weight',
'gap',
'glyph-orientation-vertical',
'grid',
'grid-area',
'grid-auto-columns',
'grid-auto-flow',
'grid-auto-rows',
'grid-column',
'grid-column-end',
'grid-column-start',
'grid-gap',
'grid-row',
'grid-row-end',
'grid-row-start',
'grid-template',
'grid-template-areas',
'grid-template-columns',
'grid-template-rows',
'hanging-punctuation',
'height',
'hyphens',
'icon',
'image-orientation',
'image-rendering',
'image-resolution',
'ime-mode',
'inline-size',
'isolation',
'justify-content',
'left',
'letter-spacing',
'line-break',
'line-height',
'list-style',
'list-style-image',
'list-style-position',
'list-style-type',
'margin',
'margin-block',
'margin-block-end',
'margin-block-start',
'margin-bottom',
'margin-inline',
'margin-inline-end',
'margin-inline-start',
'margin-left',
'margin-right',
'margin-top',
'marks',
'mask',
'mask-border',
'mask-border-mode',
'mask-border-outset',
'mask-border-repeat',
'mask-border-slice',
'mask-border-source',
'mask-border-width',
'mask-clip',
'mask-composite',
'mask-image',
'mask-mode',
'mask-origin',
'mask-position',
'mask-repeat',
'mask-size',
'mask-type',
'max-block-size',
'max-height',
'max-inline-size',
'max-width',
'min-block-size',
'min-height',
'min-inline-size',
'min-width',
'mix-blend-mode',
'nav-down',
'nav-index',
'nav-left',
'nav-right',
'nav-up',
'none',
'normal',
'object-fit',
'object-position',
'opacity',
'order',
'orphans',
'outline',
'outline-color',
'outline-offset',
'outline-style',
'outline-width',
'overflow',
'overflow-wrap',
'overflow-x',
'overflow-y',
'padding',
'padding-block',
'padding-block-end',
'padding-block-start',
'padding-bottom',
'padding-inline',
'padding-inline-end',
'padding-inline-start',
'padding-left',
'padding-right',
'padding-top',
'page-break-after',
'page-break-before',
'page-break-inside',
'pause',
'pause-after',
'pause-before',
'perspective',
'perspective-origin',
'pointer-events',
'position',
'quotes',
'resize',
'rest',
'rest-after',
'rest-before',
'right',
'row-gap',
'scroll-margin',
'scroll-margin-block',
'scroll-margin-block-end',
'scroll-margin-block-start',
'scroll-margin-bottom',
'scroll-margin-inline',
'scroll-margin-inline-end',
'scroll-margin-inline-start',
'scroll-margin-left',
'scroll-margin-right',
'scroll-margin-top',
'scroll-padding',
'scroll-padding-block',
'scroll-padding-block-end',
'scroll-padding-block-start',
'scroll-padding-bottom',
'scroll-padding-inline',
'scroll-padding-inline-end',
'scroll-padding-inline-start',
'scroll-padding-left',
'scroll-padding-right',
'scroll-padding-top',
'scroll-snap-align',
'scroll-snap-stop',
'scroll-snap-type',
'scrollbar-color',
'scrollbar-gutter',
'scrollbar-width',
'shape-image-threshold',
'shape-margin',
'shape-outside',
'speak',
'speak-as',
'src', // @font-face
'tab-size',
'table-layout',
'text-align',
'text-align-all',
'text-align-last',
'text-combine-upright',
'text-decoration',
'text-decoration-color',
'text-decoration-line',
'text-decoration-style',
'text-emphasis',
'text-emphasis-color',
'text-emphasis-position',
'text-emphasis-style',
'text-indent',
'text-justify',
'text-orientation',
'text-overflow',
'text-rendering',
'text-shadow',
'text-transform',
'text-underline-position',
'top',
'transform',
'transform-box',
'transform-origin',
'transform-style',
'transition',
'transition-delay',
'transition-duration',
'transition-property',
'transition-timing-function',
'unicode-bidi',
'vertical-align',
'visibility',
'voice-balance',
'voice-duration',
'voice-family',
'voice-pitch',
'voice-range',
'voice-rate',
'voice-stress',
'voice-volume',
'white-space',
'widows',
'width',
'will-change',
'word-break',
'word-spacing',
'word-wrap',
'writing-mode',
'z-index'
// reverse makes sure longer attributes `font-weight` are matched fully
// instead of getting false positives on say `font`
].reverse();
/*
Language: SCSS
Description: Scss is an extension of the syntax of CSS.
Author: Kurt Emch <kurt@kurtemch.com>
Website: https://sass-lang.com
Category: common, css, web
*/
/** @type LanguageFn */
function scss(hljs) {
const modes = MODES$1(hljs);
const PSEUDO_ELEMENTS$1$1 = PSEUDO_ELEMENTS$1;
const PSEUDO_CLASSES$1$1 = PSEUDO_CLASSES$1;
const AT_IDENTIFIER = '@[a-z-]+'; // @font-face
const AT_MODIFIERS = "and or not only";
const IDENT_RE = '[a-zA-Z-][a-zA-Z0-9_-]*';
const VARIABLE = {
className: 'variable',
begin: '(\\$' + IDENT_RE + ')\\b',
relevance: 0
};
return {
name: 'SCSS',
case_insensitive: true,
illegal: '[=/|\']',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
// to recognize keyframe 40% etc which are outside the scope of our
// attribute value mode
modes.CSS_NUMBER_MODE,
{
className: 'selector-id',
begin: '#[A-Za-z0-9_-]+',
relevance: 0
},
{
className: 'selector-class',
begin: '\\.[A-Za-z0-9_-]+',
relevance: 0
},
modes.ATTRIBUTE_SELECTOR_MODE,
{
className: 'selector-tag',
begin: '\\b(' + TAGS$1.join('|') + ')\\b',
// was there, before, but why?
relevance: 0
},
{
className: 'selector-pseudo',
begin: ':(' + PSEUDO_CLASSES$1$1.join('|') + ')'
},
{
className: 'selector-pseudo',
begin: ':(:)?(' + PSEUDO_ELEMENTS$1$1.join('|') + ')'
},
VARIABLE,
{ // pseudo-selector params
begin: /\(/,
end: /\)/,
contains: [ modes.CSS_NUMBER_MODE ]
},
modes.CSS_VARIABLE,
{
className: 'attribute',
begin: '\\b(' + ATTRIBUTES$1.join('|') + ')\\b'
},
{ begin: '\\b(whitespace|wait|w-resize|visible|vertical-text|vertical-ideographic|uppercase|upper-roman|upper-alpha|underline|transparent|top|thin|thick|text|text-top|text-bottom|tb-rl|table-header-group|table-footer-group|sw-resize|super|strict|static|square|solid|small-caps|separate|se-resize|scroll|s-resize|rtl|row-resize|ridge|right|repeat|repeat-y|repeat-x|relative|progress|pointer|overline|outside|outset|oblique|nowrap|not-allowed|normal|none|nw-resize|no-repeat|no-drop|newspaper|ne-resize|n-resize|move|middle|medium|ltr|lr-tb|lowercase|lower-roman|lower-alpha|loose|list-item|line|line-through|line-edge|lighter|left|keep-all|justify|italic|inter-word|inter-ideograph|inside|inset|inline|inline-block|inherit|inactive|ideograph-space|ideograph-parenthesis|ideograph-numeric|ideograph-alpha|horizontal|hidden|help|hand|groove|fixed|ellipsis|e-resize|double|dotted|distribute|distribute-space|distribute-letter|distribute-all-lines|disc|disabled|default|decimal|dashed|crosshair|collapse|col-resize|circle|char|center|capitalize|break-word|break-all|bottom|both|bolder|bold|block|bidi-override|below|baseline|auto|always|all-scroll|absolute|table|table-cell)\\b' },
{
begin: /:/,
end: /[;}{]/,
relevance: 0,
contains: [
modes.BLOCK_COMMENT,
VARIABLE,
modes.HEXCOLOR,
modes.CSS_NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
modes.IMPORTANT,
modes.FUNCTION_DISPATCH
]
},
// matching these here allows us to treat them more like regular CSS
// rules so everything between the {} gets regular rule highlighting,
// which is what we want for page and font-face
{
begin: '@(page|font-face)',
keywords: {
$pattern: AT_IDENTIFIER,
keyword: '@page @font-face'
}
},
{
begin: '@',
end: '[{;]',
returnBegin: true,
keywords: {
$pattern: /[a-z-]+/,
keyword: AT_MODIFIERS,
attribute: MEDIA_FEATURES$1.join(" ")
},
contains: [
{
begin: AT_IDENTIFIER,
className: "keyword"
},
{
begin: /[a-z-]+(?=:)/,
className: "attribute"
},
VARIABLE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
modes.HEXCOLOR,
modes.CSS_NUMBER_MODE
]
},
modes.FUNCTION_DISPATCH
]
};
}
var scss_1 = scss;
/*
Language: Shell Session
Requires: bash.js
Author: TSUYUSATO Kitsune <make.just.on@gmail.com>
Category: common
Audit: 2020
*/
/** @type LanguageFn */
function shell(hljs) {
return {
name: 'Shell Session',
aliases: [
'console',
'shellsession'
],
contains: [
{
className: 'meta.prompt',
// We cannot add \s (spaces) in the regular expression otherwise it will be too broad and produce unexpected result.
// For instance, in the following example, it would match "echo /path/to/home >" as a prompt:
// echo /path/to/home > t.exe
begin: /^\s{0,3}[/~\w\d[\]()@-]*[>%$#][ ]?/,
starts: {
end: /[^\\](?=\s*$)/,
subLanguage: 'bash'
}
}
]
};
}
var shell_1 = shell;
/*
Language: Smali
Author: Dennis Titze <dennis.titze@gmail.com>
Description: Basic Smali highlighting
Website: https://github.com/JesusFreke/smali
*/
function smali(hljs) {
const smali_instr_low_prio = [
'add',
'and',
'cmp',
'cmpg',
'cmpl',
'const',
'div',
'double',
'float',
'goto',
'if',
'int',
'long',
'move',
'mul',
'neg',
'new',
'nop',
'not',
'or',
'rem',
'return',
'shl',
'shr',
'sput',
'sub',
'throw',
'ushr',
'xor'
];
const smali_instr_high_prio = [
'aget',
'aput',
'array',
'check',
'execute',
'fill',
'filled',
'goto/16',
'goto/32',
'iget',
'instance',
'invoke',
'iput',
'monitor',
'packed',
'sget',
'sparse'
];
const smali_keywords = [
'transient',
'constructor',
'abstract',
'final',
'synthetic',
'public',
'private',
'protected',
'static',
'bridge',
'system'
];
return {
name: 'Smali',
contains: [
{
className: 'string',
begin: '"',
end: '"',
relevance: 0
},
hljs.COMMENT(
'#',
'$',
{ relevance: 0 }
),
{
className: 'keyword',
variants: [
{ begin: '\\s*\\.end\\s[a-zA-Z0-9]*' },
{
begin: '^[ ]*\\.[a-zA-Z]*',
relevance: 0
},
{
begin: '\\s:[a-zA-Z_0-9]*',
relevance: 0
},
{ begin: '\\s(' + smali_keywords.join('|') + ')' }
]
},
{
className: 'built_in',
variants: [
{ begin: '\\s(' + smali_instr_low_prio.join('|') + ')\\s' },
{
begin: '\\s(' + smali_instr_low_prio.join('|') + ')((-|/)[a-zA-Z0-9]+)+\\s',
relevance: 10
},
{
begin: '\\s(' + smali_instr_high_prio.join('|') + ')((-|/)[a-zA-Z0-9]+)*\\s',
relevance: 10
}
]
},
{
className: 'class',
begin: 'L[^\(;:\n]*;',
relevance: 0
},
{ begin: '[vp][0-9]+' }
]
};
}
var smali_1 = smali;
/*
Language: Smalltalk
Description: Smalltalk is an object-oriented, dynamically typed reflective programming language.
Author: Vladimir Gubarkov <xonixx@gmail.com>
Website: https://en.wikipedia.org/wiki/Smalltalk
*/
function smalltalk(hljs) {
const VAR_IDENT_RE = '[a-z][a-zA-Z0-9_]*';
const CHAR = {
className: 'string',
begin: '\\$.{1}'
};
const SYMBOL = {
className: 'symbol',
begin: '#' + hljs.UNDERSCORE_IDENT_RE
};
return {
name: 'Smalltalk',
aliases: [ 'st' ],
keywords: [
"self",
"super",
"nil",
"true",
"false",
"thisContext"
],
contains: [
hljs.COMMENT('"', '"'),
hljs.APOS_STRING_MODE,
{
className: 'type',
begin: '\\b[A-Z][A-Za-z0-9_]*',
relevance: 0
},
{
begin: VAR_IDENT_RE + ':',
relevance: 0
},
hljs.C_NUMBER_MODE,
SYMBOL,
CHAR,
{
// This looks more complicated than needed to avoid combinatorial
// explosion under V8. It effectively means `| var1 var2 ... |` with
// whitespace adjacent to `|` being optional.
begin: '\\|[ ]*' + VAR_IDENT_RE + '([ ]+' + VAR_IDENT_RE + ')*[ ]*\\|',
returnBegin: true,
end: /\|/,
illegal: /\S/,
contains: [ { begin: '(\\|[ ]*)?' + VAR_IDENT_RE } ]
},
{
begin: '#\\(',
end: '\\)',
contains: [
hljs.APOS_STRING_MODE,
CHAR,
hljs.C_NUMBER_MODE,
SYMBOL
]
}
]
};
}
var smalltalk_1 = smalltalk;
/*
Language: SML (Standard ML)
Author: Edwin Dalorzo <edwin@dalorzo.org>
Description: SML language definition.
Website: https://www.smlnj.org
Origin: ocaml.js
Category: functional
*/
function sml(hljs) {
return {
name: 'SML (Standard ML)',
aliases: [ 'ml' ],
keywords: {
$pattern: '[a-z_]\\w*!?',
keyword:
/* according to Definition of Standard ML 97 */
'abstype and andalso as case datatype do else end eqtype '
+ 'exception fn fun functor handle if in include infix infixr '
+ 'let local nonfix of op open orelse raise rec sharing sig '
+ 'signature struct structure then type val with withtype where while',
built_in:
/* built-in types according to basis library */
'array bool char exn int list option order real ref string substring vector unit word',
literal:
'true false NONE SOME LESS EQUAL GREATER nil'
},
illegal: /\/\/|>>/,
contains: [
{
className: 'literal',
begin: /\[(\|\|)?\]|\(\)/,
relevance: 0
},
hljs.COMMENT(
'\\(\\*',
'\\*\\)',
{ contains: [ 'self' ] }
),
{ /* type variable */
className: 'symbol',
begin: '\'[A-Za-z_](?!\')[\\w\']*'
/* the grammar is ambiguous on how 'a'b should be interpreted but not the compiler */
},
{ /* polymorphic variant */
className: 'type',
begin: '`[A-Z][\\w\']*'
},
{ /* module or constructor */
className: 'type',
begin: '\\b[A-Z][\\w\']*',
relevance: 0
},
{ /* don't color identifiers, but safely catch all identifiers with ' */
begin: '[a-z_]\\w*\'[\\w\']*' },
hljs.inherit(hljs.APOS_STRING_MODE, {
className: 'string',
relevance: 0
}),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
className: 'number',
begin:
'\\b(0[xX][a-fA-F0-9_]+[Lln]?|'
+ '0[oO][0-7_]+[Lln]?|'
+ '0[bB][01_]+[Lln]?|'
+ '[0-9][0-9_]*([Lln]|(\\.[0-9_]*)?([eE][-+]?[0-9_]+)?)?)',
relevance: 0
},
{ begin: /[-=]>/ // relevance booster
}
]
};
}
var sml_1 = sml;
/*
Language: SQF
Author: Søren Enevoldsen <senevoldsen90@gmail.com>
Contributors: Marvin Saignat <contact@zgmrvn.com>, Dedmen Miller <dedmen@dedmen.de>, Leopard20
Description: Scripting language for the Arma game series
Website: https://community.bistudio.com/wiki/SQF_syntax
Category: scripting
Last update: 07.01.2023, Arma 3 v2.11
*/
/*
////////////////////////////////////////////////////////////////////////////////////////////
* Author: Leopard20
* Description:
This script can be used to dump all commands to the clipboard.
Make sure you're using the Diag EXE to dump all of the commands.
* How to use:
Simply replace the _KEYWORDS and _LITERAL arrays with the one from this sqf.js file.
Execute the script from the debug console.
All commands will be copied to the clipboard.
////////////////////////////////////////////////////////////////////////////////////////////
_KEYWORDS = ['if']; //Array of all KEYWORDS
_LITERALS = ['west']; //Array of all LITERALS
_allCommands = createHashMap;
{
_type = _x select [0,1];
if (_type != "t") then {
_command_lowercase = ((_x select [2]) splitString " ")#(((["n", "u", "b"] find _type) - 1) max 0);
_command_uppercase = supportInfo ("i:" + _command_lowercase) # 0 # 2;
_allCommands set [_command_lowercase, _command_uppercase];
};
} forEach supportInfo "";
_allCommands = _allCommands toArray false;
_allCommands sort true; //sort by lowercase
_allCommands = ((_allCommands apply {_x#1}) -_KEYWORDS)-_LITERALS; //remove KEYWORDS and LITERALS
copyToClipboard (str (_allCommands select {_x regexMatch "\w+"}) regexReplace ["""", "'"] regexReplace [",", ",\n"]);
*/
function sqf(hljs) {
// In SQF, a local variable starts with _
const VARIABLE = {
className: 'variable',
begin: /\b_+[a-zA-Z]\w*/
};
// In SQF, a function should fit myTag_fnc_myFunction pattern
// https://community.bistudio.com/wiki/Functions_Library_(Arma_3)#Adding_a_Function
const FUNCTION = {
className: 'title',
begin: /[a-zA-Z][a-zA-Z_0-9]*_fnc_[a-zA-Z_0-9]+/
};
// In SQF strings, quotes matching the start are escaped by adding a consecutive.
// Example of single escaped quotes: " "" " and ' '' '.
const STRINGS = {
className: 'string',
variants: [
{
begin: '"',
end: '"',
contains: [
{
begin: '""',
relevance: 0
}
]
},
{
begin: '\'',
end: '\'',
contains: [
{
begin: '\'\'',
relevance: 0
}
]
}
]
};
const KEYWORDS = [
'break',
'breakWith',
'breakOut',
'breakTo',
'case',
'catch',
'continue',
'continueWith',
'default',
'do',
'else',
'exit',
'exitWith',
'for',
'forEach',
'from',
'if',
'local',
'private',
'switch',
'step',
'then',
'throw',
'to',
'try',
'waitUntil',
'while',
'with'
];
const LITERAL = [
'blufor',
'civilian',
'configNull',
'controlNull',
'displayNull',
'diaryRecordNull',
'east',
'endl',
'false',
'grpNull',
'independent',
'lineBreak',
'locationNull',
'nil',
'objNull',
'opfor',
'pi',
'resistance',
'scriptNull',
'sideAmbientLife',
'sideEmpty',
'sideEnemy',
'sideFriendly',
'sideLogic',
'sideUnknown',
'taskNull',
'teamMemberNull',
'true',
'west'
];
const BUILT_IN = [
'abs',
'accTime',
'acos',
'action',
'actionIDs',
'actionKeys',
'actionKeysEx',
'actionKeysImages',
'actionKeysNames',
'actionKeysNamesArray',
'actionName',
'actionParams',
'activateAddons',
'activatedAddons',
'activateKey',
'activeTitleEffectParams',
'add3DENConnection',
'add3DENEventHandler',
'add3DENLayer',
'addAction',
'addBackpack',
'addBackpackCargo',
'addBackpackCargoGlobal',
'addBackpackGlobal',
'addBinocularItem',
'addCamShake',
'addCuratorAddons',
'addCuratorCameraArea',
'addCuratorEditableObjects',
'addCuratorEditingArea',
'addCuratorPoints',
'addEditorObject',
'addEventHandler',
'addForce',
'addForceGeneratorRTD',
'addGoggles',
'addGroupIcon',
'addHandgunItem',
'addHeadgear',
'addItem',
'addItemCargo',
'addItemCargoGlobal',
'addItemPool',
'addItemToBackpack',
'addItemToUniform',
'addItemToVest',
'addLiveStats',
'addMagazine',
'addMagazineAmmoCargo',
'addMagazineCargo',
'addMagazineCargoGlobal',
'addMagazineGlobal',
'addMagazinePool',
'addMagazines',
'addMagazineTurret',
'addMenu',
'addMenuItem',
'addMissionEventHandler',
'addMPEventHandler',
'addMusicEventHandler',
'addonFiles',
'addOwnedMine',
'addPlayerScores',
'addPrimaryWeaponItem',
'addPublicVariableEventHandler',
'addRating',
'addResources',
'addScore',
'addScoreSide',
'addSecondaryWeaponItem',
'addSwitchableUnit',
'addTeamMember',
'addToRemainsCollector',
'addTorque',
'addUniform',
'addUserActionEventHandler',
'addVehicle',
'addVest',
'addWaypoint',
'addWeapon',
'addWeaponCargo',
'addWeaponCargoGlobal',
'addWeaponGlobal',
'addWeaponItem',
'addWeaponPool',
'addWeaponTurret',
'addWeaponWithAttachmentsCargo',
'addWeaponWithAttachmentsCargoGlobal',
'admin',
'agent',
'agents',
'AGLToASL',
'aimedAtTarget',
'aimPos',
'airDensityCurveRTD',
'airDensityRTD',
'airplaneThrottle',
'airportSide',
'AISFinishHeal',
'alive',
'all3DENEntities',
'allActiveTitleEffects',
'allAddonsInfo',
'allAirports',
'allControls',
'allCurators',
'allCutLayers',
'allDead',
'allDeadMen',
'allDiaryRecords',
'allDiarySubjects',
'allDisplays',
'allEnv3DSoundSources',
'allGroups',
'allLODs',
'allMapMarkers',
'allMines',
'allMissionObjects',
'allObjects',
'allow3DMode',
'allowCrewInImmobile',
'allowCuratorLogicIgnoreAreas',
'allowDamage',
'allowDammage',
'allowedService',
'allowFileOperations',
'allowFleeing',
'allowGetIn',
'allowService',
'allowSprint',
'allPlayers',
'allSimpleObjects',
'allSites',
'allTurrets',
'allUnits',
'allUnitsUAV',
'allUsers',
'allVariables',
'ambientTemperature',
'ammo',
'ammoOnPylon',
'and',
'animate',
'animateBay',
'animateDoor',
'animatePylon',
'animateSource',
'animationNames',
'animationPhase',
'animationSourcePhase',
'animationState',
'apertureParams',
'append',
'apply',
'armoryPoints',
'arrayIntersect',
'asin',
'ASLToAGL',
'ASLToATL',
'assert',
'assignAsCargo',
'assignAsCargoIndex',
'assignAsCommander',
'assignAsDriver',
'assignAsGunner',
'assignAsTurret',
'assignCurator',
'assignedCargo',
'assignedCommander',
'assignedDriver',
'assignedGroup',
'assignedGunner',
'assignedItems',
'assignedTarget',
'assignedTeam',
'assignedVehicle',
'assignedVehicleRole',
'assignedVehicles',
'assignItem',
'assignTeam',
'assignToAirport',
'atan',
'atan2',
'atg',
'ATLToASL',
'attachedObject',
'attachedObjects',
'attachedTo',
'attachObject',
'attachTo',
'attackEnabled',
'awake',
'backpack',
'backpackCargo',
'backpackContainer',
'backpackItems',
'backpackMagazines',
'backpackSpaceFor',
'behaviour',
'benchmark',
'bezierInterpolation',
'binocular',
'binocularItems',
'binocularMagazine',
'boundingBox',
'boundingBoxReal',
'boundingCenter',
'brakesDisabled',
'briefingName',
'buildingExit',
'buildingPos',
'buldozer_EnableRoadDiag',
'buldozer_IsEnabledRoadDiag',
'buldozer_LoadNewRoads',
'buldozer_reloadOperMap',
'buttonAction',
'buttonSetAction',
'cadetMode',
'calculatePath',
'calculatePlayerVisibilityByFriendly',
'call',
'callExtension',
'camCommand',
'camCommit',
'camCommitPrepared',
'camCommitted',
'camConstuctionSetParams',
'camCreate',
'camDestroy',
'cameraEffect',
'cameraEffectEnableHUD',
'cameraInterest',
'cameraOn',
'cameraView',
'campaignConfigFile',
'camPreload',
'camPreloaded',
'camPrepareBank',
'camPrepareDir',
'camPrepareDive',
'camPrepareFocus',
'camPrepareFov',
'camPrepareFovRange',
'camPreparePos',
'camPrepareRelPos',
'camPrepareTarget',
'camSetBank',
'camSetDir',
'camSetDive',
'camSetFocus',
'camSetFov',
'camSetFovRange',
'camSetPos',
'camSetRelPos',
'camSetTarget',
'camTarget',
'camUseNVG',
'canAdd',
'canAddItemToBackpack',
'canAddItemToUniform',
'canAddItemToVest',
'cancelSimpleTaskDestination',
'canDeployWeapon',
'canFire',
'canMove',
'canSlingLoad',
'canStand',
'canSuspend',
'canTriggerDynamicSimulation',
'canUnloadInCombat',
'canVehicleCargo',
'captive',
'captiveNum',
'cbChecked',
'cbSetChecked',
'ceil',
'channelEnabled',
'cheatsEnabled',
'checkAIFeature',
'checkVisibility',
'className',
'clear3DENAttribute',
'clear3DENInventory',
'clearAllItemsFromBackpack',
'clearBackpackCargo',
'clearBackpackCargoGlobal',
'clearForcesRTD',
'clearGroupIcons',
'clearItemCargo',
'clearItemCargoGlobal',
'clearItemPool',
'clearMagazineCargo',
'clearMagazineCargoGlobal',
'clearMagazinePool',
'clearOverlay',
'clearRadio',
'clearWeaponCargo',
'clearWeaponCargoGlobal',
'clearWeaponPool',
'clientOwner',
'closeDialog',
'closeDisplay',
'closeOverlay',
'collapseObjectTree',
'collect3DENHistory',
'collectiveRTD',
'collisionDisabledWith',
'combatBehaviour',
'combatMode',
'commandArtilleryFire',
'commandChat',
'commander',
'commandFire',
'commandFollow',
'commandFSM',
'commandGetOut',
'commandingMenu',
'commandMove',
'commandRadio',
'commandStop',
'commandSuppressiveFire',
'commandTarget',
'commandWatch',
'comment',
'commitOverlay',
'compatibleItems',
'compatibleMagazines',
'compile',
'compileFinal',
'compileScript',
'completedFSM',
'composeText',
'configClasses',
'configFile',
'configHierarchy',
'configName',
'configOf',
'configProperties',
'configSourceAddonList',
'configSourceMod',
'configSourceModList',
'confirmSensorTarget',
'connectTerminalToUAV',
'connectToServer',
'controlsGroupCtrl',
'conversationDisabled',
'copyFromClipboard',
'copyToClipboard',
'copyWaypoints',
'cos',
'count',
'countEnemy',
'countFriendly',
'countSide',
'countType',
'countUnknown',
'create3DENComposition',
'create3DENEntity',
'createAgent',
'createCenter',
'createDialog',
'createDiaryLink',
'createDiaryRecord',
'createDiarySubject',
'createDisplay',
'createGearDialog',
'createGroup',
'createGuardedPoint',
'createHashMap',
'createHashMapFromArray',
'createLocation',
'createMarker',
'createMarkerLocal',
'createMenu',
'createMine',
'createMissionDisplay',
'createMPCampaignDisplay',
'createSimpleObject',
'createSimpleTask',
'createSite',
'createSoundSource',
'createTask',
'createTeam',
'createTrigger',
'createUnit',
'createVehicle',
'createVehicleCrew',
'createVehicleLocal',
'crew',
'ctAddHeader',
'ctAddRow',
'ctClear',
'ctCurSel',
'ctData',
'ctFindHeaderRows',
'ctFindRowHeader',
'ctHeaderControls',
'ctHeaderCount',
'ctRemoveHeaders',
'ctRemoveRows',
'ctrlActivate',
'ctrlAddEventHandler',
'ctrlAngle',
'ctrlAnimateModel',
'ctrlAnimationPhaseModel',
'ctrlAt',
'ctrlAutoScrollDelay',
'ctrlAutoScrollRewind',
'ctrlAutoScrollSpeed',
'ctrlBackgroundColor',
'ctrlChecked',
'ctrlClassName',
'ctrlCommit',
'ctrlCommitted',
'ctrlCreate',
'ctrlDelete',
'ctrlEnable',
'ctrlEnabled',
'ctrlFade',
'ctrlFontHeight',
'ctrlForegroundColor',
'ctrlHTMLLoaded',
'ctrlIDC',
'ctrlIDD',
'ctrlMapAnimAdd',
'ctrlMapAnimClear',
'ctrlMapAnimCommit',
'ctrlMapAnimDone',
'ctrlMapCursor',
'ctrlMapMouseOver',
'ctrlMapPosition',
'ctrlMapScale',
'ctrlMapScreenToWorld',
'ctrlMapSetPosition',
'ctrlMapWorldToScreen',
'ctrlModel',
'ctrlModelDirAndUp',
'ctrlModelScale',
'ctrlMousePosition',
'ctrlParent',
'ctrlParentControlsGroup',
'ctrlPosition',
'ctrlRemoveAllEventHandlers',
'ctrlRemoveEventHandler',
'ctrlScale',
'ctrlScrollValues',
'ctrlSetActiveColor',
'ctrlSetAngle',
'ctrlSetAutoScrollDelay',
'ctrlSetAutoScrollRewind',
'ctrlSetAutoScrollSpeed',
'ctrlSetBackgroundColor',
'ctrlSetChecked',
'ctrlSetDisabledColor',
'ctrlSetEventHandler',
'ctrlSetFade',
'ctrlSetFocus',
'ctrlSetFont',
'ctrlSetFontH1',
'ctrlSetFontH1B',
'ctrlSetFontH2',
'ctrlSetFontH2B',
'ctrlSetFontH3',
'ctrlSetFontH3B',
'ctrlSetFontH4',
'ctrlSetFontH4B',
'ctrlSetFontH5',
'ctrlSetFontH5B',
'ctrlSetFontH6',
'ctrlSetFontH6B',
'ctrlSetFontHeight',
'ctrlSetFontHeightH1',
'ctrlSetFontHeightH2',
'ctrlSetFontHeightH3',
'ctrlSetFontHeightH4',
'ctrlSetFontHeightH5',
'ctrlSetFontHeightH6',
'ctrlSetFontHeightSecondary',
'ctrlSetFontP',
'ctrlSetFontPB',
'ctrlSetFontSecondary',
'ctrlSetForegroundColor',
'ctrlSetModel',
'ctrlSetModelDirAndUp',
'ctrlSetModelScale',
'ctrlSetMousePosition',
'ctrlSetPixelPrecision',
'ctrlSetPosition',
'ctrlSetPositionH',
'ctrlSetPositionW',
'ctrlSetPositionX',
'ctrlSetPositionY',
'ctrlSetScale',
'ctrlSetScrollValues',
'ctrlSetShadow',
'ctrlSetStructuredText',
'ctrlSetText',
'ctrlSetTextColor',
'ctrlSetTextColorSecondary',
'ctrlSetTextSecondary',
'ctrlSetTextSelection',
'ctrlSetTooltip',
'ctrlSetTooltipColorBox',
'ctrlSetTooltipColorShade',
'ctrlSetTooltipColorText',
'ctrlSetTooltipMaxWidth',
'ctrlSetURL',
'ctrlSetURLOverlayMode',
'ctrlShadow',
'ctrlShow',
'ctrlShown',
'ctrlStyle',
'ctrlText',
'ctrlTextColor',
'ctrlTextHeight',
'ctrlTextSecondary',
'ctrlTextSelection',
'ctrlTextWidth',
'ctrlTooltip',
'ctrlType',
'ctrlURL',
'ctrlURLOverlayMode',
'ctrlVisible',
'ctRowControls',
'ctRowCount',
'ctSetCurSel',
'ctSetData',
'ctSetHeaderTemplate',
'ctSetRowTemplate',
'ctSetValue',
'ctValue',
'curatorAddons',
'curatorCamera',
'curatorCameraArea',
'curatorCameraAreaCeiling',
'curatorCoef',
'curatorEditableObjects',
'curatorEditingArea',
'curatorEditingAreaType',
'curatorMouseOver',
'curatorPoints',
'curatorRegisteredObjects',
'curatorSelected',
'curatorWaypointCost',
'current3DENOperation',
'currentChannel',
'currentCommand',
'currentMagazine',
'currentMagazineDetail',
'currentMagazineDetailTurret',
'currentMagazineTurret',
'currentMuzzle',
'currentNamespace',
'currentPilot',
'currentTask',
'currentTasks',
'currentThrowable',
'currentVisionMode',
'currentWaypoint',
'currentWeapon',
'currentWeaponMode',
'currentWeaponTurret',
'currentZeroing',
'cursorObject',
'cursorTarget',
'customChat',
'customRadio',
'customWaypointPosition',
'cutFadeOut',
'cutObj',
'cutRsc',
'cutText',
'damage',
'date',
'dateToNumber',
'dayTime',
'deActivateKey',
'debriefingText',
'debugFSM',
'debugLog',
'decayGraphValues',
'deg',
'delete3DENEntities',
'deleteAt',
'deleteCenter',
'deleteCollection',
'deleteEditorObject',
'deleteGroup',
'deleteGroupWhenEmpty',
'deleteIdentity',
'deleteLocation',
'deleteMarker',
'deleteMarkerLocal',
'deleteRange',
'deleteResources',
'deleteSite',
'deleteStatus',
'deleteTeam',
'deleteVehicle',
'deleteVehicleCrew',
'deleteWaypoint',
'detach',
'detectedMines',
'diag_activeMissionFSMs',
'diag_activeScripts',
'diag_activeSQFScripts',
'diag_activeSQSScripts',
'diag_allMissionEventHandlers',
'diag_captureFrame',
'diag_captureFrameToFile',
'diag_captureSlowFrame',
'diag_codePerformance',
'diag_deltaTime',
'diag_drawmode',
'diag_dumpCalltraceToLog',
'diag_dumpScriptAssembly',
'diag_dumpTerrainSynth',
'diag_dynamicSimulationEnd',
'diag_enable',
'diag_enabled',
'diag_exportConfig',
'diag_exportTerrainSVG',
'diag_fps',
'diag_fpsmin',
'diag_frameno',
'diag_getTerrainSegmentOffset',
'diag_lightNewLoad',
'diag_list',
'diag_localized',
'diag_log',
'diag_logSlowFrame',
'diag_mergeConfigFile',
'diag_recordTurretLimits',
'diag_resetFSM',
'diag_resetshapes',
'diag_scope',
'diag_setLightNew',
'diag_stacktrace',
'diag_tickTime',
'diag_toggle',
'dialog',
'diarySubjectExists',
'didJIP',
'didJIPOwner',
'difficulty',
'difficultyEnabled',
'difficultyEnabledRTD',
'difficultyOption',
'direction',
'directionStabilizationEnabled',
'directSay',
'disableAI',
'disableBrakes',
'disableCollisionWith',
'disableConversation',
'disableDebriefingStats',
'disableMapIndicators',
'disableNVGEquipment',
'disableRemoteSensors',
'disableSerialization',
'disableTIEquipment',
'disableUAVConnectability',
'disableUserInput',
'displayAddEventHandler',
'displayChild',
'displayCtrl',
'displayParent',
'displayRemoveAllEventHandlers',
'displayRemoveEventHandler',
'displaySetEventHandler',
'displayUniqueName',
'displayUpdate',
'dissolveTeam',
'distance',
'distance2D',
'distanceSqr',
'distributionRegion',
'do3DENAction',
'doArtilleryFire',
'doFire',
'doFollow',
'doFSM',
'doGetOut',
'doMove',
'doorPhase',
'doStop',
'doSuppressiveFire',
'doTarget',
'doWatch',
'drawArrow',
'drawEllipse',
'drawIcon',
'drawIcon3D',
'drawLaser',
'drawLine',
'drawLine3D',
'drawLink',
'drawLocation',
'drawPolygon',
'drawRectangle',
'drawTriangle',
'driver',
'drop',
'dynamicSimulationDistance',
'dynamicSimulationDistanceCoef',
'dynamicSimulationEnabled',
'dynamicSimulationSystemEnabled',
'echo',
'edit3DENMissionAttributes',
'editObject',
'editorSetEventHandler',
'effectiveCommander',
'elevatePeriscope',
'emptyPositions',
'enableAI',
'enableAIFeature',
'enableAimPrecision',
'enableAttack',
'enableAudioFeature',
'enableAutoStartUpRTD',
'enableAutoTrimRTD',
'enableCamShake',
'enableCaustics',
'enableChannel',
'enableCollisionWith',
'enableCopilot',
'enableDebriefingStats',
'enableDiagLegend',
'enableDirectionStabilization',
'enableDynamicSimulation',
'enableDynamicSimulationSystem',
'enableEndDialog',
'enableEngineArtillery',
'enableEnvironment',
'enableFatigue',
'enableGunLights',
'enableInfoPanelComponent',
'enableIRLasers',
'enableMimics',
'enablePersonTurret',
'enableRadio',
'enableReload',
'enableRopeAttach',
'enableSatNormalOnDetail',
'enableSaving',
'enableSentences',
'enableSimulation',
'enableSimulationGlobal',
'enableStamina',
'enableStressDamage',
'enableTeamSwitch',
'enableTraffic',
'enableUAVConnectability',
'enableUAVWaypoints',
'enableVehicleCargo',
'enableVehicleSensor',
'enableWeaponDisassembly',
'endLoadingScreen',
'endMission',
'engineOn',
'enginesIsOnRTD',
'enginesPowerRTD',
'enginesRpmRTD',
'enginesTorqueRTD',
'entities',
'environmentEnabled',
'environmentVolume',
'equipmentDisabled',
'estimatedEndServerTime',
'estimatedTimeLeft',
'evalObjectArgument',
'everyBackpack',
'everyContainer',
'exec',
'execEditorScript',
'execFSM',
'execVM',
'exp',
'expectedDestination',
'exportJIPMessages',
'eyeDirection',
'eyePos',
'face',
'faction',
'fadeEnvironment',
'fadeMusic',
'fadeRadio',
'fadeSound',
'fadeSpeech',
'failMission',
'fileExists',
'fillWeaponsFromPool',
'find',
'findAny',
'findCover',
'findDisplay',
'findEditorObject',
'findEmptyPosition',
'findEmptyPositionReady',
'findIf',
'findNearestEnemy',
'finishMissionInit',
'finite',
'fire',
'fireAtTarget',
'firstBackpack',
'flag',
'flagAnimationPhase',
'flagOwner',
'flagSide',
'flagTexture',
'flatten',
'fleeing',
'floor',
'flyInHeight',
'flyInHeightASL',
'focusedCtrl',
'fog',
'fogForecast',
'fogParams',
'forceAddUniform',
'forceAtPositionRTD',
'forceCadetDifficulty',
'forcedMap',
'forceEnd',
'forceFlagTexture',
'forceFollowRoad',
'forceGeneratorRTD',
'forceMap',
'forceRespawn',
'forceSpeed',
'forceUnicode',
'forceWalk',
'forceWeaponFire',
'forceWeatherChange',
'forEachMember',
'forEachMemberAgent',
'forEachMemberTeam',
'forgetTarget',
'format',
'formation',
'formationDirection',
'formationLeader',
'formationMembers',
'formationPosition',
'formationTask',
'formatText',
'formLeader',
'freeExtension',
'freeLook',
'fromEditor',
'fuel',
'fullCrew',
'gearIDCAmmoCount',
'gearSlotAmmoCount',
'gearSlotData',
'gestureState',
'get',
'get3DENActionState',
'get3DENAttribute',
'get3DENCamera',
'get3DENConnections',
'get3DENEntity',
'get3DENEntityID',
'get3DENGrid',
'get3DENIconsVisible',
'get3DENLayerEntities',
'get3DENLinesVisible',
'get3DENMissionAttribute',
'get3DENMouseOver',
'get3DENSelected',
'getAimingCoef',
'getAllEnv3DSoundControllers',
'getAllEnvSoundControllers',
'getAllHitPointsDamage',
'getAllOwnedMines',
'getAllPylonsInfo',
'getAllSoundControllers',
'getAllUnitTraits',
'getAmmoCargo',
'getAnimAimPrecision',
'getAnimSpeedCoef',
'getArray',
'getArtilleryAmmo',
'getArtilleryComputerSettings',
'getArtilleryETA',
'getAssetDLCInfo',
'getAssignedCuratorLogic',
'getAssignedCuratorUnit',
'getAttackTarget',
'getAudioOptionVolumes',
'getBackpackCargo',
'getBleedingRemaining',
'getBurningValue',
'getCalculatePlayerVisibilityByFriendly',
'getCameraViewDirection',
'getCargoIndex',
'getCenterOfMass',
'getClientState',
'getClientStateNumber',
'getCompatiblePylonMagazines',
'getConnectedUAV',
'getConnectedUAVUnit',
'getContainerMaxLoad',
'getCorpse',
'getCruiseControl',
'getCursorObjectParams',
'getCustomAimCoef',
'getCustomSoundController',
'getCustomSoundControllerCount',
'getDammage',
'getDebriefingText',
'getDescription',
'getDir',
'getDirVisual',
'getDiverState',
'getDLCAssetsUsage',
'getDLCAssetsUsageByName',
'getDLCs',
'getDLCUsageTime',
'getEditorCamera',
'getEditorMode',
'getEditorObjectScope',
'getElevationOffset',
'getEngineTargetRPMRTD',
'getEnv3DSoundController',
'getEnvSoundController',
'getEventHandlerInfo',
'getFatigue',
'getFieldManualStartPage',
'getForcedFlagTexture',
'getForcedSpeed',
'getFriend',
'getFSMVariable',
'getFuelCargo',
'getGraphValues',
'getGroupIcon',
'getGroupIconParams',
'getGroupIcons',
'getHideFrom',
'getHit',
'getHitIndex',
'getHitPointDamage',
'getItemCargo',
'getLighting',
'getLightingAt',
'getLoadedModsInfo',
'getMagazineCargo',
'getMarkerColor',
'getMarkerPos',
'getMarkerSize',
'getMarkerType',
'getMass',
'getMissionConfig',
'getMissionConfigValue',
'getMissionDLCs',
'getMissionLayerEntities',
'getMissionLayers',
'getMissionPath',
'getModelInfo',
'getMousePosition',
'getMusicPlayedTime',
'getNumber',
'getObjectArgument',
'getObjectChildren',
'getObjectDLC',
'getObjectFOV',
'getObjectID',
'getObjectMaterials',
'getObjectProxy',
'getObjectScale',
'getObjectTextures',
'getObjectType',
'getObjectViewDistance',
'getOpticsMode',
'getOrDefault',
'getOrDefaultCall',
'getOxygenRemaining',
'getPersonUsedDLCs',
'getPilotCameraDirection',
'getPilotCameraPosition',
'getPilotCameraRotation',
'getPilotCameraTarget',
'getPiPViewDistance',
'getPlateNumber',
'getPlayerChannel',
'getPlayerID',
'getPlayerScores',
'getPlayerUID',
'getPlayerVoNVolume',
'getPos',
'getPosASL',
'getPosASLVisual',
'getPosASLW',
'getPosATL',
'getPosATLVisual',
'getPosVisual',
'getPosWorld',
'getPosWorldVisual',
'getPylonMagazines',
'getRelDir',
'getRelPos',
'getRemoteSensorsDisabled',
'getRepairCargo',
'getResolution',
'getRoadInfo',
'getRotorBrakeRTD',
'getSensorTargets',
'getSensorThreats',
'getShadowDistance',
'getShotParents',
'getSlingLoad',
'getSoundController',
'getSoundControllerResult',
'getSpeed',
'getStamina',
'getStatValue',
'getSteamFriendsServers',
'getSubtitleOptions',
'getSuppression',
'getTerrainGrid',
'getTerrainHeight',
'getTerrainHeightASL',
'getTerrainInfo',
'getText',
'getTextRaw',
'getTextureInfo',
'getTextWidth',
'getTiParameters',
'getTotalDLCUsageTime',
'getTrimOffsetRTD',
'getTurretLimits',
'getTurretOpticsMode',
'getUnitFreefallInfo',
'getUnitLoadout',
'getUnitTrait',
'getUnloadInCombat',
'getUserInfo',
'getUserMFDText',
'getUserMFDValue',
'getVariable',
'getVehicleCargo',
'getVehicleTiPars',
'getWeaponCargo',
'getWeaponSway',
'getWingsOrientationRTD',
'getWingsPositionRTD',
'getWPPos',
'glanceAt',
'globalChat',
'globalRadio',
'goggles',
'goto',
'group',
'groupChat',
'groupFromNetId',
'groupIconSelectable',
'groupIconsVisible',
'groupID',
'groupOwner',
'groupRadio',
'groups',
'groupSelectedUnits',
'groupSelectUnit',
'gunner',
'gusts',
'halt',
'handgunItems',
'handgunMagazine',
'handgunWeapon',
'handsHit',
'hashValue',
'hasInterface',
'hasPilotCamera',
'hasWeapon',
'hcAllGroups',
'hcGroupParams',
'hcLeader',
'hcRemoveAllGroups',
'hcRemoveGroup',
'hcSelected',
'hcSelectGroup',
'hcSetGroup',
'hcShowBar',
'hcShownBar',
'headgear',
'hideBody',
'hideObject',
'hideObjectGlobal',
'hideSelection',
'hint',
'hintC',
'hintCadet',
'hintSilent',
'hmd',
'hostMission',
'htmlLoad',
'HUDMovementLevels',
'humidity',
'image',
'importAllGroups',
'importance',
'in',
'inArea',
'inAreaArray',
'incapacitatedState',
'inflame',
'inflamed',
'infoPanel',
'infoPanelComponentEnabled',
'infoPanelComponents',
'infoPanels',
'inGameUISetEventHandler',
'inheritsFrom',
'initAmbientLife',
'inPolygon',
'inputAction',
'inputController',
'inputMouse',
'inRangeOfArtillery',
'insert',
'insertEditorObject',
'intersect',
'is3DEN',
'is3DENMultiplayer',
'is3DENPreview',
'isAbleToBreathe',
'isActionMenuVisible',
'isAgent',
'isAimPrecisionEnabled',
'isAllowedCrewInImmobile',
'isArray',
'isAutoHoverOn',
'isAutonomous',
'isAutoStartUpEnabledRTD',
'isAutotest',
'isAutoTrimOnRTD',
'isAwake',
'isBleeding',
'isBurning',
'isClass',
'isCollisionLightOn',
'isCopilotEnabled',
'isDamageAllowed',
'isDedicated',
'isDLCAvailable',
'isEngineOn',
'isEqualRef',
'isEqualTo',
'isEqualType',
'isEqualTypeAll',
'isEqualTypeAny',
'isEqualTypeArray',
'isEqualTypeParams',
'isFilePatchingEnabled',
'isFinal',
'isFlashlightOn',
'isFlatEmpty',
'isForcedWalk',
'isFormationLeader',
'isGameFocused',
'isGamePaused',
'isGroupDeletedWhenEmpty',
'isHidden',
'isInRemainsCollector',
'isInstructorFigureEnabled',
'isIRLaserOn',
'isKeyActive',
'isKindOf',
'isLaserOn',
'isLightOn',
'isLocalized',
'isManualFire',
'isMarkedForCollection',
'isMissionProfileNamespaceLoaded',
'isMultiplayer',
'isMultiplayerSolo',
'isNil',
'isNotEqualRef',
'isNotEqualTo',
'isNull',
'isNumber',
'isObjectHidden',
'isObjectRTD',
'isOnRoad',
'isPiPEnabled',
'isPlayer',
'isRealTime',
'isRemoteExecuted',
'isRemoteExecutedJIP',
'isSaving',
'isSensorTargetConfirmed',
'isServer',
'isShowing3DIcons',
'isSimpleObject',
'isSprintAllowed',
'isStaminaEnabled',
'isSteamMission',
'isSteamOverlayEnabled',
'isStreamFriendlyUIEnabled',
'isStressDamageEnabled',
'isText',
'isTouchingGround',
'isTurnedOut',
'isTutHintsEnabled',
'isUAVConnectable',
'isUAVConnected',
'isUIContext',
'isUniformAllowed',
'isVehicleCargo',
'isVehicleRadarOn',
'isVehicleSensorEnabled',
'isWalking',
'isWeaponDeployed',
'isWeaponRested',
'itemCargo',
'items',
'itemsWithMagazines',
'join',
'joinAs',
'joinAsSilent',
'joinSilent',
'joinString',
'kbAddDatabase',
'kbAddDatabaseTargets',
'kbAddTopic',
'kbHasTopic',
'kbReact',
'kbRemoveTopic',
'kbTell',
'kbWasSaid',
'keyImage',
'keyName',
'keys',
'knowsAbout',
'land',
'landAt',
'landResult',
'language',
'laserTarget',
'lbAdd',
'lbClear',
'lbColor',
'lbColorRight',
'lbCurSel',
'lbData',
'lbDelete',
'lbIsSelected',
'lbPicture',
'lbPictureRight',
'lbSelection',
'lbSetColor',
'lbSetColorRight',
'lbSetCurSel',
'lbSetData',
'lbSetPicture',
'lbSetPictureColor',
'lbSetPictureColorDisabled',
'lbSetPictureColorSelected',
'lbSetPictureRight',
'lbSetPictureRightColor',
'lbSetPictureRightColorDisabled',
'lbSetPictureRightColorSelected',
'lbSetSelectColor',
'lbSetSelectColorRight',
'lbSetSelected',
'lbSetText',
'lbSetTextRight',
'lbSetTooltip',
'lbSetValue',
'lbSize',
'lbSort',
'lbSortBy',
'lbSortByValue',
'lbText',
'lbTextRight',
'lbTooltip',
'lbValue',
'leader',
'leaderboardDeInit',
'leaderboardGetRows',
'leaderboardInit',
'leaderboardRequestRowsFriends',
'leaderboardRequestRowsGlobal',
'leaderboardRequestRowsGlobalAroundUser',
'leaderboardsRequestUploadScore',
'leaderboardsRequestUploadScoreKeepBest',
'leaderboardState',
'leaveVehicle',
'libraryCredits',
'libraryDisclaimers',
'lifeState',
'lightAttachObject',
'lightDetachObject',
'lightIsOn',
'lightnings',
'limitSpeed',
'linearConversion',
'lineIntersects',
'lineIntersectsObjs',
'lineIntersectsSurfaces',
'lineIntersectsWith',
'linkItem',
'list',
'listObjects',
'listRemoteTargets',
'listVehicleSensors',
'ln',
'lnbAddArray',
'lnbAddColumn',
'lnbAddRow',
'lnbClear',
'lnbColor',
'lnbColorRight',
'lnbCurSelRow',
'lnbData',
'lnbDeleteColumn',
'lnbDeleteRow',
'lnbGetColumnsPosition',
'lnbPicture',
'lnbPictureRight',
'lnbSetColor',
'lnbSetColorRight',
'lnbSetColumnsPos',
'lnbSetCurSelRow',
'lnbSetData',
'lnbSetPicture',
'lnbSetPictureColor',
'lnbSetPictureColorRight',
'lnbSetPictureColorSelected',
'lnbSetPictureColorSelectedRight',
'lnbSetPictureRight',
'lnbSetText',
'lnbSetTextRight',
'lnbSetTooltip',
'lnbSetValue',
'lnbSize',
'lnbSort',
'lnbSortBy',
'lnbSortByValue',
'lnbText',
'lnbTextRight',
'lnbValue',
'load',
'loadAbs',
'loadBackpack',
'loadConfig',
'loadFile',
'loadGame',
'loadIdentity',
'loadMagazine',
'loadOverlay',
'loadStatus',
'loadUniform',
'loadVest',
'localize',
'localNamespace',
'locationPosition',
'lock',
'lockCameraTo',
'lockCargo',
'lockDriver',
'locked',
'lockedCameraTo',
'lockedCargo',
'lockedDriver',
'lockedInventory',
'lockedTurret',
'lockIdentity',
'lockInventory',
'lockTurret',
'lockWp',
'log',
'logEntities',
'logNetwork',
'logNetworkTerminate',
'lookAt',
'lookAtPos',
'magazineCargo',
'magazines',
'magazinesAllTurrets',
'magazinesAmmo',
'magazinesAmmoCargo',
'magazinesAmmoFull',
'magazinesDetail',
'magazinesDetailBackpack',
'magazinesDetailUniform',
'magazinesDetailVest',
'magazinesTurret',
'magazineTurretAmmo',
'mapAnimAdd',
'mapAnimClear',
'mapAnimCommit',
'mapAnimDone',
'mapCenterOnCamera',
'mapGridPosition',
'markAsFinishedOnSteam',
'markerAlpha',
'markerBrush',
'markerChannel',
'markerColor',
'markerDir',
'markerPolyline',
'markerPos',
'markerShadow',
'markerShape',
'markerSize',
'markerText',
'markerType',
'matrixMultiply',
'matrixTranspose',
'max',
'maxLoad',
'members',
'menuAction',
'menuAdd',
'menuChecked',
'menuClear',
'menuCollapse',
'menuData',
'menuDelete',
'menuEnable',
'menuEnabled',
'menuExpand',
'menuHover',
'menuPicture',
'menuSetAction',
'menuSetCheck',
'menuSetData',
'menuSetPicture',
'menuSetShortcut',
'menuSetText',
'menuSetURL',
'menuSetValue',
'menuShortcut',
'menuShortcutText',
'menuSize',
'menuSort',
'menuText',
'menuURL',
'menuValue',
'merge',
'min',
'mineActive',
'mineDetectedBy',
'missileTarget',
'missileTargetPos',
'missionConfigFile',
'missionDifficulty',
'missionEnd',
'missionName',
'missionNameSource',
'missionNamespace',
'missionProfileNamespace',
'missionStart',
'missionVersion',
'mod',
'modelToWorld',
'modelToWorldVisual',
'modelToWorldVisualWorld',
'modelToWorldWorld',
'modParams',
'moonIntensity',
'moonPhase',
'morale',
'move',
'move3DENCamera',
'moveInAny',
'moveInCargo',
'moveInCommander',
'moveInDriver',
'moveInGunner',
'moveInTurret',
'moveObjectToEnd',
'moveOut',
'moveTime',
'moveTo',
'moveToCompleted',
'moveToFailed',
'musicVolume',
'name',
'namedProperties',
'nameSound',
'nearEntities',
'nearestBuilding',
'nearestLocation',
'nearestLocations',
'nearestLocationWithDubbing',
'nearestMines',
'nearestObject',
'nearestObjects',
'nearestTerrainObjects',
'nearObjects',
'nearObjectsReady',
'nearRoads',
'nearSupplies',
'nearTargets',
'needReload',
'needService',
'netId',
'netObjNull',
'newOverlay',
'nextMenuItemIndex',
'nextWeatherChange',
'nMenuItems',
'not',
'numberOfEnginesRTD',
'numberToDate',
'objectCurators',
'objectFromNetId',
'objectParent',
'objStatus',
'onBriefingGroup',
'onBriefingNotes',
'onBriefingPlan',
'onBriefingTeamSwitch',
'onCommandModeChanged',
'onDoubleClick',
'onEachFrame',
'onGroupIconClick',
'onGroupIconOverEnter',
'onGroupIconOverLeave',
'onHCGroupSelectionChanged',
'onMapSingleClick',
'onPlayerConnected',
'onPlayerDisconnected',
'onPreloadFinished',
'onPreloadStarted',
'onShowNewObject',
'onTeamSwitch',
'openCuratorInterface',
'openDLCPage',
'openGPS',
'openMap',
'openSteamApp',
'openYoutubeVideo',
'or',
'orderGetIn',
'overcast',
'overcastForecast',
'owner',
'param',
'params',
'parseNumber',
'parseSimpleArray',
'parseText',
'parsingNamespace',
'particlesQuality',
'periscopeElevation',
'pickWeaponPool',
'pitch',
'pixelGrid',
'pixelGridBase',
'pixelGridNoUIScale',
'pixelH',
'pixelW',
'playableSlotsNumber',
'playableUnits',
'playAction',
'playActionNow',
'player',
'playerRespawnTime',
'playerSide',
'playersNumber',
'playGesture',
'playMission',
'playMove',
'playMoveNow',
'playMusic',
'playScriptedMission',
'playSound',
'playSound3D',
'playSoundUI',
'pose',
'position',
'positionCameraToWorld',
'posScreenToWorld',
'posWorldToScreen',
'ppEffectAdjust',
'ppEffectCommit',
'ppEffectCommitted',
'ppEffectCreate',
'ppEffectDestroy',
'ppEffectEnable',
'ppEffectEnabled',
'ppEffectForceInNVG',
'precision',
'preloadCamera',
'preloadObject',
'preloadSound',
'preloadTitleObj',
'preloadTitleRsc',
'preprocessFile',
'preprocessFileLineNumbers',
'primaryWeapon',
'primaryWeaponItems',
'primaryWeaponMagazine',
'priority',
'processDiaryLink',
'productVersion',
'profileName',
'profileNamespace',
'profileNameSteam',
'progressLoadingScreen',
'progressPosition',
'progressSetPosition',
'publicVariable',
'publicVariableClient',
'publicVariableServer',
'pushBack',
'pushBackUnique',
'putWeaponPool',
'queryItemsPool',
'queryMagazinePool',
'queryWeaponPool',
'rad',
'radioChannelAdd',
'radioChannelCreate',
'radioChannelInfo',
'radioChannelRemove',
'radioChannelSetCallSign',
'radioChannelSetLabel',
'radioEnabled',
'radioVolume',
'rain',
'rainbow',
'rainParams',
'random',
'rank',
'rankId',
'rating',
'rectangular',
'regexFind',
'regexMatch',
'regexReplace',
'registeredTasks',
'registerTask',
'reload',
'reloadEnabled',
'remoteControl',
'remoteExec',
'remoteExecCall',
'remoteExecutedOwner',
'remove3DENConnection',
'remove3DENEventHandler',
'remove3DENLayer',
'removeAction',
'removeAll3DENEventHandlers',
'removeAllActions',
'removeAllAssignedItems',
'removeAllBinocularItems',
'removeAllContainers',
'removeAllCuratorAddons',
'removeAllCuratorCameraAreas',
'removeAllCuratorEditingAreas',
'removeAllEventHandlers',
'removeAllHandgunItems',
'removeAllItems',
'removeAllItemsWithMagazines',
'removeAllMissionEventHandlers',
'removeAllMPEventHandlers',
'removeAllMusicEventHandlers',
'removeAllOwnedMines',
'removeAllPrimaryWeaponItems',
'removeAllSecondaryWeaponItems',
'removeAllUserActionEventHandlers',
'removeAllWeapons',
'removeBackpack',
'removeBackpackGlobal',
'removeBinocularItem',
'removeCuratorAddons',
'removeCuratorCameraArea',
'removeCuratorEditableObjects',
'removeCuratorEditingArea',
'removeDiaryRecord',
'removeDiarySubject',
'removeDrawIcon',
'removeDrawLinks',
'removeEventHandler',
'removeFromRemainsCollector',
'removeGoggles',
'removeGroupIcon',
'removeHandgunItem',
'removeHeadgear',
'removeItem',
'removeItemFromBackpack',
'removeItemFromUniform',
'removeItemFromVest',
'removeItems',
'removeMagazine',
'removeMagazineGlobal',
'removeMagazines',
'removeMagazinesTurret',
'removeMagazineTurret',
'removeMenuItem',
'removeMissionEventHandler',
'removeMPEventHandler',
'removeMusicEventHandler',
'removeOwnedMine',
'removePrimaryWeaponItem',
'removeSecondaryWeaponItem',
'removeSimpleTask',
'removeSwitchableUnit',
'removeTeamMember',
'removeUniform',
'removeUserActionEventHandler',
'removeVest',
'removeWeapon',
'removeWeaponAttachmentCargo',
'removeWeaponCargo',
'removeWeaponGlobal',
'removeWeaponTurret',
'reportRemoteTarget',
'requiredVersion',
'resetCamShake',
'resetSubgroupDirection',
'resize',
'resources',
'respawnVehicle',
'restartEditorCamera',
'reveal',
'revealMine',
'reverse',
'reversedMouseY',
'roadAt',
'roadsConnectedTo',
'roleDescription',
'ropeAttachedObjects',
'ropeAttachedTo',
'ropeAttachEnabled',
'ropeAttachTo',
'ropeCreate',
'ropeCut',
'ropeDestroy',
'ropeDetach',
'ropeEndPosition',
'ropeLength',
'ropes',
'ropesAttachedTo',
'ropeSegments',
'ropeUnwind',
'ropeUnwound',
'rotorsForcesRTD',
'rotorsRpmRTD',
'round',
'runInitScript',
'safeZoneH',
'safeZoneW',
'safeZoneWAbs',
'safeZoneX',
'safeZoneXAbs',
'safeZoneY',
'save3DENInventory',
'saveGame',
'saveIdentity',
'saveJoysticks',
'saveMissionProfileNamespace',
'saveOverlay',
'saveProfileNamespace',
'saveStatus',
'saveVar',
'savingEnabled',
'say',
'say2D',
'say3D',
'scopeName',
'score',
'scoreSide',
'screenshot',
'screenToWorld',
'scriptDone',
'scriptName',
'scudState',
'secondaryWeapon',
'secondaryWeaponItems',
'secondaryWeaponMagazine',
'select',
'selectBestPlaces',
'selectDiarySubject',
'selectedEditorObjects',
'selectEditorObject',
'selectionNames',
'selectionPosition',
'selectionVectorDirAndUp',
'selectLeader',
'selectMax',
'selectMin',
'selectNoPlayer',
'selectPlayer',
'selectRandom',
'selectRandomWeighted',
'selectWeapon',
'selectWeaponTurret',
'sendAUMessage',
'sendSimpleCommand',
'sendTask',
'sendTaskResult',
'sendUDPMessage',
'sentencesEnabled',
'serverCommand',
'serverCommandAvailable',
'serverCommandExecutable',
'serverName',
'serverNamespace',
'serverTime',
'set',
'set3DENAttribute',
'set3DENAttributes',
'set3DENGrid',
'set3DENIconsVisible',
'set3DENLayer',
'set3DENLinesVisible',
'set3DENLogicType',
'set3DENMissionAttribute',
'set3DENMissionAttributes',
'set3DENModelsVisible',
'set3DENObjectType',
'set3DENSelected',
'setAccTime',
'setActualCollectiveRTD',
'setAirplaneThrottle',
'setAirportSide',
'setAmmo',
'setAmmoCargo',
'setAmmoOnPylon',
'setAnimSpeedCoef',
'setAperture',
'setApertureNew',
'setArmoryPoints',
'setAttributes',
'setAutonomous',
'setBehaviour',
'setBehaviourStrong',
'setBleedingRemaining',
'setBrakesRTD',
'setCameraInterest',
'setCamShakeDefParams',
'setCamShakeParams',
'setCamUseTi',
'setCaptive',
'setCenterOfMass',
'setCollisionLight',
'setCombatBehaviour',
'setCombatMode',
'setCompassOscillation',
'setConvoySeparation',
'setCruiseControl',
'setCuratorCameraAreaCeiling',
'setCuratorCoef',
'setCuratorEditingAreaType',
'setCuratorWaypointCost',
'setCurrentChannel',
'setCurrentTask',
'setCurrentWaypoint',
'setCustomAimCoef',
'SetCustomMissionData',
'setCustomSoundController',
'setCustomWeightRTD',
'setDamage',
'setDammage',
'setDate',
'setDebriefingText',
'setDefaultCamera',
'setDestination',
'setDetailMapBlendPars',
'setDiaryRecordText',
'setDiarySubjectPicture',
'setDir',
'setDirection',
'setDrawIcon',
'setDriveOnPath',
'setDropInterval',
'setDynamicSimulationDistance',
'setDynamicSimulationDistanceCoef',
'setEditorMode',
'setEditorObjectScope',
'setEffectCondition',
'setEffectiveCommander',
'setEngineRpmRTD',
'setFace',
'setFaceanimation',
'setFatigue',
'setFeatureType',
'setFlagAnimationPhase',
'setFlagOwner',
'setFlagSide',
'setFlagTexture',
'setFog',
'setForceGeneratorRTD',
'setFormation',
'setFormationTask',
'setFormDir',
'setFriend',
'setFromEditor',
'setFSMVariable',
'setFuel',
'setFuelCargo',
'setGroupIcon',
'setGroupIconParams',
'setGroupIconsSelectable',
'setGroupIconsVisible',
'setGroupid',
'setGroupIdGlobal',
'setGroupOwner',
'setGusts',
'setHideBehind',
'setHit',
'setHitIndex',
'setHitPointDamage',
'setHorizonParallaxCoef',
'setHUDMovementLevels',
'setHumidity',
'setIdentity',
'setImportance',
'setInfoPanel',
'setLeader',
'setLightAmbient',
'setLightAttenuation',
'setLightBrightness',
'setLightColor',
'setLightConePars',
'setLightDayLight',
'setLightFlareMaxDistance',
'setLightFlareSize',
'setLightIntensity',
'setLightIR',
'setLightnings',
'setLightUseFlare',
'setLightVolumeShape',
'setLocalWindParams',
'setMagazineTurretAmmo',
'setMarkerAlpha',
'setMarkerAlphaLocal',
'setMarkerBrush',
'setMarkerBrushLocal',
'setMarkerColor',
'setMarkerColorLocal',
'setMarkerDir',
'setMarkerDirLocal',
'setMarkerPolyline',
'setMarkerPolylineLocal',
'setMarkerPos',
'setMarkerPosLocal',
'setMarkerShadow',
'setMarkerShadowLocal',
'setMarkerShape',
'setMarkerShapeLocal',
'setMarkerSize',
'setMarkerSizeLocal',
'setMarkerText',
'setMarkerTextLocal',
'setMarkerType',
'setMarkerTypeLocal',
'setMass',
'setMaxLoad',
'setMimic',
'setMissileTarget',
'setMissileTargetPos',
'setMousePosition',
'setMusicEffect',
'setMusicEventHandler',
'setName',
'setNameSound',
'setObjectArguments',
'setObjectMaterial',
'setObjectMaterialGlobal',
'setObjectProxy',
'setObjectScale',
'setObjectTexture',
'setObjectTextureGlobal',
'setObjectViewDistance',
'setOpticsMode',
'setOvercast',
'setOwner',
'setOxygenRemaining',
'setParticleCircle',
'setParticleClass',
'setParticleFire',
'setParticleParams',
'setParticleRandom',
'setPilotCameraDirection',
'setPilotCameraRotation',
'setPilotCameraTarget',
'setPilotLight',
'setPiPEffect',
'setPiPViewDistance',
'setPitch',
'setPlateNumber',
'setPlayable',
'setPlayerRespawnTime',
'setPlayerVoNVolume',
'setPos',
'setPosASL',
'setPosASL2',
'setPosASLW',
'setPosATL',
'setPosition',
'setPosWorld',
'setPylonLoadout',
'setPylonsPriority',
'setRadioMsg',
'setRain',
'setRainbow',
'setRandomLip',
'setRank',
'setRectangular',
'setRepairCargo',
'setRotorBrakeRTD',
'setShadowDistance',
'setShotParents',
'setSide',
'setSimpleTaskAlwaysVisible',
'setSimpleTaskCustomData',
'setSimpleTaskDescription',
'setSimpleTaskDestination',
'setSimpleTaskTarget',
'setSimpleTaskType',
'setSimulWeatherLayers',
'setSize',
'setSkill',
'setSlingLoad',
'setSoundEffect',
'setSpeaker',
'setSpeech',
'setSpeedMode',
'setStamina',
'setStaminaScheme',
'setStatValue',
'setSuppression',
'setSystemOfUnits',
'setTargetAge',
'setTaskMarkerOffset',
'setTaskResult',
'setTaskState',
'setTerrainGrid',
'setTerrainHeight',
'setText',
'setTimeMultiplier',
'setTiParameter',
'setTitleEffect',
'setTowParent',
'setTrafficDensity',
'setTrafficDistance',
'setTrafficGap',
'setTrafficSpeed',
'setTriggerActivation',
'setTriggerArea',
'setTriggerInterval',
'setTriggerStatements',
'setTriggerText',
'setTriggerTimeout',
'setTriggerType',
'setTurretLimits',
'setTurretOpticsMode',
'setType',
'setUnconscious',
'setUnitAbility',
'setUnitCombatMode',
'setUnitFreefallHeight',
'setUnitLoadout',
'setUnitPos',
'setUnitPosWeak',
'setUnitRank',
'setUnitRecoilCoefficient',
'setUnitTrait',
'setUnloadInCombat',
'setUserActionText',
'setUserMFDText',
'setUserMFDValue',
'setVariable',
'setVectorDir',
'setVectorDirAndUp',
'setVectorUp',
'setVehicleAmmo',
'setVehicleAmmoDef',
'setVehicleArmor',
'setVehicleCargo',
'setVehicleId',
'setVehicleLock',
'setVehiclePosition',
'setVehicleRadar',
'setVehicleReceiveRemoteTargets',
'setVehicleReportOwnPosition',
'setVehicleReportRemoteTargets',
'setVehicleTiPars',
'setVehicleVarName',
'setVelocity',
'setVelocityModelSpace',
'setVelocityTransformation',
'setViewDistance',
'setVisibleIfTreeCollapsed',
'setWantedRPMRTD',
'setWaves',
'setWaypointBehaviour',
'setWaypointCombatMode',
'setWaypointCompletionRadius',
'setWaypointDescription',
'setWaypointForceBehaviour',
'setWaypointFormation',
'setWaypointHousePosition',
'setWaypointLoiterAltitude',
'setWaypointLoiterRadius',
'setWaypointLoiterType',
'setWaypointName',
'setWaypointPosition',
'setWaypointScript',
'setWaypointSpeed',
'setWaypointStatements',
'setWaypointTimeout',
'setWaypointType',
'setWaypointVisible',
'setWeaponReloadingTime',
'setWeaponZeroing',
'setWind',
'setWindDir',
'setWindForce',
'setWindStr',
'setWingForceScaleRTD',
'setWPPos',
'show3DIcons',
'showChat',
'showCinemaBorder',
'showCommandingMenu',
'showCompass',
'showCuratorCompass',
'showGps',
'showHUD',
'showLegend',
'showMap',
'shownArtilleryComputer',
'shownChat',
'shownCompass',
'shownCuratorCompass',
'showNewEditorObject',
'shownGps',
'shownHUD',
'shownMap',
'shownPad',
'shownRadio',
'shownScoretable',
'shownSubtitles',
'shownUAVFeed',
'shownWarrant',
'shownWatch',
'showPad',
'showRadio',
'showScoretable',
'showSubtitles',
'showUAVFeed',
'showWarrant',
'showWatch',
'showWaypoint',
'showWaypoints',
'side',
'sideChat',
'sideRadio',
'simpleTasks',
'simulationEnabled',
'simulCloudDensity',
'simulCloudOcclusion',
'simulInClouds',
'simulWeatherSync',
'sin',
'size',
'sizeOf',
'skill',
'skillFinal',
'skipTime',
'sleep',
'sliderPosition',
'sliderRange',
'sliderSetPosition',
'sliderSetRange',
'sliderSetSpeed',
'sliderSpeed',
'slingLoadAssistantShown',
'soldierMagazines',
'someAmmo',
'sort',
'soundVolume',
'spawn',
'speaker',
'speechVolume',
'speed',
'speedMode',
'splitString',
'sqrt',
'squadParams',
'stance',
'startLoadingScreen',
'stop',
'stopEngineRTD',
'stopped',
'str',
'sunOrMoon',
'supportInfo',
'suppressFor',
'surfaceIsWater',
'surfaceNormal',
'surfaceTexture',
'surfaceType',
'swimInDepth',
'switchableUnits',
'switchAction',
'switchCamera',
'switchGesture',
'switchLight',
'switchMove',
'synchronizedObjects',
'synchronizedTriggers',
'synchronizedWaypoints',
'synchronizeObjectsAdd',
'synchronizeObjectsRemove',
'synchronizeTrigger',
'synchronizeWaypoint',
'systemChat',
'systemOfUnits',
'systemTime',
'systemTimeUTC',
'tan',
'targetKnowledge',
'targets',
'targetsAggregate',
'targetsQuery',
'taskAlwaysVisible',
'taskChildren',
'taskCompleted',
'taskCustomData',
'taskDescription',
'taskDestination',
'taskHint',
'taskMarkerOffset',
'taskName',
'taskParent',
'taskResult',
'taskState',
'taskType',
'teamMember',
'teamName',
'teams',
'teamSwitch',
'teamSwitchEnabled',
'teamType',
'terminate',
'terrainIntersect',
'terrainIntersectASL',
'terrainIntersectAtASL',
'text',
'textLog',
'textLogFormat',
'tg',
'time',
'timeMultiplier',
'titleCut',
'titleFadeOut',
'titleObj',
'titleRsc',
'titleText',
'toArray',
'toFixed',
'toLower',
'toLowerANSI',
'toString',
'toUpper',
'toUpperANSI',
'triggerActivated',
'triggerActivation',
'triggerAmmo',
'triggerArea',
'triggerAttachedVehicle',
'triggerAttachObject',
'triggerAttachVehicle',
'triggerDynamicSimulation',
'triggerInterval',
'triggerStatements',
'triggerText',
'triggerTimeout',
'triggerTimeoutCurrent',
'triggerType',
'trim',
'turretLocal',
'turretOwner',
'turretUnit',
'tvAdd',
'tvClear',
'tvCollapse',
'tvCollapseAll',
'tvCount',
'tvCurSel',
'tvData',
'tvDelete',
'tvExpand',
'tvExpandAll',
'tvIsSelected',
'tvPicture',
'tvPictureRight',
'tvSelection',
'tvSetColor',
'tvSetCurSel',
'tvSetData',
'tvSetPicture',
'tvSetPictureColor',
'tvSetPictureColorDisabled',
'tvSetPictureColorSelected',
'tvSetPictureRight',
'tvSetPictureRightColor',
'tvSetPictureRightColorDisabled',
'tvSetPictureRightColorSelected',
'tvSetSelectColor',
'tvSetSelected',
'tvSetText',
'tvSetTooltip',
'tvSetValue',
'tvSort',
'tvSortAll',
'tvSortByValue',
'tvSortByValueAll',
'tvText',
'tvTooltip',
'tvValue',
'type',
'typeName',
'typeOf',
'UAVControl',
'uiNamespace',
'uiSleep',
'unassignCurator',
'unassignItem',
'unassignTeam',
'unassignVehicle',
'underwater',
'uniform',
'uniformContainer',
'uniformItems',
'uniformMagazines',
'uniqueUnitItems',
'unitAddons',
'unitAimPosition',
'unitAimPositionVisual',
'unitBackpack',
'unitCombatMode',
'unitIsUAV',
'unitPos',
'unitReady',
'unitRecoilCoefficient',
'units',
'unitsBelowHeight',
'unitTurret',
'unlinkItem',
'unlockAchievement',
'unregisterTask',
'updateDrawIcon',
'updateMenuItem',
'updateObjectTree',
'useAIOperMapObstructionTest',
'useAISteeringComponent',
'useAudioTimeForMoves',
'userInputDisabled',
'values',
'vectorAdd',
'vectorCos',
'vectorCrossProduct',
'vectorDiff',
'vectorDir',
'vectorDirVisual',
'vectorDistance',
'vectorDistanceSqr',
'vectorDotProduct',
'vectorFromTo',
'vectorLinearConversion',
'vectorMagnitude',
'vectorMagnitudeSqr',
'vectorModelToWorld',
'vectorModelToWorldVisual',
'vectorMultiply',
'vectorNormalized',
'vectorUp',
'vectorUpVisual',
'vectorWorldToModel',
'vectorWorldToModelVisual',
'vehicle',
'vehicleCargoEnabled',
'vehicleChat',
'vehicleMoveInfo',
'vehicleRadio',
'vehicleReceiveRemoteTargets',
'vehicleReportOwnPosition',
'vehicleReportRemoteTargets',
'vehicles',
'vehicleVarName',
'velocity',
'velocityModelSpace',
'verifySignature',
'vest',
'vestContainer',
'vestItems',
'vestMagazines',
'viewDistance',
'visibleCompass',
'visibleGps',
'visibleMap',
'visiblePosition',
'visiblePositionASL',
'visibleScoretable',
'visibleWatch',
'waves',
'waypointAttachedObject',
'waypointAttachedVehicle',
'waypointAttachObject',
'waypointAttachVehicle',
'waypointBehaviour',
'waypointCombatMode',
'waypointCompletionRadius',
'waypointDescription',
'waypointForceBehaviour',
'waypointFormation',
'waypointHousePosition',
'waypointLoiterAltitude',
'waypointLoiterRadius',
'waypointLoiterType',
'waypointName',
'waypointPosition',
'waypoints',
'waypointScript',
'waypointsEnabledUAV',
'waypointShow',
'waypointSpeed',
'waypointStatements',
'waypointTimeout',
'waypointTimeoutCurrent',
'waypointType',
'waypointVisible',
'weaponAccessories',
'weaponAccessoriesCargo',
'weaponCargo',
'weaponDirection',
'weaponInertia',
'weaponLowered',
'weaponReloadingTime',
'weapons',
'weaponsInfo',
'weaponsItems',
'weaponsItemsCargo',
'weaponState',
'weaponsTurret',
'weightRTD',
'WFSideText',
'wind',
'windDir',
'windRTD',
'windStr',
'wingsForcesRTD',
'worldName',
'worldSize',
'worldToModel',
'worldToModelVisual',
'worldToScreen'
];
// list of keywords from:
// https://community.bistudio.com/wiki/PreProcessor_Commands
const PREPROCESSOR = {
className: 'meta',
begin: /#\s*[a-z]+\b/,
end: /$/,
keywords: 'define undef ifdef ifndef else endif include if',
contains: [
{
begin: /\\\n/,
relevance: 0
},
hljs.inherit(STRINGS, { className: 'string' }),
{
begin: /<[^\n>]*>/,
end: /$/,
illegal: '\\n'
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
return {
name: 'SQF',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_IN,
literal: LITERAL
},
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.NUMBER_MODE,
VARIABLE,
FUNCTION,
STRINGS,
PREPROCESSOR
],
illegal: [
//$ is only valid when used with Hex numbers (e.g. $FF)
/\$[^a-fA-F0-9]/,
/\w\$/,
/\?/, //There's no ? in SQF
/@/, //There's no @ in SQF
// Brute-force-fixing the build error. See https://github.com/highlightjs/highlight.js/pull/3193#issuecomment-843088729
/ \| /,
// . is only used in numbers
/[a-zA-Z_]\./,
/\:\=/,
/\[\:/
]
};
}
var sqf_1 = sqf;
/*
Language: SQL
Website: https://en.wikipedia.org/wiki/SQL
Category: common, database
*/
/*
Goals:
SQL is intended to highlight basic/common SQL keywords and expressions
- If pretty much every single SQL server includes supports, then it's a canidate.
- It is NOT intended to include tons of vendor specific keywords (Oracle, MySQL,
PostgreSQL) although the list of data types is purposely a bit more expansive.
- For more specific SQL grammars please see:
- PostgreSQL and PL/pgSQL - core
- T-SQL - https://github.com/highlightjs/highlightjs-tsql
- sql_more (core)
*/
function sql(hljs) {
const regex = hljs.regex;
const COMMENT_MODE = hljs.COMMENT('--', '$');
const STRING = {
className: 'string',
variants: [
{
begin: /'/,
end: /'/,
contains: [ { begin: /''/ } ]
}
]
};
const QUOTED_IDENTIFIER = {
begin: /"/,
end: /"/,
contains: [ { begin: /""/ } ]
};
const LITERALS = [
"true",
"false",
// Not sure it's correct to call NULL literal, and clauses like IS [NOT] NULL look strange that way.
// "null",
"unknown"
];
const MULTI_WORD_TYPES = [
"double precision",
"large object",
"with timezone",
"without timezone"
];
const TYPES = [
'bigint',
'binary',
'blob',
'boolean',
'char',
'character',
'clob',
'date',
'dec',
'decfloat',
'decimal',
'float',
'int',
'integer',
'interval',
'nchar',
'nclob',
'national',
'numeric',
'real',
'row',
'smallint',
'time',
'timestamp',
'varchar',
'varying', // modifier (character varying)
'varbinary'
];
const NON_RESERVED_WORDS = [
"add",
"asc",
"collation",
"desc",
"final",
"first",
"last",
"view"
];
// https://jakewheat.github.io/sql-overview/sql-2016-foundation-grammar.html#reserved-word
const RESERVED_WORDS = [
"abs",
"acos",
"all",
"allocate",
"alter",
"and",
"any",
"are",
"array",
"array_agg",
"array_max_cardinality",
"as",
"asensitive",
"asin",
"asymmetric",
"at",
"atan",
"atomic",
"authorization",
"avg",
"begin",
"begin_frame",
"begin_partition",
"between",
"bigint",
"binary",
"blob",
"boolean",
"both",
"by",
"call",
"called",
"cardinality",
"cascaded",
"case",
"cast",
"ceil",
"ceiling",
"char",
"char_length",
"character",
"character_length",
"check",
"classifier",
"clob",
"close",
"coalesce",
"collate",
"collect",
"column",
"commit",
"condition",
"connect",
"constraint",
"contains",
"convert",
"copy",
"corr",
"corresponding",
"cos",
"cosh",
"count",
"covar_pop",
"covar_samp",
"create",
"cross",
"cube",
"cume_dist",
"current",
"current_catalog",
"current_date",
"current_default_transform_group",
"current_path",
"current_role",
"current_row",
"current_schema",
"current_time",
"current_timestamp",
"current_path",
"current_role",
"current_transform_group_for_type",
"current_user",
"cursor",
"cycle",
"date",
"day",
"deallocate",
"dec",
"decimal",
"decfloat",
"declare",
"default",
"define",
"delete",
"dense_rank",
"deref",
"describe",
"deterministic",
"disconnect",
"distinct",
"double",
"drop",
"dynamic",
"each",
"element",
"else",
"empty",
"end",
"end_frame",
"end_partition",
"end-exec",
"equals",
"escape",
"every",
"except",
"exec",
"execute",
"exists",
"exp",
"external",
"extract",
"false",
"fetch",
"filter",
"first_value",
"float",
"floor",
"for",
"foreign",
"frame_row",
"free",
"from",
"full",
"function",
"fusion",
"get",
"global",
"grant",
"group",
"grouping",
"groups",
"having",
"hold",
"hour",
"identity",
"in",
"indicator",
"initial",
"inner",
"inout",
"insensitive",
"insert",
"int",
"integer",
"intersect",
"intersection",
"interval",
"into",
"is",
"join",
"json_array",
"json_arrayagg",
"json_exists",
"json_object",
"json_objectagg",
"json_query",
"json_table",
"json_table_primitive",
"json_value",
"lag",
"language",
"large",
"last_value",
"lateral",
"lead",
"leading",
"left",
"like",
"like_regex",
"listagg",
"ln",
"local",
"localtime",
"localtimestamp",
"log",
"log10",
"lower",
"match",
"match_number",
"match_recognize",
"matches",
"max",
"member",
"merge",
"method",
"min",
"minute",
"mod",
"modifies",
"module",
"month",
"multiset",
"national",
"natural",
"nchar",
"nclob",
"new",
"no",
"none",
"normalize",
"not",
"nth_value",
"ntile",
"null",
"nullif",
"numeric",
"octet_length",
"occurrences_regex",
"of",
"offset",
"old",
"omit",
"on",
"one",
"only",
"open",
"or",
"order",
"out",
"outer",
"over",
"overlaps",
"overlay",
"parameter",
"partition",
"pattern",
"per",
"percent",
"percent_rank",
"percentile_cont",
"percentile_disc",
"period",
"portion",
"position",
"position_regex",
"power",
"precedes",
"precision",
"prepare",
"primary",
"procedure",
"ptf",
"range",
"rank",
"reads",
"real",
"recursive",
"ref",
"references",
"referencing",
"regr_avgx",
"regr_avgy",
"regr_count",
"regr_intercept",
"regr_r2",
"regr_slope",
"regr_sxx",
"regr_sxy",
"regr_syy",
"release",
"result",
"return",
"returns",
"revoke",
"right",
"rollback",
"rollup",
"row",
"row_number",
"rows",
"running",
"savepoint",
"scope",
"scroll",
"search",
"second",
"seek",
"select",
"sensitive",
"session_user",
"set",
"show",
"similar",
"sin",
"sinh",
"skip",
"smallint",
"some",
"specific",
"specifictype",
"sql",
"sqlexception",
"sqlstate",
"sqlwarning",
"sqrt",
"start",
"static",
"stddev_pop",
"stddev_samp",
"submultiset",
"subset",
"substring",
"substring_regex",
"succeeds",
"sum",
"symmetric",
"system",
"system_time",
"system_user",
"table",
"tablesample",
"tan",
"tanh",
"then",
"time",
"timestamp",
"timezone_hour",
"timezone_minute",
"to",
"trailing",
"translate",
"translate_regex",
"translation",
"treat",
"trigger",
"trim",
"trim_array",
"true",
"truncate",
"uescape",
"union",
"unique",
"unknown",
"unnest",
"update",
"upper",
"user",
"using",
"value",
"values",
"value_of",
"var_pop",
"var_samp",
"varbinary",
"varchar",
"varying",
"versioning",
"when",
"whenever",
"where",
"width_bucket",
"window",
"with",
"within",
"without",
"year",
];
// these are reserved words we have identified to be functions
// and should only be highlighted in a dispatch-like context
// ie, array_agg(...), etc.
const RESERVED_FUNCTIONS = [
"abs",
"acos",
"array_agg",
"asin",
"atan",
"avg",
"cast",
"ceil",
"ceiling",
"coalesce",
"corr",
"cos",
"cosh",
"count",
"covar_pop",
"covar_samp",
"cume_dist",
"dense_rank",
"deref",
"element",
"exp",
"extract",
"first_value",
"floor",
"json_array",
"json_arrayagg",
"json_exists",
"json_object",
"json_objectagg",
"json_query",
"json_table",
"json_table_primitive",
"json_value",
"lag",
"last_value",
"lead",
"listagg",
"ln",
"log",
"log10",
"lower",
"max",
"min",
"mod",
"nth_value",
"ntile",
"nullif",
"percent_rank",
"percentile_cont",
"percentile_disc",
"position",
"position_regex",
"power",
"rank",
"regr_avgx",
"regr_avgy",
"regr_count",
"regr_intercept",
"regr_r2",
"regr_slope",
"regr_sxx",
"regr_sxy",
"regr_syy",
"row_number",
"sin",
"sinh",
"sqrt",
"stddev_pop",
"stddev_samp",
"substring",
"substring_regex",
"sum",
"tan",
"tanh",
"translate",
"translate_regex",
"treat",
"trim",
"trim_array",
"unnest",
"upper",
"value_of",
"var_pop",
"var_samp",
"width_bucket",
];
// these functions can
const POSSIBLE_WITHOUT_PARENS = [
"current_catalog",
"current_date",
"current_default_transform_group",
"current_path",
"current_role",
"current_schema",
"current_transform_group_for_type",
"current_user",
"session_user",
"system_time",
"system_user",
"current_time",
"localtime",
"current_timestamp",
"localtimestamp"
];
// those exist to boost relevance making these very
// "SQL like" keyword combos worth +1 extra relevance
const COMBOS = [
"create table",
"insert into",
"primary key",
"foreign key",
"not null",
"alter table",
"add constraint",
"grouping sets",
"on overflow",
"character set",
"respect nulls",
"ignore nulls",
"nulls first",
"nulls last",
"depth first",
"breadth first"
];
const FUNCTIONS = RESERVED_FUNCTIONS;
const KEYWORDS = [
...RESERVED_WORDS,
...NON_RESERVED_WORDS
].filter((keyword) => {
return !RESERVED_FUNCTIONS.includes(keyword);
});
const VARIABLE = {
className: "variable",
begin: /@[a-z0-9][a-z0-9_]*/,
};
const OPERATOR = {
className: "operator",
begin: /[-+*/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?/,
relevance: 0,
};
const FUNCTION_CALL = {
begin: regex.concat(/\b/, regex.either(...FUNCTIONS), /\s*\(/),
relevance: 0,
keywords: { built_in: FUNCTIONS }
};
// keywords with less than 3 letters are reduced in relevancy
function reduceRelevancy(list, {
exceptions, when
} = {}) {
const qualifyFn = when;
exceptions = exceptions || [];
return list.map((item) => {
if (item.match(/\|\d+$/) || exceptions.includes(item)) {
return item;
} else if (qualifyFn(item)) {
return `${item}|0`;
} else {
return item;
}
});
}
return {
name: 'SQL',
case_insensitive: true,
// does not include {} or HTML tags `</`
illegal: /[{}]|<\//,
keywords: {
$pattern: /\b[\w\.]+/,
keyword:
reduceRelevancy(KEYWORDS, { when: (x) => x.length < 3 }),
literal: LITERALS,
type: TYPES,
built_in: POSSIBLE_WITHOUT_PARENS
},
contains: [
{
begin: regex.either(...COMBOS),
relevance: 0,
keywords: {
$pattern: /[\w\.]+/,
keyword: KEYWORDS.concat(COMBOS),
literal: LITERALS,
type: TYPES
},
},
{
className: "type",
begin: regex.either(...MULTI_WORD_TYPES)
},
FUNCTION_CALL,
VARIABLE,
STRING,
QUOTED_IDENTIFIER,
hljs.C_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE,
COMMENT_MODE,
OPERATOR
]
};
}
var sql_1 = sql;
/*
Language: Stan
Description: The Stan probabilistic programming language
Author: Sean Pinkney <sean.pinkney@gmail.com>
Website: http://mc-stan.org/
Category: scientific
*/
function stan(hljs) {
const regex = hljs.regex;
// variable names cannot conflict with block identifiers
const BLOCKS = [
'functions',
'model',
'data',
'parameters',
'quantities',
'transformed',
'generated'
];
const STATEMENTS = [
'for',
'in',
'if',
'else',
'while',
'break',
'continue',
'return'
];
const TYPES = [
'array',
'tuple',
'complex',
'int',
'real',
'vector',
'complex_vector',
'ordered',
'positive_ordered',
'simplex',
'unit_vector',
'row_vector',
'complex_row_vector',
'matrix',
'complex_matrix',
'cholesky_factor_corr|10',
'cholesky_factor_cov|10',
'corr_matrix|10',
'cov_matrix|10',
'void'
];
// to get the functions list
// clone the [stan-docs repo](https://github.com/stan-dev/docs)
// then cd into it and run this bash script https://gist.github.com/joshgoebel/dcd33f82d4059a907c986049893843cf
//
// the output files are
// distributions_quoted.txt
// functions_quoted.txt
const FUNCTIONS = [
'abs',
'acos',
'acosh',
'add_diag',
'algebra_solver',
'algebra_solver_newton',
'append_array',
'append_col',
'append_row',
'asin',
'asinh',
'atan',
'atan2',
'atanh',
'bessel_first_kind',
'bessel_second_kind',
'binary_log_loss',
'block',
'cbrt',
'ceil',
'chol2inv',
'cholesky_decompose',
'choose',
'col',
'cols',
'columns_dot_product',
'columns_dot_self',
'complex_schur_decompose',
'complex_schur_decompose_t',
'complex_schur_decompose_u',
'conj',
'cos',
'cosh',
'cov_exp_quad',
'crossprod',
'csr_extract',
'csr_extract_u',
'csr_extract_v',
'csr_extract_w',
'csr_matrix_times_vector',
'csr_to_dense_matrix',
'cumulative_sum',
'dae',
'dae_tol',
'determinant',
'diag_matrix',
'diagonal',
'diag_post_multiply',
'diag_pre_multiply',
'digamma',
'dims',
'distance',
'dot_product',
'dot_self',
'eigendecompose',
'eigendecompose_sym',
'eigenvalues',
'eigenvalues_sym',
'eigenvectors',
'eigenvectors_sym',
'erf',
'erfc',
'exp',
'exp2',
'expm1',
'falling_factorial',
'fdim',
'fft',
'fft2',
'floor',
'fma',
'fmax',
'fmin',
'fmod',
'gamma_p',
'gamma_q',
'generalized_inverse',
'get_imag',
'get_real',
'head',
'hmm_hidden_state_prob',
'hmm_marginal',
'hypot',
'identity_matrix',
'inc_beta',
'integrate_1d',
'integrate_ode',
'integrate_ode_adams',
'integrate_ode_bdf',
'integrate_ode_rk45',
'int_step',
'inv',
'inv_cloglog',
'inv_erfc',
'inverse',
'inverse_spd',
'inv_fft',
'inv_fft2',
'inv_inc_beta',
'inv_logit',
'inv_Phi',
'inv_sqrt',
'inv_square',
'is_inf',
'is_nan',
'lambert_w0',
'lambert_wm1',
'lbeta',
'lchoose',
'ldexp',
'lgamma',
'linspaced_array',
'linspaced_int_array',
'linspaced_row_vector',
'linspaced_vector',
'lmgamma',
'lmultiply',
'log',
'log1m',
'log1m_exp',
'log1m_inv_logit',
'log1p',
'log1p_exp',
'log_determinant',
'log_diff_exp',
'log_falling_factorial',
'log_inv_logit',
'log_inv_logit_diff',
'logit',
'log_mix',
'log_modified_bessel_first_kind',
'log_rising_factorial',
'log_softmax',
'log_sum_exp',
'machine_precision',
'map_rect',
'matrix_exp',
'matrix_exp_multiply',
'matrix_power',
'max',
'mdivide_left_spd',
'mdivide_left_tri_low',
'mdivide_right_spd',
'mdivide_right_tri_low',
'mean',
'min',
'modified_bessel_first_kind',
'modified_bessel_second_kind',
'multiply_lower_tri_self_transpose',
'negative_infinity',
'norm',
'norm1',
'norm2',
'not_a_number',
'num_elements',
'ode_adams',
'ode_adams_tol',
'ode_adjoint_tol_ctl',
'ode_bdf',
'ode_bdf_tol',
'ode_ckrk',
'ode_ckrk_tol',
'ode_rk45',
'ode_rk45_tol',
'one_hot_array',
'one_hot_int_array',
'one_hot_row_vector',
'one_hot_vector',
'ones_array',
'ones_int_array',
'ones_row_vector',
'ones_vector',
'owens_t',
'Phi',
'Phi_approx',
'polar',
'positive_infinity',
'pow',
'print',
'prod',
'proj',
'qr',
'qr_Q',
'qr_R',
'qr_thin',
'qr_thin_Q',
'qr_thin_R',
'quad_form',
'quad_form_diag',
'quad_form_sym',
'quantile',
'rank',
'reduce_sum',
'reject',
'rep_array',
'rep_matrix',
'rep_row_vector',
'rep_vector',
'reverse',
'rising_factorial',
'round',
'row',
'rows',
'rows_dot_product',
'rows_dot_self',
'scale_matrix_exp_multiply',
'sd',
'segment',
'sin',
'singular_values',
'sinh',
'size',
'softmax',
'sort_asc',
'sort_desc',
'sort_indices_asc',
'sort_indices_desc',
'sqrt',
'square',
'squared_distance',
'step',
'sub_col',
'sub_row',
'sum',
'svd',
'svd_U',
'svd_V',
'symmetrize_from_lower_tri',
'tail',
'tan',
'tanh',
'target',
'tcrossprod',
'tgamma',
'to_array_1d',
'to_array_2d',
'to_complex',
'to_int',
'to_matrix',
'to_row_vector',
'to_vector',
'trace',
'trace_gen_quad_form',
'trace_quad_form',
'trigamma',
'trunc',
'uniform_simplex',
'variance',
'zeros_array',
'zeros_int_array',
'zeros_row_vector'
];
const DISTRIBUTIONS = [
'bernoulli',
'bernoulli_logit',
'bernoulli_logit_glm',
'beta',
'beta_binomial',
'beta_proportion',
'binomial',
'binomial_logit',
'categorical',
'categorical_logit',
'categorical_logit_glm',
'cauchy',
'chi_square',
'dirichlet',
'discrete_range',
'double_exponential',
'exp_mod_normal',
'exponential',
'frechet',
'gamma',
'gaussian_dlm_obs',
'gumbel',
'hmm_latent',
'hypergeometric',
'inv_chi_square',
'inv_gamma',
'inv_wishart',
'inv_wishart_cholesky',
'lkj_corr',
'lkj_corr_cholesky',
'logistic',
'loglogistic',
'lognormal',
'multi_gp',
'multi_gp_cholesky',
'multinomial',
'multinomial_logit',
'multi_normal',
'multi_normal_cholesky',
'multi_normal_prec',
'multi_student_cholesky_t',
'multi_student_t',
'multi_student_t_cholesky',
'neg_binomial',
'neg_binomial_2',
'neg_binomial_2_log',
'neg_binomial_2_log_glm',
'normal',
'normal_id_glm',
'ordered_logistic',
'ordered_logistic_glm',
'ordered_probit',
'pareto',
'pareto_type_2',
'poisson',
'poisson_log',
'poisson_log_glm',
'rayleigh',
'scaled_inv_chi_square',
'skew_double_exponential',
'skew_normal',
'std_normal',
'std_normal_log',
'student_t',
'uniform',
'von_mises',
'weibull',
'wiener',
'wishart',
'wishart_cholesky'
];
const BLOCK_COMMENT = hljs.COMMENT(
/\/\*/,
/\*\//,
{
relevance: 0,
contains: [
{
scope: 'doctag',
match: /@(return|param)/
}
]
}
);
const INCLUDE = {
scope: 'meta',
begin: /#include\b/,
end: /$/,
contains: [
{
match: /[a-z][a-z-._]+/,
scope: 'string'
},
hljs.C_LINE_COMMENT_MODE
]
};
const RANGE_CONSTRAINTS = [
"lower",
"upper",
"offset",
"multiplier"
];
return {
name: 'Stan',
aliases: [ 'stanfuncs' ],
keywords: {
$pattern: hljs.IDENT_RE,
title: BLOCKS,
type: TYPES,
keyword: STATEMENTS,
built_in: FUNCTIONS
},
contains: [
hljs.C_LINE_COMMENT_MODE,
INCLUDE,
hljs.HASH_COMMENT_MODE,
BLOCK_COMMENT,
{
scope: 'built_in',
match: /\s(pi|e|sqrt2|log2|log10)(?=\()/,
relevance: 0
},
{
match: regex.concat(/[<,]\s*/, regex.either(...RANGE_CONSTRAINTS), /\s*=/),
keywords: RANGE_CONSTRAINTS
},
{
scope: 'keyword',
match: /\btarget(?=\s*\+=)/,
},
{
// highlights the 'T' in T[,] for only Stan language distributrions
match: [
/~\s*/,
regex.either(...DISTRIBUTIONS),
/(?:\(\))/,
/\s*T(?=\s*\[)/
],
scope: {
2: "built_in",
4: "keyword"
}
},
{
// highlights distributions that end with special endings
scope: 'built_in',
keywords: DISTRIBUTIONS,
begin: regex.concat(/\w*/, regex.either(...DISTRIBUTIONS), /(_lpdf|_lupdf|_lpmf|_cdf|_lcdf|_lccdf|_qf)(?=\s*[\(.*\)])/)
},
{
// highlights distributions after ~
begin: [
/~/,
/\s*/,
regex.concat(regex.either(...DISTRIBUTIONS), /(?=\s*[\(.*\)])/)
],
scope: { 3: "built_in" }
},
{
// highlights user defined distributions after ~
begin: [
/~/,
/\s*\w+(?=\s*[\(.*\)])/,
'(?!.*/\b(' + regex.either(...DISTRIBUTIONS) + ')\b)'
],
scope: { 2: "title.function" }
},
{
// highlights user defined distributions with special endings
scope: 'title.function',
begin: /\w*(_lpdf|_lupdf|_lpmf|_cdf|_lcdf|_lccdf|_qf)(?=\s*[\(.*\)])/
},
{
scope: 'number',
match: regex.concat(
// Comes from @RunDevelopment accessed 11/29/2021 at
// https://github.com/PrismJS/prism/blob/c53ad2e65b7193ab4f03a1797506a54bbb33d5a2/components/prism-stan.js#L56
// start of big noncapture group which
// 1. gets numbers that are by themselves
// 2. numbers that are separated by _
// 3. numbers that are separted by .
/(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)/,
// grabs scientific notation
// grabs complex numbers with i
/(?:[eE][+-]?\d+(?:_\d+)*)?i?(?!\w)/
),
relevance: 0
},
{
scope: 'string',
begin: /"/,
end: /"/
}
]
};
}
var stan_1 = stan;
/*
Language: Stata
Author: Brian Quistorff <bquistorff@gmail.com>
Contributors: Drew McDonald <drewmcdo@gmail.com>
Description: Stata is a general-purpose statistical software package created in 1985 by StataCorp.
Website: https://en.wikipedia.org/wiki/Stata
Category: scientific
*/
/*
This is a fork and modification of Drew McDonald's file (https://github.com/drewmcdonald/stata-highlighting). I have also included a list of builtin commands from https://bugs.kde.org/show_bug.cgi?id=135646.
*/
function stata(hljs) {
return {
name: 'Stata',
aliases: [
'do',
'ado'
],
case_insensitive: true,
keywords: 'if else in foreach for forv forva forval forvalu forvalue forvalues by bys bysort xi quietly qui capture about ac ac_7 acprplot acprplot_7 adjust ado adopath adoupdate alpha ameans an ano anov anova anova_estat anova_terms anovadef aorder ap app appe appen append arch arch_dr arch_estat arch_p archlm areg areg_p args arima arima_dr arima_estat arima_p as asmprobit asmprobit_estat asmprobit_lf asmprobit_mfx__dlg asmprobit_p ass asse asser assert avplot avplot_7 avplots avplots_7 bcskew0 bgodfrey bias binreg bip0_lf biplot bipp_lf bipr_lf bipr_p biprobit bitest bitesti bitowt blogit bmemsize boot bootsamp bootstrap bootstrap_8 boxco_l boxco_p boxcox boxcox_6 boxcox_p bprobit br break brier bro brow brows browse brr brrstat bs bs_7 bsampl_w bsample bsample_7 bsqreg bstat bstat_7 bstat_8 bstrap bstrap_7 bubble bubbleplot ca ca_estat ca_p cabiplot camat canon canon_8 canon_8_p canon_estat canon_p cap caprojection capt captu captur capture cat cc cchart cchart_7 cci cd censobs_table centile cf char chdir checkdlgfiles checkestimationsample checkhlpfiles checksum chelp ci cii cl class classutil clear cli clis clist clo clog clog_lf clog_p clogi clogi_sw clogit clogit_lf clogit_p clogitp clogl_sw cloglog clonevar clslistarray cluster cluster_measures cluster_stop cluster_tree cluster_tree_8 clustermat cmdlog cnr cnre cnreg cnreg_p cnreg_sw cnsreg codebook collaps4 collapse colormult_nb colormult_nw compare compress conf confi confir confirm conren cons const constr constra constrai constrain constraint continue contract copy copyright copysource cor corc corr corr2data corr_anti corr_kmo corr_smc corre correl correla correlat correlate corrgram cou coun count cox cox_p cox_sw coxbase coxhaz coxvar cprplot cprplot_7 crc cret cretu cretur creturn cross cs cscript cscript_log csi ct ct_is ctset ctst_5 ctst_st cttost cumsp cumsp_7 cumul cusum cusum_7 cutil d|0 datasig datasign datasigna datasignat datasignatu datasignatur datasignature datetof db dbeta de dec deco decod decode deff des desc descr descri describ describe destring dfbeta dfgls dfuller di di_g dir dirstats dis discard disp disp_res disp_s displ displa display distinct do doe doed doedi doedit dotplot dotplot_7 dprobit drawnorm drop ds ds_util dstdize duplicates durbina dwstat dydx e|0 ed edi edit egen eivreg emdef en enc enco encod encode eq erase ereg ereg_lf ereg_p ereg_sw ereghet ereghet_glf ereghet_glf_sh ereghet_gp ereghet_ilf ereghet_ilf_sh ereghet_ip eret eretu eretur ereturn err erro error esize est est_cfexist est_cfname est_clickable est_expand est_hold est_table est_unhold est_unholdok estat estat_default estat_summ estat_vce_only esti estimates etodow etof etomdy ex exi exit expand expandcl fac fact facto factor factor_estat factor_p factor_pca_rotated factor_rotate factormat fcast fcast_compute fcast_graph fdades fdadesc fdadescr fdadescri fdadescrib fdadescribe fdasav fdasave fdause fh_st file open file read file close file filefilter fillin find_hlp_file findfile findit findit_7 fit fl fli flis flist for5_0 forest forestplot form forma format fpredict frac_154 frac_adj frac_chk frac_cox frac_ddp frac_dis frac_dv frac_in frac_mun frac_pp frac_pq frac_pv frac_wgt frac_xo fracgen fracplot fracplot_7 fracpoly fracpred fron_ex fron_hn fron_p fron_tn fron_tn2 frontier ftodate ftoe ftomdy ftowdate funnel funnelplot g|0 gamhet_glf gamhet_gp gamhet_ilf gamhet_ip gamma gamma_d2 gamma_p gamma_sw gammahet gdi_hexagon gdi_spokes ge gen gene gener genera generat generate genrank genstd genvmean gettoken gl gladder gladder_7 glim_l01 glim_l02 glim_l03 glim_l04 glim_l05 glim_l06 glim_l07 glim_l08 glim_l09 glim_l10 glim_l11 glim_l12 glim_lf glim_mu glim_nw1 glim_nw2 glim_nw3 glim_p glim_v1 glim_v2 glim_v3 glim_v4 glim_v5 glim_v6 glim_v7 glm glm_6 glm_p glm_sw glmpred glo glob globa global glogit glogit_8 glogit_p gmeans gnbre_lf gnbreg gnbreg_5 gnbreg_p gomp_lf gompe_sw gomper_p gompertz gompertzhet gomphet_glf gomphet_glf_sh gomphet_gp gomphet_ilf gomphet_ilf_sh gomphet_ip gphdot gphpen gphprint gprefs gprobi_p gprobit gprobit_8 gr gr7 gr_copy gr_current gr_db gr_describe gr_dir gr_draw gr_draw_replay gr_drop gr_edit gr_editviewopts gr_example gr_example2 gr_export gr_print gr_qscheme gr_query gr_read gr_rename gr_replay gr_save gr_set gr_setscheme gr_table gr_undo gr_use graph graph7 grebar greigen greigen_7 greigen_8 grmeanby grmeanby_7 gs_fileinfo gs_filetype gs_graphinfo gs_stat gsort gwood h|0 hadimvo hareg hausman haver he heck_d2 heckma_p heckman heckp_lf heckpr_p heckprob hel help hereg hetpr_lf hetpr_p hetprob hettest hexdump hilite hist hist_7 histogram hlogit hlu hmeans hotel hotelling hprobit hreg hsearch icd9 icd9_ff icd9p iis impute imtest inbase include inf infi infil infile infix inp inpu input ins insheet insp inspe inspec inspect integ inten intreg intreg_7 intreg_p intrg2_ll intrg_ll intrg_ll2 ipolate iqreg ir irf irf_create irfm iri is_svy is_svysum isid istdize ivprob_1_lf ivprob_lf ivprobit ivprobit_p ivreg ivreg_footnote ivtob_1_lf ivtob_lf ivtobit ivtobit_p jackknife jacknife jknife jknife_6 jknife_8 jkstat joinby kalarma1 kap kap_3 kapmeier kappa kapwgt kdensity kdensity_7 keep ksm ksmirnov ktau kwallis l|0 la lab labbe labbeplot labe label labelbook ladder levels levelsof leverage lfit lfit_p li lincom line linktest lis list lloghet_glf lloghet_glf_sh lloghet_gp lloghet_ilf lloghet_ilf_sh lloghet_ip llogi_sw llogis_p llogist llogistic llogistichet lnorm_lf lnorm_sw lnorma_p lnormal lnormalhet lnormhet_glf lnormhet_glf_sh lnormhet_gp lnormhet_ilf lnormhet_ilf_sh lnormhet_ip lnskew0 loadingplot loc loca local log logi logis_lf logistic logistic_p logit logit_estat logit_p loglogs logrank loneway lookfor lookup lowess lowess_7 lpredict lrecomp lroc lroc_7 lrtest ls lsens lsens_7 lsens_x lstat ltable ltable_7 ltriang lv lvr2plot lvr2plot_7 m|0 ma mac macr macro makecns man manova manova_estat manova_p manovatest mantel mark markin markout marksample mat mat_capp mat_order mat_put_rr mat_rapp mata mata_clear mata_describe mata_drop mata_matdescribe mata_matsave mata_matuse mata_memory mata_mlib mata_mosave mata_rename mata_which matalabel matcproc matlist matname matr matri matrix matrix_input__dlg matstrik mcc mcci md0_ md1_ md1debug_ md2_ md2debug_ mds mds_estat mds_p mdsconfig mdslong mdsmat mdsshepard mdytoe mdytof me_derd mean means median memory memsize menl meqparse mer merg merge meta mfp mfx mhelp mhodds minbound mixed_ll mixed_ll_reparm mkassert mkdir mkmat mkspline ml ml_5 ml_adjs ml_bhhhs ml_c_d ml_check ml_clear ml_cnt ml_debug ml_defd ml_e0 ml_e0_bfgs ml_e0_cycle ml_e0_dfp ml_e0i ml_e1 ml_e1_bfgs ml_e1_bhhh ml_e1_cycle ml_e1_dfp ml_e2 ml_e2_cycle ml_ebfg0 ml_ebfr0 ml_ebfr1 ml_ebh0q ml_ebhh0 ml_ebhr0 ml_ebr0i ml_ecr0i ml_edfp0 ml_edfr0 ml_edfr1 ml_edr0i ml_eds ml_eer0i ml_egr0i ml_elf ml_elf_bfgs ml_elf_bhhh ml_elf_cycle ml_elf_dfp ml_elfi ml_elfs ml_enr0i ml_enrr0 ml_erdu0 ml_erdu0_bfgs ml_erdu0_bhhh ml_erdu0_bhhhq ml_erdu0_cycle ml_erdu0_dfp ml_erdu0_nrbfgs ml_exde ml_footnote ml_geqnr ml_grad0 ml_graph ml_hbhhh ml_hd0 ml_hold ml_init ml_inv ml_log ml_max ml_mlout ml_mlout_8 ml_model ml_nb0 ml_opt ml_p ml_plot ml_query ml_rdgrd ml_repor ml_s_e ml_score ml_searc ml_technique ml_unhold mleval mlf_ mlmatbysum mlmatsum mlog mlogi mlogit mlogit_footnote mlogit_p mlopts mlsum mlvecsum mnl0_ mor more mov move mprobit mprobit_lf mprobit_p mrdu0_ mrdu1_ mvdecode mvencode mvreg mvreg_estat n|0 nbreg nbreg_al nbreg_lf nbreg_p nbreg_sw nestreg net newey newey_7 newey_p news nl nl_7 nl_9 nl_9_p nl_p nl_p_7 nlcom nlcom_p nlexp2 nlexp2_7 nlexp2a nlexp2a_7 nlexp3 nlexp3_7 nlgom3 nlgom3_7 nlgom4 nlgom4_7 nlinit nllog3 nllog3_7 nllog4 nllog4_7 nlog_rd nlogit nlogit_p nlogitgen nlogittree nlpred no nobreak noi nois noisi noisil noisily note notes notes_dlg nptrend numlabel numlist odbc old_ver olo olog ologi ologi_sw ologit ologit_p ologitp on one onew onewa oneway op_colnm op_comp op_diff op_inv op_str opr opro oprob oprob_sw oprobi oprobi_p oprobit oprobitp opts_exclusive order orthog orthpoly ou out outf outfi outfil outfile outs outsh outshe outshee outsheet ovtest pac pac_7 palette parse parse_dissim pause pca pca_8 pca_display pca_estat pca_p pca_rotate pcamat pchart pchart_7 pchi pchi_7 pcorr pctile pentium pergram pergram_7 permute permute_8 personal peto_st pkcollapse pkcross pkequiv pkexamine pkexamine_7 pkshape pksumm pksumm_7 pl plo plot plugin pnorm pnorm_7 poisgof poiss_lf poiss_sw poisso_p poisson poisson_estat post postclose postfile postutil pperron pr prais prais_e prais_e2 prais_p predict predictnl preserve print pro prob probi probit probit_estat probit_p proc_time procoverlay procrustes procrustes_estat procrustes_p profiler prog progr progra program prop proportion prtest prtesti pwcorr pwd q\\s qby qbys qchi qchi_7 qladder qladder_7 qnorm qnorm_7 qqplot qqplot_7 qreg qreg_c qreg_p qreg_sw qu quadchk quantile quantile_7 que quer query range ranksum ratio rchart rchart_7 rcof recast reclink recode reg reg3 reg3_p regdw regr regre regre_p2 regres regres_p regress regress_estat regriv_p remap ren rena renam rename renpfix repeat replace report reshape restore ret retu retur return rm rmdir robvar roccomp roccomp_7 roccomp_8 rocf_lf rocfit rocfit_8 rocgold rocplot rocplot_7 roctab roctab_7 rolling rologit rologit_p rot rota rotat rotate rotatemat rreg rreg_p ru run runtest rvfplot rvfplot_7 rvpplot rvpplot_7 sa safesum sample sampsi sav save savedresults saveold sc sca scal scala scalar scatter scm_mine sco scob_lf scob_p scobi_sw scobit scor score scoreplot scoreplot_help scree screeplot screeplot_help sdtest sdtesti se search separate seperate serrbar serrbar_7 serset set set_defaults sfrancia sh she shel shell shewhart shewhart_7 signestimationsample signrank signtest simul simul_7 simulate simulate_8 sktest sleep slogit slogit_d2 slogit_p smooth snapspan so sor sort spearman spikeplot spikeplot_7 spikeplt spline_x split sqreg sqreg_p sret sretu sretur sreturn ssc st st_ct st_hc st_hcd st_hcd_sh st_is st_issys st_note st_promo st_set st_show st_smpl st_subid stack statsby statsby_8 stbase stci stci_7 stcox stcox_estat stcox_fr stcox_fr_ll stcox_p stcox_sw stcoxkm stcoxkm_7 stcstat stcurv stcurve stcurve_7 stdes stem stepwise stereg stfill stgen stir stjoin stmc stmh stphplot stphplot_7 stphtest stphtest_7 stptime strate strate_7 streg streg_sw streset sts sts_7 stset stsplit stsum sttocc sttoct stvary stweib su suest suest_8 sum summ summa summar summari summariz summarize sunflower sureg survcurv survsum svar svar_p svmat svy svy_disp svy_dreg svy_est svy_est_7 svy_estat svy_get svy_gnbreg_p svy_head svy_header svy_heckman_p svy_heckprob_p svy_intreg_p svy_ivreg_p svy_logistic_p svy_logit_p svy_mlogit_p svy_nbreg_p svy_ologit_p svy_oprobit_p svy_poisson_p svy_probit_p svy_regress_p svy_sub svy_sub_7 svy_x svy_x_7 svy_x_p svydes svydes_8 svygen svygnbreg svyheckman svyheckprob svyintreg svyintreg_7 svyintrg svyivreg svylc svylog_p svylogit svymarkout svymarkout_8 svymean svymlog svymlogit svynbreg svyolog svyologit svyoprob svyoprobit svyopts svypois svypois_7 svypoisson svyprobit svyprobt svyprop svyprop_7 svyratio svyreg svyreg_p svyregress svyset svyset_7 svyset_8 svytab svytab_7 svytest svytotal sw sw_8 swcnreg swcox swereg swilk swlogis swlogit swologit swoprbt swpois swprobit swqreg swtobit swweib symmetry symmi symplot symplot_7 syntax sysdescribe sysdir sysuse szroeter ta tab tab1 tab2 tab_or tabd tabdi tabdis tabdisp tabi table tabodds tabodds_7 tabstat tabu tabul tabula tabulat tabulate te tempfile tempname tempvar tes test testnl testparm teststd tetrachoric time_it timer tis tob tobi tobit tobit_p tobit_sw token tokeni tokeniz tokenize tostring total translate translator transmap treat_ll treatr_p treatreg trim trimfill trnb_cons trnb_mean trpoiss_d2 trunc_ll truncr_p truncreg tsappend tset tsfill tsline tsline_ex tsreport tsrevar tsrline tsset tssmooth tsunab ttest ttesti tut_chk tut_wait tutorial tw tware_st two twoway twoway__fpfit_serset twoway__function_gen twoway__histogram_gen twoway__ipoint_serset twoway__ipoints_serset twoway__kdensity_gen twoway__lfit_serset twoway__normgen_gen twoway__pci_serset twoway__qfit_serset twoway__scatteri_serset twoway__sunflower_gen twoway_ksm_serset ty typ type typeof u|0 unab unabbrev unabcmd update us use uselabel var var_mkcompanion var_p varbasic varfcast vargranger varirf varirf_add varirf_cgraph varirf_create varirf_ctable varirf_describe varirf_dir varirf_drop varirf_erase varirf_graph varirf_ograph varirf_rename varirf_set varirf_table varlist varlmar varnorm varsoc varstable varstable_w varstable_w2 varwle vce vec vec_fevd vec_mkphi vec_p vec_p_w vecirf_create veclmar veclmar_w vecnorm vecnorm_w vecrank vecstable verinst vers versi versio version view viewsource vif vwls wdatetof webdescribe webseek webuse weib1_lf weib2_lf weib_lf weib_lf0 weibhet_glf weibhet_glf_sh weibhet_glfa weibhet_glfa_sh weibhet_gp weibhet_ilf weibhet_ilf_sh weibhet_ilfa weibhet_ilfa_sh weibhet_ip weibu_sw weibul_p weibull weibull_c weibull_s weibullhet wh whelp whi which whil while wilc_st wilcoxon win wind windo window winexec wntestb wntestb_7 wntestq xchart xchart_7 xcorr xcorr_7 xi xi_6 xmlsav xmlsave xmluse xpose xsh xshe xshel xshell xt_iis xt_tis xtab_p xtabond xtbin_p xtclog xtcloglog xtcloglog_8 xtcloglog_d2 xtcloglog_pa_p xtcloglog_re_p xtcnt_p xtcorr xtdata xtdes xtfront_p xtfrontier xtgee xtgee_elink xtgee_estat xtgee_makeivar xtgee_p xtgee_plink xtgls xtgls_p xthaus xthausman xtht_p xthtaylor xtile xtint_p xtintreg xtintreg_8 xtintreg_d2 xtintreg_p xtivp_1 xtivp_2 xtivreg xtline xtline_ex xtlogit xtlogit_8 xtlogit_d2 xtlogit_fe_p xtlogit_pa_p xtlogit_re_p xtmixed xtmixed_estat xtmixed_p xtnb_fe xtnb_lf xtnbreg xtnbreg_pa_p xtnbreg_refe_p xtpcse xtpcse_p xtpois xtpoisson xtpoisson_d2 xtpoisson_pa_p xtpoisson_refe_p xtpred xtprobit xtprobit_8 xtprobit_d2 xtprobit_re_p xtps_fe xtps_lf xtps_ren xtps_ren_8 xtrar_p xtrc xtrc_p xtrchh xtrefe_p xtreg xtreg_be xtreg_fe xtreg_ml xtreg_pa_p xtreg_re xtregar xtrere_p xtset xtsf_ll xtsf_llti xtsum xttab xttest0 xttobit xttobit_8 xttobit_p xttrans yx yxview__barlike_draw yxview_area_draw yxview_bar_draw yxview_dot_draw yxview_dropline_draw yxview_function_draw yxview_iarrow_draw yxview_ilabels_draw yxview_normal_draw yxview_pcarrow_draw yxview_pcbarrow_draw yxview_pccapsym_draw yxview_pcscatter_draw yxview_pcspike_draw yxview_rarea_draw yxview_rbar_draw yxview_rbarm_draw yxview_rcap_draw yxview_rcapsym_draw yxview_rconnected_draw yxview_rline_draw yxview_rscatter_draw yxview_rspike_draw yxview_spike_draw yxview_sunflower_draw zap_s zinb zinb_llf zinb_plf zip zip_llf zip_p zip_plf zt_ct_5 zt_hc_5 zt_hcd_5 zt_is_5 zt_iss_5 zt_sho_5 zt_smp_5 ztbase_5 ztcox_5 ztdes_5 ztereg_5 ztfill_5 ztgen_5 ztir_5 ztjoin_5 ztnb ztnb_p ztp ztp_p zts_5 ztset_5 ztspli_5 ztsum_5 zttoct_5 ztvary_5 ztweib_5',
contains: [
{
className: 'symbol',
begin: /`[a-zA-Z0-9_]+'/
},
{
className: 'variable',
begin: /\$\{?[a-zA-Z0-9_]+\}?/,
relevance: 0
},
{
className: 'string',
variants: [
{ begin: '`"[^\r\n]*?"\'' },
{ begin: '"[^\r\n"]*"' }
]
},
{
className: 'built_in',
variants: [ { begin: '\\b(abs|acos|asin|atan|atan2|atanh|ceil|cloglog|comb|cos|digamma|exp|floor|invcloglog|invlogit|ln|lnfact|lnfactorial|lngamma|log|log10|max|min|mod|reldif|round|sign|sin|sqrt|sum|tan|tanh|trigamma|trunc|betaden|Binomial|binorm|binormal|chi2|chi2tail|dgammapda|dgammapdada|dgammapdadx|dgammapdx|dgammapdxdx|F|Fden|Ftail|gammaden|gammap|ibeta|invbinomial|invchi2|invchi2tail|invF|invFtail|invgammap|invibeta|invnchi2|invnFtail|invnibeta|invnorm|invnormal|invttail|nbetaden|nchi2|nFden|nFtail|nibeta|norm|normal|normalden|normd|npnchi2|tden|ttail|uniform|abbrev|char|index|indexnot|length|lower|ltrim|match|plural|proper|real|regexm|regexr|regexs|reverse|rtrim|string|strlen|strlower|strltrim|strmatch|strofreal|strpos|strproper|strreverse|strrtrim|strtrim|strupper|subinstr|subinword|substr|trim|upper|word|wordcount|_caller|autocode|byteorder|chop|clip|cond|e|epsdouble|epsfloat|group|inlist|inrange|irecode|matrix|maxbyte|maxdouble|maxfloat|maxint|maxlong|mi|minbyte|mindouble|minfloat|minint|minlong|missing|r|recode|replay|return|s|scalar|d|date|day|dow|doy|halfyear|mdy|month|quarter|week|year|d|daily|dofd|dofh|dofm|dofq|dofw|dofy|h|halfyearly|hofd|m|mofd|monthly|q|qofd|quarterly|tin|twithin|w|weekly|wofd|y|yearly|yh|ym|yofd|yq|yw|cholesky|colnumb|colsof|corr|det|diag|diag0cnt|el|get|hadamard|I|inv|invsym|issym|issymmetric|J|matmissing|matuniform|mreldif|nullmat|rownumb|rowsof|sweep|syminv|trace|vec|vecdiag)(?=\\()' } ]
},
hljs.COMMENT('^[ \t]*\\*.*$', false),
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]
};
}
var stata_1 = stata;
/*
Language: STEP Part 21
Contributors: Adam Joseph Cook <adam.joseph.cook@gmail.com>
Description: Syntax highlighter for STEP Part 21 files (ISO 10303-21).
Website: https://en.wikipedia.org/wiki/ISO_10303-21
*/
function step21(hljs) {
const STEP21_IDENT_RE = '[A-Z_][A-Z0-9_.]*';
const STEP21_KEYWORDS = {
$pattern: STEP21_IDENT_RE,
keyword: [
"HEADER",
"ENDSEC",
"DATA"
]
};
const STEP21_START = {
className: 'meta',
begin: 'ISO-10303-21;',
relevance: 10
};
const STEP21_CLOSE = {
className: 'meta',
begin: 'END-ISO-10303-21;',
relevance: 10
};
return {
name: 'STEP Part 21',
aliases: [
'p21',
'step',
'stp'
],
case_insensitive: true, // STEP 21 is case insensitive in theory, in practice all non-comments are capitalized.
keywords: STEP21_KEYWORDS,
contains: [
STEP21_START,
STEP21_CLOSE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.COMMENT('/\\*\\*!', '\\*/'),
hljs.C_NUMBER_MODE,
hljs.inherit(hljs.APOS_STRING_MODE, { illegal: null }),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }),
{
className: 'string',
begin: "'",
end: "'"
},
{
className: 'symbol',
variants: [
{
begin: '#',
end: '\\d+',
illegal: '\\W'
}
]
}
]
};
}
var step21_1 = step21;
const MODES = (hljs) => {
return {
IMPORTANT: {
scope: 'meta',
begin: '!important'
},
BLOCK_COMMENT: hljs.C_BLOCK_COMMENT_MODE,
HEXCOLOR: {
scope: 'number',
begin: /#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/
},
FUNCTION_DISPATCH: {
className: "built_in",
begin: /[\w-]+(?=\()/
},
ATTRIBUTE_SELECTOR_MODE: {
scope: 'selector-attr',
begin: /\[/,
end: /\]/,
illegal: '$',
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
},
CSS_NUMBER_MODE: {
scope: 'number',
begin: hljs.NUMBER_RE + '(' +
'%|em|ex|ch|rem' +
'|vw|vh|vmin|vmax' +
'|cm|mm|in|pt|pc|px' +
'|deg|grad|rad|turn' +
'|s|ms' +
'|Hz|kHz' +
'|dpi|dpcm|dppx' +
')?',
relevance: 0
},
CSS_VARIABLE: {
className: "attr",
begin: /--[A-Za-z_][A-Za-z0-9_-]*/
}
};
};
const TAGS = [
'a',
'abbr',
'address',
'article',
'aside',
'audio',
'b',
'blockquote',
'body',
'button',
'canvas',
'caption',
'cite',
'code',
'dd',
'del',
'details',
'dfn',
'div',
'dl',
'dt',
'em',
'fieldset',
'figcaption',
'figure',
'footer',
'form',
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'header',
'hgroup',
'html',
'i',
'iframe',
'img',
'input',
'ins',
'kbd',
'label',
'legend',
'li',
'main',
'mark',
'menu',
'nav',
'object',
'ol',
'p',
'q',
'quote',
'samp',
'section',
'span',
'strong',
'summary',
'sup',
'table',
'tbody',
'td',
'textarea',
'tfoot',
'th',
'thead',
'time',
'tr',
'ul',
'var',
'video'
];
const MEDIA_FEATURES = [
'any-hover',
'any-pointer',
'aspect-ratio',
'color',
'color-gamut',
'color-index',
'device-aspect-ratio',
'device-height',
'device-width',
'display-mode',
'forced-colors',
'grid',
'height',
'hover',
'inverted-colors',
'monochrome',
'orientation',
'overflow-block',
'overflow-inline',
'pointer',
'prefers-color-scheme',
'prefers-contrast',
'prefers-reduced-motion',
'prefers-reduced-transparency',
'resolution',
'scan',
'scripting',
'update',
'width',
// TODO: find a better solution?
'min-width',
'max-width',
'min-height',
'max-height'
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-classes
const PSEUDO_CLASSES = [
'active',
'any-link',
'blank',
'checked',
'current',
'default',
'defined',
'dir', // dir()
'disabled',
'drop',
'empty',
'enabled',
'first',
'first-child',
'first-of-type',
'fullscreen',
'future',
'focus',
'focus-visible',
'focus-within',
'has', // has()
'host', // host or host()
'host-context', // host-context()
'hover',
'indeterminate',
'in-range',
'invalid',
'is', // is()
'lang', // lang()
'last-child',
'last-of-type',
'left',
'link',
'local-link',
'not', // not()
'nth-child', // nth-child()
'nth-col', // nth-col()
'nth-last-child', // nth-last-child()
'nth-last-col', // nth-last-col()
'nth-last-of-type', //nth-last-of-type()
'nth-of-type', //nth-of-type()
'only-child',
'only-of-type',
'optional',
'out-of-range',
'past',
'placeholder-shown',
'read-only',
'read-write',
'required',
'right',
'root',
'scope',
'target',
'target-within',
'user-invalid',
'valid',
'visited',
'where' // where()
];
// https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-elements
const PSEUDO_ELEMENTS = [
'after',
'backdrop',
'before',
'cue',
'cue-region',
'first-letter',
'first-line',
'grammar-error',
'marker',
'part',
'placeholder',
'selection',
'slotted',
'spelling-error'
];
const ATTRIBUTES = [
'align-content',
'align-items',
'align-self',
'all',
'animation',
'animation-delay',
'animation-direction',
'animation-duration',
'animation-fill-mode',
'animation-iteration-count',
'animation-name',
'animation-play-state',
'animation-timing-function',
'backface-visibility',
'background',
'background-attachment',
'background-blend-mode',
'background-clip',
'background-color',
'background-image',
'background-origin',
'background-position',
'background-repeat',
'background-size',
'block-size',
'border',
'border-block',
'border-block-color',
'border-block-end',
'border-block-end-color',
'border-block-end-style',
'border-block-end-width',
'border-block-start',
'border-block-start-color',
'border-block-start-style',
'border-block-start-width',
'border-block-style',
'border-block-width',
'border-bottom',
'border-bottom-color',
'border-bottom-left-radius',
'border-bottom-right-radius',
'border-bottom-style',
'border-bottom-width',
'border-collapse',
'border-color',
'border-image',
'border-image-outset',
'border-image-repeat',
'border-image-slice',
'border-image-source',
'border-image-width',
'border-inline',
'border-inline-color',
'border-inline-end',
'border-inline-end-color',
'border-inline-end-style',
'border-inline-end-width',
'border-inline-start',
'border-inline-start-color',
'border-inline-start-style',
'border-inline-start-width',
'border-inline-style',
'border-inline-width',
'border-left',
'border-left-color',
'border-left-style',
'border-left-width',
'border-radius',
'border-right',
'border-right-color',
'border-right-style',
'border-right-width',
'border-spacing',
'border-style',
'border-top',
'border-top-color',
'border-top-left-radius',
'border-top-right-radius',
'border-top-style',
'border-top-width',
'border-width',
'bottom',
'box-decoration-break',
'box-shadow',
'box-sizing',
'break-after',
'break-before',
'break-inside',
'caption-side',
'caret-color',
'clear',
'clip',
'clip-path',
'clip-rule',
'color',
'column-count',
'column-fill',
'column-gap',
'column-rule',
'column-rule-color',
'column-rule-style',
'column-rule-width',
'column-span',
'column-width',
'columns',
'contain',
'content',
'content-visibility',
'counter-increment',
'counter-reset',
'cue',
'cue-after',
'cue-before',
'cursor',
'direction',
'display',
'empty-cells',
'filter',
'flex',
'flex-basis',
'flex-direction',
'flex-flow',
'flex-grow',
'flex-shrink',
'flex-wrap',
'float',
'flow',
'font',
'font-display',
'font-family',
'font-feature-settings',
'font-kerning',
'font-language-override',
'font-size',
'font-size-adjust',
'font-smoothing',
'font-stretch',
'font-style',
'font-synthesis',
'font-variant',
'font-variant-caps',
'font-variant-east-asian',
'font-variant-ligatures',
'font-variant-numeric',
'font-variant-position',
'font-variation-settings',
'font-weight',
'gap',
'glyph-orientation-vertical',
'grid',
'grid-area',
'grid-auto-columns',
'grid-auto-flow',
'grid-auto-rows',
'grid-column',
'grid-column-end',
'grid-column-start',
'grid-gap',
'grid-row',
'grid-row-end',
'grid-row-start',
'grid-template',
'grid-template-areas',
'grid-template-columns',
'grid-template-rows',
'hanging-punctuation',
'height',
'hyphens',
'icon',
'image-orientation',
'image-rendering',
'image-resolution',
'ime-mode',
'inline-size',
'isolation',
'justify-content',
'left',
'letter-spacing',
'line-break',
'line-height',
'list-style',
'list-style-image',
'list-style-position',
'list-style-type',
'margin',
'margin-block',
'margin-block-end',
'margin-block-start',
'margin-bottom',
'margin-inline',
'margin-inline-end',
'margin-inline-start',
'margin-left',
'margin-right',
'margin-top',
'marks',
'mask',
'mask-border',
'mask-border-mode',
'mask-border-outset',
'mask-border-repeat',
'mask-border-slice',
'mask-border-source',
'mask-border-width',
'mask-clip',
'mask-composite',
'mask-image',
'mask-mode',
'mask-origin',
'mask-position',
'mask-repeat',
'mask-size',
'mask-type',
'max-block-size',
'max-height',
'max-inline-size',
'max-width',
'min-block-size',
'min-height',
'min-inline-size',
'min-width',
'mix-blend-mode',
'nav-down',
'nav-index',
'nav-left',
'nav-right',
'nav-up',
'none',
'normal',
'object-fit',
'object-position',
'opacity',
'order',
'orphans',
'outline',
'outline-color',
'outline-offset',
'outline-style',
'outline-width',
'overflow',
'overflow-wrap',
'overflow-x',
'overflow-y',
'padding',
'padding-block',
'padding-block-end',
'padding-block-start',
'padding-bottom',
'padding-inline',
'padding-inline-end',
'padding-inline-start',
'padding-left',
'padding-right',
'padding-top',
'page-break-after',
'page-break-before',
'page-break-inside',
'pause',
'pause-after',
'pause-before',
'perspective',
'perspective-origin',
'pointer-events',
'position',
'quotes',
'resize',
'rest',
'rest-after',
'rest-before',
'right',
'row-gap',
'scroll-margin',
'scroll-margin-block',
'scroll-margin-block-end',
'scroll-margin-block-start',
'scroll-margin-bottom',
'scroll-margin-inline',
'scroll-margin-inline-end',
'scroll-margin-inline-start',
'scroll-margin-left',
'scroll-margin-right',
'scroll-margin-top',
'scroll-padding',
'scroll-padding-block',
'scroll-padding-block-end',
'scroll-padding-block-start',
'scroll-padding-bottom',
'scroll-padding-inline',
'scroll-padding-inline-end',
'scroll-padding-inline-start',
'scroll-padding-left',
'scroll-padding-right',
'scroll-padding-top',
'scroll-snap-align',
'scroll-snap-stop',
'scroll-snap-type',
'scrollbar-color',
'scrollbar-gutter',
'scrollbar-width',
'shape-image-threshold',
'shape-margin',
'shape-outside',
'speak',
'speak-as',
'src', // @font-face
'tab-size',
'table-layout',
'text-align',
'text-align-all',
'text-align-last',
'text-combine-upright',
'text-decoration',
'text-decoration-color',
'text-decoration-line',
'text-decoration-style',
'text-emphasis',
'text-emphasis-color',
'text-emphasis-position',
'text-emphasis-style',
'text-indent',
'text-justify',
'text-orientation',
'text-overflow',
'text-rendering',
'text-shadow',
'text-transform',
'text-underline-position',
'top',
'transform',
'transform-box',
'transform-origin',
'transform-style',
'transition',
'transition-delay',
'transition-duration',
'transition-property',
'transition-timing-function',
'unicode-bidi',
'vertical-align',
'visibility',
'voice-balance',
'voice-duration',
'voice-family',
'voice-pitch',
'voice-range',
'voice-rate',
'voice-stress',
'voice-volume',
'white-space',
'widows',
'width',
'will-change',
'word-break',
'word-spacing',
'word-wrap',
'writing-mode',
'z-index'
// reverse makes sure longer attributes `font-weight` are matched fully
// instead of getting false positives on say `font`
].reverse();
/*
Language: Stylus
Author: Bryant Williams <b.n.williams@gmail.com>
Description: Stylus is an expressive, robust, feature-rich CSS language built for nodejs.
Website: https://github.com/stylus/stylus
Category: css, web
*/
/** @type LanguageFn */
function stylus(hljs) {
const modes = MODES(hljs);
const AT_MODIFIERS = "and or not only";
const VARIABLE = {
className: 'variable',
begin: '\\$' + hljs.IDENT_RE
};
const AT_KEYWORDS = [
'charset',
'css',
'debug',
'extend',
'font-face',
'for',
'import',
'include',
'keyframes',
'media',
'mixin',
'page',
'warn',
'while'
];
const LOOKAHEAD_TAG_END = '(?=[.\\s\\n[:,(])';
// illegals
const ILLEGAL = [
'\\?',
'(\\bReturn\\b)', // monkey
'(\\bEnd\\b)', // monkey
'(\\bend\\b)', // vbscript
'(\\bdef\\b)', // gradle
';', // a whole lot of languages
'#\\s', // markdown
'\\*\\s', // markdown
'===\\s', // markdown
'\\|',
'%' // prolog
];
return {
name: 'Stylus',
aliases: [ 'styl' ],
case_insensitive: false,
keywords: 'if else for in',
illegal: '(' + ILLEGAL.join('|') + ')',
contains: [
// strings
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
// comments
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
// hex colors
modes.HEXCOLOR,
// class tag
{
begin: '\\.[a-zA-Z][a-zA-Z0-9_-]*' + LOOKAHEAD_TAG_END,
className: 'selector-class'
},
// id tag
{
begin: '#[a-zA-Z][a-zA-Z0-9_-]*' + LOOKAHEAD_TAG_END,
className: 'selector-id'
},
// tags
{
begin: '\\b(' + TAGS.join('|') + ')' + LOOKAHEAD_TAG_END,
className: 'selector-tag'
},
// psuedo selectors
{
className: 'selector-pseudo',
begin: '&?:(' + PSEUDO_CLASSES.join('|') + ')' + LOOKAHEAD_TAG_END
},
{
className: 'selector-pseudo',
begin: '&?:(:)?(' + PSEUDO_ELEMENTS.join('|') + ')' + LOOKAHEAD_TAG_END
},
modes.ATTRIBUTE_SELECTOR_MODE,
{
className: "keyword",
begin: /@media/,
starts: {
end: /[{;}]/,
keywords: {
$pattern: /[a-z-]+/,
keyword: AT_MODIFIERS,
attribute: MEDIA_FEATURES.join(" ")
},
contains: [ modes.CSS_NUMBER_MODE ]
}
},
// @ keywords
{
className: 'keyword',
begin: '\@((-(o|moz|ms|webkit)-)?(' + AT_KEYWORDS.join('|') + '))\\b'
},
// variables
VARIABLE,
// dimension
modes.CSS_NUMBER_MODE,
// functions
// - only from beginning of line + whitespace
{
className: 'function',
begin: '^[a-zA-Z][a-zA-Z0-9_\-]*\\(.*\\)',
illegal: '[\\n]',
returnBegin: true,
contains: [
{
className: 'title',
begin: '\\b[a-zA-Z][a-zA-Z0-9_\-]*'
},
{
className: 'params',
begin: /\(/,
end: /\)/,
contains: [
modes.HEXCOLOR,
VARIABLE,
hljs.APOS_STRING_MODE,
modes.CSS_NUMBER_MODE,
hljs.QUOTE_STRING_MODE
]
}
]
},
// css variables
modes.CSS_VARIABLE,
// attributes
// - only from beginning of line + whitespace
// - must have whitespace after it
{
className: 'attribute',
begin: '\\b(' + ATTRIBUTES.join('|') + ')\\b',
starts: {
// value container
end: /;|$/,
contains: [
modes.HEXCOLOR,
VARIABLE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
modes.CSS_NUMBER_MODE,
hljs.C_BLOCK_COMMENT_MODE,
modes.IMPORTANT,
modes.FUNCTION_DISPATCH
],
illegal: /\./,
relevance: 0
}
},
modes.FUNCTION_DISPATCH
]
};
}
var stylus_1 = stylus;
/*
Language: SubUnit
Author: Sergey Bronnikov <sergeyb@bronevichok.ru>
Website: https://pypi.org/project/python-subunit/
*/
function subunit(hljs) {
const DETAILS = {
className: 'string',
begin: '\\[\n(multipart)?',
end: '\\]\n'
};
const TIME = {
className: 'string',
begin: '\\d{4}-\\d{2}-\\d{2}(\\s+)\\d{2}:\\d{2}:\\d{2}\.\\d+Z'
};
const PROGRESSVALUE = {
className: 'string',
begin: '(\\+|-)\\d+'
};
const KEYWORDS = {
className: 'keyword',
relevance: 10,
variants: [
{ begin: '^(test|testing|success|successful|failure|error|skip|xfail|uxsuccess)(:?)\\s+(test)?' },
{ begin: '^progress(:?)(\\s+)?(pop|push)?' },
{ begin: '^tags:' },
{ begin: '^time:' }
]
};
return {
name: 'SubUnit',
case_insensitive: true,
contains: [
DETAILS,
TIME,
PROGRESSVALUE,
KEYWORDS
]
};
}
var subunit_1 = subunit;
/**
* @param {string} value
* @returns {RegExp}
* */
/**
* @param {RegExp | string } re
* @returns {string}
*/
function source(re) {
if (!re) return null;
if (typeof re === "string") return re;
return re.source;
}
/**
* @param {RegExp | string } re
* @returns {string}
*/
function lookahead(re) {
return concat('(?=', re, ')');
}
/**
* @param {...(RegExp | string) } args
* @returns {string}
*/
function concat(...args) {
const joined = args.map((x) => source(x)).join("");
return joined;
}
/**
* @param { Array<string | RegExp | Object> } args
* @returns {object}
*/
function stripOptionsFromArgs(args) {
const opts = args[args.length - 1];
if (typeof opts === 'object' && opts.constructor === Object) {
args.splice(args.length - 1, 1);
return opts;
} else {
return {};
}
}
/** @typedef { {capture?: boolean} } RegexEitherOptions */
/**
* Any of the passed expresssions may match
*
* Creates a huge this | this | that | that match
* @param {(RegExp | string)[] | [...(RegExp | string)[], RegexEitherOptions]} args
* @returns {string}
*/
function either(...args) {
/** @type { object & {capture?: boolean} } */
const opts = stripOptionsFromArgs(args);
const joined = '('
+ (opts.capture ? "" : "?:")
+ args.map((x) => source(x)).join("|") + ")";
return joined;
}
const keywordWrapper = keyword => concat(
/\b/,
keyword,
/\w$/.test(keyword) ? /\b/ : /\B/
);
// Keywords that require a leading dot.
const dotKeywords = [
'Protocol', // contextual
'Type' // contextual
].map(keywordWrapper);
// Keywords that may have a leading dot.
const optionalDotKeywords = [
'init',
'self'
].map(keywordWrapper);
// should register as keyword, not type
const keywordTypes = [
'Any',
'Self'
];
// Regular keywords and literals.
const keywords = [
// strings below will be fed into the regular `keywords` engine while regex
// will result in additional modes being created to scan for those keywords to
// avoid conflicts with other rules
'actor',
'any', // contextual
'associatedtype',
'async',
'await',
/as\?/, // operator
/as!/, // operator
'as', // operator
'borrowing', // contextual
'break',
'case',
'catch',
'class',
'consume', // contextual
'consuming', // contextual
'continue',
'convenience', // contextual
'copy', // contextual
'default',
'defer',
'deinit',
'didSet', // contextual
'distributed',
'do',
'dynamic', // contextual
'each',
'else',
'enum',
'extension',
'fallthrough',
/fileprivate\(set\)/,
'fileprivate',
'final', // contextual
'for',
'func',
'get', // contextual
'guard',
'if',
'import',
'indirect', // contextual
'infix', // contextual
/init\?/,
/init!/,
'inout',
/internal\(set\)/,
'internal',
'in',
'is', // operator
'isolated', // contextual
'nonisolated', // contextual
'lazy', // contextual
'let',
'macro',
'mutating', // contextual
'nonmutating', // contextual
/open\(set\)/, // contextual
'open', // contextual
'operator',
'optional', // contextual
'override', // contextual
'postfix', // contextual
'precedencegroup',
'prefix', // contextual
/private\(set\)/,
'private',
'protocol',
/public\(set\)/,
'public',
'repeat',
'required', // contextual
'rethrows',
'return',
'set', // contextual
'some', // contextual
'static',
'struct',
'subscript',
'super',
'switch',
'throws',
'throw',
/try\?/, // operator
/try!/, // operator
'try', // operator
'typealias',
/unowned\(safe\)/, // contextual
/unowned\(unsafe\)/, // contextual
'unowned', // contextual
'var',
'weak', // contextual
'where',
'while',
'willSet' // contextual
];
// NOTE: Contextual keywords are reserved only in specific contexts.
// Ideally, these should be matched using modes to avoid false positives.
// Literals.
const literals = [
'false',
'nil',
'true'
];
// Keywords used in precedence groups.
const precedencegroupKeywords = [
'assignment',
'associativity',
'higherThan',
'left',
'lowerThan',
'none',
'right'
];
// Keywords that start with a number sign (#).
// #(un)available is handled separately.
const numberSignKeywords = [
'#colorLiteral',
'#column',
'#dsohandle',
'#else',
'#elseif',
'#endif',
'#error',
'#file',
'#fileID',
'#fileLiteral',
'#filePath',
'#function',
'#if',
'#imageLiteral',
'#keyPath',
'#line',
'#selector',
'#sourceLocation',
'#warning'
];
// Global functions in the Standard Library.
const builtIns = [
'abs',
'all',
'any',
'assert',
'assertionFailure',
'debugPrint',
'dump',
'fatalError',
'getVaList',
'isKnownUniquelyReferenced',
'max',
'min',
'numericCast',
'pointwiseMax',
'pointwiseMin',
'precondition',
'preconditionFailure',
'print',
'readLine',
'repeatElement',
'sequence',
'stride',
'swap',
'swift_unboxFromSwiftValueWithType',
'transcode',
'type',
'unsafeBitCast',
'unsafeDowncast',
'withExtendedLifetime',
'withUnsafeMutablePointer',
'withUnsafePointer',
'withVaList',
'withoutActuallyEscaping',
'zip'
];
// Valid first characters for operators.
const operatorHead = either(
/[/=\-+!*%<>&|^~?]/,
/[\u00A1-\u00A7]/,
/[\u00A9\u00AB]/,
/[\u00AC\u00AE]/,
/[\u00B0\u00B1]/,
/[\u00B6\u00BB\u00BF\u00D7\u00F7]/,
/[\u2016-\u2017]/,
/[\u2020-\u2027]/,
/[\u2030-\u203E]/,
/[\u2041-\u2053]/,
/[\u2055-\u205E]/,
/[\u2190-\u23FF]/,
/[\u2500-\u2775]/,
/[\u2794-\u2BFF]/,
/[\u2E00-\u2E7F]/,
/[\u3001-\u3003]/,
/[\u3008-\u3020]/,
/[\u3030]/
);
// Valid characters for operators.
const operatorCharacter = either(
operatorHead,
/[\u0300-\u036F]/,
/[\u1DC0-\u1DFF]/,
/[\u20D0-\u20FF]/,
/[\uFE00-\uFE0F]/,
/[\uFE20-\uFE2F]/
// TODO: The following characters are also allowed, but the regex isn't supported yet.
// /[\u{E0100}-\u{E01EF}]/u
);
// Valid operator.
const operator = concat(operatorHead, operatorCharacter, '*');
// Valid first characters for identifiers.
const identifierHead = either(
/[a-zA-Z_]/,
/[\u00A8\u00AA\u00AD\u00AF\u00B2-\u00B5\u00B7-\u00BA]/,
/[\u00BC-\u00BE\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF]/,
/[\u0100-\u02FF\u0370-\u167F\u1681-\u180D\u180F-\u1DBF]/,
/[\u1E00-\u1FFF]/,
/[\u200B-\u200D\u202A-\u202E\u203F-\u2040\u2054\u2060-\u206F]/,
/[\u2070-\u20CF\u2100-\u218F\u2460-\u24FF\u2776-\u2793]/,
/[\u2C00-\u2DFF\u2E80-\u2FFF]/,
/[\u3004-\u3007\u3021-\u302F\u3031-\u303F\u3040-\uD7FF]/,
/[\uF900-\uFD3D\uFD40-\uFDCF\uFDF0-\uFE1F\uFE30-\uFE44]/,
/[\uFE47-\uFEFE\uFF00-\uFFFD]/ // Should be /[\uFE47-\uFFFD]/, but we have to exclude FEFF.
// The following characters are also allowed, but the regexes aren't supported yet.
// /[\u{10000}-\u{1FFFD}\u{20000-\u{2FFFD}\u{30000}-\u{3FFFD}\u{40000}-\u{4FFFD}]/u,
// /[\u{50000}-\u{5FFFD}\u{60000-\u{6FFFD}\u{70000}-\u{7FFFD}\u{80000}-\u{8FFFD}]/u,
// /[\u{90000}-\u{9FFFD}\u{A0000-\u{AFFFD}\u{B0000}-\u{BFFFD}\u{C0000}-\u{CFFFD}]/u,
// /[\u{D0000}-\u{DFFFD}\u{E0000-\u{EFFFD}]/u
);
// Valid characters for identifiers.
const identifierCharacter = either(
identifierHead,
/\d/,
/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE20-\uFE2F]/
);
// Valid identifier.
const identifier = concat(identifierHead, identifierCharacter, '*');
// Valid type identifier.
const typeIdentifier = concat(/[A-Z]/, identifierCharacter, '*');
// Built-in attributes, which are highlighted as keywords.
// @available is handled separately.
// https://docs.swift.org/swift-book/documentation/the-swift-programming-language/attributes
const keywordAttributes = [
'attached',
'autoclosure',
concat(/convention\(/, either('swift', 'block', 'c'), /\)/),
'discardableResult',
'dynamicCallable',
'dynamicMemberLookup',
'escaping',
'freestanding',
'frozen',
'GKInspectable',
'IBAction',
'IBDesignable',
'IBInspectable',
'IBOutlet',
'IBSegueAction',
'inlinable',
'main',
'nonobjc',
'NSApplicationMain',
'NSCopying',
'NSManaged',
concat(/objc\(/, identifier, /\)/),
'objc',
'objcMembers',
'propertyWrapper',
'requires_stored_property_inits',
'resultBuilder',
'Sendable',
'testable',
'UIApplicationMain',
'unchecked',
'unknown',
'usableFromInline',
'warn_unqualified_access'
];
// Contextual keywords used in @available and #(un)available.
const availabilityKeywords = [
'iOS',
'iOSApplicationExtension',
'macOS',
'macOSApplicationExtension',
'macCatalyst',
'macCatalystApplicationExtension',
'watchOS',
'watchOSApplicationExtension',
'tvOS',
'tvOSApplicationExtension',
'swift'
];
/*
Language: Swift
Description: Swift is a general-purpose programming language built using a modern approach to safety, performance, and software design patterns.
Author: Steven Van Impe <steven.vanimpe@icloud.com>
Contributors: Chris Eidhof <chris@eidhof.nl>, Nate Cook <natecook@gmail.com>, Alexander Lichter <manniL@gmx.net>, Richard Gibson <gibson042@github>
Website: https://swift.org
Category: common, system
*/
/** @type LanguageFn */
function swift(hljs) {
const WHITESPACE = {
match: /\s+/,
relevance: 0
};
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID411
const BLOCK_COMMENT = hljs.COMMENT(
'/\\*',
'\\*/',
{ contains: [ 'self' ] }
);
const COMMENTS = [
hljs.C_LINE_COMMENT_MODE,
BLOCK_COMMENT
];
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID413
// https://docs.swift.org/swift-book/ReferenceManual/zzSummaryOfTheGrammar.html
const DOT_KEYWORD = {
match: [
/\./,
either(...dotKeywords, ...optionalDotKeywords)
],
className: { 2: "keyword" }
};
const KEYWORD_GUARD = {
// Consume .keyword to prevent highlighting properties and methods as keywords.
match: concat(/\./, either(...keywords)),
relevance: 0
};
const PLAIN_KEYWORDS = keywords
.filter(kw => typeof kw === 'string')
.concat([ "_|0" ]); // seems common, so 0 relevance
const REGEX_KEYWORDS = keywords
.filter(kw => typeof kw !== 'string') // find regex
.concat(keywordTypes)
.map(keywordWrapper);
const KEYWORD = { variants: [
{
className: 'keyword',
match: either(...REGEX_KEYWORDS, ...optionalDotKeywords)
}
] };
// find all the regular keywords
const KEYWORDS = {
$pattern: either(
/\b\w+/, // regular keywords
/#\w+/ // number keywords
),
keyword: PLAIN_KEYWORDS
.concat(numberSignKeywords),
literal: literals
};
const KEYWORD_MODES = [
DOT_KEYWORD,
KEYWORD_GUARD,
KEYWORD
];
// https://github.com/apple/swift/tree/main/stdlib/public/core
const BUILT_IN_GUARD = {
// Consume .built_in to prevent highlighting properties and methods.
match: concat(/\./, either(...builtIns)),
relevance: 0
};
const BUILT_IN = {
className: 'built_in',
match: concat(/\b/, either(...builtIns), /(?=\()/)
};
const BUILT_INS = [
BUILT_IN_GUARD,
BUILT_IN
];
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID418
const OPERATOR_GUARD = {
// Prevent -> from being highlighting as an operator.
match: /->/,
relevance: 0
};
const OPERATOR = {
className: 'operator',
relevance: 0,
variants: [
{ match: operator },
{
// dot-operator: only operators that start with a dot are allowed to use dots as
// characters (..., ...<, .*, etc). So there rule here is: a dot followed by one or more
// characters that may also include dots.
match: `\\.(\\.|${operatorCharacter})+` }
]
};
const OPERATORS = [
OPERATOR_GUARD,
OPERATOR
];
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#grammar_numeric-literal
// TODO: Update for leading `-` after lookbehind is supported everywhere
const decimalDigits = '([0-9]_*)+';
const hexDigits = '([0-9a-fA-F]_*)+';
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
// decimal floating-point-literal (subsumes decimal-literal)
{ match: `\\b(${decimalDigits})(\\.(${decimalDigits}))?` + `([eE][+-]?(${decimalDigits}))?\\b` },
// hexadecimal floating-point-literal (subsumes hexadecimal-literal)
{ match: `\\b0x(${hexDigits})(\\.(${hexDigits}))?` + `([pP][+-]?(${decimalDigits}))?\\b` },
// octal-literal
{ match: /\b0o([0-7]_*)+\b/ },
// binary-literal
{ match: /\b0b([01]_*)+\b/ }
]
};
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#grammar_string-literal
const ESCAPED_CHARACTER = (rawDelimiter = "") => ({
className: 'subst',
variants: [
{ match: concat(/\\/, rawDelimiter, /[0\\tnr"']/) },
{ match: concat(/\\/, rawDelimiter, /u\{[0-9a-fA-F]{1,8}\}/) }
]
});
const ESCAPED_NEWLINE = (rawDelimiter = "") => ({
className: 'subst',
match: concat(/\\/, rawDelimiter, /[\t ]*(?:[\r\n]|\r\n)/)
});
const INTERPOLATION = (rawDelimiter = "") => ({
className: 'subst',
label: "interpol",
begin: concat(/\\/, rawDelimiter, /\(/),
end: /\)/
});
const MULTILINE_STRING = (rawDelimiter = "") => ({
begin: concat(rawDelimiter, /"""/),
end: concat(/"""/, rawDelimiter),
contains: [
ESCAPED_CHARACTER(rawDelimiter),
ESCAPED_NEWLINE(rawDelimiter),
INTERPOLATION(rawDelimiter)
]
});
const SINGLE_LINE_STRING = (rawDelimiter = "") => ({
begin: concat(rawDelimiter, /"/),
end: concat(/"/, rawDelimiter),
contains: [
ESCAPED_CHARACTER(rawDelimiter),
INTERPOLATION(rawDelimiter)
]
});
const STRING = {
className: 'string',
variants: [
MULTILINE_STRING(),
MULTILINE_STRING("#"),
MULTILINE_STRING("##"),
MULTILINE_STRING("###"),
SINGLE_LINE_STRING(),
SINGLE_LINE_STRING("#"),
SINGLE_LINE_STRING("##"),
SINGLE_LINE_STRING("###")
]
};
const REGEXP_CONTENTS = [
hljs.BACKSLASH_ESCAPE,
{
begin: /\[/,
end: /\]/,
relevance: 0,
contains: [ hljs.BACKSLASH_ESCAPE ]
}
];
const BARE_REGEXP_LITERAL = {
begin: /\/[^\s](?=[^/\n]*\/)/,
end: /\//,
contains: REGEXP_CONTENTS
};
const EXTENDED_REGEXP_LITERAL = (rawDelimiter) => {
const begin = concat(rawDelimiter, /\//);
const end = concat(/\//, rawDelimiter);
return {
begin,
end,
contains: [
...REGEXP_CONTENTS,
{
scope: "comment",
begin: `#(?!.*${end})`,
end: /$/,
},
],
};
};
// https://docs.swift.org/swift-book/documentation/the-swift-programming-language/lexicalstructure/#Regular-Expression-Literals
const REGEXP = {
scope: "regexp",
variants: [
EXTENDED_REGEXP_LITERAL('###'),
EXTENDED_REGEXP_LITERAL('##'),
EXTENDED_REGEXP_LITERAL('#'),
BARE_REGEXP_LITERAL
]
};
// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID412
const QUOTED_IDENTIFIER = { match: concat(/`/, identifier, /`/) };
const IMPLICIT_PARAMETER = {
className: 'variable',
match: /\$\d+/
};
const PROPERTY_WRAPPER_PROJECTION = {
className: 'variable',
match: `\\$${identifierCharacter}+`
};
const IDENTIFIERS = [
QUOTED_IDENTIFIER,
IMPLICIT_PARAMETER,
PROPERTY_WRAPPER_PROJECTION
];
// https://docs.swift.org/swift-book/ReferenceManual/Attributes.html
const AVAILABLE_ATTRIBUTE = {
match: /(@|#(un)?)available/,
scope: 'keyword',
starts: { contains: [
{
begin: /\(/,
end: /\)/,
keywords: availabilityKeywords,
contains: [
...OPERATORS,
NUMBER,
STRING
]
}
] }
};
const KEYWORD_ATTRIBUTE = {
scope: 'keyword',
match: concat(/@/, either(...keywordAttributes))
};
const USER_DEFINED_ATTRIBUTE = {
scope: 'meta',
match: concat(/@/, identifier)
};
const ATTRIBUTES = [
AVAILABLE_ATTRIBUTE,
KEYWORD_ATTRIBUTE,
USER_DEFINED_ATTRIBUTE
];
// https://docs.swift.org/swift-book/ReferenceManual/Types.html
const TYPE = {
match: lookahead(/\b[A-Z]/),
relevance: 0,
contains: [
{ // Common Apple frameworks, for relevance boost
className: 'type',
match: concat(/(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)/, identifierCharacter, '+')
},
{ // Type identifier
className: 'type',
match: typeIdentifier,
relevance: 0
},
{ // Optional type
match: /[?!]+/,
relevance: 0
},
{ // Variadic parameter
match: /\.\.\./,
relevance: 0
},
{ // Protocol composition
match: concat(/\s+&\s+/, lookahead(typeIdentifier)),
relevance: 0
}
]
};
const GENERIC_ARGUMENTS = {
begin: /</,
end: />/,
keywords: KEYWORDS,
contains: [
...COMMENTS,
...KEYWORD_MODES,
...ATTRIBUTES,
OPERATOR_GUARD,
TYPE
]
};
TYPE.contains.push(GENERIC_ARGUMENTS);
// https://docs.swift.org/swift-book/ReferenceManual/Expressions.html#ID552
// Prevents element names from being highlighted as keywords.
const TUPLE_ELEMENT_NAME = {
match: concat(identifier, /\s*:/),
keywords: "_|0",
relevance: 0
};
// Matches tuples as well as the parameter list of a function type.
const TUPLE = {
begin: /\(/,
end: /\)/,
relevance: 0,
keywords: KEYWORDS,
contains: [
'self',
TUPLE_ELEMENT_NAME,
...COMMENTS,
REGEXP,
...KEYWORD_MODES,
...BUILT_INS,
...OPERATORS,
NUMBER,
STRING,
...IDENTIFIERS,
...ATTRIBUTES,
TYPE
]
};
const GENERIC_PARAMETERS = {
begin: /</,
end: />/,
keywords: 'repeat each',
contains: [
...COMMENTS,
TYPE
]
};
const FUNCTION_PARAMETER_NAME = {
begin: either(
lookahead(concat(identifier, /\s*:/)),
lookahead(concat(identifier, /\s+/, identifier, /\s*:/))
),
end: /:/,
relevance: 0,
contains: [
{
className: 'keyword',
match: /\b_\b/
},
{
className: 'params',
match: identifier
}
]
};
const FUNCTION_PARAMETERS = {
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [
FUNCTION_PARAMETER_NAME,
...COMMENTS,
...KEYWORD_MODES,
...OPERATORS,
NUMBER,
STRING,
...ATTRIBUTES,
TYPE,
TUPLE
],
endsParent: true,
illegal: /["']/
};
// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID362
// https://docs.swift.org/swift-book/documentation/the-swift-programming-language/declarations/#Macro-Declaration
const FUNCTION_OR_MACRO = {
match: [
/(func|macro)/,
/\s+/,
either(QUOTED_IDENTIFIER.match, identifier, operator)
],
className: {
1: "keyword",
3: "title.function"
},
contains: [
GENERIC_PARAMETERS,
FUNCTION_PARAMETERS,
WHITESPACE
],
illegal: [
/\[/,
/%/
]
};
// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID375
// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID379
const INIT_SUBSCRIPT = {
match: [
/\b(?:subscript|init[?!]?)/,
/\s*(?=[<(])/,
],
className: { 1: "keyword" },
contains: [
GENERIC_PARAMETERS,
FUNCTION_PARAMETERS,
WHITESPACE
],
illegal: /\[|%/
};
// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID380
const OPERATOR_DECLARATION = {
match: [
/operator/,
/\s+/,
operator
],
className: {
1: "keyword",
3: "title"
}
};
// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID550
const PRECEDENCEGROUP = {
begin: [
/precedencegroup/,
/\s+/,
typeIdentifier
],
className: {
1: "keyword",
3: "title"
},
contains: [ TYPE ],
keywords: [
...precedencegroupKeywords,
...literals
],
end: /}/
};
// Add supported submodes to string interpolation.
for (const variant of STRING.variants) {
const interpolation = variant.contains.find(mode => mode.label === "interpol");
// TODO: Interpolation can contain any expression, so there's room for improvement here.
interpolation.keywords = KEYWORDS;
const submodes = [
...KEYWORD_MODES,
...BUILT_INS,
...OPERATORS,
NUMBER,
STRING,
...IDENTIFIERS
];
interpolation.contains = [
...submodes,
{
begin: /\(/,
end: /\)/,
contains: [
'self',
...submodes
]
}
];
}
return {
name: 'Swift',
keywords: KEYWORDS,
contains: [
...COMMENTS,
FUNCTION_OR_MACRO,
INIT_SUBSCRIPT,
{
beginKeywords: 'struct protocol class extension enum actor',
end: '\\{',
excludeEnd: true,
keywords: KEYWORDS,
contains: [
hljs.inherit(hljs.TITLE_MODE, {
className: "title.class",
begin: /[A-Za-z$_][\u00C0-\u02B80-9A-Za-z$_]*/
}),
...KEYWORD_MODES
]
},
OPERATOR_DECLARATION,
PRECEDENCEGROUP,
{
beginKeywords: 'import',
end: /$/,
contains: [ ...COMMENTS ],
relevance: 0
},
REGEXP,
...KEYWORD_MODES,
...BUILT_INS,
...OPERATORS,
NUMBER,
STRING,
...IDENTIFIERS,
...ATTRIBUTES,
TYPE,
TUPLE
]
};
}
var swift_1 = swift;
/*
Language: Tagger Script
Author: Philipp Wolfer <ph.wolfer@gmail.com>
Description: Syntax Highlighting for the Tagger Script as used by MusicBrainz Picard.
Website: https://picard.musicbrainz.org
*/
function taggerscript(hljs) {
const NOOP = {
className: 'comment',
begin: /\$noop\(/,
end: /\)/,
contains: [
{ begin: /\\[()]/ },
{
begin: /\(/,
end: /\)/,
contains: [
{ begin: /\\[()]/ },
'self'
]
}
],
relevance: 10
};
const FUNCTION = {
className: 'keyword',
begin: /\$[_a-zA-Z0-9]+(?=\()/
};
const VARIABLE = {
className: 'variable',
begin: /%[_a-zA-Z0-9:]+%/
};
const ESCAPE_SEQUENCE_UNICODE = {
className: 'symbol',
begin: /\\u[a-fA-F0-9]{4}/
};
const ESCAPE_SEQUENCE = {
className: 'symbol',
begin: /\\[\\nt$%,()]/
};
return {
name: 'Tagger Script',
contains: [
NOOP,
FUNCTION,
VARIABLE,
ESCAPE_SEQUENCE,
ESCAPE_SEQUENCE_UNICODE
]
};
}
var taggerscript_1 = taggerscript;
/*
Language: YAML
Description: Yet Another Markdown Language
Author: Stefan Wienert <stwienert@gmail.com>
Contributors: Carl Baxter <carl@cbax.tech>
Requires: ruby.js
Website: https://yaml.org
Category: common, config
*/
function yaml(hljs) {
const LITERALS = 'true false yes no null';
// YAML spec allows non-reserved URI characters in tags.
const URI_CHARACTERS = '[\\w#;/?:@&=+$,.~*\'()[\\]]+';
// Define keys as starting with a word character
// ...containing word chars, spaces, colons, forward-slashes, hyphens and periods
// ...and ending with a colon followed immediately by a space, tab or newline.
// The YAML spec allows for much more than this, but this covers most use-cases.
const KEY = {
className: 'attr',
variants: [
{ begin: '\\w[\\w :\\/.-]*:(?=[ \t]|$)' },
{ // double quoted keys
begin: '"\\w[\\w :\\/.-]*":(?=[ \t]|$)' },
{ // single quoted keys
begin: '\'\\w[\\w :\\/.-]*\':(?=[ \t]|$)' }
]
};
const TEMPLATE_VARIABLES = {
className: 'template-variable',
variants: [
{ // jinja templates Ansible
begin: /\{\{/,
end: /\}\}/
},
{ // Ruby i18n
begin: /%\{/,
end: /\}/
}
]
};
const STRING = {
className: 'string',
relevance: 0,
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
},
{ begin: /\S+/ }
],
contains: [
hljs.BACKSLASH_ESCAPE,
TEMPLATE_VARIABLES
]
};
// Strings inside of value containers (objects) can't contain braces,
// brackets, or commas
const CONTAINER_STRING = hljs.inherit(STRING, { variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
},
{ begin: /[^\s,{}[\]]+/ }
] });
const DATE_RE = '[0-9]{4}(-[0-9][0-9]){0,2}';
const TIME_RE = '([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?';
const FRACTION_RE = '(\\.[0-9]*)?';
const ZONE_RE = '([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?';
const TIMESTAMP = {
className: 'number',
begin: '\\b' + DATE_RE + TIME_RE + FRACTION_RE + ZONE_RE + '\\b'
};
const VALUE_CONTAINER = {
end: ',',
endsWithParent: true,
excludeEnd: true,
keywords: LITERALS,
relevance: 0
};
const OBJECT = {
begin: /\{/,
end: /\}/,
contains: [ VALUE_CONTAINER ],
illegal: '\\n',
relevance: 0
};
const ARRAY = {
begin: '\\[',
end: '\\]',
contains: [ VALUE_CONTAINER ],
illegal: '\\n',
relevance: 0
};
const MODES = [
KEY,
{
className: 'meta',
begin: '^---\\s*$',
relevance: 10
},
{ // multi line string
// Blocks start with a | or > followed by a newline
//
// Indentation of subsequent lines must be the same to
// be considered part of the block
className: 'string',
begin: '[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*'
},
{ // Ruby/Rails erb
begin: '<%[%=-]?',
end: '[%-]?%>',
subLanguage: 'ruby',
excludeBegin: true,
excludeEnd: true,
relevance: 0
},
{ // named tags
className: 'type',
begin: '!\\w+!' + URI_CHARACTERS
},
// https://yaml.org/spec/1.2/spec.html#id2784064
{ // verbatim tags
className: 'type',
begin: '!<' + URI_CHARACTERS + ">"
},
{ // primary tags
className: 'type',
begin: '!' + URI_CHARACTERS
},
{ // secondary tags
className: 'type',
begin: '!!' + URI_CHARACTERS
},
{ // fragment id &ref
className: 'meta',
begin: '&' + hljs.UNDERSCORE_IDENT_RE + '$'
},
{ // fragment reference *ref
className: 'meta',
begin: '\\*' + hljs.UNDERSCORE_IDENT_RE + '$'
},
{ // array listing
className: 'bullet',
// TODO: remove |$ hack when we have proper look-ahead support
begin: '-(?=[ ]|$)',
relevance: 0
},
hljs.HASH_COMMENT_MODE,
{
beginKeywords: LITERALS,
keywords: { literal: LITERALS }
},
TIMESTAMP,
// numbers are any valid C-style number that
// sit isolated from other words
{
className: 'number',
begin: hljs.C_NUMBER_RE + '\\b',
relevance: 0
},
OBJECT,
ARRAY,
STRING
];
const VALUE_MODES = [ ...MODES ];
VALUE_MODES.pop();
VALUE_MODES.push(CONTAINER_STRING);
VALUE_CONTAINER.contains = VALUE_MODES;
return {
name: 'YAML',
case_insensitive: true,
aliases: [ 'yml' ],
contains: MODES
};
}
var yaml_1 = yaml;
/*
Language: Test Anything Protocol
Description: TAP, the Test Anything Protocol, is a simple text-based interface between testing modules in a test harness.
Requires: yaml.js
Author: Sergey Bronnikov <sergeyb@bronevichok.ru>
Website: https://testanything.org
*/
function tap(hljs) {
return {
name: 'Test Anything Protocol',
case_insensitive: true,
contains: [
hljs.HASH_COMMENT_MODE,
// version of format and total amount of testcases
{
className: 'meta',
variants: [
{ begin: '^TAP version (\\d+)$' },
{ begin: '^1\\.\\.(\\d+)$' }
]
},
// YAML block
{
begin: /---$/,
end: '\\.\\.\\.$',
subLanguage: 'yaml',
relevance: 0
},
// testcase number
{
className: 'number',
begin: ' (\\d+) '
},
// testcase status and description
{
className: 'symbol',
variants: [
{ begin: '^ok' },
{ begin: '^not ok' }
]
}
]
};
}
var tap_1 = tap;
/*
Language: Tcl
Description: Tcl is a very simple programming language.
Author: Radek Liska <radekliska@gmail.com>
Website: https://www.tcl.tk/about/language.html
*/
function tcl(hljs) {
const regex = hljs.regex;
const TCL_IDENT = /[a-zA-Z_][a-zA-Z0-9_]*/;
const NUMBER = {
className: 'number',
variants: [
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE
]
};
const KEYWORDS = [
"after",
"append",
"apply",
"array",
"auto_execok",
"auto_import",
"auto_load",
"auto_mkindex",
"auto_mkindex_old",
"auto_qualify",
"auto_reset",
"bgerror",
"binary",
"break",
"catch",
"cd",
"chan",
"clock",
"close",
"concat",
"continue",
"dde",
"dict",
"encoding",
"eof",
"error",
"eval",
"exec",
"exit",
"expr",
"fblocked",
"fconfigure",
"fcopy",
"file",
"fileevent",
"filename",
"flush",
"for",
"foreach",
"format",
"gets",
"glob",
"global",
"history",
"http",
"if",
"incr",
"info",
"interp",
"join",
"lappend|10",
"lassign|10",
"lindex|10",
"linsert|10",
"list",
"llength|10",
"load",
"lrange|10",
"lrepeat|10",
"lreplace|10",
"lreverse|10",
"lsearch|10",
"lset|10",
"lsort|10",
"mathfunc",
"mathop",
"memory",
"msgcat",
"namespace",
"open",
"package",
"parray",
"pid",
"pkg::create",
"pkg_mkIndex",
"platform",
"platform::shell",
"proc",
"puts",
"pwd",
"read",
"refchan",
"regexp",
"registry",
"regsub|10",
"rename",
"return",
"safe",
"scan",
"seek",
"set",
"socket",
"source",
"split",
"string",
"subst",
"switch",
"tcl_endOfWord",
"tcl_findLibrary",
"tcl_startOfNextWord",
"tcl_startOfPreviousWord",
"tcl_wordBreakAfter",
"tcl_wordBreakBefore",
"tcltest",
"tclvars",
"tell",
"time",
"tm",
"trace",
"unknown",
"unload",
"unset",
"update",
"uplevel",
"upvar",
"variable",
"vwait",
"while"
];
return {
name: 'Tcl',
aliases: [ 'tk' ],
keywords: KEYWORDS,
contains: [
hljs.COMMENT(';[ \\t]*#', '$'),
hljs.COMMENT('^[ \\t]*#', '$'),
{
beginKeywords: 'proc',
end: '[\\{]',
excludeEnd: true,
contains: [
{
className: 'title',
begin: '[ \\t\\n\\r]+(::)?[a-zA-Z_]((::)?[a-zA-Z0-9_])*',
end: '[ \\t\\n\\r]',
endsWithParent: true,
excludeEnd: true
}
]
},
{
className: "variable",
variants: [
{ begin: regex.concat(
/\$/,
regex.optional(/::/),
TCL_IDENT,
'(::',
TCL_IDENT,
')*'
) },
{
begin: '\\$\\{(::)?[a-zA-Z_]((::)?[a-zA-Z0-9_])*',
end: '\\}',
contains: [ NUMBER ]
}
]
},
{
className: 'string',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [ hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null }) ]
},
NUMBER
]
};
}
var tcl_1 = tcl;
/*
Language: Thrift
Author: Oleg Efimov <efimovov@gmail.com>
Description: Thrift message definition format
Website: https://thrift.apache.org
Category: protocols
*/
function thrift(hljs) {
const TYPES = [
"bool",
"byte",
"i16",
"i32",
"i64",
"double",
"string",
"binary"
];
const KEYWORDS = [
"namespace",
"const",
"typedef",
"struct",
"enum",
"service",
"exception",
"void",
"oneway",
"set",
"list",
"map",
"required",
"optional"
];
return {
name: 'Thrift',
keywords: {
keyword: KEYWORDS,
type: TYPES,
literal: 'true false'
},
contains: [
hljs.QUOTE_STRING_MODE,
hljs.NUMBER_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'class',
beginKeywords: 'struct enum service exception',
end: /\{/,
illegal: /\n/,
contains: [
hljs.inherit(hljs.TITLE_MODE, {
// hack: eating everything after the first title
starts: {
endsWithParent: true,
excludeEnd: true
} })
]
},
{
begin: '\\b(set|list|map)\\s*<',
keywords: { type: [
...TYPES,
"set",
"list",
"map"
] },
end: '>',
contains: [ 'self' ]
}
]
};
}
var thrift_1 = thrift;
/*
Language: TP
Author: Jay Strybis <jay.strybis@gmail.com>
Description: FANUC TP programming language (TPP).
*/
function tp(hljs) {
const TPID = {
className: 'number',
begin: '[1-9][0-9]*', /* no leading zeros */
relevance: 0
};
const TPLABEL = {
className: 'symbol',
begin: ':[^\\]]+'
};
const TPDATA = {
className: 'built_in',
begin: '(AR|P|PAYLOAD|PR|R|SR|RSR|LBL|VR|UALM|MESSAGE|UTOOL|UFRAME|TIMER|'
+ 'TIMER_OVERFLOW|JOINT_MAX_SPEED|RESUME_PROG|DIAG_REC)\\[',
end: '\\]',
contains: [
'self',
TPID,
TPLABEL
]
};
const TPIO = {
className: 'built_in',
begin: '(AI|AO|DI|DO|F|RI|RO|UI|UO|GI|GO|SI|SO)\\[',
end: '\\]',
contains: [
'self',
TPID,
hljs.QUOTE_STRING_MODE, /* for pos section at bottom */
TPLABEL
]
};
const KEYWORDS = [
"ABORT",
"ACC",
"ADJUST",
"AND",
"AP_LD",
"BREAK",
"CALL",
"CNT",
"COL",
"CONDITION",
"CONFIG",
"DA",
"DB",
"DIV",
"DETECT",
"ELSE",
"END",
"ENDFOR",
"ERR_NUM",
"ERROR_PROG",
"FINE",
"FOR",
"GP",
"GUARD",
"INC",
"IF",
"JMP",
"LINEAR_MAX_SPEED",
"LOCK",
"MOD",
"MONITOR",
"OFFSET",
"Offset",
"OR",
"OVERRIDE",
"PAUSE",
"PREG",
"PTH",
"RT_LD",
"RUN",
"SELECT",
"SKIP",
"Skip",
"TA",
"TB",
"TO",
"TOOL_OFFSET",
"Tool_Offset",
"UF",
"UT",
"UFRAME_NUM",
"UTOOL_NUM",
"UNLOCK",
"WAIT",
"X",
"Y",
"Z",
"W",
"P",
"R",
"STRLEN",
"SUBSTR",
"FINDSTR",
"VOFFSET",
"PROG",
"ATTR",
"MN",
"POS"
];
const LITERALS = [
"ON",
"OFF",
"max_speed",
"LPOS",
"JPOS",
"ENABLE",
"DISABLE",
"START",
"STOP",
"RESET"
];
return {
name: 'TP',
keywords: {
keyword: KEYWORDS,
literal: LITERALS
},
contains: [
TPDATA,
TPIO,
{
className: 'keyword',
begin: '/(PROG|ATTR|MN|POS|END)\\b'
},
{
/* this is for cases like ,CALL */
className: 'keyword',
begin: '(CALL|RUN|POINT_LOGIC|LBL)\\b'
},
{
/* this is for cases like CNT100 where the default lexemes do not
* separate the keyword and the number */
className: 'keyword',
begin: '\\b(ACC|CNT|Skip|Offset|PSPD|RT_LD|AP_LD|Tool_Offset)'
},
{
/* to catch numbers that do not have a word boundary on the left */
className: 'number',
begin: '\\d+(sec|msec|mm/sec|cm/min|inch/min|deg/sec|mm|in|cm)?\\b',
relevance: 0
},
hljs.COMMENT('//', '[;$]'),
hljs.COMMENT('!', '[;$]'),
hljs.COMMENT('--eg:', '$'),
hljs.QUOTE_STRING_MODE,
{
className: 'string',
begin: '\'',
end: '\''
},
hljs.C_NUMBER_MODE,
{
className: 'variable',
begin: '\\$[A-Za-z0-9_]+'
}
]
};
}
var tp_1 = tp;
/*
Language: Twig
Requires: xml.js
Author: Luke Holder <lukemh@gmail.com>
Description: Twig is a templating language for PHP
Website: https://twig.symfony.com
Category: template
*/
function twig(hljs) {
const regex = hljs.regex;
const FUNCTION_NAMES = [
"absolute_url",
"asset|0",
"asset_version",
"attribute",
"block",
"constant",
"controller|0",
"country_timezones",
"csrf_token",
"cycle",
"date",
"dump",
"expression",
"form|0",
"form_end",
"form_errors",
"form_help",
"form_label",
"form_rest",
"form_row",
"form_start",
"form_widget",
"html_classes",
"include",
"is_granted",
"logout_path",
"logout_url",
"max",
"min",
"parent",
"path|0",
"random",
"range",
"relative_path",
"render",
"render_esi",
"source",
"template_from_string",
"url|0"
];
const FILTERS = [
"abs",
"abbr_class",
"abbr_method",
"batch",
"capitalize",
"column",
"convert_encoding",
"country_name",
"currency_name",
"currency_symbol",
"data_uri",
"date",
"date_modify",
"default",
"escape",
"file_excerpt",
"file_link",
"file_relative",
"filter",
"first",
"format",
"format_args",
"format_args_as_text",
"format_currency",
"format_date",
"format_datetime",
"format_file",
"format_file_from_text",
"format_number",
"format_time",
"html_to_markdown",
"humanize",
"inky_to_html",
"inline_css",
"join",
"json_encode",
"keys",
"language_name",
"last",
"length",
"locale_name",
"lower",
"map",
"markdown",
"markdown_to_html",
"merge",
"nl2br",
"number_format",
"raw",
"reduce",
"replace",
"reverse",
"round",
"slice",
"slug",
"sort",
"spaceless",
"split",
"striptags",
"timezone_name",
"title",
"trans",
"transchoice",
"trim",
"u|0",
"upper",
"url_encode",
"yaml_dump",
"yaml_encode"
];
let TAG_NAMES = [
"apply",
"autoescape",
"block",
"cache",
"deprecated",
"do",
"embed",
"extends",
"filter",
"flush",
"for",
"form_theme",
"from",
"if",
"import",
"include",
"macro",
"sandbox",
"set",
"stopwatch",
"trans",
"trans_default_domain",
"transchoice",
"use",
"verbatim",
"with"
];
TAG_NAMES = TAG_NAMES.concat(TAG_NAMES.map(t => `end${t}`));
const STRING = {
scope: 'string',
variants: [
{
begin: /'/,
end: /'/
},
{
begin: /"/,
end: /"/
},
]
};
const NUMBER = {
scope: "number",
match: /\d+/
};
const PARAMS = {
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
contains: [
STRING,
NUMBER
]
};
const FUNCTIONS = {
beginKeywords: FUNCTION_NAMES.join(" "),
keywords: { name: FUNCTION_NAMES },
relevance: 0,
contains: [ PARAMS ]
};
const FILTER = {
match: /\|(?=[A-Za-z_]+:?)/,
beginScope: "punctuation",
relevance: 0,
contains: [
{
match: /[A-Za-z_]+:?/,
keywords: FILTERS
},
]
};
const tagNamed = (tagnames, { relevance }) => {
return {
beginScope: {
1: 'template-tag',
3: 'name'
},
relevance: relevance || 2,
endScope: 'template-tag',
begin: [
/\{%/,
/\s*/,
regex.either(...tagnames)
],
end: /%\}/,
keywords: "in",
contains: [
FILTER,
FUNCTIONS,
STRING,
NUMBER
]
};
};
const CUSTOM_TAG_RE = /[a-z_]+/;
const TAG = tagNamed(TAG_NAMES, { relevance: 2 });
const CUSTOM_TAG = tagNamed([ CUSTOM_TAG_RE ], { relevance: 1 });
return {
name: 'Twig',
aliases: [ 'craftcms' ],
case_insensitive: true,
subLanguage: 'xml',
contains: [
hljs.COMMENT(/\{#/, /#\}/),
TAG,
CUSTOM_TAG,
{
className: 'template-variable',
begin: /\{\{/,
end: /\}\}/,
contains: [
'self',
FILTER,
FUNCTIONS,
STRING,
NUMBER
]
}
]
};
}
var twig_1 = twig;
const IDENT_RE = '[A-Za-z$_][0-9A-Za-z$_]*';
const KEYWORDS = [
"as", // for exports
"in",
"of",
"if",
"for",
"while",
"finally",
"var",
"new",
"function",
"do",
"return",
"void",
"else",
"break",
"catch",
"instanceof",
"with",
"throw",
"case",
"default",
"try",
"switch",
"continue",
"typeof",
"delete",
"let",
"yield",
"const",
"class",
// JS handles these with a special rule
// "get",
// "set",
"debugger",
"async",
"await",
"static",
"import",
"from",
"export",
"extends"
];
const LITERALS = [
"true",
"false",
"null",
"undefined",
"NaN",
"Infinity"
];
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
const TYPES = [
// Fundamental objects
"Object",
"Function",
"Boolean",
"Symbol",
// numbers and dates
"Math",
"Date",
"Number",
"BigInt",
// text
"String",
"RegExp",
// Indexed collections
"Array",
"Float32Array",
"Float64Array",
"Int8Array",
"Uint8Array",
"Uint8ClampedArray",
"Int16Array",
"Int32Array",
"Uint16Array",
"Uint32Array",
"BigInt64Array",
"BigUint64Array",
// Keyed collections
"Set",
"Map",
"WeakSet",
"WeakMap",
// Structured data
"ArrayBuffer",
"SharedArrayBuffer",
"Atomics",
"DataView",
"JSON",
// Control abstraction objects
"Promise",
"Generator",
"GeneratorFunction",
"AsyncFunction",
// Reflection
"Reflect",
"Proxy",
// Internationalization
"Intl",
// WebAssembly
"WebAssembly"
];
const ERROR_TYPES = [
"Error",
"EvalError",
"InternalError",
"RangeError",
"ReferenceError",
"SyntaxError",
"TypeError",
"URIError"
];
const BUILT_IN_GLOBALS = [
"setInterval",
"setTimeout",
"clearInterval",
"clearTimeout",
"require",
"exports",
"eval",
"isFinite",
"isNaN",
"parseFloat",
"parseInt",
"decodeURI",
"decodeURIComponent",
"encodeURI",
"encodeURIComponent",
"escape",
"unescape"
];
const BUILT_IN_VARIABLES = [
"arguments",
"this",
"super",
"console",
"window",
"document",
"localStorage",
"sessionStorage",
"module",
"global" // Node.js
];
const BUILT_INS = [].concat(
BUILT_IN_GLOBALS,
TYPES,
ERROR_TYPES
);
/*
Language: JavaScript
Description: JavaScript (JS) is a lightweight, interpreted, or just-in-time compiled programming language with first-class functions.
Category: common, scripting, web
Website: https://developer.mozilla.org/en-US/docs/Web/JavaScript
*/
/** @type LanguageFn */
function javascript(hljs) {
const regex = hljs.regex;
/**
* Takes a string like "<Booger" and checks to see
* if we can find a matching "</Booger" later in the
* content.
* @param {RegExpMatchArray} match
* @param {{after:number}} param1
*/
const hasClosingTag = (match, { after }) => {
const tag = "</" + match[0].slice(1);
const pos = match.input.indexOf(tag, after);
return pos !== -1;
};
const IDENT_RE$1 = IDENT_RE;
const FRAGMENT = {
begin: '<>',
end: '</>'
};
// to avoid some special cases inside isTrulyOpeningTag
const XML_SELF_CLOSING = /<[A-Za-z0-9\\._:-]+\s*\/>/;
const XML_TAG = {
begin: /<[A-Za-z0-9\\._:-]+/,
end: /\/[A-Za-z0-9\\._:-]+>|\/>/,
/**
* @param {RegExpMatchArray} match
* @param {CallbackResponse} response
*/
isTrulyOpeningTag: (match, response) => {
const afterMatchIndex = match[0].length + match.index;
const nextChar = match.input[afterMatchIndex];
if (
// HTML should not include another raw `<` inside a tag
// nested type?
// `<Array<Array<number>>`, etc.
nextChar === "<" ||
// the , gives away that this is not HTML
// `<T, A extends keyof T, V>`
nextChar === ","
) {
response.ignoreMatch();
return;
}
// `<something>`
// Quite possibly a tag, lets look for a matching closing tag...
if (nextChar === ">") {
// if we cannot find a matching closing tag, then we
// will ignore it
if (!hasClosingTag(match, { after: afterMatchIndex })) {
response.ignoreMatch();
}
}
// `<blah />` (self-closing)
// handled by simpleSelfClosing rule
let m;
const afterMatch = match.input.substring(afterMatchIndex);
// some more template typing stuff
// <T = any>(key?: string) => Modify<
if ((m = afterMatch.match(/^\s*=/))) {
response.ignoreMatch();
return;
}
// `<From extends string>`
// technically this could be HTML, but it smells like a type
// NOTE: This is ugh, but added specifically for https://github.com/highlightjs/highlight.js/issues/3276
if ((m = afterMatch.match(/^\s+extends\s+/))) {
if (m.index === 0) {
response.ignoreMatch();
// eslint-disable-next-line no-useless-return
return;
}
}
}
};
const KEYWORDS$1 = {
$pattern: IDENT_RE,
keyword: KEYWORDS,
literal: LITERALS,
built_in: BUILT_INS,
"variable.language": BUILT_IN_VARIABLES
};
// https://tc39.es/ecma262/#sec-literals-numeric-literals
const decimalDigits = '[0-9](_?[0-9])*';
const frac = `\\.(${decimalDigits})`;
// DecimalIntegerLiteral, including Annex B NonOctalDecimalIntegerLiteral
// https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals
const decimalInteger = `0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`;
const NUMBER = {
className: 'number',
variants: [
// DecimalLiteral
{ begin: `(\\b(${decimalInteger})((${frac})|\\.)?|(${frac}))` +
`[eE][+-]?(${decimalDigits})\\b` },
{ begin: `\\b(${decimalInteger})\\b((${frac})\\b|\\.)?|(${frac})\\b` },
// DecimalBigIntegerLiteral
{ begin: `\\b(0|[1-9](_?[0-9])*)n\\b` },
// NonDecimalIntegerLiteral
{ begin: "\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b" },
{ begin: "\\b0[bB][0-1](_?[0-1])*n?\\b" },
{ begin: "\\b0[oO][0-7](_?[0-7])*n?\\b" },
// LegacyOctalIntegerLiteral (does not include underscore separators)
// https://tc39.es/ecma262/#sec-additional-syntax-numeric-literals
{ begin: "\\b0[0-7]+n?\\b" },
],
relevance: 0
};
const SUBST = {
className: 'subst',
begin: '\\$\\{',
end: '\\}',
keywords: KEYWORDS$1,
contains: [] // defined later
};
const HTML_TEMPLATE = {
begin: 'html`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'xml'
}
};
const CSS_TEMPLATE = {
begin: 'css`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'css'
}
};
const GRAPHQL_TEMPLATE = {
begin: 'gql`',
end: '',
starts: {
end: '`',
returnEnd: false,
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
],
subLanguage: 'graphql'
}
};
const TEMPLATE_STRING = {
className: 'string',
begin: '`',
end: '`',
contains: [
hljs.BACKSLASH_ESCAPE,
SUBST
]
};
const JSDOC_COMMENT = hljs.COMMENT(
/\/\*\*(?!\/)/,
'\\*/',
{
relevance: 0,
contains: [
{
begin: '(?=@[A-Za-z]+)',
relevance: 0,
contains: [
{
className: 'doctag',
begin: '@[A-Za-z]+'
},
{
className: 'type',
begin: '\\{',
end: '\\}',
excludeEnd: true,
excludeBegin: true,
relevance: 0
},
{
className: 'variable',
begin: IDENT_RE$1 + '(?=\\s*(-)|$)',
endsParent: true,
relevance: 0
},
// eat spaces (not newlines) so we can find
// types or variables
{
begin: /(?=[^\n])\s/,
relevance: 0
}
]
}
]
}
);
const COMMENT = {
className: "comment",
variants: [
JSDOC_COMMENT,
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_LINE_COMMENT_MODE
]
};
const SUBST_INTERNALS = [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
HTML_TEMPLATE,
CSS_TEMPLATE,
GRAPHQL_TEMPLATE,
TEMPLATE_STRING,
// Skip numbers when they are part of a variable name
{ match: /\$\d+/ },
NUMBER,
// This is intentional:
// See https://github.com/highlightjs/highlight.js/issues/3288
// hljs.REGEXP_MODE
];
SUBST.contains = SUBST_INTERNALS
.concat({
// we need to pair up {} inside our subst to prevent
// it from ending too early by matching another }
begin: /\{/,
end: /\}/,
keywords: KEYWORDS$1,
contains: [
"self"
].concat(SUBST_INTERNALS)
});
const SUBST_AND_COMMENTS = [].concat(COMMENT, SUBST.contains);
const PARAMS_CONTAINS = SUBST_AND_COMMENTS.concat([
// eat recursive parens in sub expressions
{
begin: /\(/,
end: /\)/,
keywords: KEYWORDS$1,
contains: ["self"].concat(SUBST_AND_COMMENTS)
}
]);
const PARAMS = {
className: 'params',
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS$1,
contains: PARAMS_CONTAINS
};
// ES6 classes
const CLASS_OR_EXTENDS = {
variants: [
// class Car extends vehicle
{
match: [
/class/,
/\s+/,
IDENT_RE$1,
/\s+/,
/extends/,
/\s+/,
regex.concat(IDENT_RE$1, "(", regex.concat(/\./, IDENT_RE$1), ")*")
],
scope: {
1: "keyword",
3: "title.class",
5: "keyword",
7: "title.class.inherited"
}
},
// class Car
{
match: [
/class/,
/\s+/,
IDENT_RE$1
],
scope: {
1: "keyword",
3: "title.class"
}
},
]
};
const CLASS_REFERENCE = {
relevance: 0,
match:
regex.either(
// Hard coded exceptions
/\bJSON/,
// Float32Array, OutT
/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,
// CSSFactory, CSSFactoryT
/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,
// FPs, FPsT
/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/,
// P
// single letters are not highlighted
// BLAH
// this will be flagged as a UPPER_CASE_CONSTANT instead
),
className: "title.class",
keywords: {
_: [
// se we still get relevance credit for JS library classes
...TYPES,
...ERROR_TYPES
]
}
};
const USE_STRICT = {
label: "use_strict",
className: 'meta',
relevance: 10,
begin: /^\s*['"]use (strict|asm)['"]/
};
const FUNCTION_DEFINITION = {
variants: [
{
match: [
/function/,
/\s+/,
IDENT_RE$1,
/(?=\s*\()/
]
},
// anonymous function
{
match: [
/function/,
/\s*(?=\()/
]
}
],
className: {
1: "keyword",
3: "title.function"
},
label: "func.def",
contains: [ PARAMS ],
illegal: /%/
};
const UPPER_CASE_CONSTANT = {
relevance: 0,
match: /\b[A-Z][A-Z_0-9]+\b/,
className: "variable.constant"
};
function noneOf(list) {
return regex.concat("(?!", list.join("|"), ")");
}
const FUNCTION_CALL = {
match: regex.concat(
/\b/,
noneOf([
...BUILT_IN_GLOBALS,
"super",
"import"
]),
IDENT_RE$1, regex.lookahead(/\(/)),
className: "title.function",
relevance: 0
};
const PROPERTY_ACCESS = {
begin: regex.concat(/\./, regex.lookahead(
regex.concat(IDENT_RE$1, /(?![0-9A-Za-z$_(])/)
)),
end: IDENT_RE$1,
excludeBegin: true,
keywords: "prototype",
className: "property",
relevance: 0
};
const GETTER_OR_SETTER = {
match: [
/get|set/,
/\s+/,
IDENT_RE$1,
/(?=\()/
],
className: {
1: "keyword",
3: "title.function"
},
contains: [
{ // eat to avoid empty params
begin: /\(\)/
},
PARAMS
]
};
const FUNC_LEAD_IN_RE = '(\\(' +
'[^()]*(\\(' +
'[^()]*(\\(' +
'[^()]*' +
'\\)[^()]*)*' +
'\\)[^()]*)*' +
'\\)|' + hljs.UNDERSCORE_IDENT_RE + ')\\s*=>';
const FUNCTION_VARIABLE = {
match: [
/const|var|let/, /\s+/,
IDENT_RE$1, /\s*/,
/=\s*/,
/(async\s*)?/, // async is optional
regex.lookahead(FUNC_LEAD_IN_RE)
],
keywords: "async",
className: {
1: "keyword",
3: "title.function"
},
contains: [
PARAMS
]
};
return {
name: 'JavaScript',
aliases: ['js', 'jsx', 'mjs', 'cjs'],
keywords: KEYWORDS$1,
// this will be extended by TypeScript
exports: { PARAMS_CONTAINS, CLASS_REFERENCE },
illegal: /#(?![$_A-z])/,
contains: [
hljs.SHEBANG({
label: "shebang",
binary: "node",
relevance: 5
}),
USE_STRICT,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
HTML_TEMPLATE,
CSS_TEMPLATE,
GRAPHQL_TEMPLATE,
TEMPLATE_STRING,
COMMENT,
// Skip numbers when they are part of a variable name
{ match: /\$\d+/ },
NUMBER,
CLASS_REFERENCE,
{
className: 'attr',
begin: IDENT_RE$1 + regex.lookahead(':'),
relevance: 0
},
FUNCTION_VARIABLE,
{ // "value" container
begin: '(' + hljs.RE_STARTERS_RE + '|\\b(case|return|throw)\\b)\\s*',
keywords: 'return throw case',
relevance: 0,
contains: [
COMMENT,
hljs.REGEXP_MODE,
{
className: 'function',
// we have to count the parens to make sure we actually have the
// correct bounding ( ) before the =>. There could be any number of
// sub-expressions inside also surrounded by parens.
begin: FUNC_LEAD_IN_RE,
returnBegin: true,
end: '\\s*=>',
contains: [
{
className: 'params',
variants: [
{
begin: hljs.UNDERSCORE_IDENT_RE,
relevance: 0
},
{
className: null,
begin: /\(\s*\)/,
skip: true
},
{
begin: /\(/,
end: /\)/,
excludeBegin: true,
excludeEnd: true,
keywords: KEYWORDS$1,
contains: PARAMS_CONTAINS
}
]
}
]
},
{ // could be a comma delimited list of params to a function call
begin: /,/,
relevance: 0
},
{
match: /\s+/,
relevance: 0
},
{ // JSX
variants: [
{ begin: FRAGMENT.begin, end: FRAGMENT.end },
{ match: XML_SELF_CLOSING },
{
begin: XML_TAG.begin,
// we carefully check the opening tag to see if it truly
// is a tag and not a false positive
'on:begin': XML_TAG.isTrulyOpeningTag,
end: XML_TAG.end
}
],
subLanguage: 'xml',
contains: [
{
begin: XML_TAG.begin,
end: XML_TAG.end,
skip: true,
contains: ['self']
}
]
}
],
},
FUNCTION_DEFINITION,
{
// prevent this from getting swallowed up by function
// since they appear "function like"
beginKeywords: "while if switch catch for"
},
{
// we have to count the parens to make sure we actually have the correct
// bounding ( ). There could be any number of sub-expressions inside
// also surrounded by parens.
begin: '\\b(?!function)' + hljs.UNDERSCORE_IDENT_RE +
'\\(' + // first parens
'[^()]*(\\(' +
'[^()]*(\\(' +
'[^()]*' +
'\\)[^()]*)*' +
'\\)[^()]*)*' +
'\\)\\s*\\{', // end parens
returnBegin:true,
label: "func.def",
contains: [
PARAMS,
hljs.inherit(hljs.TITLE_MODE, { begin: IDENT_RE$1, className: "title.function" })
]
},
// catch ... so it won't trigger the property rule below
{
match: /\.\.\./,
relevance: 0
},
PROPERTY_ACCESS,
// hack: prevents detection of keywords in some circumstances
// .keyword()
// $keyword = x
{
match: '\\$' + IDENT_RE$1,
relevance: 0
},
{
match: [ /\bconstructor(?=\s*\()/ ],
className: { 1: "title.function" },
contains: [ PARAMS ]
},
FUNCTION_CALL,
UPPER_CASE_CONSTANT,
CLASS_OR_EXTENDS,
GETTER_OR_SETTER,
{
match: /\$[(.]/ // relevance booster for a pattern common to JS libs: `$(something)` and `$.something`
}
]
};
}
/*
Language: TypeScript
Author: Panu Horsmalahti <panu.horsmalahti@iki.fi>
Contributors: Ike Ku <dempfi@yahoo.com>
Description: TypeScript is a strict superset of JavaScript
Website: https://www.typescriptlang.org
Category: common, scripting
*/
/** @type LanguageFn */
function typescript(hljs) {
const tsLanguage = javascript(hljs);
const IDENT_RE$1 = IDENT_RE;
const TYPES = [
"any",
"void",
"number",
"boolean",
"string",
"object",
"never",
"symbol",
"bigint",
"unknown"
];
const NAMESPACE = {
beginKeywords: 'namespace',
end: /\{/,
excludeEnd: true,
contains: [ tsLanguage.exports.CLASS_REFERENCE ]
};
const INTERFACE = {
beginKeywords: 'interface',
end: /\{/,
excludeEnd: true,
keywords: {
keyword: 'interface extends',
built_in: TYPES
},
contains: [ tsLanguage.exports.CLASS_REFERENCE ]
};
const USE_STRICT = {
className: 'meta',
relevance: 10,
begin: /^\s*['"]use strict['"]/
};
const TS_SPECIFIC_KEYWORDS = [
"type",
"namespace",
"interface",
"public",
"private",
"protected",
"implements",
"declare",
"abstract",
"readonly",
"enum",
"override"
];
const KEYWORDS$1 = {
$pattern: IDENT_RE,
keyword: KEYWORDS.concat(TS_SPECIFIC_KEYWORDS),
literal: LITERALS,
built_in: BUILT_INS.concat(TYPES),
"variable.language": BUILT_IN_VARIABLES
};
const DECORATOR = {
className: 'meta',
begin: '@' + IDENT_RE$1,
};
const swapMode = (mode, label, replacement) => {
const indx = mode.contains.findIndex(m => m.label === label);
if (indx === -1) { throw new Error("can not find mode to replace"); }
mode.contains.splice(indx, 1, replacement);
};
// this should update anywhere keywords is used since
// it will be the same actual JS object
Object.assign(tsLanguage.keywords, KEYWORDS$1);
tsLanguage.exports.PARAMS_CONTAINS.push(DECORATOR);
tsLanguage.contains = tsLanguage.contains.concat([
DECORATOR,
NAMESPACE,
INTERFACE,
]);
// TS gets a simpler shebang rule than JS
swapMode(tsLanguage, "shebang", hljs.SHEBANG());
// JS use strict rule purposely excludes `asm` which makes no sense
swapMode(tsLanguage, "use_strict", USE_STRICT);
const functionDeclaration = tsLanguage.contains.find(m => m.label === "func.def");
functionDeclaration.relevance = 0; // () => {} is more typical in TypeScript
Object.assign(tsLanguage, {
name: 'TypeScript',
aliases: [
'ts',
'tsx',
'mts',
'cts'
]
});
return tsLanguage;
}
var typescript_1 = typescript;
/*
Language: Vala
Author: Antono Vasiljev <antono.vasiljev@gmail.com>
Description: Vala is a new programming language that aims to bring modern programming language features to GNOME developers without imposing any additional runtime requirements and without using a different ABI compared to applications and libraries written in C.
Website: https://wiki.gnome.org/Projects/Vala
*/
function vala(hljs) {
return {
name: 'Vala',
keywords: {
keyword:
// Value types
'char uchar unichar int uint long ulong short ushort int8 int16 int32 int64 uint8 '
+ 'uint16 uint32 uint64 float double bool struct enum string void '
// Reference types
+ 'weak unowned owned '
// Modifiers
+ 'async signal static abstract interface override virtual delegate '
// Control Structures
+ 'if while do for foreach else switch case break default return try catch '
// Visibility
+ 'public private protected internal '
// Other
+ 'using new this get set const stdout stdin stderr var',
built_in:
'DBus GLib CCode Gee Object Gtk Posix',
literal:
'false true null'
},
contains: [
{
className: 'class',
beginKeywords: 'class interface namespace',
end: /\{/,
excludeEnd: true,
illegal: '[^,:\\n\\s\\.]',
contains: [ hljs.UNDERSCORE_TITLE_MODE ]
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'string',
begin: '"""',
end: '"""',
relevance: 5
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
begin: '^#',
end: '$',
}
]
};
}
var vala_1 = vala;
/*
Language: Visual Basic .NET
Description: Visual Basic .NET (VB.NET) is a multi-paradigm, object-oriented programming language, implemented on the .NET Framework.
Authors: Poren Chiang <ren.chiang@gmail.com>, Jan Pilzer
Website: https://docs.microsoft.com/dotnet/visual-basic/getting-started
Category: common
*/
/** @type LanguageFn */
function vbnet(hljs) {
const regex = hljs.regex;
/**
* Character Literal
* Either a single character ("a"C) or an escaped double quote (""""C).
*/
const CHARACTER = {
className: 'string',
begin: /"(""|[^/n])"C\b/
};
const STRING = {
className: 'string',
begin: /"/,
end: /"/,
illegal: /\n/,
contains: [
{
// double quote escape
begin: /""/ }
]
};
/** Date Literals consist of a date, a time, or both separated by whitespace, surrounded by # */
const MM_DD_YYYY = /\d{1,2}\/\d{1,2}\/\d{4}/;
const YYYY_MM_DD = /\d{4}-\d{1,2}-\d{1,2}/;
const TIME_12H = /(\d|1[012])(:\d+){0,2} *(AM|PM)/;
const TIME_24H = /\d{1,2}(:\d{1,2}){1,2}/;
const DATE = {
className: 'literal',
variants: [
{
// #YYYY-MM-DD# (ISO-Date) or #M/D/YYYY# (US-Date)
begin: regex.concat(/# */, regex.either(YYYY_MM_DD, MM_DD_YYYY), / *#/) },
{
// #H:mm[:ss]# (24h Time)
begin: regex.concat(/# */, TIME_24H, / *#/) },
{
// #h[:mm[:ss]] A# (12h Time)
begin: regex.concat(/# */, TIME_12H, / *#/) },
{
// date plus time
begin: regex.concat(
/# */,
regex.either(YYYY_MM_DD, MM_DD_YYYY),
/ +/,
regex.either(TIME_12H, TIME_24H),
/ *#/
) }
]
};
const NUMBER = {
className: 'number',
relevance: 0,
variants: [
{
// Float
begin: /\b\d[\d_]*((\.[\d_]+(E[+-]?[\d_]+)?)|(E[+-]?[\d_]+))[RFD@!#]?/ },
{
// Integer (base 10)
begin: /\b\d[\d_]*((U?[SIL])|[%&])?/ },
{
// Integer (base 16)
begin: /&H[\dA-F_]+((U?[SIL])|[%&])?/ },
{
// Integer (base 8)
begin: /&O[0-7_]+((U?[SIL])|[%&])?/ },
{
// Integer (base 2)
begin: /&B[01_]+((U?[SIL])|[%&])?/ }
]
};
const LABEL = {
className: 'label',
begin: /^\w+:/
};
const DOC_COMMENT = hljs.COMMENT(/'''/, /$/, { contains: [
{
className: 'doctag',
begin: /<\/?/,
end: />/
}
] });
const COMMENT = hljs.COMMENT(null, /$/, { variants: [
{ begin: /'/ },
{
// TODO: Use multi-class for leading spaces
begin: /([\t ]|^)REM(?=\s)/ }
] });
const DIRECTIVES = {
className: 'meta',
// TODO: Use multi-class for indentation once available
begin: /[\t ]*#(const|disable|else|elseif|enable|end|externalsource|if|region)\b/,
end: /$/,
keywords: { keyword:
'const disable else elseif enable end externalsource if region then' },
contains: [ COMMENT ]
};
return {
name: 'Visual Basic .NET',
aliases: [ 'vb' ],
case_insensitive: true,
classNameAliases: { label: 'symbol' },
keywords: {
keyword:
'addhandler alias aggregate ansi as async assembly auto binary by byref byval ' /* a-b */
+ 'call case catch class compare const continue custom declare default delegate dim distinct do ' /* c-d */
+ 'each equals else elseif end enum erase error event exit explicit finally for friend from function ' /* e-f */
+ 'get global goto group handles if implements imports in inherits interface into iterator ' /* g-i */
+ 'join key let lib loop me mid module mustinherit mustoverride mybase myclass ' /* j-m */
+ 'namespace narrowing new next notinheritable notoverridable ' /* n */
+ 'of off on operator option optional order overloads overridable overrides ' /* o */
+ 'paramarray partial preserve private property protected public ' /* p */
+ 'raiseevent readonly redim removehandler resume return ' /* r */
+ 'select set shadows shared skip static step stop structure strict sub synclock ' /* s */
+ 'take text then throw to try unicode until using when where while widening with withevents writeonly yield' /* t-y */,
built_in:
// Operators https://docs.microsoft.com/dotnet/visual-basic/language-reference/operators
'addressof and andalso await directcast gettype getxmlnamespace is isfalse isnot istrue like mod nameof new not or orelse trycast typeof xor '
// Type Conversion Functions https://docs.microsoft.com/dotnet/visual-basic/language-reference/functions/type-conversion-functions
+ 'cbool cbyte cchar cdate cdbl cdec cint clng cobj csbyte cshort csng cstr cuint culng cushort',
type:
// Data types https://docs.microsoft.com/dotnet/visual-basic/language-reference/data-types
'boolean byte char date decimal double integer long object sbyte short single string uinteger ulong ushort',
literal: 'true false nothing'
},
illegal:
'//|\\{|\\}|endif|gosub|variant|wend|^\\$ ' /* reserved deprecated keywords */,
contains: [
CHARACTER,
STRING,
DATE,
NUMBER,
LABEL,
DOC_COMMENT,
COMMENT,
DIRECTIVES
]
};
}
var vbnet_1 = vbnet;
/*
Language: VBScript
Description: VBScript ("Microsoft Visual Basic Scripting Edition") is an Active Scripting language developed by Microsoft that is modeled on Visual Basic.
Author: Nikita Ledyaev <lenikita@yandex.ru>
Contributors: Michal Gabrukiewicz <mgabru@gmail.com>
Website: https://en.wikipedia.org/wiki/VBScript
Category: scripting
*/
/** @type LanguageFn */
function vbscript(hljs) {
const regex = hljs.regex;
const BUILT_IN_FUNCTIONS = [
"lcase",
"month",
"vartype",
"instrrev",
"ubound",
"setlocale",
"getobject",
"rgb",
"getref",
"string",
"weekdayname",
"rnd",
"dateadd",
"monthname",
"now",
"day",
"minute",
"isarray",
"cbool",
"round",
"formatcurrency",
"conversions",
"csng",
"timevalue",
"second",
"year",
"space",
"abs",
"clng",
"timeserial",
"fixs",
"len",
"asc",
"isempty",
"maths",
"dateserial",
"atn",
"timer",
"isobject",
"filter",
"weekday",
"datevalue",
"ccur",
"isdate",
"instr",
"datediff",
"formatdatetime",
"replace",
"isnull",
"right",
"sgn",
"array",
"snumeric",
"log",
"cdbl",
"hex",
"chr",
"lbound",
"msgbox",
"ucase",
"getlocale",
"cos",
"cdate",
"cbyte",
"rtrim",
"join",
"hour",
"oct",
"typename",
"trim",
"strcomp",
"int",
"createobject",
"loadpicture",
"tan",
"formatnumber",
"mid",
"split",
"cint",
"sin",
"datepart",
"ltrim",
"sqr",
"time",
"derived",
"eval",
"date",
"formatpercent",
"exp",
"inputbox",
"left",
"ascw",
"chrw",
"regexp",
"cstr",
"err"
];
const BUILT_IN_OBJECTS = [
"server",
"response",
"request",
// take no arguments so can be called without ()
"scriptengine",
"scriptenginebuildversion",
"scriptengineminorversion",
"scriptenginemajorversion"
];
const BUILT_IN_CALL = {
begin: regex.concat(regex.either(...BUILT_IN_FUNCTIONS), "\\s*\\("),
// relevance 0 because this is acting as a beginKeywords really
relevance: 0,
keywords: { built_in: BUILT_IN_FUNCTIONS }
};
const LITERALS = [
"true",
"false",
"null",
"nothing",
"empty"
];
const KEYWORDS = [
"call",
"class",
"const",
"dim",
"do",
"loop",
"erase",
"execute",
"executeglobal",
"exit",
"for",
"each",
"next",
"function",
"if",
"then",
"else",
"on",
"error",
"option",
"explicit",
"new",
"private",
"property",
"let",
"get",
"public",
"randomize",
"redim",
"rem",
"select",
"case",
"set",
"stop",
"sub",
"while",
"wend",
"with",
"end",
"to",
"elseif",
"is",
"or",
"xor",
"and",
"not",
"class_initialize",
"class_terminate",
"default",
"preserve",
"in",
"me",
"byval",
"byref",
"step",
"resume",
"goto"
];
return {
name: 'VBScript',
aliases: [ 'vbs' ],
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_IN_OBJECTS,
literal: LITERALS
},
illegal: '//',
contains: [
BUILT_IN_CALL,
hljs.inherit(hljs.QUOTE_STRING_MODE, { contains: [ { begin: '""' } ] }),
hljs.COMMENT(
/'/,
/$/,
{ relevance: 0 }
),
hljs.C_NUMBER_MODE
]
};
}
var vbscript_1 = vbscript;
/*
Language: VBScript in HTML
Requires: xml.js, vbscript.js
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
Description: "Bridge" language defining fragments of VBScript in HTML within <% .. %>
Website: https://en.wikipedia.org/wiki/VBScript
Category: scripting
*/
function vbscriptHtml(hljs) {
return {
name: 'VBScript in HTML',
subLanguage: 'xml',
contains: [
{
begin: '<%',
end: '%>',
subLanguage: 'vbscript'
}
]
};
}
var vbscriptHtml_1 = vbscriptHtml;
/*
Language: Verilog
Author: Jon Evans <jon@craftyjon.com>
Contributors: Boone Severson <boone.severson@gmail.com>
Description: Verilog is a hardware description language used in electronic design automation to describe digital and mixed-signal systems. This highlighter supports Verilog and SystemVerilog through IEEE 1800-2012.
Website: http://www.verilog.com
*/
function verilog(hljs) {
const regex = hljs.regex;
const KEYWORDS = {
$pattern: /\$?[\w]+(\$[\w]+)*/,
keyword: [
"accept_on",
"alias",
"always",
"always_comb",
"always_ff",
"always_latch",
"and",
"assert",
"assign",
"assume",
"automatic",
"before",
"begin",
"bind",
"bins",
"binsof",
"bit",
"break",
"buf|0",
"bufif0",
"bufif1",
"byte",
"case",
"casex",
"casez",
"cell",
"chandle",
"checker",
"class",
"clocking",
"cmos",
"config",
"const",
"constraint",
"context",
"continue",
"cover",
"covergroup",
"coverpoint",
"cross",
"deassign",
"default",
"defparam",
"design",
"disable",
"dist",
"do",
"edge",
"else",
"end",
"endcase",
"endchecker",
"endclass",
"endclocking",
"endconfig",
"endfunction",
"endgenerate",
"endgroup",
"endinterface",
"endmodule",
"endpackage",
"endprimitive",
"endprogram",
"endproperty",
"endspecify",
"endsequence",
"endtable",
"endtask",
"enum",
"event",
"eventually",
"expect",
"export",
"extends",
"extern",
"final",
"first_match",
"for",
"force",
"foreach",
"forever",
"fork",
"forkjoin",
"function",
"generate|5",
"genvar",
"global",
"highz0",
"highz1",
"if",
"iff",
"ifnone",
"ignore_bins",
"illegal_bins",
"implements",
"implies",
"import",
"incdir",
"include",
"initial",
"inout",
"input",
"inside",
"instance",
"int",
"integer",
"interconnect",
"interface",
"intersect",
"join",
"join_any",
"join_none",
"large",
"let",
"liblist",
"library",
"local",
"localparam",
"logic",
"longint",
"macromodule",
"matches",
"medium",
"modport",
"module",
"nand",
"negedge",
"nettype",
"new",
"nexttime",
"nmos",
"nor",
"noshowcancelled",
"not",
"notif0",
"notif1",
"or",
"output",
"package",
"packed",
"parameter",
"pmos",
"posedge",
"primitive",
"priority",
"program",
"property",
"protected",
"pull0",
"pull1",
"pulldown",
"pullup",
"pulsestyle_ondetect",
"pulsestyle_onevent",
"pure",
"rand",
"randc",
"randcase",
"randsequence",
"rcmos",
"real",
"realtime",
"ref",
"reg",
"reject_on",
"release",
"repeat",
"restrict",
"return",
"rnmos",
"rpmos",
"rtran",
"rtranif0",
"rtranif1",
"s_always",
"s_eventually",
"s_nexttime",
"s_until",
"s_until_with",
"scalared",
"sequence",
"shortint",
"shortreal",
"showcancelled",
"signed",
"small",
"soft",
"solve",
"specify",
"specparam",
"static",
"string",
"strong",
"strong0",
"strong1",
"struct",
"super",
"supply0",
"supply1",
"sync_accept_on",
"sync_reject_on",
"table",
"tagged",
"task",
"this",
"throughout",
"time",
"timeprecision",
"timeunit",
"tran",
"tranif0",
"tranif1",
"tri",
"tri0",
"tri1",
"triand",
"trior",
"trireg",
"type",
"typedef",
"union",
"unique",
"unique0",
"unsigned",
"until",
"until_with",
"untyped",
"use",
"uwire",
"var",
"vectored",
"virtual",
"void",
"wait",
"wait_order",
"wand",
"weak",
"weak0",
"weak1",
"while",
"wildcard",
"wire",
"with",
"within",
"wor",
"xnor",
"xor"
],
literal: [ 'null' ],
built_in: [
"$finish",
"$stop",
"$exit",
"$fatal",
"$error",
"$warning",
"$info",
"$realtime",
"$time",
"$printtimescale",
"$bitstoreal",
"$bitstoshortreal",
"$itor",
"$signed",
"$cast",
"$bits",
"$stime",
"$timeformat",
"$realtobits",
"$shortrealtobits",
"$rtoi",
"$unsigned",
"$asserton",
"$assertkill",
"$assertpasson",
"$assertfailon",
"$assertnonvacuouson",
"$assertoff",
"$assertcontrol",
"$assertpassoff",
"$assertfailoff",
"$assertvacuousoff",
"$isunbounded",
"$sampled",
"$fell",
"$changed",
"$past_gclk",
"$fell_gclk",
"$changed_gclk",
"$rising_gclk",
"$steady_gclk",
"$coverage_control",
"$coverage_get",
"$coverage_save",
"$set_coverage_db_name",
"$rose",
"$stable",
"$past",
"$rose_gclk",
"$stable_gclk",
"$future_gclk",
"$falling_gclk",
"$changing_gclk",
"$display",
"$coverage_get_max",
"$coverage_merge",
"$get_coverage",
"$load_coverage_db",
"$typename",
"$unpacked_dimensions",
"$left",
"$low",
"$increment",
"$clog2",
"$ln",
"$log10",
"$exp",
"$sqrt",
"$pow",
"$floor",
"$ceil",
"$sin",
"$cos",
"$tan",
"$countbits",
"$onehot",
"$isunknown",
"$fatal",
"$warning",
"$dimensions",
"$right",
"$high",
"$size",
"$asin",
"$acos",
"$atan",
"$atan2",
"$hypot",
"$sinh",
"$cosh",
"$tanh",
"$asinh",
"$acosh",
"$atanh",
"$countones",
"$onehot0",
"$error",
"$info",
"$random",
"$dist_chi_square",
"$dist_erlang",
"$dist_exponential",
"$dist_normal",
"$dist_poisson",
"$dist_t",
"$dist_uniform",
"$q_initialize",
"$q_remove",
"$q_exam",
"$async$and$array",
"$async$nand$array",
"$async$or$array",
"$async$nor$array",
"$sync$and$array",
"$sync$nand$array",
"$sync$or$array",
"$sync$nor$array",
"$q_add",
"$q_full",
"$psprintf",
"$async$and$plane",
"$async$nand$plane",
"$async$or$plane",
"$async$nor$plane",
"$sync$and$plane",
"$sync$nand$plane",
"$sync$or$plane",
"$sync$nor$plane",
"$system",
"$display",
"$displayb",
"$displayh",
"$displayo",
"$strobe",
"$strobeb",
"$strobeh",
"$strobeo",
"$write",
"$readmemb",
"$readmemh",
"$writememh",
"$value$plusargs",
"$dumpvars",
"$dumpon",
"$dumplimit",
"$dumpports",
"$dumpportson",
"$dumpportslimit",
"$writeb",
"$writeh",
"$writeo",
"$monitor",
"$monitorb",
"$monitorh",
"$monitoro",
"$writememb",
"$dumpfile",
"$dumpoff",
"$dumpall",
"$dumpflush",
"$dumpportsoff",
"$dumpportsall",
"$dumpportsflush",
"$fclose",
"$fdisplay",
"$fdisplayb",
"$fdisplayh",
"$fdisplayo",
"$fstrobe",
"$fstrobeb",
"$fstrobeh",
"$fstrobeo",
"$swrite",
"$swriteb",
"$swriteh",
"$swriteo",
"$fscanf",
"$fread",
"$fseek",
"$fflush",
"$feof",
"$fopen",
"$fwrite",
"$fwriteb",
"$fwriteh",
"$fwriteo",
"$fmonitor",
"$fmonitorb",
"$fmonitorh",
"$fmonitoro",
"$sformat",
"$sformatf",
"$fgetc",
"$ungetc",
"$fgets",
"$sscanf",
"$rewind",
"$ftell",
"$ferror"
]
};
const BUILT_IN_CONSTANTS = [
"__FILE__",
"__LINE__"
];
const DIRECTIVES = [
"begin_keywords",
"celldefine",
"default_nettype",
"default_decay_time",
"default_trireg_strength",
"define",
"delay_mode_distributed",
"delay_mode_path",
"delay_mode_unit",
"delay_mode_zero",
"else",
"elsif",
"end_keywords",
"endcelldefine",
"endif",
"ifdef",
"ifndef",
"include",
"line",
"nounconnected_drive",
"pragma",
"resetall",
"timescale",
"unconnected_drive",
"undef",
"undefineall"
];
return {
name: 'Verilog',
aliases: [
'v',
'sv',
'svh'
],
case_insensitive: false,
keywords: KEYWORDS,
contains: [
hljs.C_BLOCK_COMMENT_MODE,
hljs.C_LINE_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
{
scope: 'number',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
{ begin: /\b((\d+'([bhodBHOD]))[0-9xzXZa-fA-F_]+)/ },
{ begin: /\B(('([bhodBHOD]))[0-9xzXZa-fA-F_]+)/ },
{ // decimal
begin: /\b[0-9][0-9_]*/,
relevance: 0
}
]
},
/* parameters to instances */
{
scope: 'variable',
variants: [
{ begin: '#\\((?!parameter).+\\)' },
{
begin: '\\.\\w+',
relevance: 0
}
]
},
{
scope: 'variable.constant',
match: regex.concat(/`/, regex.either(...BUILT_IN_CONSTANTS)),
},
{
scope: 'meta',
begin: regex.concat(/`/, regex.either(...DIRECTIVES)),
end: /$|\/\/|\/\*/,
returnEnd: true,
keywords: DIRECTIVES
}
]
};
}
var verilog_1 = verilog;
/*
Language: VHDL
Author: Igor Kalnitsky <igor@kalnitsky.org>
Contributors: Daniel C.K. Kho <daniel.kho@tauhop.com>, Guillaume Savaton <guillaume.savaton@eseo.fr>
Description: VHDL is a hardware description language used in electronic design automation to describe digital and mixed-signal systems.
Website: https://en.wikipedia.org/wiki/VHDL
*/
function vhdl(hljs) {
// Regular expression for VHDL numeric literals.
// Decimal literal:
const INTEGER_RE = '\\d(_|\\d)*';
const EXPONENT_RE = '[eE][-+]?' + INTEGER_RE;
const DECIMAL_LITERAL_RE = INTEGER_RE + '(\\.' + INTEGER_RE + ')?' + '(' + EXPONENT_RE + ')?';
// Based literal:
const BASED_INTEGER_RE = '\\w+';
const BASED_LITERAL_RE = INTEGER_RE + '#' + BASED_INTEGER_RE + '(\\.' + BASED_INTEGER_RE + ')?' + '#' + '(' + EXPONENT_RE + ')?';
const NUMBER_RE = '\\b(' + BASED_LITERAL_RE + '|' + DECIMAL_LITERAL_RE + ')';
const KEYWORDS = [
"abs",
"access",
"after",
"alias",
"all",
"and",
"architecture",
"array",
"assert",
"assume",
"assume_guarantee",
"attribute",
"begin",
"block",
"body",
"buffer",
"bus",
"case",
"component",
"configuration",
"constant",
"context",
"cover",
"disconnect",
"downto",
"default",
"else",
"elsif",
"end",
"entity",
"exit",
"fairness",
"file",
"for",
"force",
"function",
"generate",
"generic",
"group",
"guarded",
"if",
"impure",
"in",
"inertial",
"inout",
"is",
"label",
"library",
"linkage",
"literal",
"loop",
"map",
"mod",
"nand",
"new",
"next",
"nor",
"not",
"null",
"of",
"on",
"open",
"or",
"others",
"out",
"package",
"parameter",
"port",
"postponed",
"procedure",
"process",
"property",
"protected",
"pure",
"range",
"record",
"register",
"reject",
"release",
"rem",
"report",
"restrict",
"restrict_guarantee",
"return",
"rol",
"ror",
"select",
"sequence",
"severity",
"shared",
"signal",
"sla",
"sll",
"sra",
"srl",
"strong",
"subtype",
"then",
"to",
"transport",
"type",
"unaffected",
"units",
"until",
"use",
"variable",
"view",
"vmode",
"vprop",
"vunit",
"wait",
"when",
"while",
"with",
"xnor",
"xor"
];
const BUILT_INS = [
"boolean",
"bit",
"character",
"integer",
"time",
"delay_length",
"natural",
"positive",
"string",
"bit_vector",
"file_open_kind",
"file_open_status",
"std_logic",
"std_logic_vector",
"unsigned",
"signed",
"boolean_vector",
"integer_vector",
"std_ulogic",
"std_ulogic_vector",
"unresolved_unsigned",
"u_unsigned",
"unresolved_signed",
"u_signed",
"real_vector",
"time_vector"
];
const LITERALS = [
// severity_level
"false",
"true",
"note",
"warning",
"error",
"failure",
// textio
"line",
"text",
"side",
"width"
];
return {
name: 'VHDL',
case_insensitive: true,
keywords: {
keyword: KEYWORDS,
built_in: BUILT_INS,
literal: LITERALS
},
illegal: /\{/,
contains: [
hljs.C_BLOCK_COMMENT_MODE, // VHDL-2008 block commenting.
hljs.COMMENT('--', '$'),
hljs.QUOTE_STRING_MODE,
{
className: 'number',
begin: NUMBER_RE,
relevance: 0
},
{
className: 'string',
begin: '\'(U|X|0|1|Z|W|L|H|-)\'',
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
className: 'symbol',
begin: '\'[A-Za-z](_?[A-Za-z0-9])*',
contains: [ hljs.BACKSLASH_ESCAPE ]
}
]
};
}
var vhdl_1 = vhdl;
/*
Language: Vim Script
Author: Jun Yang <yangjvn@126.com>
Description: full keyword and built-in from http://vimdoc.sourceforge.net/htmldoc/
Website: https://www.vim.org
Category: scripting
*/
function vim(hljs) {
return {
name: 'Vim Script',
keywords: {
$pattern: /[!#@\w]+/,
keyword:
// express version except: ! & * < = > !! # @ @@
'N|0 P|0 X|0 a|0 ab abc abo al am an|0 ar arga argd arge argdo argg argl argu as au aug aun b|0 bN ba bad bd be bel bf bl bm bn bo bp br brea breaka breakd breakl bro bufdo buffers bun bw c|0 cN cNf ca cabc caddb cad caddf cal cat cb cc ccl cd ce cex cf cfir cgetb cgete cg changes chd che checkt cl cla clo cm cmapc cme cn cnew cnf cno cnorea cnoreme co col colo com comc comp con conf cope '
+ 'cp cpf cq cr cs cst cu cuna cunme cw delm deb debugg delc delf dif diffg diffo diffp diffpu diffs diffthis dig di dl dell dj dli do doautoa dp dr ds dsp e|0 ea ec echoe echoh echom echon el elsei em en endfo endf endt endw ene ex exe exi exu f|0 files filet fin fina fini fir fix fo foldc foldd folddoc foldo for fu go gr grepa gu gv ha helpf helpg helpt hi hid his ia iabc if ij il im imapc '
+ 'ime ino inorea inoreme int is isp iu iuna iunme j|0 ju k|0 keepa kee keepj lN lNf l|0 lad laddb laddf la lan lat lb lc lch lcl lcs le lefta let lex lf lfir lgetb lgete lg lgr lgrepa lh ll lla lli lmak lm lmapc lne lnew lnf ln loadk lo loc lockv lol lope lp lpf lr ls lt lu lua luad luaf lv lvimgrepa lw m|0 ma mak map mapc marks mat me menut mes mk mks mksp mkv mkvie mod mz mzf nbc nb nbs new nm nmapc nme nn nnoreme noa no noh norea noreme norm nu nun nunme ol o|0 om omapc ome on ono onoreme opt ou ounme ow p|0 '
+ 'profd prof pro promptr pc ped pe perld po popu pp pre prev ps pt ptN ptf ptj ptl ptn ptp ptr pts pu pw py3 python3 py3d py3f py pyd pyf quita qa rec red redi redr redraws reg res ret retu rew ri rightb rub rubyd rubyf rund ru rv sN san sa sal sav sb sbN sba sbf sbl sbm sbn sbp sbr scrip scripte scs se setf setg setl sf sfir sh sim sig sil sl sla sm smap smapc sme sn sni sno snor snoreme sor '
+ 'so spelld spe spelli spellr spellu spellw sp spr sre st sta startg startr star stopi stj sts sun sunm sunme sus sv sw sy synti sync tN tabN tabc tabdo tabe tabf tabfir tabl tabm tabnew '
+ 'tabn tabo tabp tabr tabs tab ta tags tc tcld tclf te tf th tj tl tm tn to tp tr try ts tu u|0 undoj undol una unh unl unlo unm unme uns up ve verb vert vim vimgrepa vi viu vie vm vmapc vme vne vn vnoreme vs vu vunme windo w|0 wN wa wh wi winc winp wn wp wq wqa ws wu wv x|0 xa xmapc xm xme xn xnoreme xu xunme y|0 z|0 ~ '
// full version
+ 'Next Print append abbreviate abclear aboveleft all amenu anoremenu args argadd argdelete argedit argglobal arglocal argument ascii autocmd augroup aunmenu buffer bNext ball badd bdelete behave belowright bfirst blast bmodified bnext botright bprevious brewind break breakadd breakdel breaklist browse bunload '
+ 'bwipeout change cNext cNfile cabbrev cabclear caddbuffer caddexpr caddfile call catch cbuffer cclose center cexpr cfile cfirst cgetbuffer cgetexpr cgetfile chdir checkpath checktime clist clast close cmap cmapclear cmenu cnext cnewer cnfile cnoremap cnoreabbrev cnoremenu copy colder colorscheme command comclear compiler continue confirm copen cprevious cpfile cquit crewind cscope cstag cunmap '
+ 'cunabbrev cunmenu cwindow delete delmarks debug debuggreedy delcommand delfunction diffupdate diffget diffoff diffpatch diffput diffsplit digraphs display deletel djump dlist doautocmd doautoall deletep drop dsearch dsplit edit earlier echo echoerr echohl echomsg else elseif emenu endif endfor '
+ 'endfunction endtry endwhile enew execute exit exusage file filetype find finally finish first fixdel fold foldclose folddoopen folddoclosed foldopen function global goto grep grepadd gui gvim hardcopy help helpfind helpgrep helptags highlight hide history insert iabbrev iabclear ijump ilist imap '
+ 'imapclear imenu inoremap inoreabbrev inoremenu intro isearch isplit iunmap iunabbrev iunmenu join jumps keepalt keepmarks keepjumps lNext lNfile list laddexpr laddbuffer laddfile last language later lbuffer lcd lchdir lclose lcscope left leftabove lexpr lfile lfirst lgetbuffer lgetexpr lgetfile lgrep lgrepadd lhelpgrep llast llist lmake lmap lmapclear lnext lnewer lnfile lnoremap loadkeymap loadview '
+ 'lockmarks lockvar lolder lopen lprevious lpfile lrewind ltag lunmap luado luafile lvimgrep lvimgrepadd lwindow move mark make mapclear match menu menutranslate messages mkexrc mksession mkspell mkvimrc mkview mode mzscheme mzfile nbclose nbkey nbsart next nmap nmapclear nmenu nnoremap '
+ 'nnoremenu noautocmd noremap nohlsearch noreabbrev noremenu normal number nunmap nunmenu oldfiles open omap omapclear omenu only onoremap onoremenu options ounmap ounmenu ownsyntax print profdel profile promptfind promptrepl pclose pedit perl perldo pop popup ppop preserve previous psearch ptag ptNext '
+ 'ptfirst ptjump ptlast ptnext ptprevious ptrewind ptselect put pwd py3do py3file python pydo pyfile quit quitall qall read recover redo redir redraw redrawstatus registers resize retab return rewind right rightbelow ruby rubydo rubyfile rundo runtime rviminfo substitute sNext sandbox sargument sall saveas sbuffer sbNext sball sbfirst sblast sbmodified sbnext sbprevious sbrewind scriptnames scriptencoding '
+ 'scscope set setfiletype setglobal setlocal sfind sfirst shell simalt sign silent sleep slast smagic smapclear smenu snext sniff snomagic snoremap snoremenu sort source spelldump spellgood spellinfo spellrepall spellundo spellwrong split sprevious srewind stop stag startgreplace startreplace '
+ 'startinsert stopinsert stjump stselect sunhide sunmap sunmenu suspend sview swapname syntax syntime syncbind tNext tabNext tabclose tabedit tabfind tabfirst tablast tabmove tabnext tabonly tabprevious tabrewind tag tcl tcldo tclfile tearoff tfirst throw tjump tlast tmenu tnext topleft tprevious ' + 'trewind tselect tunmenu undo undojoin undolist unabbreviate unhide unlet unlockvar unmap unmenu unsilent update vglobal version verbose vertical vimgrep vimgrepadd visual viusage view vmap vmapclear vmenu vnew '
+ 'vnoremap vnoremenu vsplit vunmap vunmenu write wNext wall while winsize wincmd winpos wnext wprevious wqall wsverb wundo wviminfo xit xall xmapclear xmap xmenu xnoremap xnoremenu xunmap xunmenu yank',
built_in: // built in func
'synIDtrans atan2 range matcharg did_filetype asin feedkeys xor argv '
+ 'complete_check add getwinposx getqflist getwinposy screencol '
+ 'clearmatches empty extend getcmdpos mzeval garbagecollect setreg '
+ 'ceil sqrt diff_hlID inputsecret get getfperm getpid filewritable '
+ 'shiftwidth max sinh isdirectory synID system inputrestore winline '
+ 'atan visualmode inputlist tabpagewinnr round getregtype mapcheck '
+ 'hasmapto histdel argidx findfile sha256 exists toupper getcmdline '
+ 'taglist string getmatches bufnr strftime winwidth bufexists '
+ 'strtrans tabpagebuflist setcmdpos remote_read printf setloclist '
+ 'getpos getline bufwinnr float2nr len getcmdtype diff_filler luaeval '
+ 'resolve libcallnr foldclosedend reverse filter has_key bufname '
+ 'str2float strlen setline getcharmod setbufvar index searchpos '
+ 'shellescape undofile foldclosed setqflist buflisted strchars str2nr '
+ 'virtcol floor remove undotree remote_expr winheight gettabwinvar '
+ 'reltime cursor tabpagenr finddir localtime acos getloclist search '
+ 'tanh matchend rename gettabvar strdisplaywidth type abs py3eval '
+ 'setwinvar tolower wildmenumode log10 spellsuggest bufloaded '
+ 'synconcealed nextnonblank server2client complete settabwinvar '
+ 'executable input wincol setmatches getftype hlID inputsave '
+ 'searchpair or screenrow line settabvar histadd deepcopy strpart '
+ 'remote_peek and eval getftime submatch screenchar winsaveview '
+ 'matchadd mkdir screenattr getfontname libcall reltimestr getfsize '
+ 'winnr invert pow getbufline byte2line soundfold repeat fnameescape '
+ 'tagfiles sin strwidth spellbadword trunc maparg log lispindent '
+ 'hostname setpos globpath remote_foreground getchar synIDattr '
+ 'fnamemodify cscope_connection stridx winbufnr indent min '
+ 'complete_add nr2char searchpairpos inputdialog values matchlist '
+ 'items hlexists strridx browsedir expand fmod pathshorten line2byte '
+ 'argc count getwinvar glob foldtextresult getreg foreground cosh '
+ 'matchdelete has char2nr simplify histget searchdecl iconv '
+ 'winrestcmd pumvisible writefile foldlevel haslocaldir keys cos '
+ 'matchstr foldtext histnr tan tempname getcwd byteidx getbufvar '
+ 'islocked escape eventhandler remote_send serverlist winrestview '
+ 'synstack pyeval prevnonblank readfile cindent filereadable changenr '
+ 'exp'
},
illegal: /;/,
contains: [
hljs.NUMBER_MODE,
{
className: 'string',
begin: '\'',
end: '\'',
illegal: '\\n'
},
/*
A double quote can start either a string or a line comment. Strings are
ended before the end of a line by another double quote and can contain
escaped double-quotes and post-escaped line breaks.
Also, any double quote at the beginning of a line is a comment but we
don't handle that properly at the moment: any double quote inside will
turn them into a string. Handling it properly will require a smarter
parser.
*/
{
className: 'string',
begin: /"(\\"|\n\\|[^"\n])*"/
},
hljs.COMMENT('"', '$'),
{
className: 'variable',
begin: /[bwtglsav]:[\w\d_]+/
},
{
begin: [
/\b(?:function|function!)/,
/\s+/,
hljs.IDENT_RE
],
className: {
1: "keyword",
3: "title"
},
end: '$',
relevance: 0,
contains: [
{
className: 'params',
begin: '\\(',
end: '\\)'
}
]
},
{
className: 'symbol',
begin: /<[\w-]+>/
}
]
};
}
var vim_1 = vim;
/*
Language: WebAssembly
Website: https://webassembly.org
Description: Wasm is designed as a portable compilation target for programming languages, enabling deployment on the web for client and server applications.
Category: web, common
Audit: 2020
*/
/** @type LanguageFn */
function wasm(hljs) {
hljs.regex;
const BLOCK_COMMENT = hljs.COMMENT(/\(;/, /;\)/);
BLOCK_COMMENT.contains.push("self");
const LINE_COMMENT = hljs.COMMENT(/;;/, /$/);
const KWS = [
"anyfunc",
"block",
"br",
"br_if",
"br_table",
"call",
"call_indirect",
"data",
"drop",
"elem",
"else",
"end",
"export",
"func",
"global.get",
"global.set",
"local.get",
"local.set",
"local.tee",
"get_global",
"get_local",
"global",
"if",
"import",
"local",
"loop",
"memory",
"memory.grow",
"memory.size",
"module",
"mut",
"nop",
"offset",
"param",
"result",
"return",
"select",
"set_global",
"set_local",
"start",
"table",
"tee_local",
"then",
"type",
"unreachable"
];
const FUNCTION_REFERENCE = {
begin: [
/(?:func|call|call_indirect)/,
/\s+/,
/\$[^\s)]+/
],
className: {
1: "keyword",
3: "title.function"
}
};
const ARGUMENT = {
className: "variable",
begin: /\$[\w_]+/
};
const PARENS = {
match: /(\((?!;)|\))+/,
className: "punctuation",
relevance: 0
};
const NUMBER = {
className: "number",
relevance: 0,
// borrowed from Prism, TODO: split out into variants
match: /[+-]?\b(?:\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:[eE][+-]?\d(?:_?\d)*)?|0x[\da-fA-F](?:_?[\da-fA-F])*(?:\.[\da-fA-F](?:_?[\da-fA-D])*)?(?:[pP][+-]?\d(?:_?\d)*)?)\b|\binf\b|\bnan(?::0x[\da-fA-F](?:_?[\da-fA-D])*)?\b/
};
const TYPE = {
// look-ahead prevents us from gobbling up opcodes
match: /(i32|i64|f32|f64)(?!\.)/,
className: "type"
};
const MATH_OPERATIONS = {
className: "keyword",
// borrowed from Prism, TODO: split out into variants
match: /\b(f32|f64|i32|i64)(?:\.(?:abs|add|and|ceil|clz|const|convert_[su]\/i(?:32|64)|copysign|ctz|demote\/f64|div(?:_[su])?|eqz?|extend_[su]\/i32|floor|ge(?:_[su])?|gt(?:_[su])?|le(?:_[su])?|load(?:(?:8|16|32)_[su])?|lt(?:_[su])?|max|min|mul|nearest|neg?|or|popcnt|promote\/f32|reinterpret\/[fi](?:32|64)|rem_[su]|rot[lr]|shl|shr_[su]|store(?:8|16|32)?|sqrt|sub|trunc(?:_[su]\/f(?:32|64))?|wrap\/i64|xor))\b/
};
const OFFSET_ALIGN = {
match: [
/(?:offset|align)/,
/\s*/,
/=/
],
className: {
1: "keyword",
3: "operator"
}
};
return {
name: 'WebAssembly',
keywords: {
$pattern: /[\w.]+/,
keyword: KWS
},
contains: [
LINE_COMMENT,
BLOCK_COMMENT,
OFFSET_ALIGN,
ARGUMENT,
PARENS,
FUNCTION_REFERENCE,
hljs.QUOTE_STRING_MODE,
TYPE,
MATH_OPERATIONS,
NUMBER
]
};
}
var wasm_1 = wasm;
/*
Language: Wren
Description: Think Smalltalk in a Lua-sized package with a dash of Erlang and wrapped up in a familiar, modern syntax.
Category: scripting
Author: @joshgoebel
Maintainer: @joshgoebel
Website: https://wren.io/
*/
/** @type LanguageFn */
function wren(hljs) {
const regex = hljs.regex;
const IDENT_RE = /[a-zA-Z]\w*/;
const KEYWORDS = [
"as",
"break",
"class",
"construct",
"continue",
"else",
"for",
"foreign",
"if",
"import",
"in",
"is",
"return",
"static",
"var",
"while"
];
const LITERALS = [
"true",
"false",
"null"
];
const LANGUAGE_VARS = [
"this",
"super"
];
const CORE_CLASSES = [
"Bool",
"Class",
"Fiber",
"Fn",
"List",
"Map",
"Null",
"Num",
"Object",
"Range",
"Sequence",
"String",
"System"
];
const OPERATORS = [
"-",
"~",
/\*/,
"%",
/\.\.\./,
/\.\./,
/\+/,
"<<",
">>",
">=",
"<=",
"<",
">",
/\^/,
/!=/,
/!/,
/\bis\b/,
"==",
"&&",
"&",
/\|\|/,
/\|/,
/\?:/,
"="
];
const FUNCTION = {
relevance: 0,
match: regex.concat(/\b(?!(if|while|for|else|super)\b)/, IDENT_RE, /(?=\s*[({])/),
className: "title.function"
};
const FUNCTION_DEFINITION = {
match: regex.concat(
regex.either(
regex.concat(/\b(?!(if|while|for|else|super)\b)/, IDENT_RE),
regex.either(...OPERATORS)
),
/(?=\s*\([^)]+\)\s*\{)/),
className: "title.function",
starts: { contains: [
{
begin: /\(/,
end: /\)/,
contains: [
{
relevance: 0,
scope: "params",
match: IDENT_RE
}
]
}
] }
};
const CLASS_DEFINITION = {
variants: [
{ match: [
/class\s+/,
IDENT_RE,
/\s+is\s+/,
IDENT_RE
] },
{ match: [
/class\s+/,
IDENT_RE
] }
],
scope: {
2: "title.class",
4: "title.class.inherited"
},
keywords: KEYWORDS
};
const OPERATOR = {
relevance: 0,
match: regex.either(...OPERATORS),
className: "operator"
};
const TRIPLE_STRING = {
className: "string",
begin: /"""/,
end: /"""/
};
const PROPERTY = {
className: "property",
begin: regex.concat(/\./, regex.lookahead(IDENT_RE)),
end: IDENT_RE,
excludeBegin: true,
relevance: 0
};
const FIELD = {
relevance: 0,
match: regex.concat(/\b_/, IDENT_RE),
scope: "variable"
};
// CamelCase
const CLASS_REFERENCE = {
relevance: 0,
match: /\b[A-Z]+[a-z]+([A-Z]+[a-z]+)*/,
scope: "title.class",
keywords: { _: CORE_CLASSES }
};
// TODO: add custom number modes
const NUMBER = hljs.C_NUMBER_MODE;
const SETTER = {
match: [
IDENT_RE,
/\s*/,
/=/,
/\s*/,
/\(/,
IDENT_RE,
/\)\s*\{/
],
scope: {
1: "title.function",
3: "operator",
6: "params"
}
};
const COMMENT_DOCS = hljs.COMMENT(
/\/\*\*/,
/\*\//,
{ contains: [
{
match: /@[a-z]+/,
scope: "doctag"
},
"self"
] }
);
const SUBST = {
scope: "subst",
begin: /%\(/,
end: /\)/,
contains: [
NUMBER,
CLASS_REFERENCE,
FUNCTION,
FIELD,
OPERATOR
]
};
const STRING = {
scope: "string",
begin: /"/,
end: /"/,
contains: [
SUBST,
{
scope: "char.escape",
variants: [
{ match: /\\\\|\\["0%abefnrtv]/ },
{ match: /\\x[0-9A-F]{2}/ },
{ match: /\\u[0-9A-F]{4}/ },
{ match: /\\U[0-9A-F]{8}/ }
]
}
]
};
SUBST.contains.push(STRING);
const ALL_KWS = [
...KEYWORDS,
...LANGUAGE_VARS,
...LITERALS
];
const VARIABLE = {
relevance: 0,
match: regex.concat(
"\\b(?!",
ALL_KWS.join("|"),
"\\b)",
/[a-zA-Z_]\w*(?:[?!]|\b)/
),
className: "variable"
};
// TODO: reconsider this in the future
const ATTRIBUTE = {
// scope: "meta",
scope: "comment",
variants: [
{
begin: [
/#!?/,
/[A-Za-z_]+(?=\()/
],
beginScope: {
// 2: "attr"
},
keywords: { literal: LITERALS },
contains: [
// NUMBER,
// VARIABLE
],
end: /\)/
},
{
begin: [
/#!?/,
/[A-Za-z_]+/
],
beginScope: {
// 2: "attr"
},
end: /$/
}
]
};
return {
name: "Wren",
keywords: {
keyword: KEYWORDS,
"variable.language": LANGUAGE_VARS,
literal: LITERALS
},
contains: [
ATTRIBUTE,
NUMBER,
STRING,
TRIPLE_STRING,
COMMENT_DOCS,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
CLASS_REFERENCE,
CLASS_DEFINITION,
SETTER,
FUNCTION_DEFINITION,
FUNCTION,
OPERATOR,
FIELD,
PROPERTY,
VARIABLE
]
};
}
var wren_1 = wren;
/*
Language: Intel x86 Assembly
Author: innocenat <innocenat@gmail.com>
Description: x86 assembly language using Intel's mnemonic and NASM syntax
Website: https://en.wikipedia.org/wiki/X86_assembly_language
Category: assembler
*/
function x86asm(hljs) {
return {
name: 'Intel x86 Assembly',
case_insensitive: true,
keywords: {
$pattern: '[.%]?' + hljs.IDENT_RE,
keyword:
'lock rep repe repz repne repnz xaquire xrelease bnd nobnd '
+ 'aaa aad aam aas adc add and arpl bb0_reset bb1_reset bound bsf bsr bswap bt btc btr bts call cbw cdq cdqe clc cld cli clts cmc cmp cmpsb cmpsd cmpsq cmpsw cmpxchg cmpxchg486 cmpxchg8b cmpxchg16b cpuid cpu_read cpu_write cqo cwd cwde daa das dec div dmint emms enter equ f2xm1 fabs fadd faddp fbld fbstp fchs fclex fcmovb fcmovbe fcmove fcmovnb fcmovnbe fcmovne fcmovnu fcmovu fcom fcomi fcomip fcomp fcompp fcos fdecstp fdisi fdiv fdivp fdivr fdivrp femms feni ffree ffreep fiadd ficom ficomp fidiv fidivr fild fimul fincstp finit fist fistp fisttp fisub fisubr fld fld1 fldcw fldenv fldl2e fldl2t fldlg2 fldln2 fldpi fldz fmul fmulp fnclex fndisi fneni fninit fnop fnsave fnstcw fnstenv fnstsw fpatan fprem fprem1 fptan frndint frstor fsave fscale fsetpm fsin fsincos fsqrt fst fstcw fstenv fstp fstsw fsub fsubp fsubr fsubrp ftst fucom fucomi fucomip fucomp fucompp fxam fxch fxtract fyl2x fyl2xp1 hlt ibts icebp idiv imul in inc incbin insb insd insw int int01 int1 int03 int3 into invd invpcid invlpg invlpga iret iretd iretq iretw jcxz jecxz jrcxz jmp jmpe lahf lar lds lea leave les lfence lfs lgdt lgs lidt lldt lmsw loadall loadall286 lodsb lodsd lodsq lodsw loop loope loopne loopnz loopz lsl lss ltr mfence monitor mov movd movq movsb movsd movsq movsw movsx movsxd movzx mul mwait neg nop not or out outsb outsd outsw packssdw packsswb packuswb paddb paddd paddsb paddsiw paddsw paddusb paddusw paddw pand pandn pause paveb pavgusb pcmpeqb pcmpeqd pcmpeqw pcmpgtb pcmpgtd pcmpgtw pdistib pf2id pfacc pfadd pfcmpeq pfcmpge pfcmpgt pfmax pfmin pfmul pfrcp pfrcpit1 pfrcpit2 pfrsqit1 pfrsqrt pfsub pfsubr pi2fd pmachriw pmaddwd pmagw pmulhriw pmulhrwa pmulhrwc pmulhw pmullw pmvgezb pmvlzb pmvnzb pmvzb pop popa popad popaw popf popfd popfq popfw por prefetch prefetchw pslld psllq psllw psrad psraw psrld psrlq psrlw psubb psubd psubsb psubsiw psubsw psubusb psubusw psubw punpckhbw punpckhdq punpckhwd punpcklbw punpckldq punpcklwd push pusha pushad pushaw pushf pushfd pushfq pushfw pxor rcl rcr rdshr rdmsr rdpmc rdtsc rdtscp ret retf retn rol ror rdm rsdc rsldt rsm rsts sahf sal salc sar sbb scasb scasd scasq scasw sfence sgdt shl shld shr shrd sidt sldt skinit smi smint smintold smsw stc std sti stosb stosd stosq stosw str sub svdc svldt svts swapgs syscall sysenter sysexit sysret test ud0 ud1 ud2b ud2 ud2a umov verr verw fwait wbinvd wrshr wrmsr xadd xbts xchg xlatb xlat xor cmove cmovz cmovne cmovnz cmova cmovnbe cmovae cmovnb cmovb cmovnae cmovbe cmovna cmovg cmovnle cmovge cmovnl cmovl cmovnge cmovle cmovng cmovc cmovnc cmovo cmovno cmovs cmovns cmovp cmovpe cmovnp cmovpo je jz jne jnz ja jnbe jae jnb jb jnae jbe jna jg jnle jge jnl jl jnge jle jng jc jnc jo jno js jns jpo jnp jpe jp sete setz setne setnz seta setnbe setae setnb setnc setb setnae setcset setbe setna setg setnle setge setnl setl setnge setle setng sets setns seto setno setpe setp setpo setnp addps addss andnps andps cmpeqps cmpeqss cmpleps cmpless cmpltps cmpltss cmpneqps cmpneqss cmpnleps cmpnless cmpnltps cmpnltss cmpordps cmpordss cmpunordps cmpunordss cmpps cmpss comiss cvtpi2ps cvtps2pi cvtsi2ss cvtss2si cvttps2pi cvttss2si divps divss ldmxcsr maxps maxss minps minss movaps movhps movlhps movlps movhlps movmskps movntps movss movups mulps mulss orps rcpps rcpss rsqrtps rsqrtss shufps sqrtps sqrtss stmxcsr subps subss ucomiss unpckhps unpcklps xorps fxrstor fxrstor64 fxsave fxsave64 xgetbv xsetbv xsave xsave64 xsaveopt xsaveopt64 xrstor xrstor64 prefetchnta prefetcht0 prefetcht1 prefetcht2 maskmovq movntq pavgb pavgw pextrw pinsrw pmaxsw pmaxub pminsw pminub pmovmskb pmulhuw psadbw pshufw pf2iw pfnacc pfpnacc pi2fw pswapd maskmovdqu clflush movntdq movnti movntpd movdqa movdqu movdq2q movq2dq paddq pmuludq pshufd pshufhw pshuflw pslldq psrldq psubq punpckhqdq punpcklqdq addpd addsd andnpd andpd cmpeqpd cmpeqsd cmplepd cmplesd cmpltpd cmpltsd cmpneqpd cmpneqsd cmpnlepd cmpnlesd cmpnltpd cmpnltsd cmpordpd cmpordsd cmpunordpd cmpunordsd cmppd comisd cvtdq2pd cvtdq2ps cvtpd2dq cvtpd2pi cvtpd2ps cvtpi2pd cvtps2dq cvtps2pd cvtsd2si cvtsd2ss cvtsi2sd cvtss2sd cvttpd2pi cvttpd2dq cvttps2dq cvttsd2si divpd divsd maxpd maxsd minpd minsd movapd movhpd movlpd movmskpd movupd mulpd mulsd orpd shufpd sqrtpd sqrtsd subpd subsd ucomisd unpckhpd unpcklpd xorpd addsubpd addsubps haddpd haddps hsubpd hsubps lddqu movddup movshdup movsldup clgi stgi vmcall vmclear vmfunc vmlaunch vmload vmmcall vmptrld vmptrst vmread vmresume vmrun vmsave vmwrite vmxoff vmxon invept invvpid pabsb pabsw pabsd palignr phaddw phaddd phaddsw phsubw phsubd phsubsw pmaddubsw pmulhrsw pshufb psignb psignw psignd extrq insertq movntsd movntss lzcnt blendpd blendps blendvpd blendvps dppd dpps extractps insertps movntdqa mpsadbw packusdw pblendvb pblendw pcmpeqq pextrb pextrd pextrq phminposuw pinsrb pinsrd pinsrq pmaxsb pmaxsd pmaxud pmaxuw pminsb pminsd pminud pminuw pmovsxbw pmovsxbd pmovsxbq pmovsxwd pmovsxwq pmovsxdq pmovzxbw pmovzxbd pmovzxbq pmovzxwd pmovzxwq pmovzxdq pmuldq pmulld ptest roundpd roundps roundsd roundss crc32 pcmpestri pcmpestrm pcmpistri pcmpistrm pcmpgtq popcnt getsec pfrcpv pfrsqrtv movbe aesenc aesenclast aesdec aesdeclast aesimc aeskeygenassist vaesenc vaesenclast vaesdec vaesdeclast vaesimc vaeskeygenassist vaddpd vaddps vaddsd vaddss vaddsubpd vaddsubps vandpd vandps vandnpd vandnps vblendpd vblendps vblendvpd vblendvps vbroadcastss vbroadcastsd vbroadcastf128 vcmpeq_ospd vcmpeqpd vcmplt_ospd vcmpltpd vcmple_ospd vcmplepd vcmpunord_qpd vcmpunordpd vcmpneq_uqpd vcmpneqpd vcmpnlt_uspd vcmpnltpd vcmpnle_uspd vcmpnlepd vcmpord_qpd vcmpordpd vcmpeq_uqpd vcmpnge_uspd vcmpngepd vcmpngt_uspd vcmpngtpd vcmpfalse_oqpd vcmpfalsepd vcmpneq_oqpd vcmpge_ospd vcmpgepd vcmpgt_ospd vcmpgtpd vcmptrue_uqpd vcmptruepd vcmplt_oqpd vcmple_oqpd vcmpunord_spd vcmpneq_uspd vcmpnlt_uqpd vcmpnle_uqpd vcmpord_spd vcmpeq_uspd vcmpnge_uqpd vcmpngt_uqpd vcmpfalse_ospd vcmpneq_ospd vcmpge_oqpd vcmpgt_oqpd vcmptrue_uspd vcmppd vcmpeq_osps vcmpeqps vcmplt_osps vcmpltps vcmple_osps vcmpleps vcmpunord_qps vcmpunordps vcmpneq_uqps vcmpneqps vcmpnlt_usps vcmpnltps vcmpnle_usps vcmpnleps vcmpord_qps vcmpordps vcmpeq_uqps vcmpnge_usps vcmpngeps vcmpngt_usps vcmpngtps vcmpfalse_oqps vcmpfalseps vcmpneq_oqps vcmpge_osps vcmpgeps vcmpgt_osps vcmpgtps vcmptrue_uqps vcmptrueps vcmplt_oqps vcmple_oqps vcmpunord_sps vcmpneq_usps vcmpnlt_uqps vcmpnle_uqps vcmpord_sps vcmpeq_usps vcmpnge_uqps vcmpngt_uqps vcmpfalse_osps vcmpneq_osps vcmpge_oqps vcmpgt_oqps vcmptrue_usps vcmpps vcmpeq_ossd vcmpeqsd vcmplt_ossd vcmpltsd vcmple_ossd vcmplesd vcmpunord_qsd vcmpunordsd vcmpneq_uqsd vcmpneqsd vcmpnlt_ussd vcmpnltsd vcmpnle_ussd vcmpnlesd vcmpord_qsd vcmpordsd vcmpeq_uqsd vcmpnge_ussd vcmpngesd vcmpngt_ussd vcmpngtsd vcmpfalse_oqsd vcmpfalsesd vcmpneq_oqsd vcmpge_ossd vcmpgesd vcmpgt_ossd vcmpgtsd vcmptrue_uqsd vcmptruesd vcmplt_oqsd vcmple_oqsd vcmpunord_ssd vcmpneq_ussd vcmpnlt_uqsd vcmpnle_uqsd vcmpord_ssd vcmpeq_ussd vcmpnge_uqsd vcmpngt_uqsd vcmpfalse_ossd vcmpneq_ossd vcmpge_oqsd vcmpgt_oqsd vcmptrue_ussd vcmpsd vcmpeq_osss vcmpeqss vcmplt_osss vcmpltss vcmple_osss vcmpless vcmpunord_qss vcmpunordss vcmpneq_uqss vcmpneqss vcmpnlt_usss vcmpnltss vcmpnle_usss vcmpnless vcmpord_qss vcmpordss vcmpeq_uqss vcmpnge_usss vcmpngess vcmpngt_usss vcmpngtss vcmpfalse_oqss vcmpfalsess vcmpneq_oqss vcmpge_osss vcmpgess vcmpgt_osss vcmpgtss vcmptrue_uqss vcmptruess vcmplt_oqss vcmple_oqss vcmpunord_sss vcmpneq_usss vcmpnlt_uqss vcmpnle_uqss vcmpord_sss vcmpeq_usss vcmpnge_uqss vcmpngt_uqss vcmpfalse_osss vcmpneq_osss vcmpge_oqss vcmpgt_oqss vcmptrue_usss vcmpss vcomisd vcomiss vcvtdq2pd vcvtdq2ps vcvtpd2dq vcvtpd2ps vcvtps2dq vcvtps2pd vcvtsd2si vcvtsd2ss vcvtsi2sd vcvtsi2ss vcvtss2sd vcvtss2si vcvttpd2dq vcvttps2dq vcvttsd2si vcvttss2si vdivpd vdivps vdivsd vdivss vdppd vdpps vextractf128 vextractps vhaddpd vhaddps vhsubpd vhsubps vinsertf128 vinsertps vlddqu vldqqu vldmxcsr vmaskmovdqu vmaskmovps vmaskmovpd vmaxpd vmaxps vmaxsd vmaxss vminpd vminps vminsd vminss vmovapd vmovaps vmovd vmovq vmovddup vmovdqa vmovqqa vmovdqu vmovqqu vmovhlps vmovhpd vmovhps vmovlhps vmovlpd vmovlps vmovmskpd vmovmskps vmovntdq vmovntqq vmovntdqa vmovntpd vmovntps vmovsd vmovshdup vmovsldup vmovss vmovupd vmovups vmpsadbw vmulpd vmulps vmulsd vmulss vorpd vorps vpabsb vpabsw vpabsd vpacksswb vpackssdw vpackuswb vpackusdw vpaddb vpaddw vpaddd vpaddq vpaddsb vpaddsw vpaddusb vpaddusw vpalignr vpand vpandn vpavgb vpavgw vpblendvb vpblendw vpcmpestri vpcmpestrm vpcmpistri vpcmpistrm vpcmpeqb vpcmpeqw vpcmpeqd vpcmpeqq vpcmpgtb vpcmpgtw vpcmpgtd vpcmpgtq vpermilpd vpermilps vperm2f128 vpextrb vpextrw vpextrd vpextrq vphaddw vphaddd vphaddsw vphminposuw vphsubw vphsubd vphsubsw vpinsrb vpinsrw vpinsrd vpinsrq vpmaddwd vpmaddubsw vpmaxsb vpmaxsw vpmaxsd vpmaxub vpmaxuw vpmaxud vpminsb vpminsw vpminsd vpminub vpminuw vpminud vpmovmskb vpmovsxbw vpmovsxbd vpmovsxbq vpmovsxwd vpmovsxwq vpmovsxdq vpmovzxbw vpmovzxbd vpmovzxbq vpmovzxwd vpmovzxwq vpmovzxdq vpmulhuw vpmulhrsw vpmulhw vpmullw vpmulld vpmuludq vpmuldq vpor vpsadbw vpshufb vpshufd vpshufhw vpshuflw vpsignb vpsignw vpsignd vpslldq vpsrldq vpsllw vpslld vpsllq vpsraw vpsrad vpsrlw vpsrld vpsrlq vptest vpsubb vpsubw vpsubd vpsubq vpsubsb vpsubsw vpsubusb vpsubusw vpunpckhbw vpunpckhwd vpunpckhdq vpunpckhqdq vpunpcklbw vpunpcklwd vpunpckldq vpunpcklqdq vpxor vrcpps vrcpss vrsqrtps vrsqrtss vroundpd vroundps vroundsd vroundss vshufpd vshufps vsqrtpd vsqrtps vsqrtsd vsqrtss vstmxcsr vsubpd vsubps vsubsd vsubss vtestps vtestpd vucomisd vucomiss vunpckhpd vunpckhps vunpcklpd vunpcklps vxorpd vxorps vzeroall vzeroupper pclmullqlqdq pclmulhqlqdq pclmullqhqdq pclmulhqhqdq pclmulqdq vpclmullqlqdq vpclmulhqlqdq vpclmullqhqdq vpclmulhqhqdq vpclmulqdq vfmadd132ps vfmadd132pd vfmadd312ps vfmadd312pd vfmadd213ps vfmadd213pd vfmadd123ps vfmadd123pd vfmadd231ps vfmadd231pd vfmadd321ps vfmadd321pd vfmaddsub132ps vfmaddsub132pd vfmaddsub312ps vfmaddsub312pd vfmaddsub213ps vfmaddsub213pd vfmaddsub123ps vfmaddsub123pd vfmaddsub231ps vfmaddsub231pd vfmaddsub321ps vfmaddsub321pd vfmsub132ps vfmsub132pd vfmsub312ps vfmsub312pd vfmsub213ps vfmsub213pd vfmsub123ps vfmsub123pd vfmsub231ps vfmsub231pd vfmsub321ps vfmsub321pd vfmsubadd132ps vfmsubadd132pd vfmsubadd312ps vfmsubadd312pd vfmsubadd213ps vfmsubadd213pd vfmsubadd123ps vfmsubadd123pd vfmsubadd231ps vfmsubadd231pd vfmsubadd321ps vfmsubadd321pd vfnmadd132ps vfnmadd132pd vfnmadd312ps vfnmadd312pd vfnmadd213ps vfnmadd213pd vfnmadd123ps vfnmadd123pd vfnmadd231ps vfnmadd231pd vfnmadd321ps vfnmadd321pd vfnmsub132ps vfnmsub132pd vfnmsub312ps vfnmsub312pd vfnmsub213ps vfnmsub213pd vfnmsub123ps vfnmsub123pd vfnmsub231ps vfnmsub231pd vfnmsub321ps vfnmsub321pd vfmadd132ss vfmadd132sd vfmadd312ss vfmadd312sd vfmadd213ss vfmadd213sd vfmadd123ss vfmadd123sd vfmadd231ss vfmadd231sd vfmadd321ss vfmadd321sd vfmsub132ss vfmsub132sd vfmsub312ss vfmsub312sd vfmsub213ss vfmsub213sd vfmsub123ss vfmsub123sd vfmsub231ss vfmsub231sd vfmsub321ss vfmsub321sd vfnmadd132ss vfnmadd132sd vfnmadd312ss vfnmadd312sd vfnmadd213ss vfnmadd213sd vfnmadd123ss vfnmadd123sd vfnmadd231ss vfnmadd231sd vfnmadd321ss vfnmadd321sd vfnmsub132ss vfnmsub132sd vfnmsub312ss vfnmsub312sd vfnmsub213ss vfnmsub213sd vfnmsub123ss vfnmsub123sd vfnmsub231ss vfnmsub231sd vfnmsub321ss vfnmsub321sd rdfsbase rdgsbase rdrand wrfsbase wrgsbase vcvtph2ps vcvtps2ph adcx adox rdseed clac stac xstore xcryptecb xcryptcbc xcryptctr xcryptcfb xcryptofb montmul xsha1 xsha256 llwpcb slwpcb lwpval lwpins vfmaddpd vfmaddps vfmaddsd vfmaddss vfmaddsubpd vfmaddsubps vfmsubaddpd vfmsubaddps vfmsubpd vfmsubps vfmsubsd vfmsubss vfnmaddpd vfnmaddps vfnmaddsd vfnmaddss vfnmsubpd vfnmsubps vfnmsubsd vfnmsubss vfrczpd vfrczps vfrczsd vfrczss vpcmov vpcomb vpcomd vpcomq vpcomub vpcomud vpcomuq vpcomuw vpcomw vphaddbd vphaddbq vphaddbw vphadddq vphaddubd vphaddubq vphaddubw vphaddudq vphadduwd vphadduwq vphaddwd vphaddwq vphsubbw vphsubdq vphsubwd vpmacsdd vpmacsdqh vpmacsdql vpmacssdd vpmacssdqh vpmacssdql vpmacsswd vpmacssww vpmacswd vpmacsww vpmadcsswd vpmadcswd vpperm vprotb vprotd vprotq vprotw vpshab vpshad vpshaq vpshaw vpshlb vpshld vpshlq vpshlw vbroadcasti128 vpblendd vpbroadcastb vpbroadcastw vpbroadcastd vpbroadcastq vpermd vpermpd vpermps vpermq vperm2i128 vextracti128 vinserti128 vpmaskmovd vpmaskmovq vpsllvd vpsllvq vpsravd vpsrlvd vpsrlvq vgatherdpd vgatherqpd vgatherdps vgatherqps vpgatherdd vpgatherqd vpgatherdq vpgatherqq xabort xbegin xend xtest andn bextr blci blcic blsi blsic blcfill blsfill blcmsk blsmsk blsr blcs bzhi mulx pdep pext rorx sarx shlx shrx tzcnt tzmsk t1mskc valignd valignq vblendmpd vblendmps vbroadcastf32x4 vbroadcastf64x4 vbroadcasti32x4 vbroadcasti64x4 vcompresspd vcompressps vcvtpd2udq vcvtps2udq vcvtsd2usi vcvtss2usi vcvttpd2udq vcvttps2udq vcvttsd2usi vcvttss2usi vcvtudq2pd vcvtudq2ps vcvtusi2sd vcvtusi2ss vexpandpd vexpandps vextractf32x4 vextractf64x4 vextracti32x4 vextracti64x4 vfixupimmpd vfixupimmps vfixupimmsd vfixupimmss vgetexppd vgetexpps vgetexpsd vgetexpss vgetmantpd vgetmantps vgetmantsd vgetmantss vinsertf32x4 vinsertf64x4 vinserti32x4 vinserti64x4 vmovdqa32 vmovdqa64 vmovdqu32 vmovdqu64 vpabsq vpandd vpandnd vpandnq vpandq vpblendmd vpblendmq vpcmpltd vpcmpled vpcmpneqd vpcmpnltd vpcmpnled vpcmpd vpcmpltq vpcmpleq vpcmpneqq vpcmpnltq vpcmpnleq vpcmpq vpcmpequd vpcmpltud vpcmpleud vpcmpnequd vpcmpnltud vpcmpnleud vpcmpud vpcmpequq vpcmpltuq vpcmpleuq vpcmpnequq vpcmpnltuq vpcmpnleuq vpcmpuq vpcompressd vpcompressq vpermi2d vpermi2pd vpermi2ps vpermi2q vpermt2d vpermt2pd vpermt2ps vpermt2q vpexpandd vpexpandq vpmaxsq vpmaxuq vpminsq vpminuq vpmovdb vpmovdw vpmovqb vpmovqd vpmovqw vpmovsdb vpmovsdw vpmovsqb vpmovsqd vpmovsqw vpmovusdb vpmovusdw vpmovusqb vpmovusqd vpmovusqw vpord vporq vprold vprolq vprolvd vprolvq vprord vprorq vprorvd vprorvq vpscatterdd vpscatterdq vpscatterqd vpscatterqq vpsraq vpsravq vpternlogd vpternlogq vptestmd vptestmq vptestnmd vptestnmq vpxord vpxorq vrcp14pd vrcp14ps vrcp14sd vrcp14ss vrndscalepd vrndscaleps vrndscalesd vrndscaless vrsqrt14pd vrsqrt14ps vrsqrt14sd vrsqrt14ss vscalefpd vscalefps vscalefsd vscalefss vscatterdpd vscatterdps vscatterqpd vscatterqps vshuff32x4 vshuff64x2 vshufi32x4 vshufi64x2 kandnw kandw kmovw knotw kortestw korw kshiftlw kshiftrw kunpckbw kxnorw kxorw vpbroadcastmb2q vpbroadcastmw2d vpconflictd vpconflictq vplzcntd vplzcntq vexp2pd vexp2ps vrcp28pd vrcp28ps vrcp28sd vrcp28ss vrsqrt28pd vrsqrt28ps vrsqrt28sd vrsqrt28ss vgatherpf0dpd vgatherpf0dps vgatherpf0qpd vgatherpf0qps vgatherpf1dpd vgatherpf1dps vgatherpf1qpd vgatherpf1qps vscatterpf0dpd vscatterpf0dps vscatterpf0qpd vscatterpf0qps vscatterpf1dpd vscatterpf1dps vscatterpf1qpd vscatterpf1qps prefetchwt1 bndmk bndcl bndcu bndcn bndmov bndldx bndstx sha1rnds4 sha1nexte sha1msg1 sha1msg2 sha256rnds2 sha256msg1 sha256msg2 hint_nop0 hint_nop1 hint_nop2 hint_nop3 hint_nop4 hint_nop5 hint_nop6 hint_nop7 hint_nop8 hint_nop9 hint_nop10 hint_nop11 hint_nop12 hint_nop13 hint_nop14 hint_nop15 hint_nop16 hint_nop17 hint_nop18 hint_nop19 hint_nop20 hint_nop21 hint_nop22 hint_nop23 hint_nop24 hint_nop25 hint_nop26 hint_nop27 hint_nop28 hint_nop29 hint_nop30 hint_nop31 hint_nop32 hint_nop33 hint_nop34 hint_nop35 hint_nop36 hint_nop37 hint_nop38 hint_nop39 hint_nop40 hint_nop41 hint_nop42 hint_nop43 hint_nop44 hint_nop45 hint_nop46 hint_nop47 hint_nop48 hint_nop49 hint_nop50 hint_nop51 hint_nop52 hint_nop53 hint_nop54 hint_nop55 hint_nop56 hint_nop57 hint_nop58 hint_nop59 hint_nop60 hint_nop61 hint_nop62 hint_nop63',
built_in:
// Instruction pointer
'ip eip rip '
// 8-bit registers
+ 'al ah bl bh cl ch dl dh sil dil bpl spl r8b r9b r10b r11b r12b r13b r14b r15b '
// 16-bit registers
+ 'ax bx cx dx si di bp sp r8w r9w r10w r11w r12w r13w r14w r15w '
// 32-bit registers
+ 'eax ebx ecx edx esi edi ebp esp eip r8d r9d r10d r11d r12d r13d r14d r15d '
// 64-bit registers
+ 'rax rbx rcx rdx rsi rdi rbp rsp r8 r9 r10 r11 r12 r13 r14 r15 '
// Segment registers
+ 'cs ds es fs gs ss '
// Floating point stack registers
+ 'st st0 st1 st2 st3 st4 st5 st6 st7 '
// MMX Registers
+ 'mm0 mm1 mm2 mm3 mm4 mm5 mm6 mm7 '
// SSE registers
+ 'xmm0 xmm1 xmm2 xmm3 xmm4 xmm5 xmm6 xmm7 xmm8 xmm9 xmm10 xmm11 xmm12 xmm13 xmm14 xmm15 '
+ 'xmm16 xmm17 xmm18 xmm19 xmm20 xmm21 xmm22 xmm23 xmm24 xmm25 xmm26 xmm27 xmm28 xmm29 xmm30 xmm31 '
// AVX registers
+ 'ymm0 ymm1 ymm2 ymm3 ymm4 ymm5 ymm6 ymm7 ymm8 ymm9 ymm10 ymm11 ymm12 ymm13 ymm14 ymm15 '
+ 'ymm16 ymm17 ymm18 ymm19 ymm20 ymm21 ymm22 ymm23 ymm24 ymm25 ymm26 ymm27 ymm28 ymm29 ymm30 ymm31 '
// AVX-512F registers
+ 'zmm0 zmm1 zmm2 zmm3 zmm4 zmm5 zmm6 zmm7 zmm8 zmm9 zmm10 zmm11 zmm12 zmm13 zmm14 zmm15 '
+ 'zmm16 zmm17 zmm18 zmm19 zmm20 zmm21 zmm22 zmm23 zmm24 zmm25 zmm26 zmm27 zmm28 zmm29 zmm30 zmm31 '
// AVX-512F mask registers
+ 'k0 k1 k2 k3 k4 k5 k6 k7 '
// Bound (MPX) register
+ 'bnd0 bnd1 bnd2 bnd3 '
// Special register
+ 'cr0 cr1 cr2 cr3 cr4 cr8 dr0 dr1 dr2 dr3 dr8 tr3 tr4 tr5 tr6 tr7 '
// NASM altreg package
+ 'r0 r1 r2 r3 r4 r5 r6 r7 r0b r1b r2b r3b r4b r5b r6b r7b '
+ 'r0w r1w r2w r3w r4w r5w r6w r7w r0d r1d r2d r3d r4d r5d r6d r7d '
+ 'r0h r1h r2h r3h '
+ 'r0l r1l r2l r3l r4l r5l r6l r7l r8l r9l r10l r11l r12l r13l r14l r15l '
+ 'db dw dd dq dt ddq do dy dz '
+ 'resb resw resd resq rest resdq reso resy resz '
+ 'incbin equ times '
+ 'byte word dword qword nosplit rel abs seg wrt strict near far a32 ptr',
meta:
'%define %xdefine %+ %undef %defstr %deftok %assign %strcat %strlen %substr %rotate %elif %else %endif '
+ '%if %ifmacro %ifctx %ifidn %ifidni %ifid %ifnum %ifstr %iftoken %ifempty %ifenv %error %warning %fatal %rep '
+ '%endrep %include %push %pop %repl %pathsearch %depend %use %arg %stacksize %local %line %comment %endcomment '
+ '.nolist '
+ '__FILE__ __LINE__ __SECT__ __BITS__ __OUTPUT_FORMAT__ __DATE__ __TIME__ __DATE_NUM__ __TIME_NUM__ '
+ '__UTC_DATE__ __UTC_TIME__ __UTC_DATE_NUM__ __UTC_TIME_NUM__ __PASS__ struc endstruc istruc at iend '
+ 'align alignb sectalign daz nodaz up down zero default option assume public '
+ 'bits use16 use32 use64 default section segment absolute extern global common cpu float '
+ '__utf16__ __utf16le__ __utf16be__ __utf32__ __utf32le__ __utf32be__ '
+ '__float8__ __float16__ __float32__ __float64__ __float80m__ __float80e__ __float128l__ __float128h__ '
+ '__Infinity__ __QNaN__ __SNaN__ Inf NaN QNaN SNaN float8 float16 float32 float64 float80m float80e '
+ 'float128l float128h __FLOAT_DAZ__ __FLOAT_ROUND__ __FLOAT__'
},
contains: [
hljs.COMMENT(
';',
'$',
{ relevance: 0 }
),
{
className: 'number',
variants: [
// Float number and x87 BCD
{
begin: '\\b(?:([0-9][0-9_]*)?\\.[0-9_]*(?:[eE][+-]?[0-9_]+)?|'
+ '(0[Xx])?[0-9][0-9_]*(\\.[0-9_]*)?(?:[pP](?:[+-]?[0-9_]+)?)?)\\b',
relevance: 0
},
// Hex number in $
{
begin: '\\$[0-9][0-9A-Fa-f]*',
relevance: 0
},
// Number in H,D,T,Q,O,B,Y suffix
{ begin: '\\b(?:[0-9A-Fa-f][0-9A-Fa-f_]*[Hh]|[0-9][0-9_]*[DdTt]?|[0-7][0-7_]*[QqOo]|[0-1][0-1_]*[BbYy])\\b' },
// Number in X,D,T,Q,O,B,Y prefix
{ begin: '\\b(?:0[Xx][0-9A-Fa-f_]+|0[DdTt][0-9_]+|0[QqOo][0-7_]+|0[BbYy][0-1_]+)\\b' }
]
},
// Double quote string
hljs.QUOTE_STRING_MODE,
{
className: 'string',
variants: [
// Single-quoted string
{
begin: '\'',
end: '[^\\\\]\''
},
// Backquoted string
{
begin: '`',
end: '[^\\\\]`'
}
],
relevance: 0
},
{
className: 'symbol',
variants: [
// Global label and local label
{ begin: '^\\s*[A-Za-z._?][A-Za-z0-9_$#@~.?]*(:|\\s+label)' },
// Macro-local label
{ begin: '^\\s*%%[A-Za-z0-9_$#@~.?]*:' }
],
relevance: 0
},
// Macro parameter
{
className: 'subst',
begin: '%[0-9]+',
relevance: 0
},
// Macro parameter
{
className: 'subst',
begin: '%!\S+',
relevance: 0
},
{
className: 'meta',
begin: /^\s*\.[\w_-]+/
}
]
};
}
var x86asm_1 = x86asm;
/*
Language: XL
Author: Christophe de Dinechin <christophe@taodyne.com>
Description: An extensible programming language, based on parse tree rewriting
Website: http://xlr.sf.net
*/
function xl(hljs) {
const KWS = [
"if",
"then",
"else",
"do",
"while",
"until",
"for",
"loop",
"import",
"with",
"is",
"as",
"where",
"when",
"by",
"data",
"constant",
"integer",
"real",
"text",
"name",
"boolean",
"symbol",
"infix",
"prefix",
"postfix",
"block",
"tree"
];
const BUILT_INS = [
"in",
"mod",
"rem",
"and",
"or",
"xor",
"not",
"abs",
"sign",
"floor",
"ceil",
"sqrt",
"sin",
"cos",
"tan",
"asin",
"acos",
"atan",
"exp",
"expm1",
"log",
"log2",
"log10",
"log1p",
"pi",
"at",
"text_length",
"text_range",
"text_find",
"text_replace",
"contains",
"page",
"slide",
"basic_slide",
"title_slide",
"title",
"subtitle",
"fade_in",
"fade_out",
"fade_at",
"clear_color",
"color",
"line_color",
"line_width",
"texture_wrap",
"texture_transform",
"texture",
"scale_?x",
"scale_?y",
"scale_?z?",
"translate_?x",
"translate_?y",
"translate_?z?",
"rotate_?x",
"rotate_?y",
"rotate_?z?",
"rectangle",
"circle",
"ellipse",
"sphere",
"path",
"line_to",
"move_to",
"quad_to",
"curve_to",
"theme",
"background",
"contents",
"locally",
"time",
"mouse_?x",
"mouse_?y",
"mouse_buttons"
];
const BUILTIN_MODULES = [
"ObjectLoader",
"Animate",
"MovieCredits",
"Slides",
"Filters",
"Shading",
"Materials",
"LensFlare",
"Mapping",
"VLCAudioVideo",
"StereoDecoder",
"PointCloud",
"NetworkAccess",
"RemoteControl",
"RegExp",
"ChromaKey",
"Snowfall",
"NodeJS",
"Speech",
"Charts"
];
const LITERALS = [
"true",
"false",
"nil"
];
const KEYWORDS = {
$pattern: /[a-zA-Z][a-zA-Z0-9_?]*/,
keyword: KWS,
literal: LITERALS,
built_in: BUILT_INS.concat(BUILTIN_MODULES)
};
const DOUBLE_QUOTE_TEXT = {
className: 'string',
begin: '"',
end: '"',
illegal: '\\n'
};
const SINGLE_QUOTE_TEXT = {
className: 'string',
begin: '\'',
end: '\'',
illegal: '\\n'
};
const LONG_TEXT = {
className: 'string',
begin: '<<',
end: '>>'
};
const BASED_NUMBER = {
className: 'number',
begin: '[0-9]+#[0-9A-Z_]+(\\.[0-9-A-Z_]+)?#?([Ee][+-]?[0-9]+)?'
};
const IMPORT = {
beginKeywords: 'import',
end: '$',
keywords: KEYWORDS,
contains: [ DOUBLE_QUOTE_TEXT ]
};
const FUNCTION_DEFINITION = {
className: 'function',
begin: /[a-z][^\n]*->/,
returnBegin: true,
end: /->/,
contains: [
hljs.inherit(hljs.TITLE_MODE, { starts: {
endsWithParent: true,
keywords: KEYWORDS
} })
]
};
return {
name: 'XL',
aliases: [ 'tao' ],
keywords: KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
DOUBLE_QUOTE_TEXT,
SINGLE_QUOTE_TEXT,
LONG_TEXT,
FUNCTION_DEFINITION,
IMPORT,
BASED_NUMBER,
hljs.NUMBER_MODE
]
};
}
var xl_1 = xl;
/*
Language: XQuery
Author: Dirk Kirsten <dk@basex.org>
Contributor: Duncan Paterson
Description: Supports XQuery 3.1 including XQuery Update 3, so also XPath (as it is a superset)
Refactored to process xml constructor syntax and function-bodies. Added missing data-types, xpath operands, inbuilt functions, and query prologs
Website: https://www.w3.org/XML/Query/
Category: functional
Audit: 2020
*/
/** @type LanguageFn */
function xquery(_hljs) {
// see https://www.w3.org/TR/xquery/#id-terminal-delimitation
const KEYWORDS = [
"module",
"schema",
"namespace",
"boundary-space",
"preserve",
"no-preserve",
"strip",
"default",
"collation",
"base-uri",
"ordering",
"context",
"decimal-format",
"decimal-separator",
"copy-namespaces",
"empty-sequence",
"except",
"exponent-separator",
"external",
"grouping-separator",
"inherit",
"no-inherit",
"lax",
"minus-sign",
"per-mille",
"percent",
"schema-attribute",
"schema-element",
"strict",
"unordered",
"zero-digit",
"declare",
"import",
"option",
"function",
"validate",
"variable",
"for",
"at",
"in",
"let",
"where",
"order",
"group",
"by",
"return",
"if",
"then",
"else",
"tumbling",
"sliding",
"window",
"start",
"when",
"only",
"end",
"previous",
"next",
"stable",
"ascending",
"descending",
"allowing",
"empty",
"greatest",
"least",
"some",
"every",
"satisfies",
"switch",
"case",
"typeswitch",
"try",
"catch",
"and",
"or",
"to",
"union",
"intersect",
"instance",
"of",
"treat",
"as",
"castable",
"cast",
"map",
"array",
"delete",
"insert",
"into",
"replace",
"value",
"rename",
"copy",
"modify",
"update"
];
// Node Types (sorted by inheritance)
// atomic types (sorted by inheritance)
const TYPES = [
"item",
"document-node",
"node",
"attribute",
"document",
"element",
"comment",
"namespace",
"namespace-node",
"processing-instruction",
"text",
"construction",
"xs:anyAtomicType",
"xs:untypedAtomic",
"xs:duration",
"xs:time",
"xs:decimal",
"xs:float",
"xs:double",
"xs:gYearMonth",
"xs:gYear",
"xs:gMonthDay",
"xs:gMonth",
"xs:gDay",
"xs:boolean",
"xs:base64Binary",
"xs:hexBinary",
"xs:anyURI",
"xs:QName",
"xs:NOTATION",
"xs:dateTime",
"xs:dateTimeStamp",
"xs:date",
"xs:string",
"xs:normalizedString",
"xs:token",
"xs:language",
"xs:NMTOKEN",
"xs:Name",
"xs:NCName",
"xs:ID",
"xs:IDREF",
"xs:ENTITY",
"xs:integer",
"xs:nonPositiveInteger",
"xs:negativeInteger",
"xs:long",
"xs:int",
"xs:short",
"xs:byte",
"xs:nonNegativeInteger",
"xs:unisignedLong",
"xs:unsignedInt",
"xs:unsignedShort",
"xs:unsignedByte",
"xs:positiveInteger",
"xs:yearMonthDuration",
"xs:dayTimeDuration"
];
const LITERALS = [
"eq",
"ne",
"lt",
"le",
"gt",
"ge",
"is",
"self::",
"child::",
"descendant::",
"descendant-or-self::",
"attribute::",
"following::",
"following-sibling::",
"parent::",
"ancestor::",
"ancestor-or-self::",
"preceding::",
"preceding-sibling::",
"NaN"
];
// functions (TODO: find regex for op: without breaking build)
const BUILT_IN = {
className: 'built_in',
variants: [
{
begin: /\barray:/,
end: /(?:append|filter|flatten|fold-(?:left|right)|for-each(?:-pair)?|get|head|insert-before|join|put|remove|reverse|size|sort|subarray|tail)\b/
},
{
begin: /\bmap:/,
end: /(?:contains|entry|find|for-each|get|keys|merge|put|remove|size)\b/
},
{
begin: /\bmath:/,
end: /(?:a(?:cos|sin|tan[2]?)|cos|exp(?:10)?|log(?:10)?|pi|pow|sin|sqrt|tan)\b/
},
{
begin: /\bop:/,
end: /\(/,
excludeEnd: true
},
{
begin: /\bfn:/,
end: /\(/,
excludeEnd: true
},
// do not highlight inbuilt strings as variable or xml element names
{ begin: /[^</$:'"-]\b(?:abs|accumulator-(?:after|before)|adjust-(?:date(?:Time)?|time)-to-timezone|analyze-string|apply|available-(?:environment-variables|system-properties)|avg|base-uri|boolean|ceiling|codepoints?-(?:equal|to-string)|collation-key|collection|compare|concat|contains(?:-token)?|copy-of|count|current(?:-)?(?:date(?:Time)?|time|group(?:ing-key)?|output-uri|merge-(?:group|key))?data|dateTime|days?-from-(?:date(?:Time)?|duration)|deep-equal|default-(?:collation|language)|distinct-values|document(?:-uri)?|doc(?:-available)?|element-(?:available|with-id)|empty|encode-for-uri|ends-with|environment-variable|error|escape-html-uri|exactly-one|exists|false|filter|floor|fold-(?:left|right)|for-each(?:-pair)?|format-(?:date(?:Time)?|time|integer|number)|function-(?:arity|available|lookup|name)|generate-id|has-children|head|hours-from-(?:dateTime|duration|time)|id(?:ref)?|implicit-timezone|in-scope-prefixes|index-of|innermost|insert-before|iri-to-uri|json-(?:doc|to-xml)|key|lang|last|load-xquery-module|local-name(?:-from-QName)?|(?:lower|upper)-case|matches|max|minutes-from-(?:dateTime|duration|time)|min|months?-from-(?:date(?:Time)?|duration)|name(?:space-uri-?(?:for-prefix|from-QName)?)?|nilled|node-name|normalize-(?:space|unicode)|not|number|one-or-more|outermost|parse-(?:ietf-date|json)|path|position|(?:prefix-from-)?QName|random-number-generator|regex-group|remove|replace|resolve-(?:QName|uri)|reverse|root|round(?:-half-to-even)?|seconds-from-(?:dateTime|duration|time)|snapshot|sort|starts-with|static-base-uri|stream-available|string-?(?:join|length|to-codepoints)?|subsequence|substring-?(?:after|before)?|sum|system-property|tail|timezone-from-(?:date(?:Time)?|time)|tokenize|trace|trans(?:form|late)|true|type-available|unordered|unparsed-(?:entity|text)?-?(?:public-id|uri|available|lines)?|uri-collection|xml-to-json|years?-from-(?:date(?:Time)?|duration)|zero-or-one)\b/ },
{
begin: /\blocal:/,
end: /\(/,
excludeEnd: true
},
{
begin: /\bzip:/,
end: /(?:zip-file|(?:xml|html|text|binary)-entry| (?:update-)?entries)\b/
},
{
begin: /\b(?:util|db|functx|app|xdmp|xmldb):/,
end: /\(/,
excludeEnd: true
}
]
};
const TITLE = {
className: 'title',
begin: /\bxquery version "[13]\.[01]"\s?(?:encoding ".+")?/,
end: /;/
};
const VAR = {
className: 'variable',
begin: /[$][\w\-:]+/
};
const NUMBER = {
className: 'number',
begin: /(\b0[0-7_]+)|(\b0x[0-9a-fA-F_]+)|(\b[1-9][0-9_]*(\.[0-9_]+)?)|[0_]\b/,
relevance: 0
};
const STRING = {
className: 'string',
variants: [
{
begin: /"/,
end: /"/,
contains: [
{
begin: /""/,
relevance: 0
}
]
},
{
begin: /'/,
end: /'/,
contains: [
{
begin: /''/,
relevance: 0
}
]
}
]
};
const ANNOTATION = {
className: 'meta',
begin: /%[\w\-:]+/
};
const COMMENT = {
className: 'comment',
begin: /\(:/,
end: /:\)/,
relevance: 10,
contains: [
{
className: 'doctag',
begin: /@\w+/
}
]
};
// see https://www.w3.org/TR/xquery/#id-computedConstructors
// mocha: computed_inbuilt
// see https://www.regexpal.com/?fam=99749
const COMPUTED = {
beginKeywords: 'element attribute comment document processing-instruction',
end: /\{/,
excludeEnd: true
};
// mocha: direct_method
const DIRECT = {
begin: /<([\w._:-]+)(\s+\S*=('|").*('|"))?>/,
end: /(\/[\w._:-]+>)/,
subLanguage: 'xml',
contains: [
{
begin: /\{/,
end: /\}/,
subLanguage: 'xquery'
},
'self'
]
};
const CONTAINS = [
VAR,
BUILT_IN,
STRING,
NUMBER,
COMMENT,
ANNOTATION,
TITLE,
COMPUTED,
DIRECT
];
return {
name: 'XQuery',
aliases: [
'xpath',
'xq',
'xqm'
],
case_insensitive: false,
illegal: /(proc)|(abstract)|(extends)|(until)|(#)/,
keywords: {
$pattern: /[a-zA-Z$][a-zA-Z0-9_:-]*/,
keyword: KEYWORDS,
type: TYPES,
literal: LITERALS
},
contains: CONTAINS
};
}
var xquery_1 = xquery;
/*
Language: Zephir
Description: Zephir, an open source, high-level language designed to ease the creation and maintainability of extensions for PHP with a focus on type and memory safety.
Author: Oleg Efimov <efimovov@gmail.com>
Website: https://zephir-lang.com/en
Audit: 2020
*/
/** @type LanguageFn */
function zephir(hljs) {
const STRING = {
className: 'string',
contains: [ hljs.BACKSLASH_ESCAPE ],
variants: [
hljs.inherit(hljs.APOS_STRING_MODE, { illegal: null }),
hljs.inherit(hljs.QUOTE_STRING_MODE, { illegal: null })
]
};
const TITLE_MODE = hljs.UNDERSCORE_TITLE_MODE;
const NUMBER = { variants: [
hljs.BINARY_NUMBER_MODE,
hljs.C_NUMBER_MODE
] };
const KEYWORDS =
// classes and objects
'namespace class interface use extends '
+ 'function return '
+ 'abstract final public protected private static deprecated '
// error handling
+ 'throw try catch Exception '
// keyword-ish things their website does NOT seem to highlight (in their own snippets)
// 'typeof fetch in ' +
// operators/helpers
+ 'echo empty isset instanceof unset '
// assignment/variables
+ 'let var new const self '
// control
+ 'require '
+ 'if else elseif switch case default '
+ 'do while loop for continue break '
+ 'likely unlikely '
// magic constants
// https://github.com/phalcon/zephir/blob/master/Library/Expression/Constants.php
+ '__LINE__ __FILE__ __DIR__ __FUNCTION__ __CLASS__ __TRAIT__ __METHOD__ __NAMESPACE__ '
// types - https://docs.zephir-lang.com/0.12/en/types
+ 'array boolean float double integer object resource string '
+ 'char long unsigned bool int uint ulong uchar '
// built-ins
+ 'true false null undefined';
return {
name: 'Zephir',
aliases: [ 'zep' ],
keywords: KEYWORDS,
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT(
/\/\*/,
/\*\//,
{ contains: [
{
className: 'doctag',
begin: /@[A-Za-z]+/
}
] }
),
{
className: 'string',
begin: /<<<['"]?\w+['"]?$/,
end: /^\w+;/,
contains: [ hljs.BACKSLASH_ESCAPE ]
},
{
// swallow composed identifiers to avoid parsing them as keywords
begin: /(::|->)+[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/ },
{
className: 'function',
beginKeywords: 'function fn',
end: /[;{]/,
excludeEnd: true,
illegal: /\$|\[|%/,
contains: [
TITLE_MODE,
{
className: 'params',
begin: /\(/,
end: /\)/,
keywords: KEYWORDS,
contains: [
'self',
hljs.C_BLOCK_COMMENT_MODE,
STRING,
NUMBER
]
}
]
},
{
className: 'class',
beginKeywords: 'class interface',
end: /\{/,
excludeEnd: true,
illegal: /[:($"]/,
contains: [
{ beginKeywords: 'extends implements' },
TITLE_MODE
]
},
{
beginKeywords: 'namespace',
end: /;/,
illegal: /[.']/,
contains: [ TITLE_MODE ]
},
{
beginKeywords: 'use',
end: /;/,
contains: [ TITLE_MODE ]
},
{ begin: /=>/ // No markup, just a relevance booster
},
STRING,
NUMBER
]
};
}
var zephir_1 = zephir;
var hljs$1 = core;
var require$$0 = _1c_1;
var require$$1 = abnf_1;
var require$$2 = accesslog_1;
var require$$3 = actionscript_1;
var require$$4 = ada_1;
var require$$5 = angelscript_1;
var require$$6 = apache_1;
var require$$7 = applescript_1;
var require$$8 = arcade_1;
var require$$9 = arduino_1;
var require$$10 = armasm_1;
var require$$11 = xml_1;
var require$$12 = asciidoc_1;
var require$$13 = aspectj_1;
var require$$14 = autohotkey_1;
var require$$15 = autoit_1;
var require$$16 = avrasm_1;
var require$$17 = awk_1;
var require$$18 = axapta_1;
var require$$19 = bash_1;
var require$$20 = basic_1;
var require$$21 = bnf_1;
var require$$22 = brainfuck_1;
var require$$23 = c_1;
var require$$24 = cal_1;
var require$$25 = capnproto_1;
var require$$26 = ceylon_1;
var require$$27 = clean_1;
var require$$28 = clojure_1;
var require$$29 = clojureRepl_1;
var require$$30 = cmake_1;
var require$$31 = coffeescript_1;
var require$$32 = coq_1;
var require$$33 = cos_1;
var require$$34 = cpp_1;
var require$$35 = crmsh_1;
var require$$36 = crystal_1;
var require$$37 = csharp_1;
var require$$38 = csp_1;
var require$$39 = css_1;
var require$$40 = d_1;
var require$$41 = markdown_1;
var require$$42 = dart_1;
var require$$43 = delphi_1;
var require$$44 = diff_1;
var require$$45 = django_1;
var require$$46 = dns_1;
var require$$47 = dockerfile_1;
var require$$48 = dos_1;
var require$$49 = dsconfig_1;
var require$$50 = dts_1;
var require$$51 = dust_1;
var require$$52 = ebnf_1;
var require$$53 = elixir_1;
var require$$54 = elm_1;
var require$$55 = ruby_1;
var require$$56 = erb_1;
var require$$57 = erlangRepl_1;
var require$$58 = erlang_1;
var require$$59 = excel_1;
var require$$60 = fix_1;
var require$$61 = flix_1;
var require$$62 = fortran_1;
var require$$63 = fsharp_1;
var require$$64 = gams_1;
var require$$65 = gauss_1;
var require$$66 = gcode_1;
var require$$67 = gherkin_1;
var require$$68 = glsl_1;
var require$$69 = gml_1;
var require$$70 = go_1;
var require$$71 = golo_1;
var require$$72 = gradle_1;
var require$$73 = graphql_1;
var require$$74 = groovy_1;
var require$$75 = haml_1;
var require$$76 = handlebars_1;
var require$$77 = haskell_1;
var require$$78 = haxe_1;
var require$$79 = hsp_1;
var require$$80 = http_1;
var require$$81 = hy_1;
var require$$82 = inform7_1;
var require$$83 = ini_1;
var require$$84 = irpf90_1;
var require$$85 = isbl_1;
var require$$86 = java_1;
var require$$87 = javascript_1;
var require$$88 = jbossCli_1;
var require$$89 = json_1;
var require$$90 = julia_1;
var require$$91 = juliaRepl_1;
var require$$92 = kotlin_1;
var require$$93 = lasso_1;
var require$$94 = latex_1;
var require$$95 = ldif_1;
var require$$96 = leaf_1;
var require$$97 = less_1;
var require$$98 = lisp_1;
var require$$99 = livecodeserver_1;
var require$$100 = livescript_1;
var require$$101 = llvm_1;
var require$$102 = lsl_1;
var require$$103 = lua_1;
var require$$104 = makefile_1;
var require$$105 = mathematica_1;
var require$$106 = matlab_1;
var require$$107 = maxima_1;
var require$$108 = mel_1;
var require$$109 = mercury_1;
var require$$110 = mipsasm_1;
var require$$111 = mizar_1;
var require$$112 = perl_1;
var require$$113 = mojolicious_1;
var require$$114 = monkey_1;
var require$$115 = moonscript_1;
var require$$116 = n1ql_1;
var require$$117 = nestedtext_1;
var require$$118 = nginx_1;
var require$$119 = nim_1;
var require$$120 = nix_1;
var require$$121 = nodeRepl_1;
var require$$122 = nsis_1;
var require$$123 = objectivec_1;
var require$$124 = ocaml_1;
var require$$125 = openscad_1;
var require$$126 = oxygene_1;
var require$$127 = parser3_1;
var require$$128 = pf_1;
var require$$129 = pgsql_1;
var require$$130 = php_1;
var require$$131 = phpTemplate_1;
var require$$132 = plaintext_1;
var require$$133 = pony_1;
var require$$134 = powershell_1;
var require$$135 = processing_1;
var require$$136 = profile_1;
var require$$137 = prolog_1;
var require$$138 = properties_1;
var require$$139 = protobuf_1;
var require$$140 = puppet_1;
var require$$141 = purebasic_1;
var require$$142 = python_1;
var require$$143 = pythonRepl_1;
var require$$144 = q_1;
var require$$145 = qml_1;
var require$$146 = r_1;
var require$$147 = reasonml_1;
var require$$148 = rib_1;
var require$$149 = roboconf_1;
var require$$150 = routeros_1;
var require$$151 = rsl_1;
var require$$152 = ruleslanguage_1;
var require$$153 = rust_1;
var require$$154 = sas_1;
var require$$155 = scala_1;
var require$$156 = scheme_1;
var require$$157 = scilab_1;
var require$$158 = scss_1;
var require$$159 = shell_1;
var require$$160 = smali_1;
var require$$161 = smalltalk_1;
var require$$162 = sml_1;
var require$$163 = sqf_1;
var require$$164 = sql_1;
var require$$165 = stan_1;
var require$$166 = stata_1;
var require$$167 = step21_1;
var require$$168 = stylus_1;
var require$$169 = subunit_1;
var require$$170 = swift_1;
var require$$171 = taggerscript_1;
var require$$172 = yaml_1;
var require$$173 = tap_1;
var require$$174 = tcl_1;
var require$$175 = thrift_1;
var require$$176 = tp_1;
var require$$177 = twig_1;
var require$$178 = typescript_1;
var require$$179 = vala_1;
var require$$180 = vbnet_1;
var require$$181 = vbscript_1;
var require$$182 = vbscriptHtml_1;
var require$$183 = verilog_1;
var require$$184 = vhdl_1;
var require$$185 = vim_1;
var require$$186 = wasm_1;
var require$$187 = wren_1;
var require$$188 = x86asm_1;
var require$$189 = xl_1;
var require$$190 = xquery_1;
var require$$191 = zephir_1;
hljs$1.registerLanguage('1c', require$$0);
hljs$1.registerLanguage('abnf', require$$1);
hljs$1.registerLanguage('accesslog', require$$2);
hljs$1.registerLanguage('actionscript', require$$3);
hljs$1.registerLanguage('ada', require$$4);
hljs$1.registerLanguage('angelscript', require$$5);
hljs$1.registerLanguage('apache', require$$6);
hljs$1.registerLanguage('applescript', require$$7);
hljs$1.registerLanguage('arcade', require$$8);
hljs$1.registerLanguage('arduino', require$$9);
hljs$1.registerLanguage('armasm', require$$10);
hljs$1.registerLanguage('xml', require$$11);
hljs$1.registerLanguage('asciidoc', require$$12);
hljs$1.registerLanguage('aspectj', require$$13);
hljs$1.registerLanguage('autohotkey', require$$14);
hljs$1.registerLanguage('autoit', require$$15);
hljs$1.registerLanguage('avrasm', require$$16);
hljs$1.registerLanguage('awk', require$$17);
hljs$1.registerLanguage('axapta', require$$18);
hljs$1.registerLanguage('bash', require$$19);
hljs$1.registerLanguage('basic', require$$20);
hljs$1.registerLanguage('bnf', require$$21);
hljs$1.registerLanguage('brainfuck', require$$22);
hljs$1.registerLanguage('c', require$$23);
hljs$1.registerLanguage('cal', require$$24);
hljs$1.registerLanguage('capnproto', require$$25);
hljs$1.registerLanguage('ceylon', require$$26);
hljs$1.registerLanguage('clean', require$$27);
hljs$1.registerLanguage('clojure', require$$28);
hljs$1.registerLanguage('clojure-repl', require$$29);
hljs$1.registerLanguage('cmake', require$$30);
hljs$1.registerLanguage('coffeescript', require$$31);
hljs$1.registerLanguage('coq', require$$32);
hljs$1.registerLanguage('cos', require$$33);
hljs$1.registerLanguage('cpp', require$$34);
hljs$1.registerLanguage('crmsh', require$$35);
hljs$1.registerLanguage('crystal', require$$36);
hljs$1.registerLanguage('csharp', require$$37);
hljs$1.registerLanguage('csp', require$$38);
hljs$1.registerLanguage('css', require$$39);
hljs$1.registerLanguage('d', require$$40);
hljs$1.registerLanguage('markdown', require$$41);
hljs$1.registerLanguage('dart', require$$42);
hljs$1.registerLanguage('delphi', require$$43);
hljs$1.registerLanguage('diff', require$$44);
hljs$1.registerLanguage('django', require$$45);
hljs$1.registerLanguage('dns', require$$46);
hljs$1.registerLanguage('dockerfile', require$$47);
hljs$1.registerLanguage('dos', require$$48);
hljs$1.registerLanguage('dsconfig', require$$49);
hljs$1.registerLanguage('dts', require$$50);
hljs$1.registerLanguage('dust', require$$51);
hljs$1.registerLanguage('ebnf', require$$52);
hljs$1.registerLanguage('elixir', require$$53);
hljs$1.registerLanguage('elm', require$$54);
hljs$1.registerLanguage('ruby', require$$55);
hljs$1.registerLanguage('erb', require$$56);
hljs$1.registerLanguage('erlang-repl', require$$57);
hljs$1.registerLanguage('erlang', require$$58);
hljs$1.registerLanguage('excel', require$$59);
hljs$1.registerLanguage('fix', require$$60);
hljs$1.registerLanguage('flix', require$$61);
hljs$1.registerLanguage('fortran', require$$62);
hljs$1.registerLanguage('fsharp', require$$63);
hljs$1.registerLanguage('gams', require$$64);
hljs$1.registerLanguage('gauss', require$$65);
hljs$1.registerLanguage('gcode', require$$66);
hljs$1.registerLanguage('gherkin', require$$67);
hljs$1.registerLanguage('glsl', require$$68);
hljs$1.registerLanguage('gml', require$$69);
hljs$1.registerLanguage('go', require$$70);
hljs$1.registerLanguage('golo', require$$71);
hljs$1.registerLanguage('gradle', require$$72);
hljs$1.registerLanguage('graphql', require$$73);
hljs$1.registerLanguage('groovy', require$$74);
hljs$1.registerLanguage('haml', require$$75);
hljs$1.registerLanguage('handlebars', require$$76);
hljs$1.registerLanguage('haskell', require$$77);
hljs$1.registerLanguage('haxe', require$$78);
hljs$1.registerLanguage('hsp', require$$79);
hljs$1.registerLanguage('http', require$$80);
hljs$1.registerLanguage('hy', require$$81);
hljs$1.registerLanguage('inform7', require$$82);
hljs$1.registerLanguage('ini', require$$83);
hljs$1.registerLanguage('irpf90', require$$84);
hljs$1.registerLanguage('isbl', require$$85);
hljs$1.registerLanguage('java', require$$86);
hljs$1.registerLanguage('javascript', require$$87);
hljs$1.registerLanguage('jboss-cli', require$$88);
hljs$1.registerLanguage('json', require$$89);
hljs$1.registerLanguage('julia', require$$90);
hljs$1.registerLanguage('julia-repl', require$$91);
hljs$1.registerLanguage('kotlin', require$$92);
hljs$1.registerLanguage('lasso', require$$93);
hljs$1.registerLanguage('latex', require$$94);
hljs$1.registerLanguage('ldif', require$$95);
hljs$1.registerLanguage('leaf', require$$96);
hljs$1.registerLanguage('less', require$$97);
hljs$1.registerLanguage('lisp', require$$98);
hljs$1.registerLanguage('livecodeserver', require$$99);
hljs$1.registerLanguage('livescript', require$$100);
hljs$1.registerLanguage('llvm', require$$101);
hljs$1.registerLanguage('lsl', require$$102);
hljs$1.registerLanguage('lua', require$$103);
hljs$1.registerLanguage('makefile', require$$104);
hljs$1.registerLanguage('mathematica', require$$105);
hljs$1.registerLanguage('matlab', require$$106);
hljs$1.registerLanguage('maxima', require$$107);
hljs$1.registerLanguage('mel', require$$108);
hljs$1.registerLanguage('mercury', require$$109);
hljs$1.registerLanguage('mipsasm', require$$110);
hljs$1.registerLanguage('mizar', require$$111);
hljs$1.registerLanguage('perl', require$$112);
hljs$1.registerLanguage('mojolicious', require$$113);
hljs$1.registerLanguage('monkey', require$$114);
hljs$1.registerLanguage('moonscript', require$$115);
hljs$1.registerLanguage('n1ql', require$$116);
hljs$1.registerLanguage('nestedtext', require$$117);
hljs$1.registerLanguage('nginx', require$$118);
hljs$1.registerLanguage('nim', require$$119);
hljs$1.registerLanguage('nix', require$$120);
hljs$1.registerLanguage('node-repl', require$$121);
hljs$1.registerLanguage('nsis', require$$122);
hljs$1.registerLanguage('objectivec', require$$123);
hljs$1.registerLanguage('ocaml', require$$124);
hljs$1.registerLanguage('openscad', require$$125);
hljs$1.registerLanguage('oxygene', require$$126);
hljs$1.registerLanguage('parser3', require$$127);
hljs$1.registerLanguage('pf', require$$128);
hljs$1.registerLanguage('pgsql', require$$129);
hljs$1.registerLanguage('php', require$$130);
hljs$1.registerLanguage('php-template', require$$131);
hljs$1.registerLanguage('plaintext', require$$132);
hljs$1.registerLanguage('pony', require$$133);
hljs$1.registerLanguage('powershell', require$$134);
hljs$1.registerLanguage('processing', require$$135);
hljs$1.registerLanguage('profile', require$$136);
hljs$1.registerLanguage('prolog', require$$137);
hljs$1.registerLanguage('properties', require$$138);
hljs$1.registerLanguage('protobuf', require$$139);
hljs$1.registerLanguage('puppet', require$$140);
hljs$1.registerLanguage('purebasic', require$$141);
hljs$1.registerLanguage('python', require$$142);
hljs$1.registerLanguage('python-repl', require$$143);
hljs$1.registerLanguage('q', require$$144);
hljs$1.registerLanguage('qml', require$$145);
hljs$1.registerLanguage('r', require$$146);
hljs$1.registerLanguage('reasonml', require$$147);
hljs$1.registerLanguage('rib', require$$148);
hljs$1.registerLanguage('roboconf', require$$149);
hljs$1.registerLanguage('routeros', require$$150);
hljs$1.registerLanguage('rsl', require$$151);
hljs$1.registerLanguage('ruleslanguage', require$$152);
hljs$1.registerLanguage('rust', require$$153);
hljs$1.registerLanguage('sas', require$$154);
hljs$1.registerLanguage('scala', require$$155);
hljs$1.registerLanguage('scheme', require$$156);
hljs$1.registerLanguage('scilab', require$$157);
hljs$1.registerLanguage('scss', require$$158);
hljs$1.registerLanguage('shell', require$$159);
hljs$1.registerLanguage('smali', require$$160);
hljs$1.registerLanguage('smalltalk', require$$161);
hljs$1.registerLanguage('sml', require$$162);
hljs$1.registerLanguage('sqf', require$$163);
hljs$1.registerLanguage('sql', require$$164);
hljs$1.registerLanguage('stan', require$$165);
hljs$1.registerLanguage('stata', require$$166);
hljs$1.registerLanguage('step21', require$$167);
hljs$1.registerLanguage('stylus', require$$168);
hljs$1.registerLanguage('subunit', require$$169);
hljs$1.registerLanguage('swift', require$$170);
hljs$1.registerLanguage('taggerscript', require$$171);
hljs$1.registerLanguage('yaml', require$$172);
hljs$1.registerLanguage('tap', require$$173);
hljs$1.registerLanguage('tcl', require$$174);
hljs$1.registerLanguage('thrift', require$$175);
hljs$1.registerLanguage('tp', require$$176);
hljs$1.registerLanguage('twig', require$$177);
hljs$1.registerLanguage('typescript', require$$178);
hljs$1.registerLanguage('vala', require$$179);
hljs$1.registerLanguage('vbnet', require$$180);
hljs$1.registerLanguage('vbscript', require$$181);
hljs$1.registerLanguage('vbscript-html', require$$182);
hljs$1.registerLanguage('verilog', require$$183);
hljs$1.registerLanguage('vhdl', require$$184);
hljs$1.registerLanguage('vim', require$$185);
hljs$1.registerLanguage('wasm', require$$186);
hljs$1.registerLanguage('wren', require$$187);
hljs$1.registerLanguage('x86asm', require$$188);
hljs$1.registerLanguage('xl', require$$189);
hljs$1.registerLanguage('xquery', require$$190);
hljs$1.registerLanguage('zephir', require$$191);
hljs$1.HighlightJS = hljs$1;
hljs$1.default = hljs$1;
var lib$1 = hljs$1;
var hljs = lib$1;
var decodeHtml = lib$2.decode,
classAttr = 'class="';
/**
* showdownHighlight
* Highlight the code in the showdown input.
*
* Examples:
*
* ```js
* let converter = new showdown.Converter({
* extensions: [showdownHighlight]
* })
* ```
*
* Enable the classes in the `<pre>` element:
*
* ```js
* let converter = new showdown.Converter({
* extensions: [showdownHighlight({ pre: true })]
* })
* ```
*
*
* If you want to disable language [auto detection](https://highlightjs.org/usage/)
* feature of hljs, change `auto_detection` flag as `false`. With this option
* turned off, `showdown-highlight` will not process any codeblocks with no
* language specified.
*
* ```js
* let converter = new showdown.Converter({
* extensions: [showdownHighlight({ auto_detection: false })]
* })
* ```
*
* @name showdownHighlight
* @function
*/
var lib = function showdownHighlight() {
var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
_ref$pre = _ref.pre,
pre = _ref$pre === undefined ? false : _ref$pre,
_ref$auto_detection = _ref.auto_detection,
auto_detection = _ref$auto_detection === undefined ? true : _ref$auto_detection;
var filter = function filter(text, converter, options) {
var params = {
left: "<pre><code\\b[^>]*>",
right: "</code></pre>",
flags: "g"
};
var replacement = function replacement(wholeMatch, match, left, right) {
match = decodeHtml(match);
var lang = (left.match(/class=\"([^ \"]+)/) || [])[1];
if (!lang && !auto_detection) {
return wholeMatch;
}
if (left.includes(classAttr)) {
var attrIndex = left.indexOf(classAttr) + classAttr.length;
left = left.slice(0, attrIndex) + 'hljs ' + left.slice(attrIndex);
} else {
left = left.slice(0, -1) + ' class="hljs">';
}
if (pre && lang) {
left = left.replace('<pre>', "<pre class=\"" + lang + " language-" + lang + "\">");
}
if (lang && hljs.getLanguage(lang)) {
return left + hljs.highlight(match, { language: lang }).value + right;
}
return left + hljs.highlightAuto(match).value + right;
};
return showdown.helper.replaceRecursiveRegExp(text, replacement, params.left, params.right, params.flags);
};
return [{
type: "output",
filter: filter
}];
};
const ANKI_MATH_REGEXP = /(\\\[[\s\S]*?\\\])|(\\\([\s\S]*?\\\))/g;
const HIGHLIGHT_REGEXP = /==(.*?)==/g;
const MATH_REPLACE = "OBSTOANKIMATH";
const INLINE_CODE_REPLACE = "OBSTOANKICODEINLINE";
const DISPLAY_CODE_REPLACE = "OBSTOANKICODEDISPLAY";
const CLOZE_REGEXP = /(?:(?<!{){(?:c?(\d+)[:|])?(?!{))((?:[^\n][\n]?)+?)(?:(?<!})}(?!}))/g;
const IMAGE_EXTS = [".png", ".jpg", ".jpeg", ".gif", ".bmp", ".svg", ".tiff"];
const AUDIO_EXTS = [".wav", ".m4a", ".flac", ".mp3", ".wma", ".aac", ".webm"];
const PARA_OPEN = "<p>";
const PARA_CLOSE = "</p>";
let cloze_unset_num = 1;
let converter = new showdown.Converter({
simplifiedAutoLink: true,
literalMidWordUnderscores: true,
tables: true, tasklists: true,
simpleLineBreaks: true,
requireSpaceBeforeHeadingText: true,
extensions: [lib]
});
function escapeHtml(unsafe) {
return unsafe
.replace(/&/g, "&amp;")
.replace(/</g, "&lt;")
.replace(/>/g, "&gt;")
.replace(/"/g, "&quot;")
.replace(/'/g, "&#039;");
}
class FormatConverter {
file_cache;
vault_name;
detectedMedia;
constructor(file_cache, vault_name) {
this.vault_name = vault_name;
this.file_cache = file_cache;
this.detectedMedia = new Set();
}
getUrlFromLink(link) {
return "obsidian://open?vault=" + encodeURIComponent(this.vault_name) + String.raw `&file=` + encodeURIComponent(link);
}
format_note_with_url(note, url, field) {
note.fields[field] += '<br><a href="' + url + '" class="obsidian-link">Obsidian</a>';
}
format_note_with_frozen_fields(note, frozen_fields_dict) {
for (let field in note.fields) {
note.fields[field] += frozen_fields_dict[note.modelName][field];
}
}
obsidian_to_anki_math(note_text) {
return note_text.replace(OBS_DISPLAY_MATH_REGEXP, "\\[$1\\]").replace(OBS_INLINE_MATH_REGEXP, "\\($1\\)");
}
cloze_repl(_1, match_id, match_content) {
if (match_id == undefined) {
let result = "{{c" + cloze_unset_num.toString() + "::" + match_content + "}}";
cloze_unset_num += 1;
return result;
}
let result = "{{c" + match_id + "::" + match_content + "}}";
return result;
}
curly_to_cloze(text) {
/*Change text in curly brackets to Anki-formatted cloze.*/
text = text.replace(CLOZE_REGEXP, this.cloze_repl);
cloze_unset_num = 1;
return text;
}
getAndFormatMedias(note_text) {
if (!(this.file_cache.hasOwnProperty("embeds"))) {
return note_text;
}
for (let embed of this.file_cache.embeds) {
if (note_text.includes(embed.original)) {
this.detectedMedia.add(embed.link);
if (AUDIO_EXTS.includes(path$1.extname(embed.link))) {
note_text = note_text.replace(new RegExp(escapeRegex(embed.original), "g"), "[sound:" + path$1.basename(embed.link) + "]");
}
else if (IMAGE_EXTS.includes(path$1.extname(embed.link))) {
note_text = note_text.replace(new RegExp(escapeRegex(embed.original), "g"), '<img src="' + path$1.basename(embed.link) + '" alt="' + embed.displayText + '">');
}
else {
console.warn("Unsupported extension: ", path$1.extname(embed.link));
}
}
}
return note_text;
}
formatLinks(note_text) {
if (!(this.file_cache.hasOwnProperty("links"))) {
return note_text;
}
for (let link of this.file_cache.links) {
note_text = note_text.replace(new RegExp(escapeRegex(link.original), "g"), '<a href="' + this.getUrlFromLink(link.link) + '">' + link.displayText + "</a>");
}
return note_text;
}
censor(note_text, regexp, mask) {
/*Take note_text and replace every match of regexp with mask, simultaneously adding it to a string array*/
let matches = [];
for (let match of note_text.matchAll(regexp)) {
matches.push(match[0]);
}
return [note_text.replace(regexp, mask), matches];
}
decensor(note_text, mask, replacements, escape) {
for (let replacement of replacements) {
note_text = note_text.replace(mask, escape ? escapeHtml(replacement) : replacement);
}
return note_text;
}
format(note_text, cloze, highlights_to_cloze) {
note_text = this.obsidian_to_anki_math(note_text);
//Extract the parts that are anki math
let math_matches;
let inline_code_matches;
let display_code_matches;
const add_highlight_css = note_text.match(OBS_DISPLAY_CODE_REGEXP) ? true : false;
[note_text, math_matches] = this.censor(note_text, ANKI_MATH_REGEXP, MATH_REPLACE);
[note_text, display_code_matches] = this.censor(note_text, OBS_DISPLAY_CODE_REGEXP, DISPLAY_CODE_REPLACE);
[note_text, inline_code_matches] = this.censor(note_text, OBS_CODE_REGEXP, INLINE_CODE_REPLACE);
if (cloze) {
if (highlights_to_cloze) {
note_text = note_text.replace(HIGHLIGHT_REGEXP, "{$1}");
}
note_text = this.curly_to_cloze(note_text);
}
note_text = this.getAndFormatMedias(note_text);
note_text = this.formatLinks(note_text);
//Special for formatting highlights now, but want to avoid any == in code
note_text = note_text.replace(HIGHLIGHT_REGEXP, String.raw `<mark>$1</mark>`);
note_text = this.decensor(note_text, DISPLAY_CODE_REPLACE, display_code_matches, false);
note_text = this.decensor(note_text, INLINE_CODE_REPLACE, inline_code_matches, false);
note_text = converter.makeHtml(note_text);
note_text = this.decensor(note_text, MATH_REPLACE, math_matches, true).trim();
// Remove unnecessary paragraph tag
if (note_text.startsWith(PARA_OPEN) && note_text.endsWith(PARA_CLOSE)) {
note_text = note_text.slice(PARA_OPEN.length, -1 * PARA_CLOSE.length);
}
if (add_highlight_css) {
note_text = '<link href="' + CODE_CSS_URL + '" rel="stylesheet">' + note_text;
}
return note_text;
}
}
/*Performing plugin operations on markdown file contents*/
const double_regexp = /(?:\r\n|\r|\n)((?:\r\n|\r|\n)(?:<!--)?ID: \d+)/g;
function id_to_str(identifier, inline = false, comment = false) {
let result = "ID: " + identifier.toString();
if (comment) {
result = "<!--" + result + "-->";
}
if (inline) {
result += " ";
}
else {
result += "\n";
}
return result;
}
function string_insert(text, position_inserts) {
/*Insert strings in position_inserts into text, at indices.
position_inserts will look like:
[(0, "hi"), (3, "hello"), (5, "beep")]*/
let offset = 0;
let sorted_inserts = position_inserts.sort((a, b) => a[0] - b[0]);
for (let insertion of sorted_inserts) {
let position = insertion[0];
let insert_str = insertion[1];
text = text.slice(0, position + offset) + insert_str + text.slice(position + offset);
offset += insert_str.length;
}
return text;
}
function spans(pattern, text) {
/*Return a list of span-tuples for matches of pattern in text.*/
let output = [];
let matches = text.matchAll(pattern);
for (let match of matches) {
output.push([match.index, match.index + match[0].length]);
}
return output;
}
function contained_in(span, spans) {
/*Return whether span is contained in spans (+- 1 leeway)*/
return spans.some((element) => span[0] >= element[0] - 1 && span[1] <= element[1] + 1);
}
function* findignore(pattern, text, ignore_spans) {
let matches = text.matchAll(pattern);
for (let match of matches) {
if (!(contained_in([match.index, match.index + match[0].length], ignore_spans))) {
yield match;
}
}
}
class AbstractFile {
file;
path;
url;
original_file;
data;
file_cache;
frozen_fields_dict;
target_deck;
global_tags;
notes_to_add;
id_indexes;
notes_to_edit;
notes_to_delete;
all_notes_to_add;
note_ids;
card_ids;
tags;
formatter;
constructor(file_contents, path, url, data, file_cache) {
this.data = data;
this.file = file_contents;
this.path = path;
this.url = url;
this.original_file = this.file;
this.file_cache = file_cache;
this.formatter = new FormatConverter(file_cache, this.data.vault_name);
}
setup_frozen_fields_dict() {
let frozen_fields_dict = {};
for (let note_type in this.data.fields_dict) {
let fields = this.data.fields_dict[note_type];
let temp_dict = {};
for (let field of fields) {
temp_dict[field] = "";
}
frozen_fields_dict[note_type] = temp_dict;
}
for (let match of this.file.matchAll(this.data.FROZEN_REGEXP)) {
const [note_type, fields] = [match[1], match[2]];
const virtual_note = note_type + "\n" + fields;
const parsed_fields = new Note(virtual_note, this.data.fields_dict, this.data.curly_cloze, this.data.highlights_to_cloze, this.formatter).getFields();
frozen_fields_dict[note_type] = parsed_fields;
}
this.frozen_fields_dict = frozen_fields_dict;
}
setup_target_deck() {
const result = this.file.match(this.data.DECK_REGEXP);
this.target_deck = result ? result[1] : this.data.template["deckName"];
}
setup_global_tags() {
const result = this.file.match(this.data.TAG_REGEXP);
this.global_tags = result ? result[1] : "";
}
getHash() {
return md5.Md5.hashStr(this.file);
}
scanDeletions() {
for (let match of this.file.matchAll(this.data.EMPTY_REGEXP)) {
this.notes_to_delete.push(parseInt(match[1]));
}
}
getContextAtIndex(position) {
let result = this.path;
let currentContext = [];
if (!(this.file_cache.hasOwnProperty('headings'))) {
return result;
}
for (let currentHeading of this.file_cache.headings) {
if (position < currentHeading.position.start.offset) {
//We've gone past position now with headings, so let's return!
break;
}
let insert_index = 0;
for (let contextHeading of currentContext) {
if (currentHeading.level > contextHeading.level) {
insert_index += 1;
continue;
}
break;
}
currentContext = currentContext.slice(0, insert_index);
currentContext.push(currentHeading);
}
let heading_strs = [];
for (let contextHeading of currentContext) {
heading_strs.push(contextHeading.heading);
}
let result_arr = [result];
result_arr.push(...heading_strs);
return result_arr.join(" > ");
}
removeEmpties() {
this.file = this.file.replace(this.data.EMPTY_REGEXP, "");
}
getCreateDecks() {
let actions = [];
for (let note of this.all_notes_to_add) {
actions.push(createDeck(note.deckName));
}
return multi(actions);
}
getAddNotes() {
let actions = [];
for (let note of this.all_notes_to_add) {
actions.push(addNote(note));
}
return multi(actions);
}
getDeleteNotes() {
return deleteNotes(this.notes_to_delete);
}
getUpdateFields() {
let actions = [];
for (let parsed of this.notes_to_edit) {
actions.push(updateNoteFields(parsed.identifier, parsed.note.fields));
}
return multi(actions);
}
getNoteInfo() {
let IDs = [];
for (let parsed of this.notes_to_edit) {
IDs.push(parsed.identifier);
}
return notesInfo(IDs);
}
getChangeDecks() {
return changeDeck(this.card_ids, this.target_deck);
}
getClearTags() {
let IDs = [];
for (let parsed of this.notes_to_edit) {
IDs.push(parsed.identifier);
}
return removeTags(IDs, this.tags.join(" "));
}
getAddTags() {
let actions = [];
for (let parsed of this.notes_to_edit) {
actions.push(addTags([parsed.identifier], parsed.note.tags.join(" ") + " " + this.global_tags));
}
return multi(actions);
}
}
class AllFile extends AbstractFile {
ignore_spans;
custom_regexps;
inline_notes_to_add;
inline_id_indexes;
regex_notes_to_add;
regex_id_indexes;
constructor(file_contents, path, url, data, file_cache) {
super(file_contents, path, url, data, file_cache);
this.custom_regexps = data.custom_regexps;
}
add_spans_to_ignore() {
this.ignore_spans = [];
this.ignore_spans.push(...spans(this.data.FROZEN_REGEXP, this.file));
const deck_result = this.file.match(this.data.DECK_REGEXP);
if (deck_result) {
this.ignore_spans.push([deck_result.index, deck_result.index + deck_result[0].length]);
}
const tag_result = this.file.match(this.data.TAG_REGEXP);
if (tag_result) {
this.ignore_spans.push([tag_result.index, tag_result.index + tag_result[0].length]);
}
this.ignore_spans.push(...spans(this.data.NOTE_REGEXP, this.file));
this.ignore_spans.push(...spans(this.data.INLINE_REGEXP, this.file));
this.ignore_spans.push(...spans(OBS_INLINE_MATH_REGEXP, this.file));
this.ignore_spans.push(...spans(OBS_DISPLAY_MATH_REGEXP, this.file));
this.ignore_spans.push(...spans(OBS_CODE_REGEXP, this.file));
this.ignore_spans.push(...spans(OBS_DISPLAY_CODE_REGEXP, this.file));
}
setupScan() {
this.setup_frozen_fields_dict();
this.setup_target_deck();
this.setup_global_tags();
this.add_spans_to_ignore();
this.notes_to_add = [];
this.inline_notes_to_add = [];
this.regex_notes_to_add = [];
this.id_indexes = [];
this.inline_id_indexes = [];
this.regex_id_indexes = [];
this.notes_to_edit = [];
this.notes_to_delete = [];
}
scanNotes() {
for (let note_match of this.file.matchAll(this.data.NOTE_REGEXP)) {
let [note, position] = [note_match[1], note_match.index + note_match[0].indexOf(note_match[1]) + note_match[1].length];
// That second thing essentially gets the index of the end of the first capture group.
let parsed = new Note(note, this.data.fields_dict, this.data.curly_cloze, this.data.highlights_to_cloze, this.formatter).parse(this.target_deck, this.url, this.frozen_fields_dict, this.data, this.data.add_context ? this.getContextAtIndex(note_match.index) : "");
if (parsed.identifier == null) {
// Need to make sure global_tags get added
parsed.note.tags.push(...this.global_tags.split(TAG_SEP));
this.notes_to_add.push(parsed.note);
this.id_indexes.push(position);
}
else if (!this.data.EXISTING_IDS.includes(parsed.identifier)) {
if (parsed.identifier == CLOZE_ERROR) {
continue;
}
// Need to show an error otherwise
else if (parsed.identifier == NOTE_TYPE_ERROR) {
console.warn("Did not recognise note type ", parsed.note.modelName, " in file ", this.path);
}
else {
console.warn("Note with id", parsed.identifier, " in file ", this.path, " does not exist in Anki!");
}
}
else {
this.notes_to_edit.push(parsed);
}
}
}
scanInlineNotes() {
for (let note_match of this.file.matchAll(this.data.INLINE_REGEXP)) {
let [note, position] = [note_match[1], note_match.index + note_match[0].indexOf(note_match[1]) + note_match[1].length];
// That second thing essentially gets the index of the end of the first capture group.
let parsed = new InlineNote(note, this.data.fields_dict, this.data.curly_cloze, this.data.highlights_to_cloze, this.formatter).parse(this.target_deck, this.url, this.frozen_fields_dict, this.data, this.data.add_context ? this.getContextAtIndex(note_match.index) : "");
if (parsed.identifier == null) {
// Need to make sure global_tags get added
parsed.note.tags.push(...this.global_tags.split(TAG_SEP));
this.inline_notes_to_add.push(parsed.note);
this.inline_id_indexes.push(position);
}
else if (!this.data.EXISTING_IDS.includes(parsed.identifier)) {
// Need to show an error
if (parsed.identifier == CLOZE_ERROR) {
continue;
}
console.warn("Note with id", parsed.identifier, " in file ", this.path, " does not exist in Anki!");
}
else {
this.notes_to_edit.push(parsed);
}
}
}
search(note_type, regexp_str) {
//Search the file for regex matches
//ignoring matches inside ignore_spans,
//and adding any matches to ignore_spans.
for (let search_id of [true, false]) {
for (let search_tags of [true, false]) {
let id_str = search_id ? ID_REGEXP_STR : "";
let tag_str = search_tags ? TAG_REGEXP_STR : "";
let regexp = new RegExp(regexp_str + tag_str + id_str, 'gm');
for (let match of findignore(regexp, this.file, this.ignore_spans)) {
this.ignore_spans.push([match.index, match.index + match[0].length]);
const parsed = new RegexNote(match, note_type, this.data.fields_dict, search_tags, search_id, this.data.curly_cloze, this.data.highlights_to_cloze, this.formatter).parse(this.target_deck, this.url, this.frozen_fields_dict, this.data, this.data.add_context ? this.getContextAtIndex(match.index) : "");
if (search_id) {
if (!(this.data.EXISTING_IDS.includes(parsed.identifier))) {
if (parsed.identifier == CLOZE_ERROR) {
// This means it wasn't actually a note! So we should remove it from ignore_spans
this.ignore_spans.pop();
continue;
}
console.warn("Note with id", parsed.identifier, " in file ", this.path, " does not exist in Anki!");
}
else {
this.notes_to_edit.push(parsed);
}
}
else {
if (parsed.identifier == CLOZE_ERROR) {
// This means it wasn't actually a note! So we should remove it from ignore_spans
this.ignore_spans.pop();
continue;
}
parsed.note.tags.push(...this.global_tags.split(TAG_SEP));
this.regex_notes_to_add.push(parsed.note);
this.regex_id_indexes.push(match.index + match[0].length);
}
}
}
}
}
scanFile() {
this.setupScan();
this.scanNotes();
this.scanInlineNotes();
for (let note_type in this.custom_regexps) {
const regexp_str = this.custom_regexps[note_type];
if (regexp_str) {
this.search(note_type, regexp_str);
}
}
this.all_notes_to_add = this.notes_to_add.concat(this.inline_notes_to_add).concat(this.regex_notes_to_add);
this.scanDeletions();
}
fix_newline_ids() {
this.file = this.file.replace(double_regexp, "$1");
}
writeIDs() {
let normal_inserts = [];
this.id_indexes.forEach((id_position, index) => {
const identifier = this.note_ids[index];
if (identifier) {
normal_inserts.push([id_position, id_to_str(identifier, false, this.data.comment)]);
}
});
let inline_inserts = [];
this.inline_id_indexes.forEach((id_position, index) => {
const identifier = this.note_ids[index + this.notes_to_add.length]; //Since regular then inline
if (identifier) {
inline_inserts.push([id_position, id_to_str(identifier, true, this.data.comment)]);
}
});
let regex_inserts = [];
this.regex_id_indexes.forEach((id_position, index) => {
const identifier = this.note_ids[index + this.notes_to_add.length + this.inline_notes_to_add.length]; // Since regular then inline then regex
if (identifier) {
regex_inserts.push([id_position, "\n" + id_to_str(identifier, false, this.data.comment)]);
}
});
this.file = string_insert(this.file, normal_inserts.concat(inline_inserts).concat(regex_inserts));
this.fix_newline_ids();
}
}
var balancedMatch = balanced;
function balanced(a, b, str) {
if (a instanceof RegExp) a = maybeMatch(a, str);
if (b instanceof RegExp) b = maybeMatch(b, str);
var r = range(a, b, str);
return r && {
start: r[0],
end: r[1],
pre: str.slice(0, r[0]),
body: str.slice(r[0] + a.length, r[1]),
post: str.slice(r[1] + b.length)
};
}
function maybeMatch(reg, str) {
var m = str.match(reg);
return m ? m[0] : null;
}
balanced.range = range;
function range(a, b, str) {
var begs, beg, left, right, result;
var ai = str.indexOf(a);
var bi = str.indexOf(b, ai + 1);
var i = ai;
if (ai >= 0 && bi > 0) {
if(a===b) {
return [ai, bi];
}
begs = [];
left = str.length;
while (i >= 0 && !result) {
if (i == ai) {
begs.push(i);
ai = str.indexOf(a, i + 1);
} else if (begs.length == 1) {
result = [ begs.pop(), bi ];
} else {
beg = begs.pop();
if (beg < left) {
left = beg;
right = bi;
}
bi = str.indexOf(b, i + 1);
}
i = ai < bi && ai >= 0 ? ai : bi;
}
if (begs.length) {
result = [ left, right ];
}
}
return result;
}
var braceExpansion = expandTop;
var escSlash = '\0SLASH'+Math.random()+'\0';
var escOpen = '\0OPEN'+Math.random()+'\0';
var escClose = '\0CLOSE'+Math.random()+'\0';
var escComma = '\0COMMA'+Math.random()+'\0';
var escPeriod = '\0PERIOD'+Math.random()+'\0';
function numeric(str) {
return parseInt(str, 10) == str
? parseInt(str, 10)
: str.charCodeAt(0);
}
function escapeBraces(str) {
return str.split('\\\\').join(escSlash)
.split('\\{').join(escOpen)
.split('\\}').join(escClose)
.split('\\,').join(escComma)
.split('\\.').join(escPeriod);
}
function unescapeBraces(str) {
return str.split(escSlash).join('\\')
.split(escOpen).join('{')
.split(escClose).join('}')
.split(escComma).join(',')
.split(escPeriod).join('.');
}
// Basically just str.split(","), but handling cases
// where we have nested braced sections, which should be
// treated as individual members, like {a,{b,c},d}
function parseCommaParts(str) {
if (!str)
return [''];
var parts = [];
var m = balancedMatch('{', '}', str);
if (!m)
return str.split(',');
var pre = m.pre;
var body = m.body;
var post = m.post;
var p = pre.split(',');
p[p.length-1] += '{' + body + '}';
var postParts = parseCommaParts(post);
if (post.length) {
p[p.length-1] += postParts.shift();
p.push.apply(p, postParts);
}
parts.push.apply(parts, p);
return parts;
}
function expandTop(str) {
if (!str)
return [];
// I don't know why Bash 4.3 does this, but it does.
// Anything starting with {} will have the first two bytes preserved
// but *only* at the top level, so {},a}b will not expand to anything,
// but a{},b}c will be expanded to [a}c,abc].
// One could argue that this is a bug in Bash, but since the goal of
// this module is to match Bash's rules, we escape a leading {}
if (str.substr(0, 2) === '{}') {
str = '\\{\\}' + str.substr(2);
}
return expand(escapeBraces(str), true).map(unescapeBraces);
}
function embrace(str) {
return '{' + str + '}';
}
function isPadded(el) {
return /^-?0\d/.test(el);
}
function lte(i, y) {
return i <= y;
}
function gte(i, y) {
return i >= y;
}
function expand(str, isTop) {
var expansions = [];
var m = balancedMatch('{', '}', str);
if (!m) return [str];
// no need to expand pre, since it is guaranteed to be free of brace-sets
var pre = m.pre;
var post = m.post.length
? expand(m.post, false)
: [''];
if (/\$$/.test(m.pre)) {
for (var k = 0; k < post.length; k++) {
var expansion = pre+ '{' + m.body + '}' + post[k];
expansions.push(expansion);
}
} else {
var isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body);
var isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body);
var isSequence = isNumericSequence || isAlphaSequence;
var isOptions = m.body.indexOf(',') >= 0;
if (!isSequence && !isOptions) {
// {a},b}
if (m.post.match(/,.*\}/)) {
str = m.pre + '{' + m.body + escClose + m.post;
return expand(str);
}
return [str];
}
var n;
if (isSequence) {
n = m.body.split(/\.\./);
} else {
n = parseCommaParts(m.body);
if (n.length === 1) {
// x{{a,b}}y ==> x{a}y x{b}y
n = expand(n[0], false).map(embrace);
if (n.length === 1) {
return post.map(function(p) {
return m.pre + n[0] + p;
});
}
}
}
// at this point, n is the parts, and we know it's not a comma set
// with a single entry.
var N;
if (isSequence) {
var x = numeric(n[0]);
var y = numeric(n[1]);
var width = Math.max(n[0].length, n[1].length);
var incr = n.length == 3
? Math.abs(numeric(n[2]))
: 1;
var test = lte;
var reverse = y < x;
if (reverse) {
incr *= -1;
test = gte;
}
var pad = n.some(isPadded);
N = [];
for (var i = x; test(i, y); i += incr) {
var c;
if (isAlphaSequence) {
c = String.fromCharCode(i);
if (c === '\\')
c = '';
} else {
c = String(i);
if (pad) {
var need = width - c.length;
if (need > 0) {
var z = new Array(need + 1).join('0');
if (i < 0)
c = '-' + z + c.slice(1);
else
c = z + c;
}
}
}
N.push(c);
}
} else {
N = [];
for (var j = 0; j < n.length; j++) {
N.push.apply(N, expand(n[j], false));
}
}
for (var j = 0; j < N.length; j++) {
for (var k = 0; k < post.length; k++) {
var expansion = pre + N[j] + post[k];
if (!isTop || isSequence || expansion)
expansions.push(expansion);
}
}
}
return expansions;
}
const MAX_PATTERN_LENGTH = 1024 * 64;
const assertValidPattern = (pattern) => {
if (typeof pattern !== 'string') {
throw new TypeError('invalid pattern');
}
if (pattern.length > MAX_PATTERN_LENGTH) {
throw new TypeError('pattern is too long');
}
};
// translate the various posix character classes into unicode properties
// this works across all unicode locales
// { <posix class>: [<translation>, /u flag required, negated]
const posixClasses = {
'[:alnum:]': ['\\p{L}\\p{Nl}\\p{Nd}', true],
'[:alpha:]': ['\\p{L}\\p{Nl}', true],
'[:ascii:]': ['\\x' + '00-\\x' + '7f', false],
'[:blank:]': ['\\p{Zs}\\t', true],
'[:cntrl:]': ['\\p{Cc}', true],
'[:digit:]': ['\\p{Nd}', true],
'[:graph:]': ['\\p{Z}\\p{C}', true, true],
'[:lower:]': ['\\p{Ll}', true],
'[:print:]': ['\\p{C}', true],
'[:punct:]': ['\\p{P}', true],
'[:space:]': ['\\p{Z}\\t\\r\\n\\v\\f', true],
'[:upper:]': ['\\p{Lu}', true],
'[:word:]': ['\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}', true],
'[:xdigit:]': ['A-Fa-f0-9', false],
};
// only need to escape a few things inside of brace expressions
// escapes: [ \ ] -
const braceEscape = (s) => s.replace(/[[\]\\-]/g, '\\$&');
// escape all regexp magic characters
const regexpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
// everything has already been escaped, we just have to join
const rangesToString = (ranges) => ranges.join('');
// takes a glob string at a posix brace expression, and returns
// an equivalent regular expression source, and boolean indicating
// whether the /u flag needs to be applied, and the number of chars
// consumed to parse the character class.
// This also removes out of order ranges, and returns ($.) if the
// entire class just no good.
const parseClass = (glob, position) => {
const pos = position;
/* c8 ignore start */
if (glob.charAt(pos) !== '[') {
throw new Error('not in a brace expression');
}
/* c8 ignore stop */
const ranges = [];
const negs = [];
let i = pos + 1;
let sawStart = false;
let uflag = false;
let escaping = false;
let negate = false;
let endPos = pos;
let rangeStart = '';
WHILE: while (i < glob.length) {
const c = glob.charAt(i);
if ((c === '!' || c === '^') && i === pos + 1) {
negate = true;
i++;
continue;
}
if (c === ']' && sawStart && !escaping) {
endPos = i + 1;
break;
}
sawStart = true;
if (c === '\\') {
if (!escaping) {
escaping = true;
i++;
continue;
}
// escaped \ char, fall through and treat like normal char
}
if (c === '[' && !escaping) {
// either a posix class, a collation equivalent, or just a [
for (const [cls, [unip, u, neg]] of Object.entries(posixClasses)) {
if (glob.startsWith(cls, i)) {
// invalid, [a-[] is fine, but not [a-[:alpha]]
if (rangeStart) {
return ['$.', false, glob.length - pos, true];
}
i += cls.length;
if (neg)
negs.push(unip);
else
ranges.push(unip);
uflag = uflag || u;
continue WHILE;
}
}
}
// now it's just a normal character, effectively
escaping = false;
if (rangeStart) {
// throw this range away if it's not valid, but others
// can still match.
if (c > rangeStart) {
ranges.push(braceEscape(rangeStart) + '-' + braceEscape(c));
}
else if (c === rangeStart) {
ranges.push(braceEscape(c));
}
rangeStart = '';
i++;
continue;
}
// now might be the start of a range.
// can be either c-d or c-] or c<more...>] or c] at this point
if (glob.startsWith('-]', i + 1)) {
ranges.push(braceEscape(c + '-'));
i += 2;
continue;
}
if (glob.startsWith('-', i + 1)) {
rangeStart = c;
i += 2;
continue;
}
// not the start of a range, just a single character
ranges.push(braceEscape(c));
i++;
}
if (endPos < i) {
// didn't see the end of the class, not a valid class,
// but might still be valid as a literal match.
return ['', false, 0, false];
}
// if we got no ranges and no negates, then we have a range that
// cannot possibly match anything, and that poisons the whole glob
if (!ranges.length && !negs.length) {
return ['$.', false, glob.length - pos, true];
}
// if we got one positive range, and it's a single character, then that's
// not actually a magic pattern, it's just that one literal character.
// we should not treat that as "magic", we should just return the literal
// character. [_] is a perfectly valid way to escape glob magic chars.
if (negs.length === 0 &&
ranges.length === 1 &&
/^\\?.$/.test(ranges[0]) &&
!negate) {
const r = ranges[0].length === 2 ? ranges[0].slice(-1) : ranges[0];
return [regexpEscape(r), false, endPos - pos, false];
}
const sranges = '[' + (negate ? '^' : '') + rangesToString(ranges) + ']';
const snegs = '[' + (negate ? '' : '^') + rangesToString(negs) + ']';
const comb = ranges.length && negs.length
? '(' + sranges + '|' + snegs + ')'
: ranges.length
? sranges
: snegs;
return [comb, uflag, endPos - pos, true];
};
/**
* Un-escape a string that has been escaped with {@link escape}.
*
* If the {@link windowsPathsNoEscape} option is used, then square-brace
* escapes are removed, but not backslash escapes. For example, it will turn
* the string `'[*]'` into `*`, but it will not turn `'\\*'` into `'*'`,
* becuase `\` is a path separator in `windowsPathsNoEscape` mode.
*
* When `windowsPathsNoEscape` is not set, then both brace escapes and
* backslash escapes are removed.
*
* Slashes (and backslashes in `windowsPathsNoEscape` mode) cannot be escaped
* or unescaped.
*/
const unescape = (s, { windowsPathsNoEscape = false, } = {}) => {
return windowsPathsNoEscape
? s.replace(/\[([^\/\\])\]/g, '$1')
: s.replace(/((?!\\).|^)\[([^\/\\])\]/g, '$1$2').replace(/\\([^\/])/g, '$1');
};
// parse a single path portion
const types = new Set(['!', '?', '+', '*', '@']);
const isExtglobType = (c) => types.has(c);
// Patterns that get prepended to bind to the start of either the
// entire string, or just a single path portion, to prevent dots
// and/or traversal patterns, when needed.
// Exts don't need the ^ or / bit, because the root binds that already.
const startNoTraversal = '(?!(?:^|/)\\.\\.?(?:$|/))';
const startNoDot = '(?!\\.)';
// characters that indicate a start of pattern needs the "no dots" bit,
// because a dot *might* be matched. ( is not in the list, because in
// the case of a child extglob, it will handle the prevention itself.
const addPatternStart = new Set(['[', '.']);
// cases where traversal is A-OK, no dot prevention needed
const justDots = new Set(['..', '.']);
const reSpecials = new Set('().*{}+?[]^$\\!');
const regExpEscape$1 = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
// any single thing other than /
const qmark$1 = '[^/]';
// * => any number of characters
const star$1 = qmark$1 + '*?';
// use + when we need to ensure that *something* matches, because the * is
// the only thing in the path portion.
const starNoEmpty = qmark$1 + '+?';
// remove the \ chars that we added if we end up doing a nonmagic compare
// const deslash = (s: string) => s.replace(/\\(.)/g, '$1')
class AST {
type;
#root;
#hasMagic;
#uflag = false;
#parts = [];
#parent;
#parentIndex;
#negs;
#filledNegs = false;
#options;
#toString;
// set to true if it's an extglob with no children
// (which really means one child of '')
#emptyExt = false;
constructor(type, parent, options = {}) {
this.type = type;
// extglobs are inherently magical
if (type)
this.#hasMagic = true;
this.#parent = parent;
this.#root = this.#parent ? this.#parent.#root : this;
this.#options = this.#root === this ? options : this.#root.#options;
this.#negs = this.#root === this ? [] : this.#root.#negs;
if (type === '!' && !this.#root.#filledNegs)
this.#negs.push(this);
this.#parentIndex = this.#parent ? this.#parent.#parts.length : 0;
}
get hasMagic() {
/* c8 ignore start */
if (this.#hasMagic !== undefined)
return this.#hasMagic;
/* c8 ignore stop */
for (const p of this.#parts) {
if (typeof p === 'string')
continue;
if (p.type || p.hasMagic)
return (this.#hasMagic = true);
}
// note: will be undefined until we generate the regexp src and find out
return this.#hasMagic;
}
// reconstructs the pattern
toString() {
if (this.#toString !== undefined)
return this.#toString;
if (!this.type) {
return (this.#toString = this.#parts.map(p => String(p)).join(''));
}
else {
return (this.#toString =
this.type + '(' + this.#parts.map(p => String(p)).join('|') + ')');
}
}
#fillNegs() {
/* c8 ignore start */
if (this !== this.#root)
throw new Error('should only call on root');
if (this.#filledNegs)
return this;
/* c8 ignore stop */
// call toString() once to fill this out
this.toString();
this.#filledNegs = true;
let n;
while ((n = this.#negs.pop())) {
if (n.type !== '!')
continue;
// walk up the tree, appending everthing that comes AFTER parentIndex
let p = n;
let pp = p.#parent;
while (pp) {
for (let i = p.#parentIndex + 1; !pp.type && i < pp.#parts.length; i++) {
for (const part of n.#parts) {
/* c8 ignore start */
if (typeof part === 'string') {
throw new Error('string part in extglob AST??');
}
/* c8 ignore stop */
part.copyIn(pp.#parts[i]);
}
}
p = pp;
pp = p.#parent;
}
}
return this;
}
push(...parts) {
for (const p of parts) {
if (p === '')
continue;
/* c8 ignore start */
if (typeof p !== 'string' && !(p instanceof AST && p.#parent === this)) {
throw new Error('invalid part: ' + p);
}
/* c8 ignore stop */
this.#parts.push(p);
}
}
toJSON() {
const ret = this.type === null
? this.#parts.slice().map(p => (typeof p === 'string' ? p : p.toJSON()))
: [this.type, ...this.#parts.map(p => p.toJSON())];
if (this.isStart() && !this.type)
ret.unshift([]);
if (this.isEnd() &&
(this === this.#root ||
(this.#root.#filledNegs && this.#parent?.type === '!'))) {
ret.push({});
}
return ret;
}
isStart() {
if (this.#root === this)
return true;
// if (this.type) return !!this.#parent?.isStart()
if (!this.#parent?.isStart())
return false;
if (this.#parentIndex === 0)
return true;
// if everything AHEAD of this is a negation, then it's still the "start"
const p = this.#parent;
for (let i = 0; i < this.#parentIndex; i++) {
const pp = p.#parts[i];
if (!(pp instanceof AST && pp.type === '!')) {
return false;
}
}
return true;
}
isEnd() {
if (this.#root === this)
return true;
if (this.#parent?.type === '!')
return true;
if (!this.#parent?.isEnd())
return false;
if (!this.type)
return this.#parent?.isEnd();
// if not root, it'll always have a parent
/* c8 ignore start */
const pl = this.#parent ? this.#parent.#parts.length : 0;
/* c8 ignore stop */
return this.#parentIndex === pl - 1;
}
copyIn(part) {
if (typeof part === 'string')
this.push(part);
else
this.push(part.clone(this));
}
clone(parent) {
const c = new AST(this.type, parent);
for (const p of this.#parts) {
c.copyIn(p);
}
return c;
}
static #parseAST(str, ast, pos, opt) {
let escaping = false;
let inBrace = false;
let braceStart = -1;
let braceNeg = false;
if (ast.type === null) {
// outside of a extglob, append until we find a start
let i = pos;
let acc = '';
while (i < str.length) {
const c = str.charAt(i++);
// still accumulate escapes at this point, but we do ignore
// starts that are escaped
if (escaping || c === '\\') {
escaping = !escaping;
acc += c;
continue;
}
if (inBrace) {
if (i === braceStart + 1) {
if (c === '^' || c === '!') {
braceNeg = true;
}
}
else if (c === ']' && !(i === braceStart + 2 && braceNeg)) {
inBrace = false;
}
acc += c;
continue;
}
else if (c === '[') {
inBrace = true;
braceStart = i;
braceNeg = false;
acc += c;
continue;
}
if (!opt.noext && isExtglobType(c) && str.charAt(i) === '(') {
ast.push(acc);
acc = '';
const ext = new AST(c, ast);
i = AST.#parseAST(str, ext, i, opt);
ast.push(ext);
continue;
}
acc += c;
}
ast.push(acc);
return i;
}
// some kind of extglob, pos is at the (
// find the next | or )
let i = pos + 1;
let part = new AST(null, ast);
const parts = [];
let acc = '';
while (i < str.length) {
const c = str.charAt(i++);
// still accumulate escapes at this point, but we do ignore
// starts that are escaped
if (escaping || c === '\\') {
escaping = !escaping;
acc += c;
continue;
}
if (inBrace) {
if (i === braceStart + 1) {
if (c === '^' || c === '!') {
braceNeg = true;
}
}
else if (c === ']' && !(i === braceStart + 2 && braceNeg)) {
inBrace = false;
}
acc += c;
continue;
}
else if (c === '[') {
inBrace = true;
braceStart = i;
braceNeg = false;
acc += c;
continue;
}
if (isExtglobType(c) && str.charAt(i) === '(') {
part.push(acc);
acc = '';
const ext = new AST(c, part);
part.push(ext);
i = AST.#parseAST(str, ext, i, opt);
continue;
}
if (c === '|') {
part.push(acc);
acc = '';
parts.push(part);
part = new AST(null, ast);
continue;
}
if (c === ')') {
if (acc === '' && ast.#parts.length === 0) {
ast.#emptyExt = true;
}
part.push(acc);
acc = '';
ast.push(...parts, part);
return i;
}
acc += c;
}
// unfinished extglob
// if we got here, it was a malformed extglob! not an extglob, but
// maybe something else in there.
ast.type = null;
ast.#hasMagic = undefined;
ast.#parts = [str.substring(pos - 1)];
return i;
}
static fromGlob(pattern, options = {}) {
const ast = new AST(null, undefined, options);
AST.#parseAST(pattern, ast, 0, options);
return ast;
}
// returns the regular expression if there's magic, or the unescaped
// string if not.
toMMPattern() {
// should only be called on root
/* c8 ignore start */
if (this !== this.#root)
return this.#root.toMMPattern();
/* c8 ignore stop */
const glob = this.toString();
const [re, body, hasMagic, uflag] = this.toRegExpSource();
// if we're in nocase mode, and not nocaseMagicOnly, then we do
// still need a regular expression if we have to case-insensitively
// match capital/lowercase characters.
const anyMagic = hasMagic ||
this.#hasMagic ||
(this.#options.nocase &&
!this.#options.nocaseMagicOnly &&
glob.toUpperCase() !== glob.toLowerCase());
if (!anyMagic) {
return body;
}
const flags = (this.#options.nocase ? 'i' : '') + (uflag ? 'u' : '');
return Object.assign(new RegExp(`^${re}$`, flags), {
_src: re,
_glob: glob,
});
}
// returns the string match, the regexp source, whether there's magic
// in the regexp (so a regular expression is required) and whether or
// not the uflag is needed for the regular expression (for posix classes)
// TODO: instead of injecting the start/end at this point, just return
// the BODY of the regexp, along with the start/end portions suitable
// for binding the start/end in either a joined full-path makeRe context
// (where we bind to (^|/), or a standalone matchPart context (where
// we bind to ^, and not /). Otherwise slashes get duped!
//
// In part-matching mode, the start is:
// - if not isStart: nothing
// - if traversal possible, but not allowed: ^(?!\.\.?$)
// - if dots allowed or not possible: ^
// - if dots possible and not allowed: ^(?!\.)
// end is:
// - if not isEnd(): nothing
// - else: $
//
// In full-path matching mode, we put the slash at the START of the
// pattern, so start is:
// - if first pattern: same as part-matching mode
// - if not isStart(): nothing
// - if traversal possible, but not allowed: /(?!\.\.?(?:$|/))
// - if dots allowed or not possible: /
// - if dots possible and not allowed: /(?!\.)
// end is:
// - if last pattern, same as part-matching mode
// - else nothing
//
// Always put the (?:$|/) on negated tails, though, because that has to be
// there to bind the end of the negated pattern portion, and it's easier to
// just stick it in now rather than try to inject it later in the middle of
// the pattern.
//
// We can just always return the same end, and leave it up to the caller
// to know whether it's going to be used joined or in parts.
// And, if the start is adjusted slightly, can do the same there:
// - if not isStart: nothing
// - if traversal possible, but not allowed: (?:/|^)(?!\.\.?$)
// - if dots allowed or not possible: (?:/|^)
// - if dots possible and not allowed: (?:/|^)(?!\.)
//
// But it's better to have a simpler binding without a conditional, for
// performance, so probably better to return both start options.
//
// Then the caller just ignores the end if it's not the first pattern,
// and the start always gets applied.
//
// But that's always going to be $ if it's the ending pattern, or nothing,
// so the caller can just attach $ at the end of the pattern when building.
//
// So the todo is:
// - better detect what kind of start is needed
// - return both flavors of starting pattern
// - attach $ at the end of the pattern when creating the actual RegExp
//
// Ah, but wait, no, that all only applies to the root when the first pattern
// is not an extglob. If the first pattern IS an extglob, then we need all
// that dot prevention biz to live in the extglob portions, because eg
// +(*|.x*) can match .xy but not .yx.
//
// So, return the two flavors if it's #root and the first child is not an
// AST, otherwise leave it to the child AST to handle it, and there,
// use the (?:^|/) style of start binding.
//
// Even simplified further:
// - Since the start for a join is eg /(?!\.) and the start for a part
// is ^(?!\.), we can just prepend (?!\.) to the pattern (either root
// or start or whatever) and prepend ^ or / at the Regexp construction.
toRegExpSource(allowDot) {
const dot = allowDot ?? !!this.#options.dot;
if (this.#root === this)
this.#fillNegs();
if (!this.type) {
const noEmpty = this.isStart() && this.isEnd();
const src = this.#parts
.map(p => {
const [re, _, hasMagic, uflag] = typeof p === 'string'
? AST.#parseGlob(p, this.#hasMagic, noEmpty)
: p.toRegExpSource(allowDot);
this.#hasMagic = this.#hasMagic || hasMagic;
this.#uflag = this.#uflag || uflag;
return re;
})
.join('');
let start = '';
if (this.isStart()) {
if (typeof this.#parts[0] === 'string') {
// this is the string that will match the start of the pattern,
// so we need to protect against dots and such.
// '.' and '..' cannot match unless the pattern is that exactly,
// even if it starts with . or dot:true is set.
const dotTravAllowed = this.#parts.length === 1 && justDots.has(this.#parts[0]);
if (!dotTravAllowed) {
const aps = addPatternStart;
// check if we have a possibility of matching . or ..,
// and prevent that.
const needNoTrav =
// dots are allowed, and the pattern starts with [ or .
(dot && aps.has(src.charAt(0))) ||
// the pattern starts with \., and then [ or .
(src.startsWith('\\.') && aps.has(src.charAt(2))) ||
// the pattern starts with \.\., and then [ or .
(src.startsWith('\\.\\.') && aps.has(src.charAt(4)));
// no need to prevent dots if it can't match a dot, or if a
// sub-pattern will be preventing it anyway.
const needNoDot = !dot && !allowDot && aps.has(src.charAt(0));
start = needNoTrav ? startNoTraversal : needNoDot ? startNoDot : '';
}
}
}
// append the "end of path portion" pattern to negation tails
let end = '';
if (this.isEnd() &&
this.#root.#filledNegs &&
this.#parent?.type === '!') {
end = '(?:$|\\/)';
}
const final = start + src + end;
return [
final,
unescape(src),
(this.#hasMagic = !!this.#hasMagic),
this.#uflag,
];
}
// We need to calculate the body *twice* if it's a repeat pattern
// at the start, once in nodot mode, then again in dot mode, so a
// pattern like *(?) can match 'x.y'
const repeated = this.type === '*' || this.type === '+';
// some kind of extglob
const start = this.type === '!' ? '(?:(?!(?:' : '(?:';
let body = this.#partsToRegExp(dot);
if (this.isStart() && this.isEnd() && !body && this.type !== '!') {
// invalid extglob, has to at least be *something* present, if it's
// the entire path portion.
const s = this.toString();
this.#parts = [s];
this.type = null;
this.#hasMagic = undefined;
return [s, unescape(this.toString()), false, false];
}
// XXX abstract out this map method
let bodyDotAllowed = !repeated || allowDot || dot || !startNoDot
? ''
: this.#partsToRegExp(true);
if (bodyDotAllowed === body) {
bodyDotAllowed = '';
}
if (bodyDotAllowed) {
body = `(?:${body})(?:${bodyDotAllowed})*?`;
}
// an empty !() is exactly equivalent to a starNoEmpty
let final = '';
if (this.type === '!' && this.#emptyExt) {
final = (this.isStart() && !dot ? startNoDot : '') + starNoEmpty;
}
else {
const close = this.type === '!'
? // !() must match something,but !(x) can match ''
'))' +
(this.isStart() && !dot && !allowDot ? startNoDot : '') +
star$1 +
')'
: this.type === '@'
? ')'
: this.type === '?'
? ')?'
: this.type === '+' && bodyDotAllowed
? ')'
: this.type === '*' && bodyDotAllowed
? `)?`
: `)${this.type}`;
final = start + body + close;
}
return [
final,
unescape(body),
(this.#hasMagic = !!this.#hasMagic),
this.#uflag,
];
}
#partsToRegExp(dot) {
return this.#parts
.map(p => {
// extglob ASTs should only contain parent ASTs
/* c8 ignore start */
if (typeof p === 'string') {
throw new Error('string type in extglob ast??');
}
/* c8 ignore stop */
// can ignore hasMagic, because extglobs are already always magic
const [re, _, _hasMagic, uflag] = p.toRegExpSource(dot);
this.#uflag = this.#uflag || uflag;
return re;
})
.filter(p => !(this.isStart() && this.isEnd()) || !!p)
.join('|');
}
static #parseGlob(glob, hasMagic, noEmpty = false) {
let escaping = false;
let re = '';
let uflag = false;
for (let i = 0; i < glob.length; i++) {
const c = glob.charAt(i);
if (escaping) {
escaping = false;
re += (reSpecials.has(c) ? '\\' : '') + c;
continue;
}
if (c === '\\') {
if (i === glob.length - 1) {
re += '\\\\';
}
else {
escaping = true;
}
continue;
}
if (c === '[') {
const [src, needUflag, consumed, magic] = parseClass(glob, i);
if (consumed) {
re += src;
uflag = uflag || needUflag;
i += consumed - 1;
hasMagic = hasMagic || magic;
continue;
}
}
if (c === '*') {
if (noEmpty && glob === '*')
re += starNoEmpty;
else
re += star$1;
hasMagic = true;
continue;
}
if (c === '?') {
re += qmark$1;
hasMagic = true;
continue;
}
re += regExpEscape$1(c);
}
return [re, unescape(glob), !!hasMagic, uflag];
}
}
/**
* Escape all magic characters in a glob pattern.
*
* If the {@link windowsPathsNoEscape | GlobOptions.windowsPathsNoEscape}
* option is used, then characters are escaped by wrapping in `[]`, because
* a magic character wrapped in a character class can only be satisfied by
* that exact character. In this mode, `\` is _not_ escaped, because it is
* not interpreted as a magic character, but instead as a path separator.
*/
const escape = (s, { windowsPathsNoEscape = false, } = {}) => {
// don't need to escape +@! because we escape the parens
// that make those magic, and escaping ! as [!] isn't valid,
// because [!]] is a valid glob class meaning not ']'.
return windowsPathsNoEscape
? s.replace(/[?*()[\]]/g, '[$&]')
: s.replace(/[?*()[\]\\]/g, '\\$&');
};
const minimatch = (p, pattern, options = {}) => {
assertValidPattern(pattern);
// shortcut: comments match nothing.
if (!options.nocomment && pattern.charAt(0) === '#') {
return false;
}
return new Minimatch(pattern, options).match(p);
};
// Optimized checking for the most common glob patterns.
const starDotExtRE = /^\*+([^+@!?\*\[\(]*)$/;
const starDotExtTest = (ext) => (f) => !f.startsWith('.') && f.endsWith(ext);
const starDotExtTestDot = (ext) => (f) => f.endsWith(ext);
const starDotExtTestNocase = (ext) => {
ext = ext.toLowerCase();
return (f) => !f.startsWith('.') && f.toLowerCase().endsWith(ext);
};
const starDotExtTestNocaseDot = (ext) => {
ext = ext.toLowerCase();
return (f) => f.toLowerCase().endsWith(ext);
};
const starDotStarRE = /^\*+\.\*+$/;
const starDotStarTest = (f) => !f.startsWith('.') && f.includes('.');
const starDotStarTestDot = (f) => f !== '.' && f !== '..' && f.includes('.');
const dotStarRE = /^\.\*+$/;
const dotStarTest = (f) => f !== '.' && f !== '..' && f.startsWith('.');
const starRE = /^\*+$/;
const starTest = (f) => f.length !== 0 && !f.startsWith('.');
const starTestDot = (f) => f.length !== 0 && f !== '.' && f !== '..';
const qmarksRE = /^\?+([^+@!?\*\[\(]*)?$/;
const qmarksTestNocase = ([$0, ext = '']) => {
const noext = qmarksTestNoExt([$0]);
if (!ext)
return noext;
ext = ext.toLowerCase();
return (f) => noext(f) && f.toLowerCase().endsWith(ext);
};
const qmarksTestNocaseDot = ([$0, ext = '']) => {
const noext = qmarksTestNoExtDot([$0]);
if (!ext)
return noext;
ext = ext.toLowerCase();
return (f) => noext(f) && f.toLowerCase().endsWith(ext);
};
const qmarksTestDot = ([$0, ext = '']) => {
const noext = qmarksTestNoExtDot([$0]);
return !ext ? noext : (f) => noext(f) && f.endsWith(ext);
};
const qmarksTest = ([$0, ext = '']) => {
const noext = qmarksTestNoExt([$0]);
return !ext ? noext : (f) => noext(f) && f.endsWith(ext);
};
const qmarksTestNoExt = ([$0]) => {
const len = $0.length;
return (f) => f.length === len && !f.startsWith('.');
};
const qmarksTestNoExtDot = ([$0]) => {
const len = $0.length;
return (f) => f.length === len && f !== '.' && f !== '..';
};
/* c8 ignore start */
const defaultPlatform = (typeof process === 'object' && process
? (typeof process.env === 'object' &&
process.env &&
process.env.__MINIMATCH_TESTING_PLATFORM__) ||
process.platform
: 'posix');
const path = {
win32: { sep: '\\' },
posix: { sep: '/' },
};
/* c8 ignore stop */
const sep = defaultPlatform === 'win32' ? path.win32.sep : path.posix.sep;
minimatch.sep = sep;
const GLOBSTAR = Symbol('globstar **');
minimatch.GLOBSTAR = GLOBSTAR;
// any single thing other than /
// don't need to escape / when using new RegExp()
const qmark = '[^/]';
// * => any number of characters
const star = qmark + '*?';
// ** when dots are allowed. Anything goes, except .. and .
// not (^ or / followed by one or two dots followed by $ or /),
// followed by anything, any number of times.
const twoStarDot = '(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?';
// not a ^ or / followed by a dot,
// followed by anything, any number of times.
const twoStarNoDot = '(?:(?!(?:\\/|^)\\.).)*?';
const filter = (pattern, options = {}) => (p) => minimatch(p, pattern, options);
minimatch.filter = filter;
const ext = (a, b = {}) => Object.assign({}, a, b);
const defaults = (def) => {
if (!def || typeof def !== 'object' || !Object.keys(def).length) {
return minimatch;
}
const orig = minimatch;
const m = (p, pattern, options = {}) => orig(p, pattern, ext(def, options));
return Object.assign(m, {
Minimatch: class Minimatch extends orig.Minimatch {
constructor(pattern, options = {}) {
super(pattern, ext(def, options));
}
static defaults(options) {
return orig.defaults(ext(def, options)).Minimatch;
}
},
AST: class AST extends orig.AST {
/* c8 ignore start */
constructor(type, parent, options = {}) {
super(type, parent, ext(def, options));
}
/* c8 ignore stop */
static fromGlob(pattern, options = {}) {
return orig.AST.fromGlob(pattern, ext(def, options));
}
},
unescape: (s, options = {}) => orig.unescape(s, ext(def, options)),
escape: (s, options = {}) => orig.escape(s, ext(def, options)),
filter: (pattern, options = {}) => orig.filter(pattern, ext(def, options)),
defaults: (options) => orig.defaults(ext(def, options)),
makeRe: (pattern, options = {}) => orig.makeRe(pattern, ext(def, options)),
braceExpand: (pattern, options = {}) => orig.braceExpand(pattern, ext(def, options)),
match: (list, pattern, options = {}) => orig.match(list, pattern, ext(def, options)),
sep: orig.sep,
GLOBSTAR: GLOBSTAR,
});
};
minimatch.defaults = defaults;
// Brace expansion:
// a{b,c}d -> abd acd
// a{b,}c -> abc ac
// a{0..3}d -> a0d a1d a2d a3d
// a{b,c{d,e}f}g -> abg acdfg acefg
// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg
//
// Invalid sets are not expanded.
// a{2..}b -> a{2..}b
// a{b}c -> a{b}c
const braceExpand = (pattern, options = {}) => {
assertValidPattern(pattern);
// Thanks to Yeting Li <https://github.com/yetingli> for
// improving this regexp to avoid a ReDOS vulnerability.
if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) {
// shortcut. no need to expand.
return [pattern];
}
return braceExpansion(pattern);
};
minimatch.braceExpand = braceExpand;
// parse a component of the expanded set.
// At this point, no pattern may contain "/" in it
// so we're going to return a 2d array, where each entry is the full
// pattern, split on '/', and then turned into a regular expression.
// A regexp is made at the end which joins each array with an
// escaped /, and another full one which joins each regexp with |.
//
// Following the lead of Bash 4.1, note that "**" only has special meaning
// when it is the *only* thing in a path portion. Otherwise, any series
// of * is equivalent to a single *. Globstar behavior is enabled by
// default, and can be disabled by setting options.noglobstar.
const makeRe = (pattern, options = {}) => new Minimatch(pattern, options).makeRe();
minimatch.makeRe = makeRe;
const match = (list, pattern, options = {}) => {
const mm = new Minimatch(pattern, options);
list = list.filter(f => mm.match(f));
if (mm.options.nonull && !list.length) {
list.push(pattern);
}
return list;
};
minimatch.match = match;
// replace stuff like \* with *
const globMagic = /[?*]|[+@!]\(.*?\)|\[|\]/;
const regExpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
class Minimatch {
options;
set;
pattern;
windowsPathsNoEscape;
nonegate;
negate;
comment;
empty;
preserveMultipleSlashes;
partial;
globSet;
globParts;
nocase;
isWindows;
platform;
windowsNoMagicRoot;
regexp;
constructor(pattern, options = {}) {
assertValidPattern(pattern);
options = options || {};
this.options = options;
this.pattern = pattern;
this.platform = options.platform || defaultPlatform;
this.isWindows = this.platform === 'win32';
this.windowsPathsNoEscape =
!!options.windowsPathsNoEscape || options.allowWindowsEscape === false;
if (this.windowsPathsNoEscape) {
this.pattern = this.pattern.replace(/\\/g, '/');
}
this.preserveMultipleSlashes = !!options.preserveMultipleSlashes;
this.regexp = null;
this.negate = false;
this.nonegate = !!options.nonegate;
this.comment = false;
this.empty = false;
this.partial = !!options.partial;
this.nocase = !!this.options.nocase;
this.windowsNoMagicRoot =
options.windowsNoMagicRoot !== undefined
? options.windowsNoMagicRoot
: !!(this.isWindows && this.nocase);
this.globSet = [];
this.globParts = [];
this.set = [];
// make the set of regexps etc.
this.make();
}
hasMagic() {
if (this.options.magicalBraces && this.set.length > 1) {
return true;
}
for (const pattern of this.set) {
for (const part of pattern) {
if (typeof part !== 'string')
return true;
}
}
return false;
}
debug(..._) { }
make() {
const pattern = this.pattern;
const options = this.options;
// empty patterns and comments match nothing.
if (!options.nocomment && pattern.charAt(0) === '#') {
this.comment = true;
return;
}
if (!pattern) {
this.empty = true;
return;
}
// step 1: figure out negation, etc.
this.parseNegate();
// step 2: expand braces
this.globSet = [...new Set(this.braceExpand())];
if (options.debug) {
this.debug = (...args) => console.error(...args);
}
this.debug(this.pattern, this.globSet);
// step 3: now we have a set, so turn each one into a series of
// path-portion matching patterns.
// These will be regexps, except in the case of "**", which is
// set to the GLOBSTAR object for globstar behavior,
// and will not contain any / characters
//
// First, we preprocess to make the glob pattern sets a bit simpler
// and deduped. There are some perf-killing patterns that can cause
// problems with a glob walk, but we can simplify them down a bit.
const rawGlobParts = this.globSet.map(s => this.slashSplit(s));
this.globParts = this.preprocess(rawGlobParts);
this.debug(this.pattern, this.globParts);
// glob --> regexps
let set = this.globParts.map((s, _, __) => {
if (this.isWindows && this.windowsNoMagicRoot) {
// check if it's a drive or unc path.
const isUNC = s[0] === '' &&
s[1] === '' &&
(s[2] === '?' || !globMagic.test(s[2])) &&
!globMagic.test(s[3]);
const isDrive = /^[a-z]:/i.test(s[0]);
if (isUNC) {
return [...s.slice(0, 4), ...s.slice(4).map(ss => this.parse(ss))];
}
else if (isDrive) {
return [s[0], ...s.slice(1).map(ss => this.parse(ss))];
}
}
return s.map(ss => this.parse(ss));
});
this.debug(this.pattern, set);
// filter out everything that didn't compile properly.
this.set = set.filter(s => s.indexOf(false) === -1);
// do not treat the ? in UNC paths as magic
if (this.isWindows) {
for (let i = 0; i < this.set.length; i++) {
const p = this.set[i];
if (p[0] === '' &&
p[1] === '' &&
this.globParts[i][2] === '?' &&
typeof p[3] === 'string' &&
/^[a-z]:$/i.test(p[3])) {
p[2] = '?';
}
}
}
this.debug(this.pattern, this.set);
}
// various transforms to equivalent pattern sets that are
// faster to process in a filesystem walk. The goal is to
// eliminate what we can, and push all ** patterns as far
// to the right as possible, even if it increases the number
// of patterns that we have to process.
preprocess(globParts) {
// if we're not in globstar mode, then turn all ** into *
if (this.options.noglobstar) {
for (let i = 0; i < globParts.length; i++) {
for (let j = 0; j < globParts[i].length; j++) {
if (globParts[i][j] === '**') {
globParts[i][j] = '*';
}
}
}
}
const { optimizationLevel = 1 } = this.options;
if (optimizationLevel >= 2) {
// aggressive optimization for the purpose of fs walking
globParts = this.firstPhasePreProcess(globParts);
globParts = this.secondPhasePreProcess(globParts);
}
else if (optimizationLevel >= 1) {
// just basic optimizations to remove some .. parts
globParts = this.levelOneOptimize(globParts);
}
else {
globParts = this.adjascentGlobstarOptimize(globParts);
}
return globParts;
}
// just get rid of adjascent ** portions
adjascentGlobstarOptimize(globParts) {
return globParts.map(parts => {
let gs = -1;
while (-1 !== (gs = parts.indexOf('**', gs + 1))) {
let i = gs;
while (parts[i + 1] === '**') {
i++;
}
if (i !== gs) {
parts.splice(gs, i - gs);
}
}
return parts;
});
}
// get rid of adjascent ** and resolve .. portions
levelOneOptimize(globParts) {
return globParts.map(parts => {
parts = parts.reduce((set, part) => {
const prev = set[set.length - 1];
if (part === '**' && prev === '**') {
return set;
}
if (part === '..') {
if (prev && prev !== '..' && prev !== '.' && prev !== '**') {
set.pop();
return set;
}
}
set.push(part);
return set;
}, []);
return parts.length === 0 ? [''] : parts;
});
}
levelTwoFileOptimize(parts) {
if (!Array.isArray(parts)) {
parts = this.slashSplit(parts);
}
let didSomething = false;
do {
didSomething = false;
// <pre>/<e>/<rest> -> <pre>/<rest>
if (!this.preserveMultipleSlashes) {
for (let i = 1; i < parts.length - 1; i++) {
const p = parts[i];
// don't squeeze out UNC patterns
if (i === 1 && p === '' && parts[0] === '')
continue;
if (p === '.' || p === '') {
didSomething = true;
parts.splice(i, 1);
i--;
}
}
if (parts[0] === '.' &&
parts.length === 2 &&
(parts[1] === '.' || parts[1] === '')) {
didSomething = true;
parts.pop();
}
}
// <pre>/<p>/../<rest> -> <pre>/<rest>
let dd = 0;
while (-1 !== (dd = parts.indexOf('..', dd + 1))) {
const p = parts[dd - 1];
if (p && p !== '.' && p !== '..' && p !== '**') {
didSomething = true;
parts.splice(dd - 1, 2);
dd -= 2;
}
}
} while (didSomething);
return parts.length === 0 ? [''] : parts;
}
// First phase: single-pattern processing
// <pre> is 1 or more portions
// <rest> is 1 or more portions
// <p> is any portion other than ., .., '', or **
// <e> is . or ''
//
// **/.. is *brutal* for filesystem walking performance, because
// it effectively resets the recursive walk each time it occurs,
// and ** cannot be reduced out by a .. pattern part like a regexp
// or most strings (other than .., ., and '') can be.
//
// <pre>/**/../<p>/<p>/<rest> -> {<pre>/../<p>/<p>/<rest>,<pre>/**/<p>/<p>/<rest>}
// <pre>/<e>/<rest> -> <pre>/<rest>
// <pre>/<p>/../<rest> -> <pre>/<rest>
// **/**/<rest> -> **/<rest>
//
// **/*/<rest> -> */**/<rest> <== not valid because ** doesn't follow
// this WOULD be allowed if ** did follow symlinks, or * didn't
firstPhasePreProcess(globParts) {
let didSomething = false;
do {
didSomething = false;
// <pre>/**/../<p>/<p>/<rest> -> {<pre>/../<p>/<p>/<rest>,<pre>/**/<p>/<p>/<rest>}
for (let parts of globParts) {
let gs = -1;
while (-1 !== (gs = parts.indexOf('**', gs + 1))) {
let gss = gs;
while (parts[gss + 1] === '**') {
// <pre>/**/**/<rest> -> <pre>/**/<rest>
gss++;
}
// eg, if gs is 2 and gss is 4, that means we have 3 **
// parts, and can remove 2 of them.
if (gss > gs) {
parts.splice(gs + 1, gss - gs);
}
let next = parts[gs + 1];
const p = parts[gs + 2];
const p2 = parts[gs + 3];
if (next !== '..')
continue;
if (!p ||
p === '.' ||
p === '..' ||
!p2 ||
p2 === '.' ||
p2 === '..') {
continue;
}
didSomething = true;
// edit parts in place, and push the new one
parts.splice(gs, 1);
const other = parts.slice(0);
other[gs] = '**';
globParts.push(other);
gs--;
}
// <pre>/<e>/<rest> -> <pre>/<rest>
if (!this.preserveMultipleSlashes) {
for (let i = 1; i < parts.length - 1; i++) {
const p = parts[i];
// don't squeeze out UNC patterns
if (i === 1 && p === '' && parts[0] === '')
continue;
if (p === '.' || p === '') {
didSomething = true;
parts.splice(i, 1);
i--;
}
}
if (parts[0] === '.' &&
parts.length === 2 &&
(parts[1] === '.' || parts[1] === '')) {
didSomething = true;
parts.pop();
}
}
// <pre>/<p>/../<rest> -> <pre>/<rest>
let dd = 0;
while (-1 !== (dd = parts.indexOf('..', dd + 1))) {
const p = parts[dd - 1];
if (p && p !== '.' && p !== '..' && p !== '**') {
didSomething = true;
const needDot = dd === 1 && parts[dd + 1] === '**';
const splin = needDot ? ['.'] : [];
parts.splice(dd - 1, 2, ...splin);
if (parts.length === 0)
parts.push('');
dd -= 2;
}
}
}
} while (didSomething);
return globParts;
}
// second phase: multi-pattern dedupes
// {<pre>/*/<rest>,<pre>/<p>/<rest>} -> <pre>/*/<rest>
// {<pre>/<rest>,<pre>/<rest>} -> <pre>/<rest>
// {<pre>/**/<rest>,<pre>/<rest>} -> <pre>/**/<rest>
//
// {<pre>/**/<rest>,<pre>/**/<p>/<rest>} -> <pre>/**/<rest>
// ^-- not valid because ** doens't follow symlinks
secondPhasePreProcess(globParts) {
for (let i = 0; i < globParts.length - 1; i++) {
for (let j = i + 1; j < globParts.length; j++) {
const matched = this.partsMatch(globParts[i], globParts[j], !this.preserveMultipleSlashes);
if (!matched)
continue;
globParts[i] = matched;
globParts[j] = [];
}
}
return globParts.filter(gs => gs.length);
}
partsMatch(a, b, emptyGSMatch = false) {
let ai = 0;
let bi = 0;
let result = [];
let which = '';
while (ai < a.length && bi < b.length) {
if (a[ai] === b[bi]) {
result.push(which === 'b' ? b[bi] : a[ai]);
ai++;
bi++;
}
else if (emptyGSMatch && a[ai] === '**' && b[bi] === a[ai + 1]) {
result.push(a[ai]);
ai++;
}
else if (emptyGSMatch && b[bi] === '**' && a[ai] === b[bi + 1]) {
result.push(b[bi]);
bi++;
}
else if (a[ai] === '*' &&
b[bi] &&
(this.options.dot || !b[bi].startsWith('.')) &&
b[bi] !== '**') {
if (which === 'b')
return false;
which = 'a';
result.push(a[ai]);
ai++;
bi++;
}
else if (b[bi] === '*' &&
a[ai] &&
(this.options.dot || !a[ai].startsWith('.')) &&
a[ai] !== '**') {
if (which === 'a')
return false;
which = 'b';
result.push(b[bi]);
ai++;
bi++;
}
else {
return false;
}
}
// if we fall out of the loop, it means they two are identical
// as long as their lengths match
return a.length === b.length && result;
}
parseNegate() {
if (this.nonegate)
return;
const pattern = this.pattern;
let negate = false;
let negateOffset = 0;
for (let i = 0; i < pattern.length && pattern.charAt(i) === '!'; i++) {
negate = !negate;
negateOffset++;
}
if (negateOffset)
this.pattern = pattern.slice(negateOffset);
this.negate = negate;
}
// set partial to true to test if, for example,
// "/a/b" matches the start of "/*/b/*/d"
// Partial means, if you run out of file before you run
// out of pattern, then that's fine, as long as all
// the parts match.
matchOne(file, pattern, partial = false) {
const options = this.options;
// UNC paths like //?/X:/... can match X:/... and vice versa
// Drive letters in absolute drive or unc paths are always compared
// case-insensitively.
if (this.isWindows) {
const fileDrive = typeof file[0] === 'string' && /^[a-z]:$/i.test(file[0]);
const fileUNC = !fileDrive &&
file[0] === '' &&
file[1] === '' &&
file[2] === '?' &&
/^[a-z]:$/i.test(file[3]);
const patternDrive = typeof pattern[0] === 'string' && /^[a-z]:$/i.test(pattern[0]);
const patternUNC = !patternDrive &&
pattern[0] === '' &&
pattern[1] === '' &&
pattern[2] === '?' &&
typeof pattern[3] === 'string' &&
/^[a-z]:$/i.test(pattern[3]);
const fdi = fileUNC ? 3 : fileDrive ? 0 : undefined;
const pdi = patternUNC ? 3 : patternDrive ? 0 : undefined;
if (typeof fdi === 'number' && typeof pdi === 'number') {
const [fd, pd] = [file[fdi], pattern[pdi]];
if (fd.toLowerCase() === pd.toLowerCase()) {
pattern[pdi] = fd;
if (pdi > fdi) {
pattern = pattern.slice(pdi);
}
else if (fdi > pdi) {
file = file.slice(fdi);
}
}
}
}
// resolve and reduce . and .. portions in the file as well.
// dont' need to do the second phase, because it's only one string[]
const { optimizationLevel = 1 } = this.options;
if (optimizationLevel >= 2) {
file = this.levelTwoFileOptimize(file);
}
this.debug('matchOne', this, { file, pattern });
this.debug('matchOne', file.length, pattern.length);
for (var fi = 0, pi = 0, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
this.debug('matchOne loop');
var p = pattern[pi];
var f = file[fi];
this.debug(pattern, p, f);
// should be impossible.
// some invalid regexp stuff in the set.
/* c8 ignore start */
if (p === false) {
return false;
}
/* c8 ignore stop */
if (p === GLOBSTAR) {
this.debug('GLOBSTAR', [pattern, p, f]);
// "**"
// a/**/b/**/c would match the following:
// a/b/x/y/z/c
// a/x/y/z/b/c
// a/b/x/b/x/c
// a/b/c
// To do this, take the rest of the pattern after
// the **, and see if it would match the file remainder.
// If so, return success.
// If not, the ** "swallows" a segment, and try again.
// This is recursively awful.
//
// a/**/b/**/c matching a/b/x/y/z/c
// - a matches a
// - doublestar
// - matchOne(b/x/y/z/c, b/**/c)
// - b matches b
// - doublestar
// - matchOne(x/y/z/c, c) -> no
// - matchOne(y/z/c, c) -> no
// - matchOne(z/c, c) -> no
// - matchOne(c, c) yes, hit
var fr = fi;
var pr = pi + 1;
if (pr === pl) {
this.debug('** at the end');
// a ** at the end will just swallow the rest.
// We have found a match.
// however, it will not swallow /.x, unless
// options.dot is set.
// . and .. are *never* matched by **, for explosively
// exponential reasons.
for (; fi < fl; fi++) {
if (file[fi] === '.' ||
file[fi] === '..' ||
(!options.dot && file[fi].charAt(0) === '.'))
return false;
}
return true;
}
// ok, let's see if we can swallow whatever we can.
while (fr < fl) {
var swallowee = file[fr];
this.debug('\nglobstar while', file, fr, pattern, pr, swallowee);
// XXX remove this slice. Just pass the start index.
if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) {
this.debug('globstar found match!', fr, fl, swallowee);
// found a match.
return true;
}
else {
// can't swallow "." or ".." ever.
// can only swallow ".foo" when explicitly asked.
if (swallowee === '.' ||
swallowee === '..' ||
(!options.dot && swallowee.charAt(0) === '.')) {
this.debug('dot detected!', file, fr, pattern, pr);
break;
}
// ** swallows a segment, and continue.
this.debug('globstar swallow a segment, and continue');
fr++;
}
}
// no match was found.
// However, in partial mode, we can't say this is necessarily over.
/* c8 ignore start */
if (partial) {
// ran out of file
this.debug('\n>>> no match, partial?', file, fr, pattern, pr);
if (fr === fl) {
return true;
}
}
/* c8 ignore stop */
return false;
}
// something other than **
// non-magic patterns just have to match exactly
// patterns with magic have been turned into regexps.
let hit;
if (typeof p === 'string') {
hit = f === p;
this.debug('string match', p, f, hit);
}
else {
hit = p.test(f);
this.debug('pattern match', p, f, hit);
}
if (!hit)
return false;
}
// Note: ending in / means that we'll get a final ""
// at the end of the pattern. This can only match a
// corresponding "" at the end of the file.
// If the file ends in /, then it can only match a
// a pattern that ends in /, unless the pattern just
// doesn't have any more for it. But, a/b/ should *not*
// match "a/b/*", even though "" matches against the
// [^/]*? pattern, except in partial mode, where it might
// simply not be reached yet.
// However, a/b/ should still satisfy a/*
// now either we fell off the end of the pattern, or we're done.
if (fi === fl && pi === pl) {
// ran out of pattern and filename at the same time.
// an exact hit!
return true;
}
else if (fi === fl) {
// ran out of file, but still had pattern left.
// this is ok if we're doing the match as part of
// a glob fs traversal.
return partial;
}
else if (pi === pl) {
// ran out of pattern, still have file left.
// this is only acceptable if we're on the very last
// empty segment of a file with a trailing slash.
// a/* should match a/b/
return fi === fl - 1 && file[fi] === '';
/* c8 ignore start */
}
else {
// should be unreachable.
throw new Error('wtf?');
}
/* c8 ignore stop */
}
braceExpand() {
return braceExpand(this.pattern, this.options);
}
parse(pattern) {
assertValidPattern(pattern);
const options = this.options;
// shortcuts
if (pattern === '**')
return GLOBSTAR;
if (pattern === '')
return '';
// far and away, the most common glob pattern parts are
// *, *.*, and *.<ext> Add a fast check method for those.
let m;
let fastTest = null;
if ((m = pattern.match(starRE))) {
fastTest = options.dot ? starTestDot : starTest;
}
else if ((m = pattern.match(starDotExtRE))) {
fastTest = (options.nocase
? options.dot
? starDotExtTestNocaseDot
: starDotExtTestNocase
: options.dot
? starDotExtTestDot
: starDotExtTest)(m[1]);
}
else if ((m = pattern.match(qmarksRE))) {
fastTest = (options.nocase
? options.dot
? qmarksTestNocaseDot
: qmarksTestNocase
: options.dot
? qmarksTestDot
: qmarksTest)(m);
}
else if ((m = pattern.match(starDotStarRE))) {
fastTest = options.dot ? starDotStarTestDot : starDotStarTest;
}
else if ((m = pattern.match(dotStarRE))) {
fastTest = dotStarTest;
}
const re = AST.fromGlob(pattern, this.options).toMMPattern();
return fastTest ? Object.assign(re, { test: fastTest }) : re;
}
makeRe() {
if (this.regexp || this.regexp === false)
return this.regexp;
// at this point, this.set is a 2d array of partial
// pattern strings, or "**".
//
// It's better to use .match(). This function shouldn't
// be used, really, but it's pretty convenient sometimes,
// when you just want to work with a regex.
const set = this.set;
if (!set.length) {
this.regexp = false;
return this.regexp;
}
const options = this.options;
const twoStar = options.noglobstar
? star
: options.dot
? twoStarDot
: twoStarNoDot;
const flags = new Set(options.nocase ? ['i'] : []);
// regexpify non-globstar patterns
// if ** is only item, then we just do one twoStar
// if ** is first, and there are more, prepend (\/|twoStar\/)? to next
// if ** is last, append (\/twoStar|) to previous
// if ** is in the middle, append (\/|\/twoStar\/) to previous
// then filter out GLOBSTAR symbols
let re = set
.map(pattern => {
const pp = pattern.map(p => {
if (p instanceof RegExp) {
for (const f of p.flags.split(''))
flags.add(f);
}
return typeof p === 'string'
? regExpEscape(p)
: p === GLOBSTAR
? GLOBSTAR
: p._src;
});
pp.forEach((p, i) => {
const next = pp[i + 1];
const prev = pp[i - 1];
if (p !== GLOBSTAR || prev === GLOBSTAR) {
return;
}
if (prev === undefined) {
if (next !== undefined && next !== GLOBSTAR) {
pp[i + 1] = '(?:\\/|' + twoStar + '\\/)?' + next;
}
else {
pp[i] = twoStar;
}
}
else if (next === undefined) {
pp[i - 1] = prev + '(?:\\/|' + twoStar + ')?';
}
else if (next !== GLOBSTAR) {
pp[i - 1] = prev + '(?:\\/|\\/' + twoStar + '\\/)' + next;
pp[i + 1] = GLOBSTAR;
}
});
return pp.filter(p => p !== GLOBSTAR).join('/');
})
.join('|');
// need to wrap in parens if we had more than one thing with |,
// otherwise only the first will be anchored to ^ and the last to $
const [open, close] = set.length > 1 ? ['(?:', ')'] : ['', ''];
// must match entire pattern
// ending in a * or ** will make it less strict.
re = '^' + open + re + close + '$';
// can match anything, as long as it's not this.
if (this.negate)
re = '^(?!' + re + ').+$';
try {
this.regexp = new RegExp(re, [...flags].join(''));
/* c8 ignore start */
}
catch (ex) {
// should be impossible
this.regexp = false;
}
/* c8 ignore stop */
return this.regexp;
}
slashSplit(p) {
// if p starts with // on windows, we preserve that
// so that UNC paths aren't broken. Otherwise, any number of
// / characters are coalesced into one, unless
// preserveMultipleSlashes is set to true.
if (this.preserveMultipleSlashes) {
return p.split('/');
}
else if (this.isWindows && /^\/\/[^\/]+/.test(p)) {
// add an extra '' for the one we lose
return ['', ...p.split(/\/+/)];
}
else {
return p.split(/\/+/);
}
}
match(f, partial = this.partial) {
this.debug('match', f, this.pattern);
// short-circuit in the case of busted things.
// comments, etc.
if (this.comment) {
return false;
}
if (this.empty) {
return f === '';
}
if (f === '/' && partial) {
return true;
}
const options = this.options;
// windows: need to use /, not \
if (this.isWindows) {
f = f.split('\\').join('/');
}
// treat the test path as a set of pathparts.
const ff = this.slashSplit(f);
this.debug(this.pattern, 'split', ff);
// just ONE of the pattern sets in this.set needs to match
// in order for it to be valid. If negating, then just one
// match means that we have failed.
// Either way, return on the first hit.
const set = this.set;
this.debug(this.pattern, 'set', set);
// Find the basename of the path by looking for the last non-empty segment
let filename = ff[ff.length - 1];
if (!filename) {
for (let i = ff.length - 2; !filename && i >= 0; i--) {
filename = ff[i];
}
}
for (let i = 0; i < set.length; i++) {
const pattern = set[i];
let file = ff;
if (options.matchBase && pattern.length === 1) {
file = [filename];
}
const hit = this.matchOne(file, pattern, partial);
if (hit) {
if (options.flipNegate) {
return true;
}
return !this.negate;
}
}
// didn't get any hits. this is success if it's a negative
// pattern, failure otherwise.
if (options.flipNegate) {
return false;
}
return this.negate;
}
static defaults(def) {
return minimatch.defaults(def).Minimatch;
}
}
/* c8 ignore stop */
minimatch.AST = AST;
minimatch.Minimatch = Minimatch;
minimatch.escape = escape;
minimatch.unescape = unescape;
const arrayUnion = (...arguments_) => [...new Set(arguments_.flat())];
function arrayDiffer(array, ...values) {
const rest = new Set([...values].flat());
return array.filter(element => !rest.has(element));
}
function multimatch(list, patterns, options = {}) {
list = [list].flat();
patterns = [patterns].flat();
if (list.length === 0 || patterns.length === 0) {
return [];
}
let result = [];
for (const item of list) {
for (let pattern of patterns) {
let process = arrayUnion;
if (pattern[0] === '!') {
pattern = pattern.slice(1);
process = arrayDiffer;
}
result = process(result, minimatch.match([item], pattern, options));
}
}
return result;
}
function difference(setA, setB) {
let _difference = new Set(setA);
for (let elem of setB) {
_difference.delete(elem);
}
return _difference;
}
class FileManager {
app;
data;
files;
ownFiles;
file_hashes;
requests_1_result;
added_media_set;
constructor(app, data, files, file_hashes, added_media) {
this.app = app;
this.data = data;
this.files = this.findFilesThatAreNotIgnored(files, data);
this.ownFiles = [];
this.file_hashes = file_hashes;
this.added_media_set = new Set(added_media);
}
getUrl(file) {
return "obsidian://open?vault=" + encodeURIComponent(this.data.vault_name) + String.raw `&file=` + encodeURIComponent(file.path);
}
findFilesThatAreNotIgnored(files, data) {
let ignoredFiles = [];
ignoredFiles = multimatch(files.map(file => file.path), data.ignored_file_globs);
let notIgnoredFiles = files.filter(file => !ignoredFiles.contains(file.path));
return notIgnoredFiles;
}
getFolderPathList(file) {
let result = [];
let abstractFile = file;
while (abstractFile && abstractFile.hasOwnProperty('parent')) {
result.push(abstractFile.parent);
abstractFile = abstractFile.parent;
}
result.pop(); // Removes top-level vault
return result;
}
getDefaultDeck(file, folder_path_list) {
let folder_decks = this.data.folder_decks;
for (let folder of folder_path_list) {
// Loops over them from innermost folder
if (folder_decks[folder.path]) {
return folder_decks[folder.path];
}
}
// If no decks specified
return this.data.template.deckName;
}
getDefaultTags(file, folder_path_list) {
let folder_tags = this.data.folder_tags;
let tags_list = [];
for (let folder of folder_path_list) {
// Loops over them from innermost folder
if (folder_tags[folder.path]) {
tags_list.push(...folder_tags[folder.path].split(" "));
}
}
tags_list.push(...this.data.template.tags);
return tags_list;
}
dataToFileData(file) {
const folder_path_list = this.getFolderPathList(file);
let result = JSON.parse(JSON.stringify(this.data));
//Lost regexp, so have to get them back
result.FROZEN_REGEXP = this.data.FROZEN_REGEXP;
result.DECK_REGEXP = this.data.DECK_REGEXP;
result.TAG_REGEXP = this.data.TAG_REGEXP;
result.NOTE_REGEXP = this.data.NOTE_REGEXP;
result.INLINE_REGEXP = this.data.INLINE_REGEXP;
result.EMPTY_REGEXP = this.data.EMPTY_REGEXP;
result.template.deckName = this.getDefaultDeck(file, folder_path_list);
result.template.tags = this.getDefaultTags(file, folder_path_list);
return result;
}
async genAllFiles() {
for (let file of this.files) {
const content = await this.app.vault.read(file);
const cache = this.app.metadataCache.getCache(file.path);
const file_data = this.dataToFileData(file);
this.ownFiles.push(new AllFile(content, file.path, this.data.add_file_link ? this.getUrl(file) : "", file_data, cache));
}
}
async initialiseFiles() {
await this.genAllFiles();
let files_changed = [];
let obfiles_changed = [];
for (let index in this.ownFiles) {
const i = parseInt(index);
let file = this.ownFiles[i];
if (!(this.file_hashes.hasOwnProperty(file.path) && file.getHash() === this.file_hashes[file.path])) {
//Indicates it's changed or new
console.info("Scanning ", file.path, "as it's changed or new.");
file.scanFile();
files_changed.push(file);
obfiles_changed.push(this.files[i]);
}
}
this.ownFiles = files_changed;
this.files = obfiles_changed;
}
async requests_1() {
let requests = [];
let temp = [];
console.info("Requesting addition of new deck into Anki...");
for (let file of this.ownFiles) {
temp.push(file.getCreateDecks());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting addition of notes into Anki...");
for (let file of this.ownFiles) {
temp.push(file.getAddNotes());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting card IDs of notes to be edited...");
for (let file of this.ownFiles) {
temp.push(file.getNoteInfo());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting tag list...");
requests.push(getTags());
console.info("Requesting update of fields of existing notes");
for (let file of this.ownFiles) {
temp.push(file.getUpdateFields());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting deletion of notes..");
for (let file of this.ownFiles) {
temp.push(file.getDeleteNotes());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting addition of media...");
for (let file of this.ownFiles) {
const mediaLinks = difference(file.formatter.detectedMedia, this.added_media_set);
for (let mediaLink of mediaLinks) {
console.log("Adding media file: ", mediaLink);
const dataFile = this.app.metadataCache.getFirstLinkpathDest(mediaLink, file.path);
if (!(dataFile)) {
console.warn("Couldn't locate media file ", mediaLink);
}
else {
// Located successfully, so treat as if we've added the media
this.added_media_set.add(mediaLink);
const realPath = this.app.vault.adapter.getFullPath(dataFile.path);
temp.push(storeMediaFileByPath(path$1.basename(mediaLink), realPath));
}
}
}
requests.push(multi(temp));
temp = [];
this.requests_1_result = (await invoke('multi', { actions: requests })).slice(1);
await this.parse_requests_1();
}
async parse_requests_1() {
const response = this.requests_1_result;
if (response[5].result.length >= 1 && response[5].result[0].error != null) {
new obsidian.Notice("Please update AnkiConnect! The way the script has added media files has changed.");
console.warn("Please update AnkiConnect! The way the script has added media files has changed.");
}
let note_ids_array_by_file;
try {
note_ids_array_by_file = parse(response[0]);
}
catch (error) {
console.error("Error: ", error);
note_ids_array_by_file = response[0].result;
}
const note_info_array_by_file = parse(response[1]);
const tag_list = parse(response[2]);
for (let index in note_ids_array_by_file) {
let i = parseInt(index);
let file = this.ownFiles[i];
let file_response;
try {
file_response = parse(note_ids_array_by_file[i]);
}
catch (error) {
console.error("Error: ", error);
file_response = note_ids_array_by_file[i].result;
}
file.note_ids = [];
for (let index in file_response) {
let i = parseInt(index);
let response = file_response[i];
try {
file.note_ids.push(parse(response));
}
catch (error) {
console.warn("Failed to add note ", file.all_notes_to_add[i], " in file", file.path, " due to error ", error);
file.note_ids.push(response.result);
}
}
}
for (let index in note_info_array_by_file) {
let i = parseInt(index);
let file = this.ownFiles[i];
const file_response = parse(note_info_array_by_file[i]);
let temp = [];
for (let note_response of file_response) {
temp.push(...note_response.cards);
}
file.card_ids = temp;
}
for (let index in this.ownFiles) {
let i = parseInt(index);
let ownFile = this.ownFiles[i];
let obFile = this.files[i];
ownFile.tags = tag_list;
ownFile.writeIDs();
ownFile.removeEmpties();
if (ownFile.file !== ownFile.original_file) {
await this.app.vault.modify(obFile, ownFile.file);
}
}
await this.requests_2();
}
getHashes() {
let result = {};
for (let file of this.ownFiles) {
result[file.path] = file.getHash();
}
return result;
}
async requests_2() {
let requests = [];
let temp = [];
console.info("Requesting cards to be moved to target deck...");
for (let file of this.ownFiles) {
temp.push(file.getChangeDecks());
}
requests.push(multi(temp));
temp = [];
console.info("Requesting tags to be replaced...");
for (let file of this.ownFiles) {
let rem = file.getClearTags();
if (rem.params.notes.length) {
temp.push(rem);
}
}
requests.push(multi(temp));
temp = [];
for (let file of this.ownFiles) {
temp.push(file.getAddTags());
}
requests.push(multi(temp));
temp = [];
await invoke('multi', { actions: requests });
console.info("All done!");
}
}
class MyPlugin extends obsidian.Plugin {
settings;
note_types;
fields_dict;
added_media;
file_hashes;
async getDefaultSettings() {
let settings = {
CUSTOM_REGEXPS: {},
FILE_LINK_FIELDS: {},
CONTEXT_FIELDS: {},
FOLDER_DECKS: {},
FOLDER_TAGS: {},
Syntax: {
"Begin Note": "START",
"End Note": "END",
"Begin Inline Note": "STARTI",
"End Inline Note": "ENDI",
"Target Deck Line": "TARGET DECK",
"File Tags Line": "FILE TAGS",
"Delete Note Line": "DELETE",
"Frozen Fields Line": "FROZEN"
},
Defaults: {
"Scan Directory": "",
"Tag": "Obsidian_to_Anki",
"Deck": "Default",
"Scheduling Interval": 0,
"Add File Link": false,
"Add Context": false,
"CurlyCloze": false,
"CurlyCloze - Highlights to Clozes": false,
"ID Comments": true,
"Add Obsidian Tags": false,
},
IGNORED_FILE_GLOBS: DEFAULT_IGNORED_FILE_GLOBS,
};
/*Making settings from scratch, so need note types*/
this.note_types = await invoke('modelNames');
this.fields_dict = await this.generateFieldsDict();
for (let note_type of this.note_types) {
settings["CUSTOM_REGEXPS"][note_type] = "";
const field_names = await invoke('modelFieldNames', { modelName: note_type });
this.fields_dict[note_type] = field_names;
settings["FILE_LINK_FIELDS"][note_type] = field_names[0];
}
return settings;
}
async generateFieldsDict() {
let fields_dict = {};
for (let note_type of this.note_types) {
const field_names = await invoke('modelFieldNames', { modelName: note_type });
fields_dict[note_type] = field_names;
}
return fields_dict;
}
async saveDefault() {
const default_sets = await this.getDefaultSettings();
this.saveData({
settings: default_sets,
"Added Media": [],
"File Hashes": {},
fields_dict: {}
});
}
async loadSettings() {
let current_data = await this.loadData();
if (current_data == null || Object.keys(current_data).length != 4) {
new obsidian.Notice("Need to connect to Anki generate default settings...");
const default_sets = await this.getDefaultSettings();
this.saveData({
settings: default_sets,
"Added Media": [],
"File Hashes": {},
fields_dict: {}
});
new obsidian.Notice("Default settings successfully generated!");
return default_sets;
}
else {
return current_data.settings;
}
}
async loadAddedMedia() {
let current_data = await this.loadData();
if (current_data == null) {
await this.saveDefault();
return [];
}
else {
return current_data["Added Media"];
}
}
async loadFileHashes() {
let current_data = await this.loadData();
if (current_data == null) {
await this.saveDefault();
return {};
}
else {
return current_data["File Hashes"];
}
}
async loadFieldsDict() {
let current_data = await this.loadData();
if (current_data == null) {
await this.saveDefault();
const fields_dict = await this.generateFieldsDict();
return fields_dict;
}
return current_data.fields_dict;
}
async saveAllData() {
this.saveData({
settings: this.settings,
"Added Media": this.added_media,
"File Hashes": this.file_hashes,
fields_dict: this.fields_dict
});
}
regenerateSettingsRegexps() {
let regexp_section = this.settings["CUSTOM_REGEXPS"];
// For new note types
for (let note_type of this.note_types) {
this.settings["CUSTOM_REGEXPS"][note_type] = regexp_section.hasOwnProperty(note_type) ? regexp_section[note_type] : "";
}
// Removing old note types
for (let note_type of Object.keys(this.settings["CUSTOM_REGEXPS"])) {
if (!this.note_types.includes(note_type)) {
delete this.settings["CUSTOM_REGEXPS"][note_type];
}
}
}
/**
* Recursively traverse a TFolder and return all TFiles.
* @param tfolder - The TFolder to start the traversal from.
* @returns An array of TFiles found within the folder and its subfolders.
*/
getAllTFilesInFolder(tfolder) {
const allTFiles = [];
// Check if the provided object is a TFolder
if (!(tfolder instanceof obsidian.TFolder)) {
return allTFiles;
}
// Iterate through the contents of the folder
tfolder.children.forEach((child) => {
// If it's a TFile, add it to the result
if (child instanceof obsidian.TFile) {
allTFiles.push(child);
}
else if (child instanceof obsidian.TFolder) {
// If it's a TFolder, recursively call the function on it
const filesInSubfolder = this.getAllTFilesInFolder(child);
allTFiles.push(...filesInSubfolder);
}
// Ignore other types of files or objects
});
return allTFiles;
}
async scanVault() {
new obsidian.Notice('Scanning vault, check console for details...');
console.info("Checking connection to Anki...");
try {
await invoke('modelNames');
}
catch (e) {
new obsidian.Notice("Error, couldn't connect to Anki! Check console for error message.");
return;
}
new obsidian.Notice("Successfully connected to Anki! This could take a few minutes - please don't close Anki until the plugin is finished");
const data = await settingToData(this.app, this.settings, this.fields_dict);
const scanDir = this.app.vault.getAbstractFileByPath(this.settings.Defaults["Scan Directory"]);
let manager = null;
if (scanDir !== null) {
let markdownFiles = [];
if (scanDir instanceof obsidian.TFolder) {
console.info("Using custom scan directory: " + scanDir.path);
markdownFiles = this.getAllTFilesInFolder(scanDir);
}
else {
new obsidian.Notice("Error: incorrect path for scan directory " + this.settings.Defaults["Scan Directory"]);
return;
}
manager = new FileManager(this.app, data, markdownFiles, this.file_hashes, this.added_media);
}
else {
manager = new FileManager(this.app, data, this.app.vault.getMarkdownFiles(), this.file_hashes, this.added_media);
}
await manager.initialiseFiles();
await manager.requests_1();
this.added_media = Array.from(manager.added_media_set);
const hashes = manager.getHashes();
for (let key in hashes) {
this.file_hashes[key] = hashes[key];
}
new obsidian.Notice("All done! Saving file hashes and added media now...");
this.saveAllData();
}
async onload() {
console.log('loading Obsidian_to_Anki...');
obsidian.addIcon('anki', ANKI_ICON);
try {
this.settings = await this.loadSettings();
}
catch (e) {
new obsidian.Notice("Couldn't connect to Anki! Check console for error message.");
return;
}
this.note_types = Object.keys(this.settings["CUSTOM_REGEXPS"]);
this.fields_dict = await this.loadFieldsDict();
if (Object.keys(this.fields_dict).length == 0) {
new obsidian.Notice('Need to connect to Anki to generate fields dictionary...');
try {
this.fields_dict = await this.generateFieldsDict();
new obsidian.Notice("Fields dictionary successfully generated!");
}
catch (e) {
new obsidian.Notice("Couldn't connect to Anki! Check console for error message.");
return;
}
}
this.added_media = await this.loadAddedMedia();
this.file_hashes = await this.loadFileHashes();
this.addSettingTab(new SettingsTab(this.app, this));
this.addRibbonIcon('anki', 'Obsidian_to_Anki - Scan Vault', async () => {
await this.scanVault();
});
this.addCommand({
id: 'anki-scan-vault',
name: 'Scan Vault',
callback: async () => {
await this.scanVault();
}
});
}
async onunload() {
console.log("Saving settings for Obsidian_to_Anki...");
this.saveAllData();
console.log('unloading Obsidian_to_Anki...');
}
}
module.exports = MyPlugin;