INNER CODE UNIT · Rust
run
gluesql/gluesql · cli/src/lib.rs:76
fn run<T: GStore + GStoreMut + Planner>(
mut storage: T,
storage_path: Option<&Path>,
input: Option<PathBuf>,
dump: Option<PathBuf>,
) -> Result<()> {
if let Some(path) = dump {
if let Some(storage_path) = storage_path {
match path.canonicalize() {
Ok(dump_path) => assert!(
dump_path != storage_path.canonicalize()?,
"dump output path matches storage path: {}",
dump_path.display()
),
Err(error) if error.kind() == ErrorKind::NotFound => {}
Err(error) => return Err(error.into()),
}
}