From ce355aa55323ab0071a7a34a38408dc18336f336 Mon Sep 17 00:00:00 2001 From: Stephen Chung Date: Sat, 25 Mar 2023 17:24:05 +0800 Subject: [PATCH] More slots for boxed arrays. --- src/ast/expr.rs | 4 ++-- src/parser.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ast/expr.rs b/src/ast/expr.rs index 2f96af59..1896f0df 100644 --- a/src/ast/expr.rs +++ b/src/ast/expr.rs @@ -276,9 +276,9 @@ pub enum Expr { /// [String][ImmutableString] constant. StringConstant(ImmutableString, Position), /// An interpolated [string][ImmutableString]. - InterpolatedString(Box>, Position), + InterpolatedString(Box>, Position), /// [ expr, ... ] - Array(Box>, Position), + Array(Box>, Position), /// #{ name:expr, ... } Map( Box<(StaticVec<(Ident, Expr)>, BTreeMap)>, diff --git a/src/parser.rs b/src/parser.rs index 37c13265..d7518138 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -908,7 +908,7 @@ impl Engine { let mut settings = settings; settings.pos = eat_token(input, Token::LeftBracket); - let mut array = StaticVec::new_const(); + let mut array = FnArgsVec::new_const(); loop { const MISSING_RBRACKET: &str = "to end this array literal"; @@ -1501,7 +1501,7 @@ impl Engine { // Interpolated string Token::InterpolatedString(..) => { - let mut segments = StaticVec::::new(); + let mut segments = FnArgsVec::new_const(); let settings = settings.level_up()?; match input.next().expect(NEVER_ENDS) {