Map<String, Object> defaultEncodeAs = gspTagLibraryLookup.getEncodeAsForTag(namespace, tagName);
Map<String, Object> codecSettings = createCodecSettings(namespace, tagName, attrs, defaultEncodeAs);
OutputEncodingStackAttributes.Builder builder = WithCodecHelper.createOutputStackAttributesBuilder(codecSettings, webRequest.getAttributes().getGrailsApplication());
builder.topWriter(tagOutput);
outputStack.push(builder.build());
Object tagLibProp = tagLib.getProperty(tagName); // retrieve tag lib and create wrapper writer
if (tagLibProp instanceof Closure) {
Closure tag = (Closure) ((Closure) tagLibProp).clone();
Object bodyResult;