Revert "Improve Template::render() performance"

This reverts commit 4e8b437387.
This commit is contained in:
Kogia-sima 2020-07-25 04:00:45 +09:00
parent 383a6db3e3
commit 4fc278ecfb
1 changed files with 0 additions and 14 deletions

View File

@ -284,20 +284,6 @@ fn derive_template_impl(tokens: TokenStream) -> Result<TokenStream, syn::Error>
*buf = __sf_buf.into_string();
Ok(())
}
fn render_once(self) -> Result<String, sailfish::runtime::RenderError> {
use sailfish::runtime as __sf_rt;
static SIZE_HINT: __sf_rt::SizeHint = __sf_rt::SizeHint::new();
let mut __sf_buf = __sf_rt::Buffer::with_capacity(SIZE_HINT.get());
let #name { #field_names } = self;
include!(#output_file_string);
SIZE_HINT.update(__sf_buf.len());
Ok(__sf_buf.into_string())
}
}
};