mirror of
https://github.com/tursodatabase/limbo.git
synced 2025-08-04 10:08:20 +00:00
migrate to using limbo_core::Value
inside Simulator
This commit is contained in:
parent
2424b1b1c9
commit
6b58c4a33f
20 changed files with 201 additions and 286 deletions
|
@ -4,7 +4,7 @@ use limbo_sqlite3_parser::ast::{
|
|||
|
||||
use crate::{
|
||||
generation::{gen_random_text, pick, pick_index, Arbitrary, ArbitraryFrom},
|
||||
model::table::Value,
|
||||
model::table::SimValue,
|
||||
SimulatorEnv,
|
||||
};
|
||||
|
||||
|
@ -251,8 +251,8 @@ impl ArbitraryFrom<&SimulatorEnv> for ast::Literal {
|
|||
}
|
||||
|
||||
// Creates a litreal value
|
||||
impl ArbitraryFrom<&Vec<&Value>> for ast::Expr {
|
||||
fn arbitrary_from<R: rand::Rng>(rng: &mut R, values: &Vec<&Value>) -> Self {
|
||||
impl ArbitraryFrom<&Vec<&SimValue>> for ast::Expr {
|
||||
fn arbitrary_from<R: rand::Rng>(rng: &mut R, values: &Vec<&SimValue>) -> Self {
|
||||
if values.is_empty() {
|
||||
return Self::Literal(ast::Literal::Null);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue