1 // Copyright 2016 The ANGLE Project Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 // 5 // Rewrite "-float" to "0.0 - float" to work around unary minus operator on float issue on Intel Mac 6 // OSX 10.11. 7 8 #ifndef COMPILER_TRANSLATOR_TREEOPS_APPLE_REWRITEUNARYMINUSOPERATORFLOAT_H_ 9 #define COMPILER_TRANSLATOR_TREEOPS_APPLE_REWRITEUNARYMINUSOPERATORFLOAT_H_ 10 11 #include "common/angleutils.h" 12 13 namespace sh 14 { 15 class TCompiler; 16 class TIntermNode; 17 18 #if defined(ANGLE_ENABLE_GLSL) && defined(ANGLE_ENABLE_APPLE_WORKAROUNDS) 19 ANGLE_NO_DISCARD bool RewriteUnaryMinusOperatorFloat(TCompiler *compiler, TIntermNode *root); 20 #else RewriteUnaryMinusOperatorFloat(TCompiler * compiler,TIntermNode * root)21ANGLE_NO_DISCARD ANGLE_INLINE bool RewriteUnaryMinusOperatorFloat(TCompiler *compiler, 22 TIntermNode *root) 23 { 24 UNREACHABLE(); 25 return false; 26 } 27 #endif 28 29 } // namespace sh 30 31 #endif // COMPILER_TRANSLATOR_TREEOPS_APPLE_REWRITEUNARYMINUSOPERATORFLOAT_H_ 32