File: getstate_blocklist_with_use.re

package info (click to toggle)
re2c 4.1-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 50,052 kB
  • sloc: cpp: 32,477; ml: 8,279; sh: 5,265; makefile: 968; haskell: 612; python: 428; ansic: 227; javascript: 111; java: 3
file content (51 lines) | stat: -rw-r--r-- 1,045 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// re2c $INPUT -o $OUTPUT -if
// This test is for `getstate:re2c` with a list of blocks
// with mixed `use:re2c` and non-use blocks.

// `getstate:re2c:y` (start in y)
/*!getstate:re2c:y */

// `getstate:re2c:z:x` (start in z)
/*!getstate:re2c:z:x */

// `getstate:re2c:y:x:z` (start in y)
/*!getstate:re2c:y:x:z */

// rules block w
/*!rules:re2c:w
    * { w }
*/

// use block (expect a local state switch for this block only)
/*!use:re2c:w */

// global block x (no start label)
/*!re2c:x
    * { x }
*/

// use block (expect a local state switch for this block only)
/*!use:re2c */

// global block y (with start label)
/*!re2c:y
    !use:w;
    * { y }
*/

// local block z (with start label)
/*!local:re2c:z
    * { z }
*/

// the same directives at the end of file (in different order)
// should be no different from the ones at the beginning of the file

// `getstate:re2c:y:x:z` (start in y)
/*!getstate:re2c:y:x:z */

// `getstate:re2c:z:x` (start in z)
/*!getstate:re2c:z:x */

// `getstate:re2c:y` (start in y)
/*!getstate:re2c:y */