From f3fe9dddb8c528b4f9955d9105908600b4a8d0c8 Mon Sep 17 00:00:00 2001 From: Tim Foley Date: Fri, 7 Jul 2017 13:34:23 -0700 Subject: Map HLSL `lerp` to GLSL `mix` - Also fix a bug in `emit.cpp` where I wasn't detecting `__intrinsic` remaps that don't include `$` (this is a byproduct of changing the string index type to be unsigned; other bugs like this may be lurking) --- source/slang/emit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/slang/emit.cpp') diff --git a/source/slang/emit.cpp b/source/slang/emit.cpp index 5d85b4d57..df74d19e4 100644 --- a/source/slang/emit.cpp +++ b/source/slang/emit.cpp @@ -1466,7 +1466,7 @@ struct EmitVisitor { auto name = getStringOrIdentifierTokenValue(targetIntrinsicModifier->definitionToken); - if(name.IndexOf('$') < 0) + if(name.IndexOf('$') == -1) { // Simple case: it is just an ordinary name, so we call it like a builtin. // -- cgit v1.2.3