summaryrefslogtreecommitdiffstats
path: root/native/src/layout/node.rs
diff options
context:
space:
mode:
Diffstat (limited to 'native/src/layout/node.rs')
-rw-r--r--native/src/layout/node.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/native/src/layout/node.rs b/native/src/layout/node.rs
index 11e93b72..a265c46a 100644
--- a/native/src/layout/node.rs
+++ b/native/src/layout/node.rs
@@ -12,7 +12,7 @@ impl Node {
///
/// [`Node`]: struct.Node.html
/// [`Size`]: ../struct.Size.html
- pub fn new(size: Size) -> Self {
+ pub const fn new(size: Size) -> Self {
Self::with_children(size, Vec::new())
}
@@ -20,7 +20,7 @@ impl Node {
///
/// [`Node`]: struct.Node.html
/// [`Size`]: ../struct.Size.html
- pub fn with_children(size: Size, children: Vec<Node>) -> Self {
+ pub const fn with_children(size: Size, children: Vec<Node>) -> Self {
Node {
bounds: Rectangle {
x: 0.0,