Expand StmtBlock inline size.

This commit is contained in:
Stephen Chung
2022-02-16 12:57:26 +08:00
parent 487d523e67
commit cf0660e36b
5 changed files with 28 additions and 23 deletions

View File

@@ -1,7 +1,7 @@
//! Module defining the AST (abstract syntax tree).
use super::{Expr, FnAccess, Stmt, StmtBlock, AST_OPTION_FLAGS::*};
use crate::{Dynamic, FnNamespace, Identifier, Position, StaticVec};
use super::{Expr, FnAccess, Stmt, StmtBlock, StmtBlockContainer, AST_OPTION_FLAGS::*};
use crate::{Dynamic, FnNamespace, Identifier, Position};
#[cfg(feature = "no_std")]
use std::prelude::v1::*;
use std::{
@@ -197,7 +197,7 @@ impl AST {
#[allow(dead_code)]
#[inline(always)]
#[must_use]
pub(crate) fn take_statements(&mut self) -> StaticVec<Stmt> {
pub(crate) fn take_statements(&mut self) -> StmtBlockContainer {
self.body.take_statements()
}
/// Does this [`AST`] contain script-defined functions?