From 7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Tue, 25 Apr 2023 10:43:29 -0400 Subject: 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. --- source/slang/slang-options.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'source/slang/slang-options.cpp') diff --git a/source/slang/slang-options.cpp b/source/slang/slang-options.cpp index a8ac88f81..34ef0763f 100644 --- a/source/slang/slang-options.cpp +++ b/source/slang/slang-options.cpp @@ -819,7 +819,7 @@ struct OptionsParser continue; } - buf.Clear(); + buf.clear(); buf << diagnostic->id << " : "; NameConventionUtil::convert(NameStyle::Camel, UnownedStringSlice(diagnostic->name), NameConvention::LowerKabab, buf); @@ -1999,7 +1999,7 @@ struct OptionsParser continue; int targetIndex = 0; - if( !mapFormatToTargetIndex.TryGetValue(impliedFormat, targetIndex) ) + if( !mapFormatToTargetIndex.tryGetValue(impliedFormat, targetIndex) ) { targetIndex = (int) rawTargets.getCount(); @@ -2026,7 +2026,7 @@ struct OptionsParser { auto format = rawTargets[targetIndex].format; - if( mapFormatToTargetIndex.ContainsKey(format) ) + if( mapFormatToTargetIndex.containsKey(format) ) { sink->diagnose(SourceLoc(), Diagnostics::duplicateTargets, format); } @@ -2272,7 +2272,7 @@ struct OptionsParser // sink->diagnose(SourceLoc(), Diagnostics::cannotDeduceOutputFormatFromPath, rawOutput.path); } - else if( mapFormatToTargetIndex.TryGetValue(rawOutput.impliedFormat, targetIndex) ) + else if( mapFormatToTargetIndex.tryGetValue(rawOutput.impliedFormat, targetIndex) ) { rawOutput.targetIndex = targetIndex; } @@ -2330,7 +2330,7 @@ struct OptionsParser auto targetID = rawTargets[rawOutput.targetIndex].targetID; auto target = requestImpl->getLinkage()->targets[targetID]; RefPtr targetInfo; - if( !requestImpl->m_targetInfos.TryGetValue(target, targetInfo) ) + if( !requestImpl->m_targetInfos.tryGetValue(target, targetInfo) ) { targetInfo = new EndToEndCompileRequest::TargetInfo(); requestImpl->m_targetInfos[target] = targetInfo; @@ -2356,7 +2356,7 @@ struct OptionsParser auto entryPointReq = requestImpl->getFrontEndReq()->getEntryPointReqs()[entryPointID]; //String outputPath; - if (targetInfo->entryPointOutputPaths.ContainsKey(entryPointID)) + if (targetInfo->entryPointOutputPaths.containsKey(entryPointID)) { sink->diagnose(SourceLoc(), Diagnostics::duplicateOutputPathsForEntryPointAndTarget, entryPointReq->getName(), target->getTarget()); } -- cgit v1.2.3