summaryrefslogtreecommitdiffstats
path: root/crates
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2024-04-28 15:54:11 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2024-04-28 15:54:11 +0200
commit853b44ba5b1d64070017336c1a480256afbfd0b2 (patch)
treec1c7c5658059a980b6d0816e6348cc5ff2ca9499 /crates
parent03826bd3d1b7d9339005963bf2a53470ad5398b3 (diff)
downloadrebel-853b44ba5b1d64070017336c1a480256afbfd0b2.tar
rebel-853b44ba5b1d64070017336c1a480256afbfd0b2.zip
rebel-lang: scope: rename Context::run() to execute()
Diffstat (limited to 'crates')
-rw-r--r--crates/rebel-lang/examples/repl.rs2
-rw-r--r--crates/rebel-lang/src/scope.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crates/rebel-lang/examples/repl.rs b/crates/rebel-lang/examples/repl.rs
index 4554486..a07c802 100644
--- a/crates/rebel-lang/examples/repl.rs
+++ b/crates/rebel-lang/examples/repl.rs
@@ -98,7 +98,7 @@ fn main() {
continue;
}
- let value = match ctx.run(&stmt) {
+ let value = match ctx.execute(&stmt) {
Ok(value) => value,
Err(err) => {
println!("Eval error: {err:?}");
diff --git a/crates/rebel-lang/src/scope.rs b/crates/rebel-lang/src/scope.rs
index 1d574b3..420c88f 100644
--- a/crates/rebel-lang/src/scope.rs
+++ b/crates/rebel-lang/src/scope.rs
@@ -15,7 +15,7 @@ pub struct Context {
}
impl Context {
- pub fn run(&mut self, stmt: &ast::BodyStmt) -> value::Result<Value> {
+ pub fn execute(&mut self, stmt: &ast::BodyStmt) -> value::Result<Value> {
match stmt {
ast::BodyStmt::Assign { dest, expr } => {
let value = Value::eval(self, expr)?;