1 //
2 // Copyright 2020 The ANGLE Project Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 //
6 
7 #ifndef COMPILER_TRANSLATOR_TRANSLATORMETALDIRECT_MAPVARIABLESTOMEMBERACCESS_H_
8 #define COMPILER_TRANSLATOR_TRANSLATORMETALDIRECT_MAPVARIABLESTOMEMBERACCESS_H_
9 
10 #include <functional>
11 
12 #include "common/angleutils.h"
13 #include "compiler/translator/Compiler.h"
14 
15 namespace sh
16 {
17 
18 // Maps TIntermSymbol nodes to TIntermNode nodes.
19 // The parent function of a symbol is provided to the mapping when applicable.
20 ANGLE_NO_DISCARD bool MapSymbols(
21     TCompiler &compiler,
22     TIntermBlock &root,
23     std::function<TIntermNode &(const TFunction *, TIntermSymbol &)> map);
24 
25 }  // namespace sh
26 
27 #endif  // COMPILER_TRANSLATOR_TRANSLATORMETALDIRECT_MAPVARIABLESTOMEMBERACCESS_H_
28