summaryrefslogtreecommitdiff
path: root/src/bin/eolian_cxx (follow)
AgeCommit message (Collapse)Author
2015-10-09eolian-cxx: Fixed possible exception escaping mainFelipe Magno de Almeida
Added try/catch around main to show the reason for the generation failure. @fix CID 1265600
2015-09-03eolian: remove support for old style docs completelyDaniel Kolesa
2015-07-08eolian: improve function_full_c_name_get APIDaniel Kolesa
It's now generalized to work properly with legacy functions as well as correctly append suffixes. Thus, it can be easily used with the documentation generator and in other places. @feature
2015-06-24eolian_cxx: Use C++ wrappers instead of native types as parametersVitor Sousa
Summary: Using C++ wrapper types in the signature of methods of the generated classes. Now, when the type is an Eo type defined in Eolian, eolian_cxx will detect it and use the equivalent C++ wrapper. Types defined in Eolian no longer need to be specified in the lookup table, so removed them from there. Disable wrapping of non-const char*. The current wrapper (unique_ptr) is not suited for some required operations like ownership acquisition from C code. Fix constructing properties that only have the "set" method. Fix translation of non-const parameters. Modified Makefiles to allow proper inclusion of evas_cxx headers required by some tests and examples. Move one auxiliary function to another reader to make it more accessible. @feature Reviewers: felipealmeida, q66, cedric Subscribers: cedric Differential Revision: https://phab.enlightenment.org/D2752
2015-06-11eolian: remove support for old event doc syntaxDaniel Kolesa
2015-06-05eolian-cxx: Removed unused functionFelipe Magno de Almeida
Removed unused function and consequent warning
2015-05-22eolian: merge eo_file_parse and eot_file_parseDaniel Kolesa
2015-05-21Fix Eolian Cxx generatorDaniel Zaoui
Compilation was failing due to the changes in the Eolian library. The generator has not been updated. This patch fixes the compilation but not the tests that I let to my lovely q66.
2015-05-12eolian_cxx: Fix @beta on generated bindings for C++Vitor Sousa
2015-04-14eolain_cxx: Fix C++ support for new Eolian featuresVitor Sousa
Added optional constructor methods for C++ Eolian wrappers. Changed the interface of wrappers' main constructors. If there are optional constructor methods they should be passed as variadic template argument at the end of the constructor. To support variadic template arguments, the optional "parent" parameter is now the first parameter and there is another constructor without the "parent" parameter. Checking for @optinal and @nullable attributes instead of @nonull. Now @nonull is the default, and eina::optional is only used when @optional or @nullable attribute is specified. The names of constructor methods no longer have the class name prefixed. Added unit tests for checking the binding of optional constructors. Added new .eo file to be used in the test. Changed the generated documentation of constructors. Changed the efl::eo::inherit accordingly, to address these new features. Now the constructor methods should be explicit called in the efl::eo::inherit constructor, which will receive them via variadic template arguments. Added another constructor to efl::eo::inherit for passing the parent object. Updated some tests and examples to follow the new interface. Removed some code that is no longer necessary. Also, fix Eolian C++ support for constructing properties. fix assertion when parsing constructing properties. Now if a property is a constructing property eolian_cxx will generate a constructor method that have the property name (without the "_set" suffix).
2015-04-14eolian_cxx: Add protected methods and events to C++ wrappers and fixesVitor Sousa
Using eina::string_view in eolian generated interfaces (instead of std::string) to allow lightweight passing of both C strings and C++ std::string. Also, No longer using eina::optional in generated headers for types that already implements the concept of null state (like Eo wrappers and eina_accessor). Also fix allocating callback objects require by class methods (i.e. static) in static vectors so the memory will be freed when the programs exit. Added a new test case for testing callbacks on class methods. Moved method definitions and supplementary code from generated C++ wrappers to auxiliary header file (.eo.impl.hh) generated together with the main ".eo.hh" file. Updated Makefiles to list such files in the compilation and cleanup processes. Updated .gitignore to include these new generated files. Made general adjustments on the documentation of generated C++ wrappers Added "PREDEFINED" preprocessor macro definition in the Doxyfile.in in order to make some adjustments for better documentation in the C++ generated headers. Excluding generation of documentation for classes in the "eo_cxx" namespace (the namespace for "abstract" eolian C++ wrappers). Now generating the documentation for the events too. Hiding some auxiliary code from being documented. Some aesthetic adjustments for generated white space. Generate documentation for the main constructor of C++ wrappers and added auxiliary grammars to list parameters names.
2015-04-14eolian_cxx: Declaring all inherited events on the concrete C++ wrapperVitor Sousa
Added declaration of all inherited events on the concrete type to avoid unnecessary type conversion on event callbacks. Note that when two events happens to have the same name, only the event of the derived class is declared in the concrete class. Access to such events should be made through the base class type specification. Fix on forwarding callback object (changed std::move to std::forward). Additional line break at the end of event handling methods in the generated headers to improve readability.
2015-01-05eolian_cxx: Using eina::optional to handle parameters without @nonull propertyVitor Sousa
2015-01-05eolian_cxx: Fix compilation of inheritance from Eolian generated classesVitor Sousa
Updated the code for the "inheritance helper" functions and classes to be in conformance with the new wrapper architecture. Member variable "parents" of efl::eo::eo_class struct was split in two member variables, "ancestors" and "parents", the former containing all Eo class ancestors and the later only the direct bases. Changed all required files accordingly. Check to avoid using biding string when the parameter is @out now matches any variation of "char". Add default constructor to efl::eo::concrete in order to allow it to be NULL initialized in the "inheritance helper" classes. Removed conflicting parent_set member function in the efl::eo::inherit class. Removed the "inheritance_extension_function" generator since it is no longer used.
2015-01-05eolian_cxx: Fix "dreaded diamond" inheritance problem for C++ wrappersVitor Sousa
Solved diamond inheritance problem by completely removing inheritance in the abstract class. All ancestors are inherited directly in the concrete class. The algorithm that list the ancestors also avoid repetition. Now concrete classes define methods too. This helps referring the correct method directly by the object type (when there are methods with the same name). Moved the declaration and definition of constructor methods to the concrete class, since they should not be used in derived classes. Updated example that call "color_set". With this model, if two ancestor classes have a method with the same name, to call one of them from a derived class you must write the scoped name of the member function in the wrapper. In this case, either Evas.Object and Evas.SmartObject have a property named "color". Added "from_global" option to the full_name grammar too.
2015-01-05cxx: General C++ Eo wrapper generation improvementVitor Sousa
Using a new architecture in the generated files that simplify multiple inheritance and allows the use of interface types as parameters. No longer using a hand-crafted C++ header for eo_base.eo. This file was added to the generation process. Updated all files that are dependent in the hand-crafted eo_base C++ header. Now there is a class that contains the essentials functions of the former eo::base wrapper and that is used to create (through inheritance) the "concrete" classes for all Eo generated wrappers. No longer binding any function or property that are protected, private or legacy for now. eolian_type_instance is now a struct with general information for the whole type. Added the new header file namespace_generator.hh to hold namespace generation grammars. Separated declaration and definition of Eo wrappers methods. Referring for most objects by its full name (starting at the global namespace ::) in the generated files. Created additional helper grammars to avoid code replication. Removed a TODO comment referring to a doubt about inheritance of constructor methods. Added a TODO comment regarding memory allocation for callbacks in static member functions.
2015-01-05eolian_cxx: Fix: Using binding type for @out parameter instead of native typeVitor Sousa
No longer reverting to the native type when the parameter has "@out" direction. Added "is_out" member variable to eolian_type class. With that, generators can keep track of the direction of the parameters. Also added helper functions "type_is_out" and "type_is_complex". Created "to_native" functions in eo_cxx_interop.hh to convert binding types from C++ arguments to the actual C function arguments. Added static assertions in these functions to enforce compatibility between the binding and the native type (Required by @out parameters). Reworked the overload of the "to_c" function for eo::base derivated objects. Now there is a overload that rely in the compatibility between the native type and the wrapper, enabling a wrapper to be used as an output parameter.
2015-01-05eolian-cxx: Fixed C++ conversion for listsFelipe Magno de Almeida
Signed-off-by: Vitor Sousa <vitorsousasilva@gmail.com>
2015-01-05added new types in lookup tableLarry Jr
Signed-off-by: Vitor Sousa <vitorsousasilva@gmail.com>
2015-01-05eolian_cxx: Fix Eolian C++ generated wrapper inconsistenciesVitor Sousa
In convert.cc: Reading functions instead of implements to convert the Eolian_Class. It avoids creation of methods that do not belong to the class, in special it avoids calling the default constructor twice in the generated code. No longer generating one constructor in the C++ wrapper for each eolian class constructor, since the correct behavior demands that all constructor should be called. Now the wrappers have "constructor methods" that must be called when creating a new object. Updated test cases and examples to match the new interface. Some class constructors and some test cases have to be removed since they were based on the wrong assumption that constructors are mutually exclusive. Created new generators for forwarding parameters and for looping over the relevant parameters to the C++ wrapper executing a generic lambda. Added a TODO comment regarding the call of constructor methods of all base classes. Currently there is no base type with constructors, so this situation should be discussed more. Added a TODO comment regarding the way callback parameters are being processed.
2014-10-08eolian-cxx: Fixed pointer dereferencing for Eolian types and constant ↵Felipe Magno de Almeida
propagation for C++ eina list containers With the addition of pointer types, the eolian C++ generator now has to dereference to get the base type which might be a complex type.
2014-09-30eolian-cxx: Add Eina_Bool* to type conversion table.Savio Sena
2014-09-25eolian-cxx: Get rid of class_prefix and related code.Savio Sena
This patch fixes the use of eolian_function_full_c_name_get API also.
2014-09-16eolian-cxx: Remove warnings during release compilation.Savio Sena
2014-09-12eolian-cxx: Refactored eolian_cxx to cope with new Eolian API.Savio Sena
2014-09-12eolian-cxx: Added properties_get() wrapper.Savio Sena
Returns the list of all properties in a class.
2014-09-12eolian-cxx: Added wrappers to handle Eolian_Implements.Savio Sena
2014-09-12eolian-cxx: Added new wrappers to handle Eolian_Function.Savio Sena
function_is_constructor() and function_is_visible().
2014-09-12eolian-cxx: Added wrappers to handle Eolian_Constructor.Savio Sena
2014-09-12eolian-cxx: Make class_name() wrapper return lower-case string.Savio Sena
2014-09-12eolian-cxx: Refactored Eolian_Function functionsSavio Sena
Renamed function_type to function_op_type and added function_type with new semantics of returning if function is either regular or class-function.
2014-09-12eolian-cxx: Simply use find_replace instead of long form.Savio Sena
2014-09-12eolian-cxx: Clean-up.Savio Sena
Removed iterator_iterator, unused functions and reworded comments.
2014-08-27eolian: remove constructors section cruftDaniel Kolesa
2014-08-27eolian_cxx: very quick workaround to make tests compile again (needs fix)Daniel Kolesa
2014-08-21eolian: turn db validation into separate APIDaniel Kolesa
2014-08-21eolian: remove a bunch of pointless stringshare refs + fix in luaDaniel Kolesa
2014-08-21eolian: get rid of the data hash in Eolian_FunctionDaniel Kolesa
2014-08-21eolian: get rid of eolian_parameter_information_getDaniel Kolesa
2014-08-21eolian: API refactoringDaniel Kolesa
Remove eolian_implement_information_get. Also, fix some nasty lookup problems.
2014-08-21eolian: API refactoringDaniel Kolesa
Start getting rid of the terrible _information_get APIs, starting with events.
2014-08-08eolian-cxx: Scan all files only when explicitly requested.Savio Sena
Fix T1463
2014-07-23eolian: use libgen.h basenameDaniel Kolesa
2014-07-23eolian: use just filename (not path) for eolian_class_get_by_fileDaniel Kolesa
2014-07-23eolian: eolian_parameters_get -> eolian_function_parameters_getDaniel Kolesa
2014-07-23eolian: list_get -> get, find_by -> get_byDaniel Kolesa
2014-07-23eolian_cxx: fix migration to iteratorsDaniel Kolesa
2014-07-23Eolian: modify APIs to return iterators instead of lists.Daniel Zaoui
The change affects the C and the C++ generators.
2014-07-21eolian-cxx: Oops. Fixing function_return_is_explicit_void the right way.Savio Sena
2014-07-21eolian-cxx: Handle exclicitly void-return getters.Savio Sena
Whenever a getter explicitly defines a void return the generated code shall not convert single-parameter getters in any ways. Actually the correct approach would be to delegate all conversions to Eolian Database instead of for the generators.