Commit Graph

123 Commits

Author SHA1 Message Date
Stefan Schmidt eebeca2900 docs/eolian: Add main landing page for Eolian documentation 2014-09-19 15:27:33 +02:00
Kai Huuhko d0ee1bd142 Eolian: Fix a c&p mistake in doc 2014-09-15 14:38:12 +03:00
Kai Huuhko 09d6592260 Eolian: Fix a few warnings
"function declaration isn't a prototype"

   void was forgotten from empty params list
2014-09-15 14:34:33 +03:00
Savio Sena 2d39b359fb eolian: Added eolian_function_is_constructor().
This patch adds a list of strings called 'ctor_of' to
_Eolian_Function. This list will contain all classes in which this
function is a constructing function.

ctor_of is filled in two moments:

* When filling the constructors of a class, class->full_name is inserted
  in the 'ctor_of' of each constructor's function.

* When filling the implements of a class, if the function is a
  constructor of its superclass it also becomes a constructor of the
  current class, so class->full_name is also inserted in the 'ctor_of'
  of each implement's function.

eolian_function_is_constructor gets a func and klass arguments. It goes
through ctor_of of func and returns EINA_TRUE if klass->full_name is
found, otherwise it returns EINA_FALSE.
2014-09-12 16:51:37 -03:00
Daniel Kolesa 7786b96359 eolian: builtin complex types
From now on, there are 5 builtin complex types, particularly accessor, array,
iterator, hash and list. All other types are simple - they can't have a complex
part. Also, the <> now binds to the type itself, not the pointer. More builtin
complex types will be added as needed.
2014-09-08 14:53:13 +01:00
Daniel Kolesa 977d4fe1a6 eolian: better handling of @virtual implements
Now they're registered correctly. Also, add new API, eolian_implement_is_virtual.
Also, deal with get/set properly (when filling in additional implements)
2014-09-05 16:05:04 +01:00
Daniel Kolesa 00192bd15e eolian: update docs on implements 2014-09-05 12:01:37 +01:00
Daniel Kolesa 5827486c3d eolian: APIs to check auto/empty on a function 2014-09-03 14:26:09 +01:00
Daniel Kolesa 0998f2af5c eolian: new APIs for expression analysis
This adds a few new APIs to retrieve the type of an expression, operators
for binary and unary expressions, lhs/rhs for binary expressions, expr for
unary expressions and value for other expressions.
2014-09-02 13:33:04 +01:00
Daniel Kolesa b13bafabba eolian: support for default param values where applicable + API 2014-09-02 10:47:55 +01:00
Daniel Kolesa d2702a4fad eolian: remove @constructor syntax 2014-09-01 16:02:40 +01:00
Daniel Kolesa 21530bd5d8 eolian: preliminary support for new constructors section 2014-09-01 15:35:50 +01:00
Daniel Kolesa 4785353baf eolian: APIs to check if an implement references get/set 2014-08-29 15:30:51 +01:00
Daniel Kolesa b05f738675 eolian: APIs to check for @empty/@auto on implements 2014-08-29 15:22:14 +01:00
Daniel Kolesa b69b90832f eolian: remove constructors section cruft 2014-08-27 15:43:47 +01:00
Daniel Kolesa b75014a024 eolian: refactor the struct/enum field APIs 2014-08-22 16:56:41 +01:00
Daniel Kolesa cdd4860520 eolian: turn db validation into separate API 2014-08-21 16:35:59 +01:00
Daniel Kolesa 58a2025c25 eolian: new API: eolian_function_is_constructing 2014-08-21 09:26:05 +01:00
Daniel Kolesa ef380c56b6 eolian: support for setting a free function to values in eo files 2014-08-21 09:26:05 +01:00
Daniel Kolesa 33c39282b1 eolian: support "eo: null;" for legacy only functions/properties 2014-08-21 09:26:05 +01:00
Daniel Kolesa e6954d143d eolian: drop Eina_Value
Because of Eina_Value being less than optimal in our usage, we're dropping it in Eolian.
This simplifies the code and makes it easier to bind to other languages, which
will aid new generators. Also, we're dropping long double support from eo files
and expressions as it causes an ABI breakage in gcc 4.4.
2014-08-21 09:26:05 +01:00
Daniel Kolesa 913e0f09fa eolian: get rid of the data hash in Eolian_Function 2014-08-21 09:26:05 +01:00
Daniel Kolesa 1688749ce9 eolian: add support for opaque struct types (+ tests) 2014-08-21 09:26:05 +01:00
Daniel Kolesa 93726c86a3 eolian: get rid of eolian_parameter_information_get 2014-08-21 09:26:04 +01:00
Daniel Kolesa ad3dbe834b eolian: API refactoring
Remove eolian_implement_information_get. Also, fix some nasty lookup problems.
2014-08-21 09:26:04 +01:00
Daniel Kolesa 057e01d67f eolian: API refactoring
Start getting rid of the terrible _information_get APIs, starting with events.
2014-08-21 09:26:04 +01:00
Daniel Kolesa ffbf149da1 eolian: new API: eolian_class_event_scope_get 2014-08-21 09:26:04 +01:00
Daniel Kolesa a5964f0252 eolian: add comments containing original expressions to generated enum fields
This required a new API, eolian_expression_serialize.
2014-08-21 09:26:04 +01:00
Daniel Kolesa 18c2b5082e eolian: allow usage of stack Eina_Value in expr API 2014-08-21 09:26:04 +01:00
Daniel Kolesa 732e3f417e eolian: new API: eolian_type_enum_legacy_prefix_set + generator changes
This change adds a new API to retrieve the legacy prefix for enum members
and also adds support for generating enums into the C generator. Besides that,
it prevents generation of entire struct contents when the .eo file declares
a named struct inside of a typedef - as the struct itself gets generated later on.
2014-08-21 09:26:04 +01:00
Daniel Kolesa abca650617 eolian: new APIs
This adds eolian_show_enum, eolian_show_global, eolian_show_constant.
2014-08-21 09:26:04 +01:00
Daniel Kolesa e2fb43b7b5 eolian: enum API implementation
This implements the previously declared APIs to manipulate enum types. Also,
it implements the appropriate lookups in expression evaluation so that you
can refer to constants and enums inside constant expressions.
2014-08-21 09:26:04 +01:00
Daniel Kolesa be68f9e1fa eolian: initial parsing code and API declarations for enums 2014-08-21 09:26:04 +01:00
Daniel Kolesa d4031a21bf eolian: test for constants/globals
Also added API to retrieve value of a variable (forgot about that one)
and made it impossible to create extern constants (doesn't make sense)
as well as made it impossible to give extern globals values.
2014-08-21 09:26:04 +01:00
Daniel Kolesa 65332eb3ca eolian: var parsing (global and constant)
This makes the API effectively functional. Also, I added new API
eolian_variable_is_extern to match structs and typedefs.
2014-08-21 09:26:04 +01:00
Daniel Kolesa cc1988fddd eolian: expose new variable API 2014-08-21 09:26:04 +01:00
Daniel Kolesa 70bf1eac24 eolian: add infrastructure for globals and constants
Nothing parses yet, and no API is exposed. Also, move the remaining instances of file
inside of existing structures to Eolian_Object and parse basename only once.
2014-08-21 09:26:04 +01:00
Daniel Kolesa bcf5f1b1dd eolian: better doc 2014-08-21 09:26:03 +01:00
Daniel Kolesa 8c1b9ed3e2 eolian: initial API for expression evaluation
This commit also does several side (related) changes. Particularly, it updates
the Eolian C generator to use the new API, it adds missing expr types (null, char)
and masks, updates the API dealing with default return values to use expressions
instead of strings and does several fixes (mainly in lexer) around the place.
It also disallows single quoted strings as those are reserved for characters.
2014-08-21 09:26:03 +01:00
Daniel Kolesa 90e17acd15 eolian: initial eval function with Eina_Value return 2014-08-21 09:26:03 +01:00
Daniel Kolesa d7ca6dc1c3 eolian: initial support for expression evaluation
There are now functions that let you evaluate Eolian_Expression. They're not exposed
yet. Further improvements will come as well as public API.
2014-08-21 09:26:03 +01:00
Daniel Kolesa 62541ce484 eolian: rename public enum members to a namespaced form 2014-08-21 09:26:03 +01:00
Daniel Kolesa 436a37f0b9 eolian: initial support for expression parsing 2014-08-21 09:26:03 +01:00
Daniel Kolesa 0e4860f215 eolian: add support for referencing classes as types
For this purpose, several other changes were made. There can now only be 1 class per file
and the class name has to match the file name. Also, I replaced the list of classes with
a hash, allowing for fast indexing (crucial for parser performance - otherwise it was
very slow).

This also adds a new API, eolian_type_class_get.
2014-08-21 09:26:02 +01:00
Daniel Kolesa 5bdbf4dbb5 eolian: doc typo fix 2014-07-25 14:31:39 +01:00
Daniel Kolesa bb7f657f90 eolian: clarify documentation 2014-07-25 14:25:45 +01:00
Daniel Kolesa a5ad792780 eolian: add support for class functions 2014-07-24 12:05:12 +01:00
Daniel Kolesa 315d5de11d eolian: use just filename (not path) for eolian_class_get_by_file 2014-07-23 17:15:00 +01:00
Daniel Kolesa 572b7aa92f eolian: eolian_function_parameter_get -> eolian_function_parameter_get_by_name 2014-07-23 14:22:25 +01:00
Daniel Kolesa 88cc1167e9 eolian: eolian_parameters_get -> eolian_function_parameters_get 2014-07-23 14:17:19 +01:00