rustpython-bytecode -> rustpython-compiler-core

This commit is contained in:
Jeong YunWon 2022-08-22 07:34:30 +09:00
parent d60ad9be23
commit b3095c7451
11 changed files with 25 additions and 23 deletions

View file

@ -9,7 +9,7 @@ edition = "2021"
[dependencies]
rustpython-ast = { path = "../ast", features = ["unparse"] }
rustpython-bytecode = { path = "../bytecode", version = "0.1.1" }
rustpython-compiler-core = { path = "../core", version = "0.1.1" }
ahash = "0.7.6"
indexmap = "1.8.1"

View file

@ -15,10 +15,10 @@ use itertools::Itertools;
use num_complex::Complex64;
use num_traits::ToPrimitive;
use rustpython_ast as ast;
use rustpython_bytecode::{self as bytecode, CodeObject, ConstantData, Instruction};
use rustpython_compiler_core::{self as bytecode, CodeObject, ConstantData, Instruction};
use std::borrow::Cow;
pub use rustpython_bytecode::Mode;
pub use rustpython_compiler_core::Mode;
type CompileResult<T> = Result<T, CodegenError>;
@ -2698,7 +2698,7 @@ fn compile_constant(value: &ast::Constant) -> ConstantData {
mod tests {
use super::{CompileOpts, Compiler};
use crate::symboltable::SymbolTable;
use rustpython_bytecode::CodeObject;
use rustpython_compiler_core::CodeObject;
use rustpython_parser::parser;
fn compile_exec(source: &str) -> CodeObject {

View file

@ -1,5 +1,5 @@
use crate::IndexSet;
use rustpython_bytecode::{CodeFlags, CodeObject, ConstantData, Instruction, Label, Location};
use rustpython_compiler_core::{CodeFlags, CodeObject, ConstantData, Instruction, Label, Location};
pub type BlockIdx = Label;