From 9e2135d8c5c960be8f8d5fe8e5d8088e8c644ea1 Mon Sep 17 00:00:00 2001 From: CohenArthur Date: Thu, 11 Nov 2021 12:57:28 +0100 Subject: [PATCH] interpreter: Format code --- interpreter/jinko.rs | 4 +++- interpreter/repl.rs | 3 +-- interpreter/repl/prompt.rs | 2 +- src/lib.rs | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/interpreter/jinko.rs b/interpreter/jinko.rs index 1bdbcfd8..500f8b34 100644 --- a/interpreter/jinko.rs +++ b/interpreter/jinko.rs @@ -3,7 +3,9 @@ mod args; mod repl; -use jinko::{Error, CheckedType, Context, JkInt, JkBool, JkFloat, ObjectInstance, FromObjectInstance}; +use jinko::{ + CheckedType, Context, Error, FromObjectInstance, JkBool, JkFloat, JkInt, ObjectInstance, +}; use args::Args; use repl::Repl; diff --git a/interpreter/repl.rs b/interpreter/repl.rs index c6b3a994..0a3e4c0f 100644 --- a/interpreter/repl.rs +++ b/interpreter/repl.rs @@ -7,8 +7,7 @@ use std::path::PathBuf; use jinko::{CheckedType, TypeCheck, TypeCtx}; use jinko::{ - Construct, Context, Error, FromObjectInstance, Instruction, JkConstant, - ObjectInstance, + Construct, Context, Error, FromObjectInstance, Instruction, JkConstant, ObjectInstance, }; use linefeed::{DefaultTerminal, Interface, ReadResult}; diff --git a/interpreter/repl/prompt.rs b/interpreter/repl/prompt.rs index 8bf94798..648ec4c6 100644 --- a/interpreter/repl/prompt.rs +++ b/interpreter/repl/prompt.rs @@ -1,7 +1,7 @@ //! Creates a prompt based on the context's current status -use jinko::Context; use colored::Colorize; +use jinko::Context; pub struct Prompt; diff --git a/src/lib.rs b/src/lib.rs index 095415aa..82911eb2 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -18,6 +18,6 @@ pub use error::{ErrKind, Error}; pub use indent::Indent; pub use instance::{FromObjectInstance, ObjectInstance, ToObjectInstance}; pub use instruction::{InstrKind, Instruction}; +pub use parser::{parse, Construct}; pub use typechecker::{CheckedType, TypeCheck, TypeCtx}; pub use value::{JkBool, JkChar, JkConstant, JkFloat, JkInt, JkString, Value}; -pub use parser::{parse, Construct};