microsoft / microsoft/DirectXShaderCompiler
DXC doesn't compile with `/Zc:preprocessor` (the new MSVC C++ conformant preprocessor)
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 3.7k
- Forks
- 900
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 44
Description
Description
DXC doesn't compile with /Zc:preprocessor build flag using MSVC.
This may explain some of our issues when trying to compile DXC with vanilla Clang (without using MSVC runtime) instead of MSVC.
Steps to Reproduce
DXC doesn't compile with /Zc:preprocessor build flag using MSVC.
Actual Behavior
Errors around the use-site of DXASSERT, its probably __VA_ARGS__ not removing the , before itself when the va-args are empty.
Environment
- DXC version: latest trunk
- Host Operating System: Windows
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by building DXC on Windows with MSVC and the /Zc:preprocessor flag, then inspect the DXASSERT use sites reported by the compiler. Check how empty VA_ARGS is handled and consider vanilla Clang compatibility; done means DXC compiles successfully with the flag.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- build-system, compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100