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

Reported compiler error on OSX when BUILD_STATIC is ON #365

Open
charlietsao opened this issue Dec 6, 2023 · 0 comments
Open

Reported compiler error on OSX when BUILD_STATIC is ON #365

charlietsao opened this issue Dec 6, 2023 · 0 comments

Comments

@charlietsao
Copy link

charlietsao commented Dec 6, 2023

Error as follows when building rttr_core_lib:

In file included from /Users/hell//rttr/src/rttr/constructor.cpp:28:
In file included from /Users/hell//rttr/src/rttr/constructor.h:35:
In file included from /Users/hell//rttr/src/rttr/array_range.h:338:
In file included from /Users/hell//rttr/src/rttr/detail/impl/array_range_impl.h:33:
In file included from /Users/hell//rttr/src/rttr/type.h:34:
In file included from /Users/hell//rttr/src/rttr/filter_item.h:32:
/Users/hell//rttr/src/rttr/enum_flags.h:277:67: error: unused parameter 'v' [-Werror,-Wunused-parameter]
        RTTR_CONSTEXPR RTTR_INLINE explicit invalid_enum_flag(int v){}
                                                                  ^
In file included from /Users/hell//rttr/src/rttr/constructor.cpp:28:
In file included from /Users/hell//rttr/src/rttr/constructor.h:35:
In file included from /Users/hell//rttr/src/rttr/array_range.h:338:
In file included from /Users/hell//rttr/src/rttr/detail/impl/array_range_impl.h:33:
In file included from /Users/hell//rttr/src/rttr/type.h:1234:
In file included from /Users/hell//rttr/src/rttr/detail/type/type_impl.h:36:
In file included from /Users/hell//rttr/src/rttr/detail/type/get_create_variant_func.h:32:
In file included from /Users/hell//rttr/src/rttr/variant.h:1157:
In file included from /Users/hell//rttr/src/rttr/detail/variant/variant_impl.h:36:
In file included from /Users/hell//rttr/src/rttr/detail/variant/variant_data_policy.h:34:
In file included from /Users/hell//rttr/src/rttr/detail/variant_associative_view/variant_associative_view_creator.h:34:
In file included from /Users/hell//rttr/src/rttr/associative_mapper.h:363:
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:85:36: error: unused parameter 'itr' [-Werror,-Wunused-parameter]
    get_value(const iterator_data& itr)
                                   ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:127:29: error: unused parameter 'container' [-Werror,-Wunused-parameter]
    static void clear(void* container)
                            ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:166:36: error: unused parameter 'container' [-Werror,-Wunused-parameter]
    static std::size_t erase(void* container, argument& key)
                                   ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:166:57: error: unused parameter 'key' [-Werror,-Wunused-parameter]
    static std::size_t erase(void* container, argument& key)
                                                        ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:190:55: error: unused parameter 'key' [-Werror,-Wunused-parameter]
    static bool insert_key(void* container, argument& key, iterator_data& itr)
                                                      ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:216:61: error: unused parameter 'key' [-Werror,-Wunused-parameter]
    static bool insert_key_value(void* container, argument& key, argument& value, iterator_data& itr)
                                                            ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:216:76: error: unused parameter 'value' [-Werror,-Wunused-parameter]
    static bool insert_key_value(void* container, argument& key, argument& value, iterator_data& itr)
                                                                           ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:310:83: error: unused parameter 'key' [-Werror,-Wunused-parameter]
    static std::pair<itr_t, bool> insert_key(container_t& container, const key_t& key)
                                                                                  ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:459:39: error: unused parameter 'itr_tgt' [-Werror,-Wunused-parameter]
    static void create(iterator_data& itr_tgt, const iterator_data& src)
                                      ^
/Users/hell//rttr/src/rttr/detail/impl/associative_mapper_impl.h:459:69: error: unused parameter 'src' [-Werror,-Wunused-parameter]
    static void create(iterator_data& itr_tgt, const iterator_data& src)

-Wno-unused-parameter should be added to the function set_compiler_warnings target in utility.cmake.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant