Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes RTTI for generated class #1568

Merged
merged 2 commits into from
Feb 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/functional-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -308,11 +308,11 @@ jobs:
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
mkdir dart-sdk
pushd dart-sdk
fetch dart
pushd sdk
git fetch --tags
git checkout tags/${DART_VERSION}
gclient root
gclient config --spec 'solutions = [{"name": "sdk", "url": "https://dart.googlesource.com/sdk.git", "deps_file": "DEPS", "managed": False, "custom_deps": {},},]'
git clone --depth 1 --branch ${DART_VERSION} https://dart.googlesource.com/sdk.git
gclient sync
pushd sdk
./tools/build.py --no-goma --mode release --arch x64 create_sdk --gn-args dart_use_tcmalloc=false
mkdir -p ${DART_BIN}
pushd out/ReleaseX64/dart-sdk
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class {{>cpp/CppExportMacro}}{{>cpp/CppAttributesInline}}{{resolveName}}{{!!
}}{{#if this.parents}}: {{#this.parents}}public {{resolveName this.type "FQN"}}{{#if iter.hasNext}}, {{/if}}{{/this.parents}}{{/if}} {
public:
{{resolveName}}();
virtual ~{{resolveName}}() = 0;
virtual ~{{resolveName}}();

{{#ifPredicate "needsInnerForwardDeclarations"}}
public:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include "gluecodium/Return.h"
#include "smoke/AsyncErrorCode.h"
#include <cstdint>
#include <functional>
#include <system_error>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT AsyncClass {
public:
AsyncClass();
virtual ~AsyncClass() = 0;
virtual ~AsyncClass();


public:
virtual void async_void( std::function<void()> _result_callback, const bool input ) = 0;
virtual void async_void( const bool input ) = 0;
Expand All @@ -26,4 +32,6 @@ class _GLUECODIUM_CPP_EXPORT AsyncClass {
static void async_static( std::function<void()> _result_callback, const bool input );
static void async_static( const bool input );
};


}
Original file line number Diff line number Diff line change
@@ -1,17 +1,25 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <functional>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT AsyncRenamed {
public:
AsyncRenamed();
virtual ~AsyncRenamed() = 0;
virtual ~AsyncRenamed();


public:
virtual void callDispose( std::function<void()> _result_callback ) = 0;
virtual void callDispose( ) = 0;
};


}
Original file line number Diff line number Diff line change
@@ -1,19 +1,27 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <functional>
#include <string>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT AsyncWithSkips {
public:
AsyncWithSkips();
virtual ~AsyncWithSkips() = 0;
virtual ~AsyncWithSkips();


public:
static void make_shared_instance( const ::std::string& android_context );
static void make_shared_instance( std::function<void()> _result_callback );
static void make_shared_instance( );
};


}
Original file line number Diff line number Diff line change
@@ -1,24 +1,34 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <string>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT [[OnClass]] AttributesClass {
public:
AttributesClass();
virtual ~AttributesClass() = 0;
virtual ~AttributesClass();


public:
[[OnConstInClass]]
static const bool PI;

public:
[[OnFunctionInClass]]
virtual void very_fun( [[OnParameterInClass]] const ::std::string& param ) = 0;
[[OnPropertyInClass]]
virtual ::std::string get_prop( ) const = 0;
[[OnPropertyInClass]]
virtual void set_prop( const ::std::string& value ) = 0;

};


}
Original file line number Diff line number Diff line change
@@ -1,25 +1,35 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include "gluecodium/TypeRepository.h"
#include <string>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT [[OnInterface]] AttributesInterface {
public:
AttributesInterface();
virtual ~AttributesInterface() = 0;
virtual ~AttributesInterface();


public:
[[OnConstInInterface]]
static const bool PI;

public:
[[OnFunctionInInterface]]
virtual void very_fun( [[OnParameterInInterface]] const ::std::string& param ) = 0;
[[OnPropertyInInterface]]
virtual ::std::string get_prop( ) const = 0;
[[OnPropertyInInterface]]
virtual void set_prop( const ::std::string& value ) = 0;

};


}
Original file line number Diff line number Diff line change
@@ -1,33 +1,46 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <string>

