Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Treat .c files as C headers #345

Merged
merged 1 commit into from
Jun 11, 2024
Merged

Conversation

denizzzka
Copy link

@denizzzka denizzzka commented Jun 3, 2024

(Rare but useful case)

Standards isn't prohibit directive like #include "c_file.c". But if included file is .c or .i (preprocessed file) it will allways be treated as C++ header by dpp.

I planning to use this change to ease creating bindings by adding -save-temps flag into (almost any) C build environment and then processing obtained preprocessed files by dpp - so it helps to avoid of collecting of C compilation flags and passing all of them into dpp

@denizzzka denizzzka marked this pull request as draft June 3, 2024 16:02
@denizzzka denizzzka marked this pull request as ready for review June 3, 2024 16:04
@denizzzka denizzzka changed the title Treat .c and .i files as C headers Treat .c files as C headers Jun 3, 2024
@denizzzka
Copy link
Author

.i files excluded because preprocessing of C++ files produces files with same extension

@denizzzka
Copy link
Author

Test is coming soon

@atilaneves atilaneves merged commit dc92324 into atilaneves:master Jun 11, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants