eolian: add parsing for @move and @by_ref
authorDaniel Kolesa <d.kolesa@samsung.com>
Fri, 30 Aug 2019 14:08:31 +0000 (16:08 +0200)
committerYeongjong Lee <yj34.lee@samsung.com>
Mon, 16 Sep 2019 01:23:00 +0000 (10:23 +0900)
commit262b59dc44922bd7f6891fec0831ae706a5bd52b
tree10f123fe9ea9d152ce022e89e8188e1eff68c80a
parent98390ba356be9c6b9e0ab98b75b2a55bc6686317
eolian: add parsing for @move and @by_ref

The @by_ref qualifier is now allowed on parameters, returns and
struct fields in the usual qualifier section. It will mean that
this type is passed around by reference, and will only be allowed
on types that are not already pointer-like.

The @move qualifier will replace @owned as one with a clearer
meaning. It means "transfer of ownership". It has the same semantics
as the current @owned, i.e. on return values it transfers ownership
of the value to the caller, on parameters it transfers ownership
to the callee (the inverse is the default when not specified).
On struct fields, it means the field will transfer together with
the struct that contains it.
src/lib/eolian/eo_lexer.h
src/lib/eolian/eo_parser.c
src/lib/eolian/eolian_database.h