From 8cf274317b437717f7e114e463de0652b973841b Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Fri, 13 Jan 2017 18:06:28 +0000 Subject: Bindings: Add rules engine for typedefs Currently this is rather simple, allowing only matching typedefs by name. If we need more later, we can extend the interface. This will make it possible to add bindings for the K18n framework. --- tests/GenerateSipBindings/cpplib.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'tests/GenerateSipBindings/cpplib.h') diff --git a/tests/GenerateSipBindings/cpplib.h b/tests/GenerateSipBindings/cpplib.h index b69480ee..34167ad3 100644 --- a/tests/GenerateSipBindings/cpplib.h +++ b/tests/GenerateSipBindings/cpplib.h @@ -128,8 +128,24 @@ qreal useEnum(MyFlags flags = EnumValueOne); int customMethod(QList const& nums); +typedef QString(*TagFormatter)(const QStringList &languages, + const QString &tagName, + const QHash &attributes, + const QString &text, + const QStringList &tagPath, + SomeNS::MyFlagType format); + } +class TypedefUser +{ +public: + + void setTagPattern(const QString &tagName, + SomeNS::TagFormatter formatter = NULL, + int leadingNewlines = 0); +}; + int anotherCustomMethod(QList const& nums); enum __attribute__((visibility("default"))) EnumWithAttributes { -- cgit v1.2.1