/**************************/
/*** preprocessor tests ***/
/**************************/ 

const char '\8';

#if 1
"#if OK";
#endif

#if 0
#error
#else
"#else OK";
#endif

#if 0
#error
#elseif 1
"#elif OK"
#endif

#define string1 "#define OK"
string1

#ifdef string1
"#ifdef OK"
#endif

#define string2 NE SERA PAS COMPILE
#undef string2
#ifdef string2
#error
#else
"#undef OK"
#endif

#ifndef string2
"#ifndef OK"
#endif

#include "testlexer_include.idl"

#pragma toto
#line 500
'\8'
#line 50

#   define    toto
# undef toto

/* bad ones */
//  commented since the C preprocessor crashes
//  # error
//  # ( error )

/*********************/
/*** comment tests ***/
/*********************/

// conneries
/* encore
*** des ***
/// conneries ///
/* hello * / coucou */


/***********************/
/*** identifier test ***/
/***********************/

echo_string
_string
_Strong

/* bad ones */
__string
_String


/*********************/
/*** keywords test ***/
/*********************/

abstract
any
attribute
boolean
case
char
const
context
custom
default
double
enum
exception
factory
FALSE
fixed
float
in
inout
interface
long
module
native
Object
octet
oneway
out
private
public
raises
readonly
sequence
short
string
struct
supports
switch
TRUE
truncatable
typedef
unsigned
union
ValueBase
valuetype
void
wchar
wstring

/* bad ones */
Boolean
false
object
true
valuebase


/*********************/
/*** literal tests ***/
/*********************/

/* integers */
0
12
014
0xC

/* characters */
'r'
'\n'
'\''
'\\'
'\1'
'\12'
'\123'
'\xa'
'\xab'
'\ua'
'\uab'
'\uabc'
'\uabcd'

/* bad characters */
''
'\8'
'\k'
'\1234'
'\xzfrt'
'\xabc'
'\ux'
'\uabcde'

/* fatal characters if preprocessor enable */
//'''
//'\'

/* fatal character */
//'z

/* wide characters */
L'r'
L'\n'
L'\''
L'\\'
L'\1'
L'\12'
L'\123'
L'\xa'
L'\xab'
L'\ua'
L'\uab'
L'\uabc'
L'\uabcd'

/* bad wide characters */
L''
L'\8'
L'\k'
L'\1234'
L'\xzfrt'
L'\xabc'
L'\ux'
L'\uabcde'

/* fatal wide characters if preprocessor enable */
//L'''
//L'\'

/* fatal wide character */
//L'z

/* floats */
1.45
0.2
.3
3.
5e3
3E4
.3e4
0.
0e0

/* strings */
"a string"
"a more"" complicated"" one"
"two" "strings"
"very """ """complicated"""
"with a \\ inside"
"with a \""" inside"
"with an octal char : \123"
"with an octal char : \12345"
"with an octal char : \03"
"with an hexa char : \xab"
"with an hexa char : \xabcd"
"with a unicode char : \uabcd"
"with a unicode char : \uabcdef"

/* bad strings */
" a multiline 
              string"
"with a null octal char : \0"
"with a bad hexa char : \xk"
"with a bad unicode char : \uk"
"with a bad escape char : \g"

/* fatal string */
//"sans fin ...

/* wide strings */
L"a string"
L"a more"" complicated"" one"
L"two" "strings"
L"very """ """complicated"""
L"with a \\ inside"
L"with a \""" inside"
L"with an "   "espace between both parts"
L"with an octal char : \123"
L"with an octal char : \12345"
L"with an octal char : \03"
L"with an hexa char : \xab"
L"with an hexa char : \xabcd"
L"with a unicode char : \uabcd"
L"with a unicode char : \uabcdef"

/* bad wide strings */
L" a multiline 
               string"
L"with a null octal char : \0"
L"with a bad hexa char : \xk"
L"with a bad unicode char : \uk"
L"with a bad escape char : \g"

/* fatal wide string */
//L"sans fin ...

/* fixed point */
2d
5D
3.4d
.5d
0d

