12#ifndef ARK_REPL_CONSOLESTYLE_HPP
13#define ARK_REPL_CONSOLESTYLE_HPP
23 "if",
"let",
"mut",
"set",
24 "fun",
"while",
"begin",
"import",
27 "len",
"empty?",
"tail",
"head",
28 "nil?",
"assert",
"toNumber",
29 "toString",
"and",
"or",
"mod",
30 "type",
"hasField",
"not",
32 "true",
"false",
"nil",
"math:pi",
33 "math:e",
"math:tau",
"math:Inf",
"math:NaN",
36 "append",
"concat",
"list",
"list:reverse",
37 "list:find",
"list:slice",
"list:sort",
38 "list:fill",
"list:setAt",
40 "print",
"puts",
"input",
"io:writeFile",
41 "io:readFile",
"io:fileExists?",
"io:listFiles",
"io:dir?",
42 "io:makeDir",
"io:removeFiles",
46 "sys:exec",
"sys:sleep",
48 "str:format",
"str:find",
"str:removeAt",
50 "math:exp",
"math:ln",
"math:ceil",
"math:floor",
51 "math:round",
"math:NaN?",
"Inf?",
"math:cos",
52 "math:sin",
"math:tan",
"math:arccos",
"math:arcsin",
60 {
"if", Replxx::Color::BRIGHTRED },
61 {
"let", Replxx::Color::BRIGHTRED },
62 {
"mut", Replxx::Color::BRIGHTRED },
63 {
"set", Replxx::Color::BRIGHTRED },
64 {
"fun", Replxx::Color::BRIGHTRED },
65 {
"while", Replxx::Color::BRIGHTRED },
66 {
"begin", Replxx::Color::BRIGHTRED },
67 {
"import", Replxx::Color::BRIGHTRED },
68 {
"quote", Replxx::Color::BRIGHTRED },
69 {
"del", Replxx::Color::BRIGHTRED },
71 {
"\\\"", Replxx::Color::BRIGHTBLUE },
72 {
"\\-", Replxx::Color::BRIGHTBLUE },
73 {
"\\+", Replxx::Color::BRIGHTBLUE },
74 {
"\\=", Replxx::Color::BRIGHTBLUE },
75 {
"\\/", Replxx::Color::BRIGHTBLUE },
76 {
"\\*", Replxx::Color::BRIGHTBLUE },
77 {
"\\<", Replxx::Color::BRIGHTBLUE },
78 {
"\\>", Replxx::Color::BRIGHTBLUE },
79 {
"\\!", Replxx::Color::BRIGHTBLUE },
80 {
"\\[", Replxx::Color::BRIGHTBLUE },
81 {
"\\]", Replxx::Color::BRIGHTBLUE },
82 {
"@", Replxx::Color::BRIGHTBLUE },
83 {
"len", Replxx::Color::BRIGHTBLUE },
84 {
"empty?", Replxx::Color::BRIGHTBLUE },
85 {
"tail", Replxx::Color::BRIGHTBLUE },
86 {
"head", Replxx::Color::BRIGHTBLUE },
87 {
"nil?", Replxx::Color::BRIGHTBLUE },
88 {
"assert", Replxx::Color::BRIGHTBLUE },
89 {
"toNumber", Replxx::Color::BRIGHTBLUE },
90 {
"toString", Replxx::Color::BRIGHTBLUE },
91 {
"and", Replxx::Color::BRIGHTBLUE },
92 {
"or ", Replxx::Color::BRIGHTBLUE },
93 {
"mod", Replxx::Color::BRIGHTBLUE },
94 {
"type", Replxx::Color::BRIGHTBLUE },
95 {
"hasField", Replxx::Color::BRIGHTBLUE },
96 {
"not", Replxx::Color::BRIGHTBLUE },
98 {
"true", Replxx::Color::RED },
99 {
"false", Replxx::Color::RED },
100 {
"nil", Replxx::Color::RED },
101 {
"math:pi", Replxx::Color::BLUE },
102 {
"math:e", Replxx::Color::BLUE },
103 {
"math:tau", Replxx::Color::BLUE },
104 {
"math:Inf", Replxx::Color::BLUE },
105 {
"math:NaN", Replxx::Color::BLUE },
108 {
"append", Replxx::Color::BRIGHTGREEN },
109 {
"concat", Replxx::Color::BRIGHTGREEN },
110 {
"pop", Replxx::Color::BRIGHTGREEN },
111 {
"append!", Replxx::Color::BRIGHTGREEN },
112 {
"concat!", Replxx::Color::BRIGHTGREEN },
113 {
"pop!", Replxx::Color::BRIGHTGREEN },
114 {
"list", Replxx::Color::BRIGHTGREEN },
115 {
"list:reverse", Replxx::Color::BRIGHTGREEN },
116 {
"list:find", Replxx::Color::BRIGHTGREEN },
117 {
"list:slice", Replxx::Color::BRIGHTGREEN },
118 {
"list:sort", Replxx::Color::BRIGHTGREEN },
119 {
"list:fill", Replxx::Color::BRIGHTGREEN },
120 {
"list:setAt", Replxx::Color::BRIGHTGREEN },
122 {
"print", Replxx::Color::GREEN },
123 {
"puts", Replxx::Color::GREEN },
124 {
"input", Replxx::Color::GREEN },
125 {
"io:writeFile", Replxx::Color::GREEN },
126 {
"io:readFile", Replxx::Color::GREEN },
127 {
"io:fileExists?", Replxx::Color::GREEN },
128 {
"io:listFiles", Replxx::Color::GREEN },
129 {
"io:dir?", Replxx::Color::GREEN },
130 {
"io:makeDir", Replxx::Color::GREEN },
131 {
"io:removeFiles", Replxx::Color::GREEN },
133 {
"time", Replxx::Color::GREEN },
135 {
"sys:exec", Replxx::Color::GREEN },
136 {
"sys:sleep", Replxx::Color::GREEN },
137 {
"sys:exit", Replxx::Color::GREEN },
139 {
"str:format", Replxx::Color::BRIGHTGREEN },
140 {
"str:find", Replxx::Color::BRIGHTGREEN },
141 {
"str:removeAt", Replxx::Color::BRIGHTGREEN },
142 {
"str:ord", Replxx::Color::BRIGHTGREEN },
143 {
"str:chr", Replxx::Color::BRIGHTGREEN },
145 {
"math:exp", Replxx::Color::BRIGHTCYAN },
146 {
"math:ln", Replxx::Color::BRIGHTCYAN },
147 {
"math:ceil", Replxx::Color::BRIGHTCYAN },
148 {
"math:floor", Replxx::Color::BRIGHTCYAN },
149 {
"math:round", Replxx::Color::BRIGHTCYAN },
150 {
"math:NaN?", Replxx::Color::BRIGHTCYAN },
151 {
"math:Inf?", Replxx::Color::BRIGHTCYAN },
152 {
"math:cos", Replxx::Color::BRIGHTCYAN },
153 {
"math:sin", Replxx::Color::BRIGHTCYAN },
154 {
"math:tan", Replxx::Color::BRIGHTCYAN },
155 {
"math:arccos", Replxx::Color::BRIGHTCYAN },
156 {
"math:arcsin", Replxx::Color::BRIGHTCYAN },
157 {
"math:arctan", Replxx::Color::BRIGHTCYAN },
158 {
"math:cosh", Replxx::Color::BRIGHTCYAN },
159 {
"math:sinh", Replxx::Color::BRIGHTCYAN },
160 {
"math:tanh", Replxx::Color::BRIGHTCYAN },
161 {
"math:acosh", Replxx::Color::BRIGHTCYAN },
162 {
"math:asinh", Replxx::Color::BRIGHTCYAN },
163 {
"math:atanh", Replxx::Color::BRIGHTCYAN },
165 {
"[\\-|+]{0,1}[0-9]+(\\.[0-9]+)?", Replxx::Color::YELLOW },
167 {
"\".*?\"", Replxx::Color::BRIGHTGREEN },
169 {
"quit", Replxx::Color::BRIGHTMAGENTA }
const std::vector< std::pair< std::string, Replxx::Color > > ColorsRegexDict
const std::vector< std::string > KeywordsDict