summaryrefslogtreecommitdiffstats
path: root/source/slang/slang-ir-lower-generic-function.cpp
diff options
context:
space:
mode:
authorjsmall-nvidia <jsmall@nvidia.com>2023-04-25 10:43:29 -0400
committerGitHub <noreply@github.com>2023-04-25 10:43:29 -0400
commit7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0 (patch)
tree9c71955dbc956b0058b19818ca127c8132cda512 /source/slang/slang-ir-lower-generic-function.cpp
parent284cee1f246c072f190c87c8fb60c1d2181e458f (diff)
Dictionary using lowerCamel (#2835)
* #include an absolute path didn't work - because paths were taken to always be relative. * WIP lowerCamel Dictionary. * WIP more lowerCamel fixes for Dictionary. * Add/Remove/Clear * GetValue/Contains * Fix tabs in dictionary. Count -> getCount * Fix fields with caps. * Key -> key Value -> value Use m_ for members where appropriate. Use lowerCamel in linked list. * Some small fixes/improvements to Dictionary. * Kick CI.
Diffstat (limited to 'source/slang/slang-ir-lower-generic-function.cpp')
-rw-r--r--source/slang/slang-ir-lower-generic-function.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/source/slang/slang-ir-lower-generic-function.cpp b/source/slang/slang-ir-lower-generic-function.cpp
index 12be27f07..31ac7850a 100644
--- a/source/slang/slang-ir-lower-generic-function.cpp
+++ b/source/slang/slang-ir-lower-generic-function.cpp
@@ -20,7 +20,7 @@ namespace Slang
IRInst* lowerGenericFunction(IRInst* genericValue)
{
IRInst* result = nullptr;
- if (sharedContext->loweredGenericFunctions.TryGetValue(genericValue, result))
+ if (sharedContext->loweredGenericFunctions.tryGetValue(genericValue, result))
return result;
// Do not lower intrinsic functions.
if (genericValue->findDecoration<IRTargetIntrinsicDecoration>())
@@ -95,11 +95,11 @@ namespace Slang
default:
{
bool shouldDemote = false;
- if (childrenToDemote.Contains(clonedChild->getFullType()))
+ if (childrenToDemote.contains(clonedChild->getFullType()))
shouldDemote = true;
for (UInt i = 0; i < clonedChild->getOperandCount(); i++)
{
- if (childrenToDemote.Contains(clonedChild->getOperand(i)))
+ if (childrenToDemote.contains(clonedChild->getOperand(i)))
{
shouldDemote = true;
break;
@@ -197,9 +197,9 @@ namespace Slang
IRInterfaceType* maybeLowerInterfaceType(IRInterfaceType* interfaceType)
{
IRInterfaceType* loweredType = nullptr;
- if (sharedContext->loweredInterfaceTypes.TryGetValue(interfaceType, loweredType))
+ if (sharedContext->loweredInterfaceTypes.tryGetValue(interfaceType, loweredType))
return loweredType;
- if (sharedContext->mapLoweredInterfaceToOriginal.ContainsKey(interfaceType))
+ if (sharedContext->mapLoweredInterfaceToOriginal.containsKey(interfaceType))
return interfaceType;
// Do not lower intrinsic interfaces.
if (isBuiltin(interfaceType))
@@ -255,7 +255,7 @@ namespace Slang
IRCloneEnv cloneEnv;
cloneInstDecorationsAndChildren(&cloneEnv, sharedContext->module,
interfaceType, loweredType);
- sharedContext->loweredInterfaceTypes.Add(interfaceType, loweredType);
+ sharedContext->loweredInterfaceTypes.add(interfaceType, loweredType);
sharedContext->mapLoweredInterfaceToOriginal[loweredType] = interfaceType;
return loweredType;
}
@@ -371,9 +371,9 @@ namespace Slang
{
for (auto lowered : sharedContext->loweredInterfaceTypes)
{
- lowered.Key->replaceUsesWith(lowered.Value);
+ lowered.key->replaceUsesWith(lowered.value);
}
- sharedContext->mapInterfaceRequirementKeyValue.Clear();
+ sharedContext->mapInterfaceRequirementKeyValue.clear();
}
void processModule()
@@ -385,7 +385,7 @@ namespace Slang
IRInst* inst = sharedContext->workList.getLast();
sharedContext->workList.removeLast();
- sharedContext->workListSet.Remove(inst);
+ sharedContext->workListSet.remove(inst);
processInst(inst);