summaryrefslogtreecommitdiffstats
path: root/core/callable_method_pointer.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2020-05-14 13:23:58 +0200
committerRémi Verschelde <rverschelde@gmail.com>2020-05-14 16:54:55 +0200
commit0be6d925dc3c6413bce7a3ccb49631b8e4a6e67a (patch)
treea27e497da7104dd0a64f98a04fa3067668735e91 /core/callable_method_pointer.h
parent710b34b70227becdc652b4ae027fe0ac47409642 (diff)
downloadredot-engine-0be6d925dc3c6413bce7a3ccb49631b8e4a6e67a.tar.gz
Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks
Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
Diffstat (limited to 'core/callable_method_pointer.h')
-rw-r--r--core/callable_method_pointer.h8
1 files changed, 0 insertions, 8 deletions
diff --git a/core/callable_method_pointer.h b/core/callable_method_pointer.h
index fb809c2b44..3b0503e259 100644
--- a/core/callable_method_pointer.h
+++ b/core/callable_method_pointer.h
@@ -38,7 +38,6 @@
#include "core/simple_type.h"
class CallableCustomMethodPointerBase : public CallableCustom {
-
uint32_t *comp_ptr;
uint32_t comp_size;
uint32_t h;
@@ -74,7 +73,6 @@ public:
template <class T>
struct VariantCasterAndValidate {
-
static _FORCE_INLINE_ T cast(const Variant **p_args, uint32_t p_arg_idx, Callable::CallError &r_error) {
Variant::Type argtype = GetTypeInfo<T>::VARIANT_TYPE;
if (!Variant::can_convert_strict(p_args[p_arg_idx]->get_type(), argtype)) {
@@ -89,7 +87,6 @@ struct VariantCasterAndValidate {
template <class T>
struct VariantCasterAndValidate<T &> {
-
static _FORCE_INLINE_ T cast(const Variant **p_args, uint32_t p_arg_idx, Callable::CallError &r_error) {
Variant::Type argtype = GetTypeInfo<T>::VARIANT_TYPE;
if (!Variant::can_convert_strict(p_args[p_arg_idx]->get_type(), argtype)) {
@@ -104,7 +101,6 @@ struct VariantCasterAndValidate<T &> {
template <class T>
struct VariantCasterAndValidate<const T &> {
-
static _FORCE_INLINE_ T cast(const Variant **p_args, uint32_t p_arg_idx, Callable::CallError &r_error) {
Variant::Type argtype = GetTypeInfo<T>::VARIANT_TYPE;
if (!Variant::can_convert_strict(p_args[p_arg_idx]->get_type(), argtype)) {
@@ -163,7 +159,6 @@ void call_with_variant_args(T *p_instance, void (T::*p_method)(P...), const Vari
template <class T, class... P>
class CallableCustomMethodPointer : public CallableCustomMethodPointerBase {
-
struct Data {
T *instance;
void (T::*method)(P...);
@@ -173,7 +168,6 @@ public:
virtual ObjectID get_object() const { return data.instance->get_instance_id(); }
virtual void call(const Variant **p_arguments, int p_argcount, Variant &r_return_value, Callable::CallError &r_call_error) const {
-
call_with_variant_args(data.instance, data.method, p_arguments, p_argcount, r_call_error);
}
@@ -246,7 +240,6 @@ void call_with_variant_args_ret(T *p_instance, R (T::*p_method)(P...), const Var
template <class T, class R, class... P>
class CallableCustomMethodPointerRet : public CallableCustomMethodPointerBase {
-
struct Data {
T *instance;
R(T::*method)
@@ -257,7 +250,6 @@ public:
virtual ObjectID get_object() const { return data.instance->get_instance_id(); }
virtual void call(const Variant **p_arguments, int p_argcount, Variant &r_return_value, Callable::CallError &r_call_error) const {
-
call_with_variant_args_ret(data.instance, data.method, p_arguments, p_argcount, r_return_value, r_call_error);
}