aboutsummaryrefslogtreecommitdiffstats
path: root/abstractmetabuilder.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixes AbstractMetaBuilder::fixDefaultValue method.Marcelo Lira2012-03-091-2/+0
| | | | | | | | | | For some reason if a default value given to above mentioned function is exactly "QVariant::Invalid" it is turned into "0". This is done for no apparent reason and causes the Python binding generator to produce bad source code for the QtSql module bindings. Reviewed by Luciano Wolf <luciano.wolf@openbossa.org> Reviewed by Renato Araújo <renato.filho@openbossa.org>
* Exclude signals from named arguments check test.Luciano Wolf2012-03-091-1/+1
| | | | | Reviewer: Hugo Parente Lima <hugo.lima@openbossa.org>, Marcelo Lira <marcelo.lira@openbossa.org>
* Append more details on message related to nameless arguments.Renato Filho2012-03-091-1/+1
|
* Only display warning for unnamed arguments when this argument hasRenato Filho2012-03-091-13/+6
| | | | default value.
* Fixed warning message output.Renato Filho2012-03-091-5/+14
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>, Marcelo Lira <marcelo.lira@openbossa.org>
* Enable warning for arguments without name.Renato Filho2012-03-091-0/+4
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>, Marcelo Lira <marcelo.lira@openbossa.org>
* Simplify progress message.Renato Filho2012-03-091-5/+5
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>, Hugo Parente Lima <hugo.lima@openbossa.org>
* Use qualified c++ names instead to do the topological sort.Hugo Parente Lima2012-03-091-8/+28
| | | | | | | | Not using topological sort will generate an incorrect sorting when there are two or more classes with the same name in different scopes. Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Renato Araújo <renato.araujo@openbossa.org>
* Disabled GCC optimization flags by default.Renato Filho2012-03-091-1/+1
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>, Marcelo Lira <marcelo.lira@openbossa.org>
* Implemented support to flag "since" on typesystem.Renato Filho2012-03-091-9/+36
| | | | | With this flag you can specify after which version the tag became valid.
* Remove ancient code commented out years ago.Hugo Parente Lima2012-03-091-144/+0
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Renato Araújo <renato.filho@openbossa.org>
* Comestic changes to follow our code style.Hugo Parente Lima2012-03-091-112/+111
|
* When the class is a alias for a template class, proper rename their ↵Hugo Parente Lima2012-03-091-0/+1
| | | | constructors.
* When the class is a alias for a template class, copy all properties from the ↵Hugo Parente Lima2012-03-091-0/+10
| | | | base class.
* Remove useless castType variable.Hugo Parente Lima2012-03-091-12/+1
|
* Do not add the base class as a dependency if the base class is not in the graph.Hugo Parente Lima2012-03-091-2/+4
|
* Add better error message when a cyclic type dependency is found.Hugo Parente Lima2012-03-091-1/+10
|
* Do not copy the QList, use a const reference instead.Hugo Parente Lima2012-03-091-5/+1
| | | | QList copy is cheap, because it's implicity shared, but const references are much more cheap indeed.
* Tag user added function inside namespaces as static functions.Hugo Parente Lima2012-03-091-0/+2
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Reviewer: Renato Araújo <renato.araujo@openbossa.org>
* Fixes template instanciation when the template parameter is a enum value.Hugo Parente Lima2012-03-091-47/+33
|
* Only add an enclosing class to the dependency graph if it's part of the graph.Hugo Parente Lima2012-03-091-1/+1
|
* Add EnumValueTypeEntry.Hugo Parente Lima2012-03-091-0/+13
| | | | | Enum values are in global namespace, so sometimes you need to get them from TypeDatabase, a use case for this is a template class where the template parameter is a enum value.
* Remove detection of duplicated enum values, this was implemented due to a ↵Hugo Parente Lima2012-03-091-49/+0
| | | | | | bug on boost::python which doesn't exists nowadays.
* Support 'void' argument.Lauro Neto2012-03-091-0/+8
| | | | | Reviewer: Anderson Lizardo <anderson.lizardo@openbossa.org> Reviewer: Renato Filho <renato.filho@openbossa.org>
* Do not generate bindings for global functions when the typesystem was loaded ↵Hugo Parente Lima2012-03-091-2/+2
| | | | | | | with generate=no. Reviewer: Lauro Moura <lauro.neto@openbossa.org> Reviewer: Luciano Wolf <luciano.wolf@openbossa.org>
* Add method setTypeEntry to AbstractMetaFunction.Hugo Parente Lima2012-03-091-0/+1
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Reviewer: Renato Araújo <renato.araujo@openbossa.org>
* Show a warning if a global function defined in typesystem was not found by ↵Hugo Parente Lima2012-03-091-25/+37
| | | | the parser.
* Do not create two AbstractMetaClass for every template class.Hugo Parente Lima2012-03-091-1/+5
|
* Fix class dependence in topological sort.Hugo Parente Lima2012-03-091-27/+4
| | | | | - An inner class depends on their enclosed class. - A class depends on their namespace.
* Do not set the include file on TypeEntries when the include file does not ↵Hugo Parente Lima2012-03-091-18/+23
| | | | | | exists or it's the global header.
* TypeDatabase class moved to its own header/cpp.Hugo Parente Lima2012-03-091-0/+1
|
* Added the "function" tag to ApiExtractor.Hugo Parente Lima2012-03-091-4/+15
| | | | | | | | | | | | | | | This change the behaviour of ApiExtractor regarding to global functions. All global function you want to be exported to python *need* to be especified in the type system with the function tag, otherwise they wont be exported at all. The syntax for this new tag is: <function signature="..." /> This is just the initial work for this tag, it is missign support for: - Function modifications. - Add a function overload with add-function tag.
* Removed methods includeFile and setIncludeFile from AbstractMetaAttribute.Hugo Parente Lima2012-03-091-3/+2
| | | | | | | | | | These methods were moved to AbstractMetaFunction, because they are created to store the include file of global enums and functions, but for enums, we store the include file in TypeEntry, as functions doesn't have TypeEntries, only global functions need this. Also the new version of includeFile returns a instance of Include class instead of a QString.
* Set the include file for enums.Hugo Parente Lima2012-03-091-6/+11
|
* Adds reverse operator functions to the proper classes.Marcelo Lira2012-03-091-0/+13
| | | | | | | | | | | AbstractMetaBuilder::traverseOperatorFunction does additional checks to avoid mistaken a class' reverse operator as a direct operator of another class. An unit test was added to check for this case. Reviewed by Anderson Lizardo <anderson.lizardo@openbossa.org> Reviewed by Hugo Parente <hugo.lima@openbossa.org>
* Do not add an operator function to a class from a referred type system.Marcelo Lira2012-03-091-2/+3
| | | | | | API Extractor does not add operator functions from the module being processed for generation to a class belonging to a referred module, that should not be generated.
* Value type classes now have implicit copy constructors added when needed.Marcelo Lira2012-03-091-4/+40
|
* Marks user added constructors with one argument of a custom type as explicit.Marcelo Lira2012-03-091-2/+5
| | | | This prevents the generation of undesired implicit conversions.
* Remove Boost::graph dependence from ApiExtractor by using our own codeHugo Lima2010-03-031-43/+26
| | | | for graph topological sort.
* Don't add external conversion operators that were removed on type system file.Marcelo Lira2010-03-011-0/+2
| | | | | | With tests, of course. Reviewed by Hugo Parente <hugo.lima@openbossa.org>
* Adds the AbstractMetaBuilder::setupExternalConversions(metaClass) method.Marcelo Lira2010-02-261-3/+13
| | | | | | | | The code to add the external conversion operators for a class found in another class was moved to its own function, setupExternalConversions, that is called after all classes were traversed. Not all classes are ready when fixReturnTypeOfConversionOperator(metaFunc), the method where the moved code dwelt, is called.
* Added method AbstractMetaBuilder::fixReturnTypeOfConversionOperator(func).Marcelo Lira2010-02-261-0/+24
| | | | | | | | | | The new method fixes the return type of conversion operators: they should return the target of the conversion as type and not the type of its owner class. fixReturnTypeOfConversionOperator is used in traverseFunctions. An unit test was added for this case. Note that this behaviour could be fixed in the parser. I dare you!
* Fix add-function tag when adding a global function.Hugo Lima2010-02-091-1/+1
| | | | Reviewed by Marcelo Lira <marcelo.lira@openbossa.org>
* Fix AbstractMetaFunction::implicitConversions.Hugo Lima2010-02-081-0/+1
| | | | | | | | | - Public ctors added by the user with 1 value-type parameter are always added to the implicity conversion list. - If the ctor visibility of an function was modified from public to private, the function isn't added to the result. Reviewed by Renato Araújo <renato.filho@openbossa.org>
* Allow a class to multiple inherit from various object-types.Hugo Lima2010-02-011-9/+1
| | | | Reviewed by Marcelo Lira <marcelo.lira@openbossa.org>
* Added function can be tagged as static methods.Hugo Lima2010-01-071-1/+2
| | | | Reviewed by Luciano Wolf <luciano.wolf@openbossa.org>
* Adds support for varargs in AbstractMetaArgument, AbstractMetaType and ↵Marcelo Lira2009-12-161-0/+3
| | | | | | VarargsTypeEntry. Reviewed by Hugo Parente <hugo.lima@openbossa.org>
* Adds support for module level 'add-function' tag.Marcelo Lira2009-12-161-2/+10
| | | | | | | | | The TypeDatabase now stores global added functions as well as function modifications. The AbstractMetaFunction::modifications method was improved to check for global modifications. The test suite was updated with the changes.
* Fixed support for modify args in add-function tag.renato2009-12-081-3/+27
| | | | | | Created tests. Reviewed by Hugo Lima <hugo.lima@openbossa.org>
* TypeEntries created for unknown types found in user added functionsHugo Lima2009-12-011-1/+1
| | | | | | are marked as CustomType isntead of TargetLangType. Reviewed by Marcelo Lira <marcelo.lira@openbossa.org>