Skip to content

I know this is an old thread, but chiming in here - because _MSC_VER is defined when clang is building in msvc compatibility mode (via clang-cl), the addition of the changes in 957291343c16aa5d1ef3c54d024957f7316b110f to add [[msvc::flatten]] raises the diagnostic -Wunknown-attributes on clang-cl builds: #279

@hanickadot

Description

@hanickadot
Owner
          I know this is an old thread, but chiming in here - because _MSC_VER is defined when clang is building in msvc compatibility mode (via clang-cl), the addition of the changes in 957291343c16aa5d1ef3c54d024957f7316b110f to add `[[msvc::flatten]]` raises the diagnostic `-Wunknown-attributes` on clang-cl builds:
ctre\ctre.hpp(5598,37): fatal error: unknown attribute 'flatten' ignored [-Wunknown-attributes]
template <ctll::fixed_string input> CTRE_FLATTEN constexpr CTRE_FORCE_INLINE auto operator""_ctre() noexcept {
                                    ^~~~~~~~~~~~
ctre\ctre.hpp(1409,24): note: expanded from macro 'CTRE_FLATTEN'
#define CTRE_FLATTEN [[msvc::flatten]]

Originally posted by @remyjette in #172 (comment)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @hanickadot

        Issue actions

          I know this is an old thread, but chiming in here - because _MSC_VER is defined when clang is building in msvc compatibility mode (via clang-cl), the addition of the changes in 957291343c16aa5d1ef3c54d024957f7316b110f to add `[[msvc::flatten]]` raises the diagnostic `-Wunknown-attributes` on clang-cl builds: · Issue #279 · hanickadot/compile-time-regular-expressions