You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes projects have sources that are not C++ but need to be generated into one. But they're also not data, they're still sources, so it'd be incorrect to put them alongside assets.
An example of such could be QML code. According to the [src.layout] section it'd be incorrect to put it alongside the C++ code.
What about adding a special section for a code generation folder?
The text was updated successfully, but these errors were encountered:
I'm not sure that src.layout intends to forbid placing the qml alongside C++ code. It does only talk about C and C++, but in a polyglot environment, it makes sense to allow placing source code in other languages alongside the C or C++ sources. I've been doing this.
It also does make sense to allow different languages to be separated into different directories. Perhaps allowing different non-C++ source directories could make sense (e.g. a qml/ directory, a rust/ directory, etc.), although it might make sense to survey some polyglot projects out there before deciding what the right choice is.
I do agree, better would be to say that such use case is underspecified.
In my current projects, I use a qml/ directory alongside the src/ directory. Mixing it bloats source trees since they're not a 1 to 1 mirror of each other, but they do share the same prefix folder structure: src/company/project/... and qml/company/project/....
I'd wish about a note on that use case in the spec to remove hesitation when doing so. 🙂
Sometimes projects have sources that are not C++ but need to be generated into one. But they're also not data, they're still sources, so it'd be incorrect to put them alongside assets.
An example of such could be QML code. According to the [src.layout] section it'd be incorrect to put it alongside the C++ code.
What about adding a special section for a code generation folder?
The text was updated successfully, but these errors were encountered: