Skip to content

Link errors with Clang 3.4 due to incorrect use of inline #14

@bmerry

Description

@bmerry

C99 has different semantics from C++ for inline functions. This causes Clang to generate link errors. See http://clang.llvm.org/compatibility.html#inline for more explanation.

The simplest fix is probably to change the inline functions to static inline. Alternatively, the inline functions in clu.h could have out-of-line implementations in clu_runtime.c - but that would need some verification to check that this works under all the flavours of inlining (C99, gnu89, C++, MSVC's not-quite-C compiler).

Note that this affects both clu.h and the code generated by clu_generator.

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

    Issue actions