DirectXMath as a C++ module
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 需要澄清
- 活跃度
- 活跃
- 技术栈
- cpp
调研方向
Start by reading DirectXMath.h and the proposed DirectXMath.ixx contents, then inspect DirectXPackedVector.h and the mentioned SHMath, Stereo3D, and XDSP components. Done means the module structure, standard-library imports, export granularity, and Windows SDK or cppwinrt integration questions are resolved and an agreed module design is documented.
由索引模型根据 Issue 内容生成。
描述
A few months ago, I designed the winrt module for C++/WinRT. C++/WinRT depends on DirectXMath, so I hope DirectXMath can also be modularized. This would help make the winrt module cleaner and compilation faster. Thanks to the high quality of DirectXMath, modularizing it is easy, but some decisions need to be discussed.
Overall, the following changes need to be made:
- Provide a macro to disable the inclusion of all standard library headers in DirectXMath.h (for example, XM_IMPL_MODULE).
- Create the following DirectXMath.ixx:
extern "C++" is used so that when the header file and the module are used at the same time, the same functions can be merged and ODR violations can be avoided.module; #include "sal.h" #include <intrins.h> #include <cassert> export module DirectXMath; import std; #define XM_IMPL_MODULE export { extern "C++" { #include "DirectXMath.h" } }
Once the details are settled, I can implement it. Any questions are welcome.
My questions:
- I hope to avoid using C standard library headers, and instead use the suffixless headers of the C++ standard library, and complete the std:: qualification for these types. This is to avoid using the std.compact module.
- Are fine-grained exports needed?
- DirectXPackedVector.h is not in DirectXMath.h. Should it be part of DirectXMath.ixx or a separate module?
- How should SHMath, Stereo3D, and XDSP be handled?
- Can the Windows SDK package the DirectXMath module?
- 主要语言
- C++
- 星标
- 1.8k
- 派生
- 262
- 平均合并
- 3 天 12 小时
- 30 天内合并 PR
- 5
环境准备
我们还没有检查这个项目的环境配置文件。先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microsoft/DirectXMath 的其他 Issue
-
难度 3/5 1-2 天 新手友好度 58/100
microsoft/DirectXMath#346 ·
-
难度 3/5 1-2 天 新手友好度 68/100
microsoft/DirectXMath#342 ·
-
enhancement
难度 5/5 一周以上 新手友好度 25/100
microsoft/DirectXMath#328 ·
-
simplemath
难度 5/5 一周以上 新手友好度 35/100
microsoft/DirectXMath#327 · 1 条评论 ·
-
Project feedback未关闭
难度 5/5 一周以上 新手友好度 20/100
microsoft/DirectXMath#326 · 2 条评论 ·
查看 microsoft/DirectXMath 的全部 Issue
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 72/100
lxqt/qtermwidget#688 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 92/100
cpinitiative/usaco-guide#6665 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
mpfaffenberger/privateer_reimagined#658 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 85/100
microsoft/onnxruntime#33018 ·
维护者通常 2 天内回复
-
Type: bug
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 2 天内回复