2023-08-24 15:34:51 -07:00
|
|
|
//! Functions implemented for language execution.
|
|
|
|
|
2024-07-16 07:45:43 -05:00
|
|
|
pub mod args;
|
2024-09-14 00:10:17 -04:00
|
|
|
pub mod array;
|
2024-07-26 15:14:51 -04:00
|
|
|
pub mod assert;
|
2024-06-17 12:13:19 -07:00
|
|
|
pub mod chamfer;
|
2024-07-25 21:18:52 -04:00
|
|
|
pub mod convert;
|
2023-08-28 14:58:24 -07:00
|
|
|
pub mod extrude;
|
2024-03-05 11:52:45 -08:00
|
|
|
pub mod fillet;
|
2024-03-25 17:07:53 -07:00
|
|
|
pub mod helix;
|
2024-02-12 12:18:37 -08:00
|
|
|
pub mod import;
|
2023-11-09 09:58:20 -06:00
|
|
|
pub mod kcl_stdlib;
|
2024-09-04 14:34:33 -07:00
|
|
|
pub mod loft;
|
2023-09-13 15:09:07 -07:00
|
|
|
pub mod math;
|
2024-09-25 16:12:18 -07:00
|
|
|
pub mod mirror;
|
2024-02-11 15:08:54 -08:00
|
|
|
pub mod patterns;
|
2024-09-04 14:34:33 -07:00
|
|
|
pub mod planes;
|
2024-07-28 22:45:40 -07:00
|
|
|
pub mod polar;
|
2024-03-26 19:07:16 -07:00
|
|
|
pub mod revolve;
|
2023-08-28 14:58:24 -07:00
|
|
|
pub mod segment;
|
2023-11-09 09:58:20 -06:00
|
|
|
pub mod shapes;
|
2024-06-17 13:10:40 -07:00
|
|
|
pub mod shell;
|
2023-08-28 14:58:24 -07:00
|
|
|
pub mod sketch;
|
2024-04-23 15:59:12 -07:00
|
|
|
pub mod types;
|
2024-08-21 12:12:56 -07:00
|
|
|
pub mod units;
|
2023-08-28 14:58:24 -07:00
|
|
|
pub mod utils;
|
2023-08-24 15:34:51 -07:00
|
|
|
|
|
|
|
use std::collections::HashMap;
|
|
|
|
|
2023-08-25 13:41:04 -07:00
|
|
|
use anyhow::Result;
|
2024-07-29 13:18:55 -07:00
|
|
|
pub use args::Args;
|
2023-08-25 13:41:04 -07:00
|
|
|
use derive_docs::stdlib;
|
2023-11-08 20:23:59 -06:00
|
|
|
use lazy_static::lazy_static;
|
2023-08-25 13:41:04 -07:00
|
|
|
use parse_display::{Display, FromStr};
|
|
|
|
use schemars::JsonSchema;
|
|
|
|
use serde::{Deserialize, Serialize};
|
|
|
|
|
2023-08-24 15:34:51 -07:00
|
|
|
use crate::{
|
2024-07-16 07:45:43 -05:00
|
|
|
ast::types::FunctionExpression,
|
2023-11-08 20:23:59 -06:00
|
|
|
docs::StdLibFn,
|
2024-07-16 07:45:43 -05:00
|
|
|
errors::KclError,
|
2024-09-23 22:42:51 +10:00
|
|
|
executor::{ExecState, KclValue, ProgramMemory},
|
2024-07-16 07:45:43 -05:00
|
|
|
std::kcl_stdlib::KclStdLibFn,
|
2023-08-24 15:34:51 -07:00
|
|
|
};
|
|
|
|
|
2024-09-16 15:10:33 -04:00
|
|
|
pub type StdFn = fn(
|
|
|
|
&mut ExecState,
|
|
|
|
Args,
|
|
|
|
) -> std::pin::Pin<Box<dyn std::future::Future<Output = Result<KclValue, KclError>> + Send + '_>>;
|
2024-04-12 21:32:57 -07:00
|
|
|
|
2023-09-05 16:02:27 -07:00
|
|
|
pub type FnMap = HashMap<String, StdFn>;
|
2023-08-24 15:34:51 -07:00
|
|
|
|
2023-11-08 20:23:59 -06:00
|
|
|
lazy_static! {
|
|
|
|
static ref CORE_FNS: Vec<Box<dyn StdLibFn>> = vec![
|
|
|
|
Box::new(LegLen),
|
|
|
|
Box::new(LegAngX),
|
|
|
|
Box::new(LegAngY),
|
2024-07-25 21:18:52 -04:00
|
|
|
Box::new(crate::std::convert::Int),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::extrude::Extrude),
|
2024-11-05 14:10:35 -06:00
|
|
|
Box::new(crate::std::segment::SegEnd),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::segment::SegEndX),
|
|
|
|
Box::new(crate::std::segment::SegEndY),
|
2024-11-05 14:10:35 -06:00
|
|
|
Box::new(crate::std::segment::SegStart),
|
|
|
|
Box::new(crate::std::segment::SegStartX),
|
|
|
|
Box::new(crate::std::segment::SegStartY),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::segment::LastSegX),
|
|
|
|
Box::new(crate::std::segment::LastSegY),
|
|
|
|
Box::new(crate::std::segment::SegLen),
|
|
|
|
Box::new(crate::std::segment::SegAng),
|
|
|
|
Box::new(crate::std::segment::AngleToMatchLengthX),
|
|
|
|
Box::new(crate::std::segment::AngleToMatchLengthY),
|
2024-03-13 17:16:57 -07:00
|
|
|
Box::new(crate::std::shapes::Circle),
|
2024-10-28 20:52:51 -04:00
|
|
|
Box::new(crate::std::shapes::Polygon),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::sketch::LineTo),
|
|
|
|
Box::new(crate::std::sketch::Line),
|
|
|
|
Box::new(crate::std::sketch::XLineTo),
|
|
|
|
Box::new(crate::std::sketch::XLine),
|
|
|
|
Box::new(crate::std::sketch::YLineTo),
|
|
|
|
Box::new(crate::std::sketch::YLine),
|
|
|
|
Box::new(crate::std::sketch::AngledLineToX),
|
|
|
|
Box::new(crate::std::sketch::AngledLineToY),
|
|
|
|
Box::new(crate::std::sketch::AngledLine),
|
|
|
|
Box::new(crate::std::sketch::AngledLineOfXLength),
|
|
|
|
Box::new(crate::std::sketch::AngledLineOfYLength),
|
|
|
|
Box::new(crate::std::sketch::AngledLineThatIntersects),
|
|
|
|
Box::new(crate::std::sketch::StartSketchAt),
|
|
|
|
Box::new(crate::std::sketch::StartSketchOn),
|
|
|
|
Box::new(crate::std::sketch::StartProfileAt),
|
2024-05-21 03:44:02 -04:00
|
|
|
Box::new(crate::std::sketch::ProfileStartX),
|
|
|
|
Box::new(crate::std::sketch::ProfileStartY),
|
|
|
|
Box::new(crate::std::sketch::ProfileStart),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::sketch::Close),
|
|
|
|
Box::new(crate::std::sketch::Arc),
|
|
|
|
Box::new(crate::std::sketch::TangentialArc),
|
|
|
|
Box::new(crate::std::sketch::TangentialArcTo),
|
2024-08-30 13:44:20 -05:00
|
|
|
Box::new(crate::std::sketch::TangentialArcToRelative),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::sketch::BezierCurve),
|
|
|
|
Box::new(crate::std::sketch::Hole),
|
2024-09-25 16:12:18 -07:00
|
|
|
Box::new(crate::std::mirror::Mirror2D),
|
2024-03-12 12:54:45 -07:00
|
|
|
Box::new(crate::std::patterns::PatternLinear2D),
|
|
|
|
Box::new(crate::std::patterns::PatternLinear3D),
|
|
|
|
Box::new(crate::std::patterns::PatternCircular2D),
|
|
|
|
Box::new(crate::std::patterns::PatternCircular3D),
|
2024-06-27 22:20:51 -05:00
|
|
|
Box::new(crate::std::patterns::PatternTransform),
|
2024-09-30 20:03:28 -05:00
|
|
|
Box::new(crate::std::array::Reduce),
|
2024-10-01 08:50:23 -05:00
|
|
|
Box::new(crate::std::array::Map),
|
2024-10-28 20:52:51 -04:00
|
|
|
Box::new(crate::std::array::Push),
|
2024-06-17 12:13:19 -07:00
|
|
|
Box::new(crate::std::chamfer::Chamfer),
|
2024-03-05 11:52:45 -08:00
|
|
|
Box::new(crate::std::fillet::Fillet),
|
|
|
|
Box::new(crate::std::fillet::GetOppositeEdge),
|
|
|
|
Box::new(crate::std::fillet::GetNextAdjacentEdge),
|
|
|
|
Box::new(crate::std::fillet::GetPreviousAdjacentEdge),
|
2024-03-25 17:07:53 -07:00
|
|
|
Box::new(crate::std::helix::Helix),
|
2024-06-17 13:10:40 -07:00
|
|
|
Box::new(crate::std::shell::Shell),
|
2024-08-23 09:57:02 -07:00
|
|
|
Box::new(crate::std::shell::Hollow),
|
2024-03-26 19:07:16 -07:00
|
|
|
Box::new(crate::std::revolve::Revolve),
|
2024-09-04 14:34:33 -07:00
|
|
|
Box::new(crate::std::loft::Loft),
|
|
|
|
Box::new(crate::std::planes::OffsetPlane),
|
2024-02-12 12:18:37 -08:00
|
|
|
Box::new(crate::std::import::Import),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::math::Cos),
|
|
|
|
Box::new(crate::std::math::Sin),
|
|
|
|
Box::new(crate::std::math::Tan),
|
|
|
|
Box::new(crate::std::math::Acos),
|
|
|
|
Box::new(crate::std::math::Asin),
|
|
|
|
Box::new(crate::std::math::Atan),
|
|
|
|
Box::new(crate::std::math::Pi),
|
|
|
|
Box::new(crate::std::math::E),
|
|
|
|
Box::new(crate::std::math::Tau),
|
|
|
|
Box::new(crate::std::math::Sqrt),
|
|
|
|
Box::new(crate::std::math::Abs),
|
2024-09-26 16:00:07 -05:00
|
|
|
Box::new(crate::std::math::Rem),
|
2023-11-08 20:23:59 -06:00
|
|
|
Box::new(crate::std::math::Floor),
|
|
|
|
Box::new(crate::std::math::Ceil),
|
|
|
|
Box::new(crate::std::math::Min),
|
|
|
|
Box::new(crate::std::math::Max),
|
|
|
|
Box::new(crate::std::math::Pow),
|
|
|
|
Box::new(crate::std::math::Log),
|
|
|
|
Box::new(crate::std::math::Log2),
|
|
|
|
Box::new(crate::std::math::Log10),
|
|
|
|
Box::new(crate::std::math::Ln),
|
2024-03-13 00:33:50 -07:00
|
|
|
Box::new(crate::std::math::ToDegrees),
|
|
|
|
Box::new(crate::std::math::ToRadians),
|
2024-08-21 12:12:56 -07:00
|
|
|
Box::new(crate::std::units::Mm),
|
|
|
|
Box::new(crate::std::units::Inch),
|
|
|
|
Box::new(crate::std::units::Ft),
|
|
|
|
Box::new(crate::std::units::M),
|
|
|
|
Box::new(crate::std::units::Cm),
|
|
|
|
Box::new(crate::std::units::Yd),
|
2024-07-28 22:45:40 -07:00
|
|
|
Box::new(crate::std::polar::Polar),
|
2024-07-26 15:14:51 -04:00
|
|
|
Box::new(crate::std::assert::Assert),
|
2024-08-05 11:31:58 -05:00
|
|
|
Box::new(crate::std::assert::AssertEqual),
|
2024-07-26 15:14:51 -04:00
|
|
|
Box::new(crate::std::assert::AssertLessThan),
|
|
|
|
Box::new(crate::std::assert::AssertGreaterThan),
|
|
|
|
Box::new(crate::std::assert::AssertLessThanOrEq),
|
|
|
|
Box::new(crate::std::assert::AssertGreaterThanOrEq),
|
2023-11-08 20:23:59 -06:00
|
|
|
];
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn name_in_stdlib(name: &str) -> bool {
|
|
|
|
CORE_FNS.iter().any(|f| f.name() == name)
|
|
|
|
}
|
|
|
|
|
2024-06-24 22:39:04 -07:00
|
|
|
pub fn get_stdlib_fn(name: &str) -> Option<Box<dyn StdLibFn>> {
|
|
|
|
CORE_FNS.iter().find(|f| f.name() == name).cloned()
|
|
|
|
}
|
|
|
|
|
2023-08-25 13:41:04 -07:00
|
|
|
pub struct StdLib {
|
2023-11-09 09:58:20 -06:00
|
|
|
pub fns: HashMap<String, Box<dyn StdLibFn>>,
|
|
|
|
pub kcl_fns: HashMap<String, Box<dyn KclStdLibFn>>,
|
2023-11-08 20:23:59 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
impl std::fmt::Debug for StdLib {
|
|
|
|
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
2023-11-09 09:58:20 -06:00
|
|
|
f.debug_struct("StdLib")
|
|
|
|
.field("fns.len()", &self.fns.len())
|
|
|
|
.field("kcl_fns.len()", &self.kcl_fns.len())
|
|
|
|
.finish()
|
2023-11-08 20:23:59 -06:00
|
|
|
}
|
2023-08-25 13:41:04 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
impl StdLib {
|
|
|
|
pub fn new() -> Self {
|
2023-11-08 20:23:59 -06:00
|
|
|
let fns = CORE_FNS
|
|
|
|
.clone()
|
2023-11-07 12:12:18 -06:00
|
|
|
.into_iter()
|
|
|
|
.map(|internal_fn| (internal_fn.name(), internal_fn))
|
|
|
|
.collect();
|
2023-08-25 13:41:04 -07:00
|
|
|
|
2024-03-13 17:16:57 -07:00
|
|
|
let kcl_internal_fns: [Box<dyn KclStdLibFn>; 0] = [];
|
2023-11-09 09:58:20 -06:00
|
|
|
let kcl_fns = kcl_internal_fns
|
|
|
|
.into_iter()
|
|
|
|
.map(|internal_fn| (internal_fn.name(), internal_fn))
|
|
|
|
.collect();
|
|
|
|
|
|
|
|
Self { fns, kcl_fns }
|
2023-09-05 16:02:27 -07:00
|
|
|
}
|
|
|
|
|
2024-03-01 14:23:30 -08:00
|
|
|
// Get the combined hashmaps.
|
|
|
|
pub fn combined(&self) -> HashMap<String, Box<dyn StdLibFn>> {
|
|
|
|
let mut combined = self.fns.clone();
|
|
|
|
for (k, v) in self.kcl_fns.clone() {
|
|
|
|
combined.insert(k, v.std_lib());
|
|
|
|
}
|
|
|
|
combined
|
|
|
|
}
|
|
|
|
|
2023-11-08 20:23:59 -06:00
|
|
|
pub fn get(&self, name: &str) -> Option<Box<dyn StdLibFn>> {
|
2023-09-05 16:02:27 -07:00
|
|
|
self.fns.get(name).cloned()
|
2023-08-25 13:41:04 -07:00
|
|
|
}
|
2023-11-09 09:58:20 -06:00
|
|
|
|
|
|
|
pub fn get_kcl(&self, name: &str) -> Option<Box<dyn KclStdLibFn>> {
|
|
|
|
self.kcl_fns.get(name).cloned()
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn get_either(&self, name: &str) -> FunctionKind {
|
|
|
|
if let Some(f) = self.get(name) {
|
|
|
|
FunctionKind::Core(f)
|
|
|
|
} else if let Some(f) = self.get_kcl(name) {
|
|
|
|
FunctionKind::Std(f)
|
|
|
|
} else {
|
|
|
|
FunctionKind::UserDefined
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn contains_key(&self, key: &str) -> bool {
|
|
|
|
self.fns.contains_key(key) || self.kcl_fns.contains_key(key)
|
|
|
|
}
|
2023-08-25 13:41:04 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
impl Default for StdLib {
|
|
|
|
fn default() -> Self {
|
|
|
|
Self::new()
|
|
|
|
}
|
2023-08-24 15:34:51 -07:00
|
|
|
}
|
|
|
|
|
Remove just one enum (#1096)
# Problem
This is my proposal for fixing #1107 . I've only done it for one stdlib function, `tangentialArcTo` -- if y'all like it, I'll apply this idea to the rest of the stdlib.
Previously, if users want to put a tag on the arc, the function's parameters change type.
```
// Tag missing: first param is array
tangentialArcTo([x, y], %)
// Tag present: first param is object
tangentialArcTo({to: [x, y], tag: "myTag"}, %)
```
# Solution
My proposal in #1006 is that KCL should have optional values. This means we can change the stdlib `tangentialArcTo` function to use them. In this PR, the calls are now like
```
// Tag missing: first param is array
tangentialArcTo([x, y], %)
// Tag present: first param is array still, but we now pass a tag at the end.
tangentialArcTo([x, y], %, "myTag")
```
This adds an "option" type to KCL typesystem, but it's not really revealed to users (no KCL types are revealed to users right now, they write untyped code and only interact with types when they get type errors upon executing programs). Also adds a None type, which is the default case of the Optional enum.
2023-12-18 23:49:32 -06:00
|
|
|
#[derive(Debug)]
|
2023-11-09 09:58:20 -06:00
|
|
|
pub enum FunctionKind {
|
|
|
|
Core(Box<dyn StdLibFn>),
|
|
|
|
Std(Box<dyn KclStdLibFn>),
|
|
|
|
UserDefined,
|
|
|
|
}
|
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the length of the given leg.
|
2024-09-16 15:10:33 -04:00
|
|
|
pub async fn leg_length(_exec_state: &mut ExecState, args: Args) -> Result<KclValue, KclError> {
|
2023-08-24 15:34:51 -07:00
|
|
|
let (hypotenuse, leg) = args.get_hypotenuse_leg()?;
|
2023-08-25 13:41:04 -07:00
|
|
|
let result = inner_leg_length(hypotenuse, leg);
|
2024-11-14 17:27:19 -06:00
|
|
|
Ok(KclValue::from_number(result, vec![args.into()]))
|
2023-08-24 15:34:51 -07:00
|
|
|
}
|
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the length of the given leg.
|
2024-03-13 12:56:46 -07:00
|
|
|
///
|
|
|
|
/// ```no_run
|
|
|
|
/// legLen(5, 3)
|
|
|
|
/// ```
|
2023-08-25 13:41:04 -07:00
|
|
|
#[stdlib {
|
|
|
|
name = "legLen",
|
2024-03-26 21:28:50 -07:00
|
|
|
tags = ["utilities"],
|
2023-08-25 13:41:04 -07:00
|
|
|
}]
|
|
|
|
fn inner_leg_length(hypotenuse: f64, leg: f64) -> f64 {
|
|
|
|
(hypotenuse.powi(2) - f64::min(hypotenuse.abs(), leg.abs()).powi(2)).sqrt()
|
|
|
|
}
|
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the angle of the given leg for x.
|
2024-09-16 15:10:33 -04:00
|
|
|
pub async fn leg_angle_x(_exec_state: &mut ExecState, args: Args) -> Result<KclValue, KclError> {
|
2023-08-24 15:34:51 -07:00
|
|
|
let (hypotenuse, leg) = args.get_hypotenuse_leg()?;
|
2023-08-25 13:41:04 -07:00
|
|
|
let result = inner_leg_angle_x(hypotenuse, leg);
|
2024-11-14 17:27:19 -06:00
|
|
|
Ok(KclValue::from_number(result, vec![args.into()]))
|
2023-08-24 15:34:51 -07:00
|
|
|
}
|
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the angle of the given leg for x.
|
2024-03-13 12:56:46 -07:00
|
|
|
///
|
|
|
|
/// ```no_run
|
|
|
|
/// legAngX(5, 3)
|
|
|
|
/// ```
|
2023-08-25 13:41:04 -07:00
|
|
|
#[stdlib {
|
|
|
|
name = "legAngX",
|
2024-03-26 21:28:50 -07:00
|
|
|
tags = ["utilities"],
|
2023-08-25 13:41:04 -07:00
|
|
|
}]
|
|
|
|
fn inner_leg_angle_x(hypotenuse: f64, leg: f64) -> f64 {
|
2023-09-13 22:25:41 -06:00
|
|
|
(leg.min(hypotenuse) / hypotenuse).acos().to_degrees()
|
2023-08-25 13:41:04 -07:00
|
|
|
}
|
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the angle of the given leg for y.
|
2024-09-16 15:10:33 -04:00
|
|
|
pub async fn leg_angle_y(_exec_state: &mut ExecState, args: Args) -> Result<KclValue, KclError> {
|
2023-08-24 15:34:51 -07:00
|
|
|
let (hypotenuse, leg) = args.get_hypotenuse_leg()?;
|
2023-08-25 13:41:04 -07:00
|
|
|
let result = inner_leg_angle_y(hypotenuse, leg);
|
2024-11-14 17:27:19 -06:00
|
|
|
Ok(KclValue::from_number(result, vec![args.into()]))
|
2023-08-24 15:34:51 -07:00
|
|
|
}
|
2023-08-25 13:41:04 -07:00
|
|
|
|
2024-08-06 20:27:26 -04:00
|
|
|
/// Compute the angle of the given leg for y.
|
2024-03-13 12:56:46 -07:00
|
|
|
///
|
|
|
|
/// ```no_run
|
|
|
|
/// legAngY(5, 3)
|
|
|
|
/// ```
|
2023-08-25 13:41:04 -07:00
|
|
|
#[stdlib {
|
|
|
|
name = "legAngY",
|
2024-03-26 21:28:50 -07:00
|
|
|
tags = ["utilities"],
|
2023-08-25 13:41:04 -07:00
|
|
|
}]
|
|
|
|
fn inner_leg_angle_y(hypotenuse: f64, leg: f64) -> f64 {
|
2023-09-13 22:25:41 -06:00
|
|
|
(leg.min(hypotenuse) / hypotenuse).asin().to_degrees()
|
2023-08-25 13:41:04 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
/// The primitive types that can be used in a KCL file.
|
|
|
|
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize, JsonSchema, Display, FromStr)]
|
|
|
|
#[serde(rename_all = "lowercase")]
|
|
|
|
#[display(style = "lowercase")]
|
|
|
|
pub enum Primitive {
|
|
|
|
/// A boolean value.
|
|
|
|
Bool,
|
|
|
|
/// A number value.
|
|
|
|
Number,
|
|
|
|
/// A string value.
|
|
|
|
String,
|
|
|
|
/// A uuid value.
|
|
|
|
Uuid,
|
|
|
|
}
|
|
|
|
|
2024-09-16 15:10:33 -04:00
|
|
|
/// A closure used as an argument to a stdlib function.
|
2024-06-27 22:20:51 -05:00
|
|
|
pub struct FnAsArg<'a> {
|
2024-09-16 15:10:33 -04:00
|
|
|
pub func: Option<&'a crate::executor::MemoryFunction>,
|
2024-10-30 16:52:17 -04:00
|
|
|
pub expr: crate::ast::types::BoxNode<FunctionExpression>,
|
2024-07-22 19:43:40 -04:00
|
|
|
pub memory: Box<ProgramMemory>,
|
2024-06-27 22:20:51 -05:00
|
|
|
}
|