Skip to content

fix: change crate name from kclvm to kcl in kclvm and its subfolders #1964

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
437 changes: 214 additions & 223 deletions kclvm/Cargo.lock

Large diffs are not rendered by default.

44 changes: 22 additions & 22 deletions kclvm/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm"
name = "kcl"
version = "0.11.2"
edition = "2021"

Expand All @@ -11,23 +11,23 @@ path = "src/lib.rs"
name = "kclvm_cli_cdylib"

[dependencies]
kclvm-api = { path = "./api" }
kclvm-cmd = { path = "./cmd" }
kclvm-ast = { path = "./ast" }
kclvm-runner = { path = "./runner" }
kclvm-parser = { path = "./parser" }
kclvm-compiler = { path = "./compiler" }
kclvm-config = { path = "./config" }
kclvm-loader = { path = "./loader" }
kclvm-runtime = { path = "./runtime" }
kclvm-sema = { path = "./sema" }
kclvm-tools = { path = "./tools" }
kclvm-version = { path = "./version" }
kclvm-error = { path = "./error" }
kclvm-evaluator = { path = "./evaluator" }
kclvm-query = { path = "./query" }
kclvm-driver = { path = "./driver" }
kclvm-primitives = { path = "./primitives" }
kcl-api = { path = "./api" }
kcl-cmd = { path = "./cmd" }
kcl-ast = { path = "./ast" }
kcl-runner = { path = "./runner" }
kcl-parser = { path = "./parser" }
kcl-compiler = { path = "./compiler" }
kcl-config = { path = "./config" }
kcl-loader = { path = "./loader" }
kcl-runtime = { path = "./runtime" }
kcl-sema = { path = "./sema" }
kcl-tools = { path = "./tools" }
kcl-version = { path = "./version" }
kcl-error = { path = "./error" }
kcl-evaluator = { path = "./evaluator" }
kcl-query = { path = "./query" }
kcl-driver = { path = "./driver" }
kcl-primitives = { path = "./primitives" }

