/* Generated by re2c */
#line 1 "encodings/unicode_group_Cc_8_encoding_policy_fail.re"
// re2c $INPUT -o $OUTPUT -8 --encoding-policy fail
#include <stdio.h>
#include "utf8.h"
#define YYCTYPE unsigned char
bool scan(const YYCTYPE * start, const YYCTYPE * const limit)
{
	__attribute__((unused)) const YYCTYPE * YYMARKER; // silence compiler warnings when YYMARKER is not used
#	define YYCURSOR start
Cc:
	
#line 14 "encodings/unicode_group_Cc_8_encoding_policy_fail.c"
{
	YYCTYPE yych;
	yych = *YYCURSOR;
	switch (yych) {
		case 0x00:
		case 0x01:
		case 0x02:
		case 0x03:
		case 0x04:
		case 0x05:
		case 0x06:
		case 0x07:
		case 0x08:
		case '\t':
		case '\n':
		case '\v':
		case '\f':
		case '\r':
		case 0x0E:
		case 0x0F:
		case 0x10:
		case 0x11:
		case 0x12:
		case 0x13:
		case 0x14:
		case 0x15:
		case 0x16:
		case 0x17:
		case 0x18:
		case 0x19:
		case 0x1A:
		case 0x1B:
		case 0x1C:
		case 0x1D:
		case 0x1E:
		case 0x1F:
		case 0x7F: goto yy1;
		case 0xC2: goto yy4;
		default: goto yy2;
	}
yy1:
	++YYCURSOR;
#line 13 "encodings/unicode_group_Cc_8_encoding_policy_fail.re"
	{ goto Cc; }
#line 59 "encodings/unicode_group_Cc_8_encoding_policy_fail.c"
yy2:
	++YYCURSOR;
yy3:
#line 14 "encodings/unicode_group_Cc_8_encoding_policy_fail.re"
	{ return YYCURSOR == limit; }
#line 65 "encodings/unicode_group_Cc_8_encoding_policy_fail.c"
yy4:
	yych = *++YYCURSOR;
	switch (yych) {
		case 0x80:
		case 0x81:
		case 0x82:
		case 0x83:
		case 0x84:
		case 0x85:
		case 0x86:
		case 0x87:
		case 0x88:
		case 0x89:
		case 0x8A:
		case 0x8B:
		case 0x8C:
		case 0x8D:
		case 0x8E:
		case 0x8F:
		case 0x90:
		case 0x91:
		case 0x92:
		case 0x93:
		case 0x94:
		case 0x95:
		case 0x96:
		case 0x97:
		case 0x98:
		case 0x99:
		case 0x9A:
		case 0x9B:
		case 0x9C:
		case 0x9D:
		case 0x9E:
		case 0x9F: goto yy1;
		default: goto yy3;
	}
}
#line 15 "encodings/unicode_group_Cc_8_encoding_policy_fail.re"

}
static const unsigned int chars_Cc [] = {0x0,0x1f,  0x7f,0x9f,  0x20,0x20};
static unsigned int encode_utf8 (const unsigned int * ranges, unsigned int ranges_count, unsigned int * s)
{
	unsigned int * const s_start = s;
	for (unsigned int i = 0; i < ranges_count - 2; i += 2)
		for (unsigned int j = ranges[i]; j <= ranges[i + 1]; ++j)
			s += re2c::utf8::rune_to_bytes (s, j);
	re2c::utf8::rune_to_bytes (s, ranges[ranges_count - 1]);
	return s - s_start + 1;
}

int main ()
{
	unsigned int * buffer_Cc = new unsigned int [264];
	YYCTYPE * s = (YYCTYPE *) buffer_Cc;
	unsigned int buffer_len = encode_utf8 (chars_Cc, sizeof (chars_Cc) / sizeof (unsigned int), buffer_Cc);
	/* convert 32-bit code units to YYCTYPE; reuse the same buffer */
	for (unsigned int i = 0; i < buffer_len; ++i) s[i] = buffer_Cc[i];
	if (!scan (s, s + buffer_len))
		printf("test 'Cc' failed\n");
	delete [] buffer_Cc;
	return 0;
}
