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

Auto Including c++ headers in .c files #23341

Closed
1 task done
hagz0r opened this issue Jan 18, 2025 · 1 comment
Closed
1 task done

Auto Including c++ headers in .c files #23341

hagz0r opened this issue Jan 18, 2025 · 1 comment
Labels
c++ C++ programming language support c C programming language support support User support (non-defect troubleshooting, documentation, etc)

Comments

@hagz0r
Copy link

hagz0r commented Jan 18, 2025

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

When writing C code and trying to use a certain function/variable defined in C headers, Zed will auto include the C++ header, instead of C version.

Zed Version and System Specs

Zed: v0.166.0 (Zed Preview)
OS: Linux Wayland arch unknown
Memory: 14.8 GiB
Architecture: x86_64
GPU: NVIDIA GeForce RTX 4070 Laptop GPU || NVIDIA || 565.77

If applicable, add screenshots or screencasts of the incorrect state / behavior

Image

If applicable, attach your Zed.log file to this issue.

N/A

@hagz0r hagz0r added admin read bug [core label] labels Jan 18, 2025
@SomeoneToIgnore
Copy link
Contributor

See #14411 (comment) for a potential solution.

Duplicate of #14660 (talks about autocompletion, but the reason is the same — clangd by default uses C++ not C).

@notpeter notpeter added c++ C++ programming language support c C programming language support support User support (non-defect troubleshooting, documentation, etc) and removed bug [core label] triage labels Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ C++ programming language support c C programming language support support User support (non-defect troubleshooting, documentation, etc)
Projects
None yet
Development

No branches or pull requests

3 participants