diff options
author | Jacques Lucke <jacques@blender.org> | 2022-02-04 19:18:41 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2022-02-04 19:18:56 +0300 |
commit | b4563ab2dfe1e553bfe48d50592823ff13a49692 (patch) | |
tree | a6ba60c3096070d0803ac43ea19d1b492ee68d87 /source/blender/functions/intern | |
parent | 4aeb6add6e88ad551ae47e0b8d7cb7fefef30cdb (diff) |
Cleanup: avoid generating some functions in all translation units
Every translation unit that included the modified headers generated
some extra code, even though it was not used. This adds unnecessary
compile time overhead and is annoying when investigating the
generated assembly.
Diffstat (limited to 'source/blender/functions/intern')
-rw-r--r-- | source/blender/functions/intern/field.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/source/blender/functions/intern/field.cc b/source/blender/functions/intern/field.cc index d6b83c42294..fe3041b8602 100644 --- a/source/blender/functions/intern/field.cc +++ b/source/blender/functions/intern/field.cc @@ -571,6 +571,13 @@ bool IndexFieldInput::is_equal_to(const fn::FieldNode &other) const } /* -------------------------------------------------------------------- + * FieldNode. + */ + +/* Avoid generating the destructor in every translation unit. */ +FieldNode::~FieldNode() = default; + +/* -------------------------------------------------------------------- * FieldOperation. */ @@ -581,6 +588,9 @@ FieldOperation::FieldOperation(std::shared_ptr<const MultiFunction> function, owned_function_ = std::move(function); } +/* Avoid generating the destructor in every translation unit. */ +FieldOperation::~FieldOperation() = default; + /** * Returns the field inputs used by all the provided fields. * This tries to reuse an existing #FieldInputs whenever possible to avoid copying it. @@ -655,6 +665,9 @@ FieldInput::FieldInput(const CPPType &type, std::string debug_name) field_inputs_ = std::move(field_inputs); } +/* Avoid generating the destructor in every translation unit. */ +FieldInput::~FieldInput() = default; + /* -------------------------------------------------------------------- * FieldConstant. */ |