Skip to content

Commit

Permalink
remove napi stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
OmarTawfik committed Sep 23, 2024
1 parent 84ae23f commit fabfd76
Show file tree
Hide file tree
Showing 128 changed files with 12 additions and 8,149 deletions.
3 changes: 1 addition & 2 deletions .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@
"$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json",
"access": "public",
"baseBranch": "main",
"changelog": ["./custom-changelog-generator.js", { "repo": "NomicFoundation/slang" }],
"fixed": [["@nomicfoundation/slang", "@nomicfoundation/slang-*"]]
"changelog": ["@changesets/changelog-github", { "repo": "NomicFoundation/slang" }]
}
14 changes: 0 additions & 14 deletions .changeset/custom-changelog-generator.js

This file was deleted.

1 change: 0 additions & 1 deletion .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
"ipfs",
"metaslang",
"mkdocs",
"napi",
"nomic",
"nomicfoundation",
"nonterminal",
Expand Down
9 changes: 0 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ members = [
"crates/codegen/language/macros",
"crates/codegen/language/tests",
"crates/codegen/runtime/cargo/crate",
"crates/codegen/runtime/cargo/node_addon",
"crates/codegen/runtime/cargo/wasm",
"crates/codegen/runtime/generator",
"crates/codegen/runtime/npm/package",
Expand All @@ -30,7 +29,6 @@ members = [
"crates/solidity/inputs/language",
"crates/solidity/outputs/cargo/cli",
"crates/solidity/outputs/cargo/crate",
"crates/solidity/outputs/cargo/node_addon",
"crates/solidity/outputs/cargo/tests",
"crates/solidity/outputs/cargo/wasm",
"crates/solidity/outputs/npm/package",
Expand All @@ -42,7 +40,6 @@ members = [

"crates/testlang/inputs/language",
"crates/testlang/outputs/cargo/crate",
"crates/testlang/outputs/cargo/node_addon",
"crates/testlang/outputs/cargo/tests",
"crates/testlang/outputs/cargo/wasm",
"crates/testlang/outputs/npm/package",
Expand All @@ -59,7 +56,6 @@ codegen_language_macros = { path = "crates/codegen/language/macros", version = "
codegen_language_tests = { path = "crates/codegen/language/tests", version = "0.17.0" }
codegen_runtime_cargo = { path = "crates/codegen/runtime/cargo/crate", version = "0.17.0" }
codegen_runtime_generator = { path = "crates/codegen/runtime/generator", version = "0.17.0" }
codegen_runtime_node_addon = { path = "crates/codegen/runtime/cargo/node_addon", version = "0.17.0" }
codegen_runtime_npm = { path = "crates/codegen/runtime/npm/package", version = "0.17.0" }
codegen_runtime_wasm = { path = "crates/codegen/runtime/cargo/wasm", version = "0.17.0" }
codegen_spec = { path = "crates/codegen/spec", version = "0.17.0" }
Expand All @@ -74,7 +70,6 @@ metaslang_cst = { path = "crates/metaslang/cst", version = "0.17.0" }

slang_solidity = { path = "crates/solidity/outputs/cargo/crate", version = "0.17.0" }
slang_solidity_cli = { path = "crates/solidity/outputs/cargo/cli", version = "0.17.0" }
solidity_cargo_node_addon = { path = "crates/solidity/outputs/cargo/node_addon", version = "0.17.0" }
solidity_cargo_tests = { path = "crates/solidity/outputs/cargo/tests", version = "0.17.0" }
solidity_cargo_wasm = { path = "crates/solidity/outputs/cargo/wasm", version = "0.17.0" }
solidity_language = { path = "crates/solidity/inputs/language", version = "0.17.0" }
Expand All @@ -86,7 +81,6 @@ solidity_testing_snapshots = { path = "crates/solidity/testing/snapshots", versi
solidity_testing_solc = { path = "crates/solidity/testing/solc", version = "0.17.0" }

slang_testlang = { path = "crates/testlang/outputs/cargo/crate", version = "0.17.0" }
testlang_cargo_node_addon = { path = "crates/testlang/outputs/cargo/node_addon", version = "0.17.0" }
testlang_cargo_tests = { path = "crates/testlang/outputs/cargo/tests", version = "0.17.0" }
testlang_cargo_wasm = { path = "crates/testlang/outputs/cargo/wasm", version = "0.17.0" }
testlang_language = { path = "crates/testlang/inputs/language", version = "0.17.0" }
Expand Down Expand Up @@ -120,9 +114,6 @@ Inflector = { version = "0.11.4" }
itertools = { version = "0.13.0" }
log = { version = "0.4.22" }
markdown = { version = "0.3.0" }
napi = { version = "2.16.9", features = ["compat-mode", "napi8", "serde-json"] }
napi-build = { version = "2.1.3" }
napi-derive = { version = "2.16.11" }
nom = { version = "7.1.3" }
num-format = { version = "0.4.4" }
once_cell = { version = "1.19.0" }
Expand Down
14 changes: 4 additions & 10 deletions crates/codegen/runtime/cargo/crate/src/runtime/cst/kinds.rs.jinja2
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
#[cfg(feature = "__private_napi_interfaces")]
use napi_derive::napi;

// This needs to stay in sync with the wit-bindgen output
{# This needs to stay in sync with the wit-bindgen output #}
{% if model.kinds.nonterminal_kinds|length <= 256 %} #[repr(u8)] {% else %} #[repr(u16)] {% endif %}
#[derive(
Debug,
Expand All @@ -16,8 +13,7 @@ use napi_derive::napi;
strum_macros::EnumString,
strum_macros::IntoStaticStr,
)]
#[cfg_attr(feature = "__private_napi_interfaces", /* derives `Clone` and `Copy` */ napi(string_enum, namespace = "cst"))]
#[cfg_attr(not(feature = "__private_napi_interfaces"), derive(Clone, Copy))]
#[derive(Clone, Copy)]
pub enum NonterminalKind {
{%- if rendering_in_stubs -%}
Stub1,
Expand Down Expand Up @@ -49,8 +45,7 @@ impl crate::cst::NonterminalKindExtensions for NonterminalKind {}
strum_macros::IntoStaticStr,
)]
#[strum(serialize_all = "snake_case")]
#[cfg_attr(feature = "__private_napi_interfaces", /* derives `Clone` and `Copy` */ napi(string_enum, namespace = "cst"))]
#[cfg_attr(not(feature = "__private_napi_interfaces"), derive(Clone, Copy))]
#[derive(Clone, Copy)]
pub enum EdgeLabel {
// Built-in:
{% for label in model.kinds.built_in_labels -%}
Expand Down Expand Up @@ -86,8 +81,7 @@ impl crate::cst::EdgeLabelExtensions for EdgeLabel {}
strum_macros::EnumString,
strum_macros::IntoStaticStr,
)]
#[cfg_attr(feature = "__private_napi_interfaces", /* derives `Clone` and `Copy` */ napi(string_enum, namespace = "cst"))]
#[cfg_attr(not(feature = "__private_napi_interfaces"), derive(Clone, Copy))]
#[derive(Clone, Copy)]
#[allow(clippy::upper_case_acronyms)]
pub enum TerminalKind {
// Built-in:
Expand Down
11 changes: 2 additions & 9 deletions crates/codegen/runtime/cargo/crate/src/runtime/mod.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
#[cfg(feature = "__experimental_bindings_api")]
pub mod bindings;
pub mod cst;
pub mod diagnostic;
pub mod parser;

#[cfg(feature = "__experimental_bindings_api")]
pub mod bindings;

#[cfg(feature = "__private_napi_interfaces")]
pub mod napi_interface;

#[cfg(feature = "__private_wit_bindings")]
pub mod wit;

This file was deleted.

Loading

0 comments on commit fabfd76

Please sign in to comment.