[profile.release]
rpath = true
Expand Down Expand Up @@ -64,8 +64,8 @@ members = [

[features]
llvm = [
"kclvm-compiler/llvm",
"kclvm-runner/llvm",
"kclvm-tools/llvm",
"kclvm-api/llvm",
"kcl-compiler/llvm",
"kcl-runner/llvm",
"kcl-tools/llvm",
"kcl-api/llvm",
]
34 changes: 17 additions & 17 deletions kclvm/api/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-api"
name = "kcl-api"
version = "0.11.2"
edition = "2021"

Expand All @@ -18,22 +18,22 @@ once_cell = "1.5.2"
prost-wkt = { path = "../third-party/prost-wkt", version = "0.4.1" }
prost-wkt-types = { path = "../third-party/prost-wkt/wkt-types", version = "0.4.1" }

kclvm-runner = { path = "../runner" }
kclvm-config = { path = "../config" }
kclvm-driver = { path = "../driver" }
kclvm-error = { path = "../error" }
kclvm-parser = { path = "../parser" }
kclvm-loader = { path = "../loader" }
kclvm-sema = { path = "../sema" }
kclvm-ast = { path = "../ast" }
kclvm-ast-pretty = { path = "../ast_pretty" }
kclvm-runtime = { path = "../runtime" }
kclvm-tools = { path = "../tools" }
kclvm-query = { path = "../query" }
kclvm-version = { path = "../version" }
kcl-runner = { path = "../runner" }
kcl-config = { path = "../config" }
kcl-driver = { path = "../driver" }
kcl-error = { path = "../error" }
kcl-parser = { path = "../parser" }
kcl-loader = { path = "../loader" }
kcl-sema = { path = "../sema" }
kcl-ast = { path = "../ast" }
kcl-ast-pretty = { path = "../ast_pretty" }
kcl-runtime = { path = "../runtime" }
kcl-tools = { path = "../tools" }
kcl-query = { path = "../query" }
kcl-version = { path = "../version" }
kcl-language-server = { path = "../tools/src/LSP" }
kclvm-primitives = { path = "../primitives" }
kclvm-utils = { path = "../utils" }
kcl-primitives = { path = "../primitives" }
kcl-utils = { path = "../utils" }

[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
jsonrpc-stdio-server = "18.0.0"
Expand All @@ -48,4 +48,4 @@ prost-build = "0.11.8"
prost-wkt-build = { path = "../third-party/prost-wkt/wkt-build", version = "0.4.1" }

[features]
llvm = ["kclvm-runner/llvm"]
llvm = ["kcl-runner/llvm"]
10 changes: 5 additions & 5 deletions kclvm/ast/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-ast"
name = "kcl-ast"
version = "0.11.2"
edition = "2021"

Expand All @@ -11,11 +11,11 @@ compiler_base_span = "0.1.2"
serde = { version = "1", features = ["derive"] }
serde_json = "1.0"

kclvm-span = { path = "../span" }
kclvm-error = { path = "../error" }
kcl-span = { path = "../span" }
kcl-error = { path = "../error" }
thread_local = "1.1.7"
kclvm-utils = {path = "../utils"}
kcl-utils = {path = "../utils"}
anyhow = "1.0"

[dev-dependencies]
kclvm-parser = { path = "../parser" }
kcl-parser = { path = "../parser" }
10 changes: 5 additions & 5 deletions kclvm/ast/src/ast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@
//! in the compiler and regenerate the walker code.
//! :copyright: Copyright The KCL Authors. All rights reserved.

use kclvm_utils::path::PathPrefix;
use kcl_error::{diagnostic::Range, Position};
use kcl_utils::path::PathPrefix;
use serde::{ser::SerializeStruct, Deserialize, Serialize, Serializer};
use std::{
collections::HashMap,
Expand All @@ -47,7 +48,6 @@ use uuid;

use super::token;
use crate::{node_ref, pos::ContainsPos};
use kclvm_error::{diagnostic::Range, Position};
use std::cell::RefCell;

thread_local! {
Expand Down Expand Up @@ -210,7 +210,7 @@ impl<T> Node<T> {
}

pub fn node(node: T, (lo, hi): (Loc, Loc)) -> Self {
let filename = kclvm_utils::path::convert_windows_drive_letter(&format!(
let filename = kcl_utils::path::convert_windows_drive_letter(&format!(
"{}",
lo.file.name.prefer_remapped()
))
Expand Down Expand Up @@ -2010,7 +2010,7 @@ impl TryFrom<token::Token> for UnaryOp {
type Error = ();

fn try_from(token: token::Token) -> Result<Self, Self::Error> {
use kclvm_span::symbol::kw;
use kcl_span::symbol::kw;

match token.kind {
token::TokenKind::UnaryOp(token::UnaryOpToken::UTilde) => Ok(UnaryOp::Invert),
Expand Down Expand Up @@ -2041,7 +2041,7 @@ impl TryFrom<token::Token> for BinOrCmpOp {
type Error = ();

fn try_from(token: token::Token) -> Result<Self, Self::Error> {
use kclvm_span::symbol::kw;
use kcl_span::symbol::kw;

match token.kind {
token::TokenKind::BinOp(ot) => match ot {
Expand Down
2 changes: 1 addition & 1 deletion kclvm/ast/src/pos.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use kclvm_error::{diagnostic::Range, Position};
use kcl_error::{diagnostic::Range, Position};

use crate::ast;

Expand Down
2 changes: 1 addition & 1 deletion kclvm/ast/src/token.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pub use TokenKind::*;
pub use UnaryOpToken::*;

use compiler_base_span::{Span, DUMMY_SP};
pub use kclvm_span::symbol::{Ident, Symbol};
pub use kcl_span::symbol::{Ident, Symbol};
pub const VALID_SPACES_LENGTH: usize = 0;

#[derive(Clone, Copy, PartialEq, Debug)]
Expand Down
10 changes: 5 additions & 5 deletions kclvm/ast_pretty/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[package]
name = "kclvm-ast-pretty"
name = "kcl-ast-pretty"
version = "0.11.2"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
kclvm-error = { path = "../error" }
kclvm-ast = { path = "../ast" }
kclvm-primitives = { path = "../primitives" }
kcl-error = { path = "../error" }
kcl-ast = { path = "../ast" }
kcl-primitives = { path = "../primitives" }

fancy-regex = "0.7.1"
pretty_assertions = "1.3.0"
compiler_base_session = "0.1.3"
compiler_base_macros = "0.1.1"

[dev-dependencies]
kclvm-parser = { path = "../parser" }
kcl-parser = { path = "../parser" }
4 changes: 2 additions & 2 deletions kclvm/ast_pretty/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
use kclvm_ast::{
use kcl_ast::{
ast::{self, Module},
token::TokenKind,
walker::MutSelfTypedResultWalker,
};
use kclvm_primitives::IndexMap;
use kcl_primitives::IndexMap;
use std::collections::VecDeque;
mod node;

Expand Down
3 changes: 2 additions & 1 deletion kclvm/ast_pretty/src/node.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
use std::collections::HashSet;

use compiler_base_macros::bug;
use kclvm_ast::{
use kcl_ast::{
ast::{self, CallExpr},
token::{DelimToken, TokenKind},
walker::MutSelfTypedResultWalker,
};
use kcl_primitives::IndexMap;

use super::{Indentation, Printer};

Expand Down
20 changes: 10 additions & 10 deletions kclvm/cmd/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-cmd"
name = "kcl-cmd"
version = "0.11.2"
edition = "2021"

Expand All @@ -8,12 +8,12 @@ anyhow = "1.0"
clap = "4.3.0"
compiler_base_session = "0.1.3"

kclvm-api = {path = "../api"}
kclvm-parser = {path = "../parser"}
kclvm-runner = {path = "../runner"}
kclvm-config = {path = "../config"}
kclvm-driver = {path = "../driver"}
kclvm-runtime = {path = "../runtime"}
kclvm-tools = {path = "../tools"}
kclvm-error = {path = "../error"}
kclvm-version = {path = "../version"}
kcl-api = {path = "../api"}
kcl-parser = {path = "../parser"}
kcl-runner = {path = "../runner"}
kcl-config = {path = "../config"}
kcl-driver = {path = "../driver"}
kcl-runtime = {path = "../runtime"}
kcl-tools = {path = "../tools"}
kcl-error = {path = "../error"}
kcl-version = {path = "../version"}
12 changes: 6 additions & 6 deletions kclvm/compiler/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-compiler"
name = "kcl-compiler"
version = "0.11.2"
edition = "2021"

Expand All @@ -14,11 +14,11 @@ bitflags = "1.2.1"
once_cell = "1.5.2"
fancy-regex = "0.7.1"
unicode_names2 = "0.4"
kclvm-ast = { path = "../ast" }
kclvm-sema = { path = "../sema" }
kclvm-runtime = { path = "../runtime" }
kclvm-error = { path = "../error" }
kclvm-primitives = { path = "../primitives" }
kcl-ast = { path = "../ast" }
kcl-sema = { path = "../sema" }
kcl-runtime = { path = "../runtime" }
kcl-error = { path = "../error" }
kcl-primitives = { path = "../primitives" }

[features]
llvm = ["inkwell/target-webassembly", "inkwell/llvm12-0"]
8 changes: 4 additions & 4 deletions kclvm/config/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-config"
name = "kcl-config"
version = "0.11.2"
edition = "2021"

Expand All @@ -16,9 +16,9 @@ glob = "0.3.0"
pathdiff = "0.2.1"
anyhow = "1.0"

kclvm-version = {path = "../version"}
kclvm-utils = {path = "../utils"}
kclvm-ast = {path = "../ast"}
kcl-version = {path = "../version"}
kcl-utils = {path = "../utils"}
kcl-ast = {path = "../ast"}
dirs = "5.0.0"
md-5 = "0.8.0"
regex = "1.10.4"
Expand Down
8 changes: 4 additions & 4 deletions kclvm/config/src/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
extern crate chrono;
use super::modfile::KCL_FILE_SUFFIX;
use anyhow::Result;
use kclvm_utils::fslock::open_lock_file;
use kclvm_utils::pkgpath::{parse_external_pkg_name, rm_external_pkg_name};
use kcl_utils::fslock::open_lock_file;
use kcl_utils::pkgpath::{parse_external_pkg_name, rm_external_pkg_name};
use kcl_utils::path::PathPrefix;
use kcl_version as version;
use md5::{Digest, Md5};
use serde::{de::DeserializeOwned, Serialize};
use std::collections::HashMap;
Expand All @@ -12,8 +14,6 @@ use std::fs::{create_dir_all, File};
use std::io::{Read, Write};
use std::path::Path;

use kclvm_version as version;

const LOCK_SUFFIX: &str = ".lock";
const DEFAULT_CACHE_DIR: &str = ".kclvm/cache";
const CACHE_INFO_FILENAME: &str = "info";
Expand Down
2 changes: 1 addition & 1 deletion kclvm/config/src/modfile.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! Copyright The KCL Authors. All rights reserved.

use anyhow::Result;
use kclvm_utils::path::PathPrefix;
use kcl_utils::path::PathPrefix;
use serde::{Deserialize, Serialize};
use std::{
collections::HashMap,
Expand Down
2 changes: 1 addition & 1 deletion kclvm/config/src/vfs.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::path::Path;

use kclvm_utils::path::PathPrefix;
use kcl_utils::path::PathPrefix;

extern crate pathdiff;

Expand Down
2 changes: 1 addition & 1 deletion kclvm/config/src/workfile.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! The config for IDE/LSP workspace config file `kcl.work'

use kclvm_utils::path::PathPrefix;
use kcl_utils::path::PathPrefix;
use serde::{Deserialize, Serialize};
use std::{
collections::HashMap,
Expand Down
14 changes: 7 additions & 7 deletions kclvm/driver/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "kclvm-driver"
name = "kcl-driver"
version = "0.11.2"
edition = "2021"

Expand All @@ -8,12 +8,12 @@ edition = "2021"
[dependencies]
serde_json = "1.0.86"

kclvm-config = { path = "../config" }
kclvm-runtime = { path = "../runtime" }
kclvm-utils = { path = "../utils" }
kclvm-parser = { path = "../parser" }
kclvm-ast = { path = "../ast" }
kclvm-primitives = { path = "../primitives" }
kcl-config = { path = "../config" }
kcl-runtime = { path = "../runtime" }
kcl-utils = { path = "../utils" }
kcl-parser = { path = "../parser" }
kcl-ast = { path = "../ast" }
kcl-primitives = { path = "../primitives" }
walkdir = "2"
serde = { version = "1.0", features = ["derive"] }
anyhow = { version = "1.0.70", features = ["backtrace"] }
Expand Down
Loading
Loading