Commit c3fed03
fix: add HasFeatureFix.h to resolve __has_feature on MSVC
MSVC (VS 2022) does not define __has_feature, which is a Clang extension.
Assimp and other headers that use __has_feature(x) fail to compile under
MSVC without this guard.
- Add Source/RuntimeAssetImport/Public/HasFeatureFix.h with an
#ifndef __has_feature / #define __has_feature(x) 0 guard.
- Include HasFeatureFix.h in AssetLoader.cpp, AssetConstructor.cpp, and
AssetConstructorHelpers.cpp immediately after the matching header and
before any engine or assimp headers, satisfying both UHT's include-order
requirement and the need to define __has_feature before assimp pulls it.
The header is placed in Public/ so it can be used via forced-include
compiler flags (/FI) if needed in future, without requiring a namespace-
qualified path from Private code.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent c91768e commit c3fed03
4 files changed
Lines changed: 11 additions & 3 deletions
File tree
- Source/RuntimeAssetImport
- Private
- Public
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
0 commit comments