Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ NestedVisitEnsureCache()

void System.Xml.Xsl.IlGen.XmlILVisitor.NestedVisitEnsureCache ( QilNode nd,
Type itemStorageType )
inlineprivate

Definition at line 3031 of file XmlILVisitor.cs.

3032 {
3033 bool flag = CachesResult(nd);
3035 if (flag)
3036 {
3038 Visit(nd);
3042 {
3043 return;
3044 }
3046 {
3048 return;
3049 }
3050 _iterCurr.EnsureNoStack("$$$cacheResult");
3051 }
3053 XmlILStorageMethods xmlILStorageMethods = XmlILMethods.StorageMethods[type];
3056 if (nd.XmlType.IsSingleton)
3057 {
3059 _helper.Call(xmlILStorageMethods.SeqReuseSgl);
3061 }
3062 else
3063 {
3068 if (flag)
3069 {
3071 }
3072 else
3073 {
3074 Visit(nd);
3075 }
3083 }
3084 _iterCurr.Storage = StorageDescriptor.Local(localBuilder, itemStorageType, isCached: true);
3085 }
static readonly OpCode Stloc
Definition OpCodes.cs:429
static readonly OpCode Pop
Definition OpCodes.cs:79
static readonly OpCode Ldloc
Definition OpCodes.cs:425
LocalBuilder DeclareLocal(string name, Type type)
void EnsureItemStorageType(XmlQueryType xmlType, Type storageTypeDest)
void Visit(QilExpression qil, GenerateHelper helper, MethodInfo methRoot)

References System.Xml.Dictionary, System.Reflection.Emit.OpCodes.Ldloc, System.Xml.Xsl.IlGen.StorageDescriptor.Local(), System.Reflection.Emit.OpCodes.Pop, System.Reflection.Emit.OpCodes.Stloc, System.Xml.Xsl.IlGen.XmlILMethods.StorageMethods, and System.type.

Referenced by System.Xml.Xsl.IlGen.XmlILVisitor.VisitDocOrderDistinct(), and System.Xml.Xsl.IlGen.XmlILVisitor.VisitXsltInvokeLateBound().