projects
/
platform
/
upstream
/
efl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a1588f6
)
eolian: restrict own() for pointers only
author
Daniel Kolesa
<d.kolesa@samsung.com>
Tue, 1 Jul 2014 16:55:34 +0000
(17:55 +0100)
committer
Daniel Kolesa
<d.kolesa@samsung.com>
Tue, 1 Jul 2014 16:55:34 +0000
(17:55 +0100)
src/lib/eolian/eo_parser.c
patch
|
blob
|
history
diff --git
a/src/lib/eolian/eo_parser.c
b/src/lib/eolian/eo_parser.c
index
673b516
..
2e4c9b0
100644
(file)
--- a/
src/lib/eolian/eo_parser.c
+++ b/
src/lib/eolian/eo_parser.c
@@
-203,11
+203,16
@@
parse_type_void(Eo_Lexer *ls)
}
case KW_own:
{
- int line;
+ int
sline = ls->line_number,
line;
eo_lexer_get(ls);
line = ls->line_number;
check_next(ls, '(');
def = parse_type_void(ls);
+ if (def->type != EOLIAN_TYPE_POINTER)
+ {
+ ls->line_number = sline;
+ eo_lexer_syntax_error(ls, "pointer type expected");
+ }
def->is_own = EINA_TRUE;
check_match(ls, ')', '(', line);
goto parse_ptr;