Skip to content
This repository was archived by the owner on Feb 8, 2024. It is now read-only.
This repository was archived by the owner on Feb 8, 2024. It is now read-only.

When using compile_commands.json, the extra compile options in defaults.hpp are faulty. #182

@mcourteaux

Description

@mcourteaux

(Sorry for fuzzy title; can't figure out better words.)

On macOS, I use cmake to generate the compile_commands.json file for my project. color_coded finds this, but still appends/prepends the extra compile options found in default.hpp. This causes conflicting compile options to be submitted to the clang backend; and syntax coloring to fail due to mismatching stdlibc versions.

I disabled the default additional compile options (by patching the functions to return {};), which fixes the issue entirely. This makes sense, as the compile_commands.json database contains the exact and correct compile options. I'm not sure what the right way to go here is in general. My guess is that defaults should not be added if there is a compile_commands.json used?

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