summaryrefslogtreecommitdiffstats
path: root/vendor/handlebars/examples
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
commitdc0db358abe19481e475e10c32149b53370f1a1c (patch)
treeab8ce99c4b255ce46f99ef402c27916055b899ee /vendor/handlebars/examples
parentReleasing progress-linux version 1.71.1+dfsg1-2~progress7.99u1. (diff)
downloadrustc-dc0db358abe19481e475e10c32149b53370f1a1c.tar.xz
rustc-dc0db358abe19481e475e10c32149b53370f1a1c.zip
Merging upstream version 1.72.1+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'vendor/handlebars/examples')
-rw-r--r--vendor/handlebars/examples/decorator.rs6
-rw-r--r--vendor/handlebars/examples/render.rs3
-rw-r--r--vendor/handlebars/examples/render_file.rs3
3 files changed, 4 insertions, 8 deletions
diff --git a/vendor/handlebars/examples/decorator.rs b/vendor/handlebars/examples/decorator.rs
index 81aa6fe8d..6d5357ba0 100644
--- a/vendor/handlebars/examples/decorator.rs
+++ b/vendor/handlebars/examples/decorator.rs
@@ -23,8 +23,7 @@ fn format_helper(
let param = h
.param(0)
.ok_or(RenderError::new("Param 0 is required for format helper."))?;
- let rendered = format!("{} pts", param.value().render());
- out.write(rendered.as_ref())?;
+ write!(out, "{} pts", param.value().render())?;
Ok(())
}
@@ -51,8 +50,7 @@ fn format_decorator(
let param = h
.param(0)
.ok_or(RenderError::new("Param 0 is required for format helper."))?;
- let rendered = format!("{} {}", param.value().render(), suffix);
- out.write(rendered.as_ref())?;
+ write!(out, "{} {}", param.value().render(), suffix)?;
Ok(())
},
),
diff --git a/vendor/handlebars/examples/render.rs b/vendor/handlebars/examples/render.rs
index 112ec504d..a6f26d0da 100644
--- a/vendor/handlebars/examples/render.rs
+++ b/vendor/handlebars/examples/render.rs
@@ -24,8 +24,7 @@ fn format_helper(
let param = h
.param(0)
.ok_or(RenderError::new("Param 0 is required for format helper."))?;
- let rendered = format!("{} pts", param.value().render());
- out.write(rendered.as_ref())?;
+ write!(out, "{} pts", param.value().render())?;
Ok(())
}
diff --git a/vendor/handlebars/examples/render_file.rs b/vendor/handlebars/examples/render_file.rs
index 7b7599672..786308608 100644
--- a/vendor/handlebars/examples/render_file.rs
+++ b/vendor/handlebars/examples/render_file.rs
@@ -27,8 +27,7 @@ fn format_helper(
let param = h
.param(0)
.ok_or(RenderError::new("Param 0 is required for format helper."))?;
- let rendered = format!("{} pts", param.value().render());
- out.write(rendered.as_ref())?;
+ write!(out, "{} pts", param.value().render())?;
Ok(())
}