Hash :
fa886975
Author :
Date :
2018-01-18T19:24:54
Fix handling array constructor statements in HLSL output Array constructors that are used as a statement by themselves need to be pruned from the AST before writing HLSL output. This fixes an assert in OutputHLSL. BUG=angleproject:2307 TEST=angle_unittests Change-Id: Ib49461a4be173f3856f5a264ac0af8d818a61798 Reviewed-on: https://chromium-review.googlesource.com/874691 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
//
// Copyright (c) 2018 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// SeparateArrayConstructorStatements splits statements that are array constructors and drops all of
// their constant arguments. For example, a statement like:
// int[2](0, i++);
// Will be changed to:
// i++;
#ifndef COMPILER_TRANSLATOR_SEPARATEARRAYCONSTRUCTORSTATEMENTS_H_
#define COMPILER_TRANSLATOR_SEPARATEARRAYCONSTRUCTORSTATEMENTS_H_
namespace sh
{
class TIntermBlock;
void SeparateArrayConstructorStatements(TIntermBlock *root);
} // namespace sh
#endif // COMPILER_TRANSLATOR_SEPARATEARRAYCONSTRUCTORSTATEMENTS_H_