File: getstate_autogen_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 (36 lines) | stat: -rw-r--r-- 785 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
// re2c $INPUT -o $OUTPUT -if
// This test is for autogenerated state switch without `getstate:re2c`
// and with mixed `use:re2c` and non-use blocks (named or anonymous).

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

// local block y (with start label)
// (expect a global state switch here with a start label in y
// including blocks y, z and the unnamed blocks)
/*!local:re2c:y
    * { y }
*/

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

// global block z that includes x (no start label)
/*!re2c:z
    !use:x;
*/

// unnamed local block that includes x (no start label)
/*!local:re2c
    !use:x;
*/

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

// unnamed global block (no start label)
/*!re2c
    * { ? }
*/