Skip to content

Commit e2a5451

Browse files
committed
Patch up new line issue and update tcpp
1 parent ddfec36 commit e2a5451

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

3rdparty/tcpp

Submodule tcpp updated from c4fcff7 to d98d918

src/nbl/asset/utils/IShaderCompiler.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,15 @@ std::string IShaderCompiler::encloseWithinExtraInclGuards(std::string&& _code, u
6060
return undefs;
6161
};
6262

63+
std::string identifier = _identifier;
64+
std::replace(identifier.begin(), identifier.end(), '\\', '/');
65+
6366
return
6467
genDefs() +
6568
"\n"
6669
"#ifndef " + defBase_ + std::to_string(_maxInclusions) +
6770
"\n" +
68-
"#line 1 \"" + _identifier + "\"\n\n" +
71+
"#line 1 \"" + identifier.c_str() + "\"\n" +
6972
_code +
7073
"\n"
7174
"#endif"

0 commit comments

Comments
 (0)