Restrict use of C++ language features to bare minimum
- Dominant language
- C
- Stars
- 34
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
MACSio is almost entirely C. But, there are a few places where the keyword _mutable_ is used for members of a struct that is used in a mostly `const` setting. Also, plugins are loaded during executable load time via the use of [non-constant, static initializers which are not supported in C but are in C++](https://stackoverflow.com/questions/13785250/definition-of-global-variables-using-a-non-constant-initializer).
We should find a way to restrict all this to a single C++ source file having all other files be C code and compiled with a C compiler. Currently, we are using C++ compiler everywhere.
Alternatively, we can keep use of C++ compiler everywhere but we should then change the source file suffixes to be either `.C` or `.cxx`.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by inspecting the source tree and build configuration to locate the mutable struct members, static initializers, and compiler settings described in the issue. Determine whether the project can isolate C++ to one source file or should rename all C++ sources with .C or .cxx suffixes. Done means the chosen approach is applied consistently and the project builds successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cpp
- Domain
- build-system, compilers
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100