Hash :
a2d98141
Author :
Date :
2017-12-15T14:18:55
Fix allowing non-constant ternary global initializer Check the qualifier of a node resulting from the folding of a ternary node correctly. The folded node might even be a TIntermConstantUnion with a non-constant qualifier. BUG=angleproject:2285 TEST=angle_unittests Change-Id: I74516e44ce9d78bc54093a5b58d14cf33a57e6e5 Reviewed-on: https://chromium-review.googlesource.com/829138 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
//
// Copyright (c) 2002-2015 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.
//
#ifndef COMPILER_TRANSLATOR_VALIDATEGLOBALINITIALIZER_H_
#define COMPILER_TRANSLATOR_VALIDATEGLOBALINITIALIZER_H_
namespace sh
{
class TIntermTyped;
// Returns true if the initializer is valid.
bool ValidateGlobalInitializer(TIntermTyped *initializer, int shaderVersion, bool *warning);
} // namespace sh
#endif // COMPILER_TRANSLATOR_VALIDATEGLOBALINITIALIZER_H_