namespace smoke {
/**
* Class comment

*/
class _GLUECODIUM_CPP_EXPORT [[OnClass]] AttributesWithComments {
public:
AttributesWithComments();
virtual ~AttributesWithComments() = 0;
virtual ~AttributesWithComments();


public:
struct _GLUECODIUM_CPP_EXPORT SomeStruct {
/**
* Field comment

*/
[[OnField]]
::std::string field = "";

SomeStruct( );
explicit SomeStruct( ::std::string field );

};

/**
* Const comment

*/
[[OnConstInClass]]
static const bool PI;

public:
/**
* Function comment
Expand All @@ -46,5 +59,8 @@ class _GLUECODIUM_CPP_EXPORT [[OnClass]] AttributesWithComments {
*/
[[OnPropertyInClass]]
virtual void set_prop( const ::std::string& value ) = 0;

};


}
Original file line number Diff line number Diff line change
@@ -1,33 +1,43 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <string>

namespace smoke {
/**
* \deprecated
* \deprecated
*/
class _GLUECODIUM_CPP_EXPORT [[OnClass]] AttributesWithDeprecated {
public:
AttributesWithDeprecated();
virtual ~AttributesWithDeprecated() = 0;
virtual ~AttributesWithDeprecated();


public:
struct _GLUECODIUM_CPP_EXPORT SomeStruct {
/**
* \deprecated
*/
[[OnField]]
::std::string field = "";

SomeStruct( );
explicit SomeStruct( ::std::string field );

};

/**
* \deprecated
*/
[[OnConstInClass]]
static const bool PI;

public:
/**
*
Expand All @@ -49,5 +59,8 @@ class _GLUECODIUM_CPP_EXPORT [[OnClass]] AttributesWithDeprecated {
*/
[[OnPropertyInClass]]
virtual void set_prop( const ::std::string& value ) = 0;

};


}
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"

namespace smoke {
class _GLUECODIUM_CPP_EXPORT MultipleAttributesCpp {
public:
MultipleAttributesCpp();
virtual ~MultipleAttributesCpp() = 0;
virtual ~MultipleAttributesCpp();


public:
[[Foo, Bar]]
virtual void no_lists2( ) = 0;
Expand All @@ -21,4 +27,6 @@ class _GLUECODIUM_CPP_EXPORT MultipleAttributesCpp {
[[Foo, Bar, Baz, Fizz]]
virtual void two_lists( ) = 0;
};


}
Original file line number Diff line number Diff line change
@@ -1,18 +1,26 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"

namespace smoke {
class _GLUECODIUM_CPP_EXPORT SpecialAttributes {
public:
SpecialAttributes();
virtual ~SpecialAttributes() = 0;
virtual ~SpecialAttributes();


public:
[[Deprecated("foo\nbar")]]
virtual void with_escaping( ) = 0;
[[HackMerm -rf *]]
virtual void with_line_break( ) = 0;
};


}
Original file line number Diff line number Diff line change
@@ -1,16 +1,22 @@
// -------------------------------------------------------------------------------------------------
//

//
// -------------------------------------------------------------------------------------------------

#pragma once

#include "gluecodium/ExportGluecodiumCpp.h"
#include <cstdint>
#include <string>

namespace smoke {
class _GLUECODIUM_CPP_EXPORT BasicTypes {
public:
BasicTypes();
virtual ~BasicTypes() = 0;
virtual ~BasicTypes();


public:
static ::std::string string_function( const ::std::string& input );
static bool bool_function( const bool input );
Expand All @@ -25,4 +31,6 @@ class _GLUECODIUM_CPP_EXPORT BasicTypes {
static uint32_t uint_function( const uint32_t input );
static uint64_t ulong_function( const uint64_t input );
};


}
Loading
Loading