sassc 0.0.10 → 0.0.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/ext/libsass/.gitignore +6 -0
- data/ext/libsass/.travis.yml +5 -1
- data/ext/libsass/Makefile +12 -3
- data/ext/libsass/Makefile.am +16 -28
- data/ext/libsass/Readme.md +1 -0
- data/ext/libsass/appveyor.yml +1 -2
- data/ext/libsass/ast.cpp +9 -0
- data/ext/libsass/ast.hpp +152 -55
- data/ext/libsass/ast_factory.hpp +2 -0
- data/ext/libsass/ast_fwd_decl.hpp +1 -0
- data/ext/libsass/backtrace.hpp +2 -2
- data/ext/libsass/bind.cpp +15 -13
- data/ext/libsass/configure.ac +17 -5
- data/ext/libsass/constants.cpp +22 -2
- data/ext/libsass/constants.hpp +21 -2
- data/ext/libsass/context.cpp +79 -57
- data/ext/libsass/context.hpp +23 -9
- data/ext/libsass/contextualize.cpp +2 -28
- data/ext/libsass/contextualize.hpp +6 -10
- data/ext/libsass/contextualize_eval.cpp +93 -0
- data/ext/libsass/contextualize_eval.hpp +44 -0
- data/ext/libsass/contrib/plugin.cpp +57 -0
- data/ext/libsass/cssize.cpp +3 -1
- data/ext/libsass/debugger.hpp +242 -83
- data/ext/libsass/emitter.cpp +1 -1
- data/ext/libsass/emitter.hpp +1 -1
- data/ext/libsass/environment.hpp +109 -25
- data/ext/libsass/error_handling.cpp +3 -3
- data/ext/libsass/error_handling.hpp +0 -1
- data/ext/libsass/eval.cpp +145 -61
- data/ext/libsass/eval.hpp +9 -1
- data/ext/libsass/expand.cpp +134 -60
- data/ext/libsass/expand.hpp +5 -2
- data/ext/libsass/extend.cpp +7 -5
- data/ext/libsass/file.cpp +176 -123
- data/ext/libsass/file.hpp +44 -7
- data/ext/libsass/functions.cpp +36 -17
- data/ext/libsass/functions.hpp +2 -2
- data/ext/libsass/inspect.cpp +23 -14
- data/ext/libsass/inspect.hpp +1 -0
- data/ext/libsass/json.cpp +132 -135
- data/ext/libsass/lexer.cpp +133 -0
- data/ext/libsass/lexer.hpp +239 -0
- data/ext/libsass/listize.cpp +83 -0
- data/ext/libsass/listize.hpp +41 -0
- data/ext/libsass/operation.hpp +2 -0
- data/ext/libsass/output.cpp +5 -6
- data/ext/libsass/parser.cpp +426 -388
- data/ext/libsass/parser.hpp +97 -109
- data/ext/libsass/plugins.cpp +15 -2
- data/ext/libsass/plugins.hpp +6 -4
- data/ext/libsass/position.cpp +52 -17
- data/ext/libsass/position.hpp +19 -17
- data/ext/libsass/prelexer.cpp +202 -235
- data/ext/libsass/prelexer.hpp +73 -333
- data/ext/libsass/sass.cpp +21 -11
- data/ext/libsass/sass.h +6 -6
- data/ext/libsass/sass_context.cpp +167 -81
- data/ext/libsass/sass_context.h +26 -6
- data/ext/libsass/sass_functions.cpp +49 -40
- data/ext/libsass/sass_functions.h +55 -43
- data/ext/libsass/sass_interface.cpp +9 -8
- data/ext/libsass/sass_interface.h +3 -3
- data/ext/libsass/sass_version.h +8 -0
- data/ext/libsass/sass_version.h.in +8 -0
- data/ext/libsass/script/ci-build-libsass +3 -3
- data/ext/libsass/script/ci-report-coverage +2 -1
- data/ext/libsass/source_map.cpp +2 -2
- data/ext/libsass/util.cpp +60 -11
- data/ext/libsass/util.hpp +6 -1
- data/ext/libsass/win/libsass.filters +12 -0
- data/ext/libsass/win/libsass.vcxproj +10 -0
- data/lib/sassc.rb +3 -1
- data/lib/sassc/cache_stores/base.rb +2 -0
- data/lib/sassc/dependency.rb +3 -1
- data/lib/sassc/engine.rb +31 -16
- data/lib/sassc/error.rb +3 -2
- data/lib/sassc/functions_handler.rb +54 -0
- data/lib/sassc/import_handler.rb +41 -0
- data/lib/sassc/importer.rb +4 -31
- data/lib/sassc/native.rb +1 -1
- data/lib/sassc/native/native_context_api.rb +3 -2
- data/lib/sassc/script.rb +0 -51
- data/lib/sassc/version.rb +1 -1
- data/sassc.gemspec +1 -0
- data/test/custom_importer_test.rb +72 -69
- data/test/engine_test.rb +53 -54
- data/test/functions_test.rb +40 -39
- data/test/native_test.rb +145 -149
- data/test/output_style_test.rb +98 -0
- data/test/test_helper.rb +21 -7
- metadata +28 -2
data/ext/libsass/prelexer.hpp
CHANGED
@@ -2,77 +2,42 @@
|
|
2
2
|
#define SASS_PRELEXER_H
|
3
3
|
|
4
4
|
#include <cstring>
|
5
|
+
#include "lexer.hpp"
|
5
6
|
|
6
7
|
namespace Sass {
|
8
|
+
// using namespace Lexer;
|
7
9
|
namespace Prelexer {
|
8
10
|
|
9
|
-
|
10
|
-
|
11
|
+
//####################################
|
12
|
+
// KEYWORD "REGEX" MATCHERS
|
13
|
+
//####################################
|
11
14
|
|
12
|
-
// Match
|
13
|
-
|
14
|
-
const char*
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
const char*
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
const char*
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
template <const char* char_class>
|
39
|
-
const char* class_char(const char* src) {
|
40
|
-
const char* cc = char_class;
|
41
|
-
while (*cc && *src != *cc) ++cc;
|
42
|
-
return *cc ? src + 1 : 0;
|
43
|
-
}
|
44
|
-
|
45
|
-
// Match a sequence of characters that all satisfy the supplied ctype predicate.
|
46
|
-
template <ctype_predicate pred>
|
47
|
-
const char* class_chars(const char* src) {
|
48
|
-
const char* p = src;
|
49
|
-
while (pred(*p)) ++p;
|
50
|
-
return p == src ? 0 : p;
|
51
|
-
}
|
52
|
-
|
53
|
-
// Match a sequence of characters that are all members of the supplied class.
|
54
|
-
template <const char* char_class>
|
55
|
-
const char* class_chars(const char* src) {
|
56
|
-
const char* p = src;
|
57
|
-
while (class_char<char_class>(p)) ++p;
|
58
|
-
return p == src ? 0 : p;
|
59
|
-
}
|
60
|
-
|
61
|
-
// Match a sequence of characters up to the next newline.
|
62
|
-
template <char end>
|
63
|
-
const char* until(const char* src) {
|
64
|
-
if (*src == '\n' && exactly<end>(src)) return 0;
|
65
|
-
while (*src && *src != '\n' && !exactly<end>(src)) ++src;
|
66
|
-
return ++src;
|
67
|
-
}
|
68
|
-
|
69
|
-
// Match a sequence of characters up to the next newline.
|
70
|
-
template <const char* prefix>
|
71
|
-
const char* to_endl(const char* src) {
|
72
|
-
if (!(src = exactly<prefix>(src))) return 0;
|
73
|
-
while (*src && *src != '\n') ++src;
|
74
|
-
return src;
|
75
|
-
}
|
15
|
+
// Match Sass boolean keywords.
|
16
|
+
const char* kwd_true(const char* src);
|
17
|
+
const char* kwd_false(const char* src);
|
18
|
+
const char* kwd_and(const char* src);
|
19
|
+
const char* kwd_or(const char* src);
|
20
|
+
const char* kwd_not(const char* src);
|
21
|
+
const char* kwd_eq(const char* src);
|
22
|
+
const char* kwd_neq(const char* src);
|
23
|
+
const char* kwd_gt(const char* src);
|
24
|
+
const char* kwd_gte(const char* src);
|
25
|
+
const char* kwd_lt(const char* src);
|
26
|
+
const char* kwd_lte(const char* src);
|
27
|
+
|
28
|
+
// Match standard control chars
|
29
|
+
const char* kwd_at(const char* src);
|
30
|
+
const char* kwd_dot(const char* src);
|
31
|
+
const char* kwd_comma(const char* src);
|
32
|
+
const char* kwd_colon(const char* src);
|
33
|
+
const char* kwd_slash(const char* src);
|
34
|
+
const char* kwd_star(const char* src);
|
35
|
+
const char* kwd_plus(const char* src);
|
36
|
+
const char* kwd_minus(const char* src);
|
37
|
+
|
38
|
+
//####################################
|
39
|
+
// SPECIAL "REGEX" CONSTRUCTS
|
40
|
+
//####################################
|
76
41
|
|
77
42
|
// Match a sequence of characters delimited by the supplied chars.
|
78
43
|
template <char beg, char end, bool esc>
|
@@ -165,28 +130,6 @@ namespace Sass {
|
|
165
130
|
}
|
166
131
|
}
|
167
132
|
|
168
|
-
// Match any single character.
|
169
|
-
const char* any_char(const char* src);
|
170
|
-
// Match any single character except the supplied one.
|
171
|
-
template <char c>
|
172
|
-
const char* any_char_except(const char* src) {
|
173
|
-
return (*src && *src != c) ? src+1 : 0;
|
174
|
-
}
|
175
|
-
// Match word boundary (look ahead)
|
176
|
-
const char* word_boundary(const char* src);
|
177
|
-
|
178
|
-
// Matches zero characters (always succeeds without consuming input).
|
179
|
-
// const char* epsilon(const char*);
|
180
|
-
|
181
|
-
// Matches the empty string.
|
182
|
-
// const char* empty(const char*);
|
183
|
-
|
184
|
-
// Succeeds of the supplied matcher fails, and vice versa.
|
185
|
-
template <prelexer mx>
|
186
|
-
const char* negate(const char* src) {
|
187
|
-
return mx(src) ? 0 : src;
|
188
|
-
}
|
189
|
-
|
190
133
|
// Tries to match a certain number of times (between the supplied interval).
|
191
134
|
template<prelexer mx, size_t lo, size_t hi>
|
192
135
|
const char* between(const char* src) {
|
@@ -202,185 +145,6 @@ namespace Sass {
|
|
202
145
|
return src;
|
203
146
|
}
|
204
147
|
|
205
|
-
// Tries the matchers in sequence and returns the first match (or none)
|
206
|
-
template <prelexer mx1, prelexer mx2>
|
207
|
-
const char* alternatives(const char* src) {
|
208
|
-
const char* rslt;
|
209
|
-
(rslt = mx1(src)) || (rslt = mx2(src));
|
210
|
-
return rslt;
|
211
|
-
}
|
212
|
-
|
213
|
-
// Same as above, but with 3 arguments.
|
214
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3>
|
215
|
-
const char* alternatives(const char* src) {
|
216
|
-
const char* rslt;
|
217
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) || (rslt = mx3(src));
|
218
|
-
return rslt;
|
219
|
-
}
|
220
|
-
|
221
|
-
// Same as above, but with 4 arguments.
|
222
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3, prelexer mx4>
|
223
|
-
const char* alternatives(const char* src) {
|
224
|
-
const char* rslt;
|
225
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) ||
|
226
|
-
(rslt = mx3(src)) || (rslt = mx4(src));
|
227
|
-
return rslt;
|
228
|
-
}
|
229
|
-
|
230
|
-
// Same as above, but with 5 arguments.
|
231
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3,
|
232
|
-
prelexer mx4, prelexer mx5>
|
233
|
-
const char* alternatives(const char* src) {
|
234
|
-
const char* rslt;
|
235
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) || (rslt = mx3(src)) ||
|
236
|
-
(rslt = mx4(src)) || (rslt = mx5(src));
|
237
|
-
return rslt;
|
238
|
-
}
|
239
|
-
|
240
|
-
// Same as above, but with 6 arguments.
|
241
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3,
|
242
|
-
prelexer mx4, prelexer mx5, prelexer mx6>
|
243
|
-
const char* alternatives(const char* src) {
|
244
|
-
const char* rslt;
|
245
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) || (rslt = mx3(src)) ||
|
246
|
-
(rslt = mx4(src)) || (rslt = mx5(src)) || (rslt = mx6(src));
|
247
|
-
return rslt;
|
248
|
-
}
|
249
|
-
|
250
|
-
// Same as above, but with 7 arguments.
|
251
|
-
template <prelexer mx1, prelexer mx2,
|
252
|
-
prelexer mx3, prelexer mx4,
|
253
|
-
prelexer mx5, prelexer mx6,
|
254
|
-
prelexer mx7>
|
255
|
-
const char* alternatives(const char* src) {
|
256
|
-
const char* rslt;
|
257
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) ||
|
258
|
-
(rslt = mx3(src)) || (rslt = mx4(src)) ||
|
259
|
-
(rslt = mx5(src)) || (rslt = mx6(src)) ||
|
260
|
-
(rslt = mx7(src));
|
261
|
-
return rslt;
|
262
|
-
}
|
263
|
-
|
264
|
-
// Same as above, but with 8 arguments.
|
265
|
-
template <prelexer mx1, prelexer mx2,
|
266
|
-
prelexer mx3, prelexer mx4,
|
267
|
-
prelexer mx5, prelexer mx6,
|
268
|
-
prelexer mx7, prelexer mx8>
|
269
|
-
const char* alternatives(const char* src) {
|
270
|
-
const char* rslt;
|
271
|
-
(rslt = mx1(src)) || (rslt = mx2(src)) ||
|
272
|
-
(rslt = mx3(src)) || (rslt = mx4(src)) ||
|
273
|
-
(rslt = mx5(src)) || (rslt = mx6(src)) ||
|
274
|
-
(rslt = mx7(src)) || (rslt = mx8(src));
|
275
|
-
return rslt;
|
276
|
-
}
|
277
|
-
|
278
|
-
// Tries the matchers in sequence and succeeds if they all succeed.
|
279
|
-
template <prelexer mx1, prelexer mx2>
|
280
|
-
const char* sequence(const char* src) {
|
281
|
-
const char* rslt = src;
|
282
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt));
|
283
|
-
return rslt;
|
284
|
-
}
|
285
|
-
|
286
|
-
// Same as above, but with 3 arguments.
|
287
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3>
|
288
|
-
const char* sequence(const char* src) {
|
289
|
-
const char* rslt = src;
|
290
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt)) && (rslt = mx3(rslt));
|
291
|
-
return rslt;
|
292
|
-
}
|
293
|
-
|
294
|
-
// Same as above, but with 4 arguments.
|
295
|
-
template <prelexer mx1, prelexer mx2, prelexer mx3, prelexer mx4>
|
296
|
-
const char* sequence(const char* src) {
|
297
|
-
const char* rslt = src;
|
298
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt)) &&
|
299
|
-
(rslt = mx3(rslt)) && (rslt = mx4(rslt));
|
300
|
-
return rslt;
|
301
|
-
}
|
302
|
-
|
303
|
-
// Same as above, but with 5 arguments.
|
304
|
-
template <prelexer mx1, prelexer mx2,
|
305
|
-
prelexer mx3, prelexer mx4,
|
306
|
-
prelexer mx5>
|
307
|
-
const char* sequence(const char* src) {
|
308
|
-
const char* rslt = src;
|
309
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt)) &&
|
310
|
-
(rslt = mx3(rslt)) && (rslt = mx4(rslt)) &&
|
311
|
-
(rslt = mx5(rslt));
|
312
|
-
return rslt;
|
313
|
-
}
|
314
|
-
|
315
|
-
// Same as above, but with 6 arguments.
|
316
|
-
template <prelexer mx1, prelexer mx2,
|
317
|
-
prelexer mx3, prelexer mx4,
|
318
|
-
prelexer mx5, prelexer mx6>
|
319
|
-
const char* sequence(const char* src) {
|
320
|
-
const char* rslt = src;
|
321
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt)) &&
|
322
|
-
(rslt = mx3(rslt)) && (rslt = mx4(rslt)) &&
|
323
|
-
(rslt = mx5(rslt)) && (rslt = mx6(rslt));
|
324
|
-
return rslt;
|
325
|
-
}
|
326
|
-
|
327
|
-
// Same as above, but with 7 arguments.
|
328
|
-
template <prelexer mx1, prelexer mx2,
|
329
|
-
prelexer mx3, prelexer mx4,
|
330
|
-
prelexer mx5, prelexer mx6,
|
331
|
-
prelexer mx7>
|
332
|
-
const char* sequence(const char* src) {
|
333
|
-
const char* rslt = src;
|
334
|
-
(rslt = mx1(rslt)) && (rslt = mx2(rslt)) &&
|
335
|
-
(rslt = mx3(rslt)) && (rslt = mx4(rslt)) &&
|
336
|
-
(rslt = mx5(rslt)) && (rslt = mx6(rslt)) &&
|
337
|
-
(rslt = mx7(rslt));
|
338
|
-
return rslt;
|
339
|
-
}
|
340
|
-
|
341
|
-
// Match a pattern or not. Always succeeds.
|
342
|
-
template <prelexer mx>
|
343
|
-
const char* optional(const char* src) {
|
344
|
-
const char* p = mx(src);
|
345
|
-
return p ? p : src;
|
346
|
-
}
|
347
|
-
|
348
|
-
// Match zero or more of the supplied pattern
|
349
|
-
template <prelexer mx>
|
350
|
-
const char* zero_plus(const char* src) {
|
351
|
-
const char* p = mx(src);
|
352
|
-
while (p) src = p, p = mx(src);
|
353
|
-
return src;
|
354
|
-
}
|
355
|
-
|
356
|
-
// Match one or more of the supplied pattern
|
357
|
-
template <prelexer mx>
|
358
|
-
const char* one_plus(const char* src) {
|
359
|
-
const char* p = mx(src);
|
360
|
-
if (!p) return 0;
|
361
|
-
while (p) src = p, p = mx(src);
|
362
|
-
return src;
|
363
|
-
}
|
364
|
-
|
365
|
-
// Match a single character satisfying the ctype predicates.
|
366
|
-
const char* space(const char* src);
|
367
|
-
const char* alpha(const char* src);
|
368
|
-
const char* digit(const char* src);
|
369
|
-
const char* xdigit(const char* src);
|
370
|
-
const char* alnum(const char* src);
|
371
|
-
const char* punct(const char* src);
|
372
|
-
// Match multiple ctype characters.
|
373
|
-
const char* spaces(const char* src);
|
374
|
-
const char* alphas(const char* src);
|
375
|
-
const char* digits(const char* src);
|
376
|
-
const char* xdigits(const char* src);
|
377
|
-
const char* alnums(const char* src);
|
378
|
-
const char* puncts(const char* src);
|
379
|
-
// Match certain white-space charactes.
|
380
|
-
const char* wspaces(const char* src);
|
381
|
-
// const char* newline(const char* src);
|
382
|
-
// const char* whitespace(const char* src);
|
383
|
-
|
384
148
|
// Match a line comment.
|
385
149
|
const char* line_comment(const char* src);
|
386
150
|
const char* line_comment_prefix(const char* src);
|
@@ -399,69 +163,71 @@ namespace Sass {
|
|
399
163
|
// Match number prefix ([\+\-]+)
|
400
164
|
const char* number_prefix(const char* src);
|
401
165
|
|
402
|
-
//
|
403
|
-
const char*
|
404
|
-
|
405
|
-
|
406
|
-
const char*
|
407
|
-
const char*
|
166
|
+
// Match zero plus white-space or line_comments
|
167
|
+
const char* optional_css_whitespace(const char* src);
|
168
|
+
const char* css_whitespace(const char* src);
|
169
|
+
// Match optional_css_whitepace plus block_comments
|
170
|
+
const char* optional_css_comments(const char* src);
|
171
|
+
const char* css_comments(const char* src);
|
408
172
|
|
409
|
-
|
173
|
+
// Match one backslash escaped char
|
174
|
+
const char* escape_seq(const char* src);
|
410
175
|
|
411
176
|
// Match CSS css variables.
|
412
177
|
const char* custom_property_name(const char* src);
|
413
178
|
// Match a CSS identifier.
|
414
179
|
const char* identifier(const char* src);
|
415
|
-
const char*
|
180
|
+
const char* identifier_alpha(const char* src);
|
181
|
+
const char* identifier_alnum(const char* src);
|
182
|
+
const char* identifier_alnums(const char* src);
|
416
183
|
// Match selector names.
|
417
184
|
// const char* sel_ident(const char* src);
|
185
|
+
const char* kwd_sel_deep(const char* src);
|
186
|
+
|
418
187
|
// Match interpolant schemas
|
419
188
|
const char* identifier_schema(const char* src);
|
420
189
|
const char* value_schema(const char* src);
|
421
|
-
const char* filename(const char* src);
|
190
|
+
// const char* filename(const char* src);
|
422
191
|
// const char* filename_schema(const char* src);
|
423
192
|
// const char* url_schema(const char* src);
|
424
193
|
// const char* url_value(const char* src);
|
425
194
|
const char* vendor_prefix(const char* src);
|
426
195
|
// Match CSS '@' keywords.
|
427
196
|
const char* at_keyword(const char* src);
|
428
|
-
const char*
|
429
|
-
const char*
|
430
|
-
const char*
|
431
|
-
const char*
|
432
|
-
const char*
|
433
|
-
const char*
|
197
|
+
const char* kwd_import(const char* src);
|
198
|
+
const char* kwd_at_root(const char* src);
|
199
|
+
const char* kwd_with_directive(const char* src);
|
200
|
+
const char* kwd_without_directive(const char* src);
|
201
|
+
const char* kwd_media(const char* src);
|
202
|
+
const char* kwd_supports(const char* src);
|
434
203
|
// const char* keyframes(const char* src);
|
435
204
|
// const char* keyf(const char* src);
|
436
|
-
const char*
|
437
|
-
const char*
|
438
|
-
const char*
|
439
|
-
const char*
|
440
|
-
const char*
|
441
|
-
const char*
|
442
|
-
|
443
|
-
const char*
|
444
|
-
const char*
|
205
|
+
const char* kwd_mixin(const char* src);
|
206
|
+
const char* kwd_function(const char* src);
|
207
|
+
const char* kwd_return_directive(const char* src);
|
208
|
+
const char* kwd_include(const char* src);
|
209
|
+
const char* kwd_content(const char* src);
|
210
|
+
const char* kwd_extend(const char* src);
|
211
|
+
|
212
|
+
const char* kwd_if_directive(const char* src);
|
213
|
+
const char* kwd_else_directive(const char* src);
|
445
214
|
const char* elseif_directive(const char* src);
|
446
215
|
|
447
|
-
const char*
|
448
|
-
const char*
|
449
|
-
const char*
|
450
|
-
const char*
|
451
|
-
|
452
|
-
const char* each_directive(const char* src);
|
453
|
-
const char* in(const char* src);
|
216
|
+
const char* kwd_for_directive(const char* src);
|
217
|
+
const char* kwd_from(const char* src);
|
218
|
+
const char* kwd_to(const char* src);
|
219
|
+
const char* kwd_through(const char* src);
|
454
220
|
|
455
|
-
const char*
|
221
|
+
const char* kwd_each_directive(const char* src);
|
222
|
+
const char* kwd_in(const char* src);
|
456
223
|
|
457
|
-
const char*
|
458
|
-
const char* err(const char* src);
|
459
|
-
const char* dbg(const char* src);
|
224
|
+
const char* kwd_while_directive(const char* src);
|
460
225
|
|
461
|
-
|
462
|
-
const char*
|
226
|
+
const char* kwd_warn(const char* src);
|
227
|
+
const char* kwd_err(const char* src);
|
228
|
+
const char* kwd_dbg(const char* src);
|
463
229
|
|
464
|
-
const char*
|
230
|
+
const char* kwd_null(const char* src);
|
465
231
|
|
466
232
|
// Match CSS type selectors
|
467
233
|
const char* namespace_prefix(const char* src);
|
@@ -484,6 +250,7 @@ namespace Sass {
|
|
484
250
|
const char* coefficient(const char* src);
|
485
251
|
const char* binomial(const char* src);
|
486
252
|
const char* percentage(const char* src);
|
253
|
+
const char* ampersand(const char* src);
|
487
254
|
const char* dimension(const char* src);
|
488
255
|
const char* hex(const char* src);
|
489
256
|
const char* hexa(const char* src);
|
@@ -491,8 +258,7 @@ namespace Sass {
|
|
491
258
|
// const char* rgb_prefix(const char* src);
|
492
259
|
// Match CSS uri specifiers.
|
493
260
|
const char* uri_prefix(const char* src);
|
494
|
-
|
495
|
-
const char* url(const char* src);
|
261
|
+
const char* uri_value(const char* src);
|
496
262
|
// Match CSS "!important" keyword.
|
497
263
|
const char* important(const char* src);
|
498
264
|
// Match CSS "!optional" keyword.
|
@@ -525,19 +291,6 @@ namespace Sass {
|
|
525
291
|
// Match SCSS variable names.
|
526
292
|
const char* variable(const char* src);
|
527
293
|
|
528
|
-
// Match Sass boolean keywords.
|
529
|
-
const char* true_val(const char* src);
|
530
|
-
const char* false_val(const char* src);
|
531
|
-
const char* and_op(const char* src);
|
532
|
-
const char* or_op(const char* src);
|
533
|
-
const char* not_op(const char* src);
|
534
|
-
const char* eq_op(const char* src);
|
535
|
-
const char* neq_op(const char* src);
|
536
|
-
const char* gt_op(const char* src);
|
537
|
-
const char* gte_op(const char* src);
|
538
|
-
const char* lt_op(const char* src);
|
539
|
-
const char* lte_op(const char* src);
|
540
|
-
|
541
294
|
// IE stuff
|
542
295
|
const char* ie_progid(const char* src);
|
543
296
|
const char* ie_expression(const char* src);
|
@@ -578,18 +331,6 @@ namespace Sass {
|
|
578
331
|
}
|
579
332
|
return 0;
|
580
333
|
}
|
581
|
-
template <char c>
|
582
|
-
unsigned int count_interval(const char* beg, const char* end) {
|
583
|
-
unsigned int counter = 0;
|
584
|
-
bool esc = false;
|
585
|
-
while (beg < end && *beg) {
|
586
|
-
if (esc) esc = false;
|
587
|
-
else if (*beg == '\\') esc = true;
|
588
|
-
else if (*beg == c) ++counter;
|
589
|
-
++beg;
|
590
|
-
}
|
591
|
-
return counter;
|
592
|
-
}
|
593
334
|
template <prelexer mx>
|
594
335
|
unsigned int count_interval(const char* beg, const char* end) {
|
595
336
|
unsigned int counter = 0;
|
@@ -613,7 +354,6 @@ namespace Sass {
|
|
613
354
|
return counter;
|
614
355
|
}
|
615
356
|
|
616
|
-
const char* chunk(const char* src);
|
617
357
|
}
|
618
358
|
}
|
619
359
|
|