summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2013-11-25 22:49:18 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2013-11-25 22:49:18 +0100
commit0c0a0c2676ff5a83b8e17cecb8d267380162723f (patch)
tree3eac8897f19058a98acba551a2fcfdb046d19eb6
parenta3fd575e473732cfbc9c5e5bcedb668518ebc72f (diff)
downloadeo_tokenizer-0c0a0c2676ff5a83b8e17cecb8d267380162723f.zip
eo_tokenizer-0c0a0c2676ff5a83b8e17cecb8d267380162723f.tar.gz
add _Def suffix to ret and param structs, add LAST to enums
-rw-r--r--eo_tokenizer.h18
-rw-r--r--eo_tokenizer.rl2
2 files changed, 11 insertions, 9 deletions
diff --git a/eo_tokenizer.h b/eo_tokenizer.h
index 5332ad6..3328ec4 100644
--- a/eo_tokenizer.h
+++ b/eo_tokenizer.h
@@ -34,11 +34,11 @@ extern int _eo_tokenizer_log_dom;
/* RET */
-typedef struct _eo_ret
+typedef struct _eo_ret_def
{
const char *type;
const char *comment;
-} Eo_Ret;
+} Eo_Ret_Def;
/* PARAMS */
@@ -46,29 +46,31 @@ typedef enum _param_way
{
IN,
OUT,
- INOUT
+ INOUT,
+ PARAM_WAY_LAST
} Param_Way;
-typedef struct _eo_param
+typedef struct _eo_param_def
{
Param_Way way;
const char *type;
const char *name;
const char *comment;
-} Eo_Param;
+} Eo_Param_Def;
/* PROPERTIES */
typedef enum _property_type
{
SETTER,
- GETTER
+ GETTER,
+ PROP_TYPE_LAST
} Property_Type;
typedef struct _eo_property_def
{
Property_Type type;
- Eo_Ret ret;
+ Eo_Ret_Def ret;
const char *name;
const char *comment;
Eina_List *params;
@@ -78,7 +80,7 @@ typedef struct _eo_property_def
typedef struct _eo_method_def
{
- Eo_Ret ret;
+ Eo_Ret_Def ret;
const char *name;
const char *comment;
Eina_List *params;
diff --git a/eo_tokenizer.rl b/eo_tokenizer.rl
index 4753a20..de12f33 100644
--- a/eo_tokenizer.rl
+++ b/eo_tokenizer.rl
@@ -39,7 +39,7 @@ static Eo_Class_Def*
_eo_tokenizer_class_get(Eo_Tokenizer *toknz, char *p)
{
Eo_Class_Def *kls = calloc(1, sizeof(Eo_Class_Def));
- if (kls == NULL) ABORT(toknz, "calloc Eo_Class failure");
+ if (kls == NULL) ABORT(toknz, "calloc Eo_Class_Def failure");
kls->name = _eo_tokenizer_token_get(toknz, p);