~mmach/netext73/glslang

« back to all changes in this revision

Viewing changes to glslang/MachineIndependent/Intermediate.cpp

  • Committer: mmach
  • Date: 2020-06-26 11:53:31 UTC
  • Revision ID: netbit73@gmail.com-20200626115331-ehli1t1eumesytz1
8.13

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
//
2
2
// Copyright (C) 2002-2005  3Dlabs Inc. Ltd.
3
3
// Copyright (C) 2012-2015 LunarG, Inc.
4
 
// Copyright (C) 2015-2018 Google, Inc.
 
4
// Copyright (C) 2015-2020 Google, Inc.
5
5
// Copyright (C) 2017 ARM Limited.
6
6
//
7
7
// All rights reserved.
538
538
        return false;
539
539
    case EbtAtomicUint:
540
540
    case EbtSampler:
541
 
    case EbtAccStructNV:
 
541
    case EbtAccStruct:
542
542
        // opaque types can be passed to functions
543
543
        if (op == EOpFunction)
544
544
            break;
2774
2774
    case EShTexSampTransUpgradeTextureRemoveSampler:
2775
2775
        performTextureUpgradeAndSamplerRemovalTransformation(root);
2776
2776
        break;
 
2777
    case EShTexSampTransCount:
 
2778
        assert(0);
 
2779
        break;
2777
2780
    }
2778
2781
#endif
2779
2782
 
3234
3237
 
3235
3238
            return false;
3236
3239
        break;
3237
 
 
3238
3240
    default:
 
3241
        // HLSL uses this path for initial function signature finding for built-ins
 
3242
        // taking a single argument, which generally don't participate in
 
3243
        // operator-based type promotion (type conversion will occur later).
 
3244
        // For now, scalar argument cases are relying on the setType() call below.
 
3245
        if (getSource() == EShSourceHlsl)
 
3246
            break;
 
3247
 
 
3248
        // GLSL only allows integer arguments for the cases identified above in the
 
3249
        // case statements.
3239
3250
        if (operand->getBasicType() != EbtFloat)
3240
 
 
3241
3251
            return false;
3242
3252
    }
3243
3253