function templateRepeat(oElement, oWithControl) {
				var sList = oElement.getAttribute("list") || "",
					oBindingInfo
						= BindingParser.complexParser(sList, oScope, false, true, true, true),
					aContexts,
					oListBinding,
					sModelName,
					oNewWithControl,
					oPromise,
					sVar = oElement.getAttribute("var");

				if (sVar === "") {
					error("Missing variable name for ", oElement);
				}
				if (!oBindingInfo) {
					error("Missing binding for ", oElement);
				}
				if (oBindingInfo.functionsNotFound) {
					warn(oElement, "Function name(s)", oBindingInfo.functionsNotFound.join(", "),
						"not found");
				}

				// set up a scope for the loop variable, so to say
				oNewWithControl = new Repeat();
				oWithControl.setChild(oNewWithControl);

				// use a list binding to get an array of contexts
				oBindingInfo.mode = BindingMode.OneTime;
				oNewWithControl.bindAggregation("list", oBindingInfo);
				oListBinding = oNewWithControl.getBinding("list");
				oNewWithControl.unbindAggregation("list", true);
				sModelName = oBindingInfo.model; // added by bindAggregation
				if (!oListBinding) {
					error("Missing model '" + sModelName + "' in ", oElement);
				}
				oListBinding.enableExtendedChangeDetection();
				aContexts = oListBinding.getContexts(oBindingInfo.startIndex,
					oBindingInfo.length || /*no Model#iSizeLimit*/Infinity);
				if (!oViewInfo.sync && aContexts.dataRequested) {
					oPromise = new SyncPromise(function (resolve) {
						oListBinding.attachEventOnce("change", resolve);
					}).then(function () {
						return oListBinding.getContexts(oBindingInfo.startIndex,
							oBindingInfo.length);
					});
				} else {
					oPromise = SyncPromise.resolve(aContexts);
				}

				// set up the model for the loop variable
				sVar ??= sModelName; // default loop variable is to keep the same model
				oNewWithControl.setModel(oListBinding.getModel(), sVar);

				// the actual loop
				iNestingLevel++;
				debug(oElement, "Starting");
				return oPromise.then(function (aContexts0) {
					return stopAndGo(aContexts0, function (oContext, i) {
						var oSourceNode = (i === aContexts0.length - 1)
								? oElement
								: oElement.cloneNode(true);

						// Note: because sVar and sModelName refer to the same model instance, it
						// is OK to use sModelName's context for sVar as well (the name is not part
						// of the context!)
						oNewWithControl.setBindingContext(oContext, sVar);
						debug(oElement, sVar, "=", oContext.getPath());
						return liftChildNodes(oSourceNode, oNewWithControl, oElement);
					}).then(function () {
						debugFinished(oElement);
						iNestingLevel -= 1;
						oElement.parentNode.removeChild(oElement);
					});
				});
			}
Processes a <template:repeat> instruction.

@param {Element} oElement
  the <template:repeat> XML DOM element
@param {sap.ui.core.template._with} oWithControl
  the parent's "with" control
@returns {sap.ui.base.SyncPromise}
  A sync promise which resolves with <code>undefined</code> as soon as the loop is
  done, or is rejected with a corresponding error if visiting child nodes fails.
@throws {Error}
  If the "name" attribute has an empty value, if the "list" attribute cannot be
  parsed as a binding, or if that binding uses a model which is missing.