From f3d70425fa339a0d8f39b920235c98280d250bbb Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Fri, 29 May 2020 08:36:10 -0400 Subject: Feature/ast syntax standard (#1360) * Small improvements to documentation and code around DiagnosticSink * Made methods/functions in slang-syntax.h be lowerCamel Removed some commented out source (was placed elsewhere in code) * Making AST related methods and function lowerCamel. Made IsLeftValue -> isLeftValue. --- source/slang/slang-check-shader.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'source/slang/slang-check-shader.cpp') diff --git a/source/slang/slang-check-shader.cpp b/source/slang/slang-check-shader.cpp index a037218f9..80860074d 100644 --- a/source/slang/slang-check-shader.cpp +++ b/source/slang/slang-check-shader.cpp @@ -95,7 +95,7 @@ namespace Slang // A structure type should recursively introduce // existential slots for its fields. // - for( auto fieldDeclRef : GetFields(structDeclRef, MemberFilterStyle::Instance) ) + for( auto fieldDeclRef : getFields(structDeclRef, MemberFilterStyle::Instance) ) { _collectExistentialSpecializationParamsRec( astBuilder, @@ -118,7 +118,7 @@ namespace Slang _collectExistentialSpecializationParamsRec( astBuilder, ioSpecializationParams, - GetType(astBuilder, paramDeclRef), + getType(astBuilder, paramDeclRef), paramDeclRef.getLoc()); } @@ -200,7 +200,7 @@ namespace Slang // if( auto funcDeclRef = getFuncDeclRef() ) { - for( auto paramDeclRef : GetParameters(funcDeclRef) ) + for( auto paramDeclRef : getParameters(funcDeclRef) ) { ShaderParamInfo shaderParamInfo; shaderParamInfo.paramDeclRef = paramDeclRef; @@ -1019,7 +1019,7 @@ namespace Slang sink->diagnose(genericTypeParamDecl, Diagnostics::cannotSpecializeGlobalGenericToAnotherGenericParam, genericTypeParamDecl->getName(), - argGenericParamDeclRef.GetName()); + argGenericParamDeclRef.getName()); continue; } } @@ -1035,7 +1035,7 @@ namespace Slang for(auto constraintDecl : genericTypeParamDecl->getMembersOfType()) { // Get the type that the constraint is enforcing conformance to - auto interfaceType = GetSup(getLinkage()->getASTBuilder(), DeclRef(constraintDecl, nullptr)); + auto interfaceType = getSup(getLinkage()->getASTBuilder(), DeclRef(constraintDecl, nullptr)); // Use our semantic-checking logic to search for a witness to the required conformance auto witness = visitor.tryGetSubtypeWitness(argType, interfaceType); @@ -1172,7 +1172,7 @@ namespace Slang // the semantic checking machinery to expand out // the rest of the arguments via inference... - auto genericDeclRef = m_funcDeclRef.GetParent().as(); + auto genericDeclRef = m_funcDeclRef.getParent().as(); SLANG_ASSERT(genericDeclRef); // otherwise we wouldn't have generic parameters RefPtr genericSubst = getLinkage()->getASTBuilder()->create(); @@ -1195,8 +1195,8 @@ namespace Slang ASTBuilder* astBuilder = getLinkage()->getASTBuilder(); - auto sub = GetSub(astBuilder, constraintDeclRef); - auto sup = GetSup(astBuilder, constraintDeclRef); + auto sub = getSub(astBuilder, constraintDeclRef); + auto sup = getSup(astBuilder, constraintDeclRef); auto subTypeWitness = visitor.tryGetSubtypeWitness(sub, sup); if(subTypeWitness) -- cgit v1.2.3