@SuppressWarnings("unchecked")
    public T call(Runnable task) {
        task.run();
        return (T) this;
    }
Allows calling out to arbitrary code for things like looping or
conditional writes without breaking method chaining.

@param task Method to invoke.
@return Returns this.
smithy-utils/src/main/java/software/amazon/smithy/utils/AbstractCodeWriter.java