Skip to content
Merged
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
7 changes: 0 additions & 7 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ members = [
"crates/perry-ext-dotenv",
"crates/perry-ext-nanoid",
"crates/perry-ext-uuid",
"crates/perry-ext-slugify",
"crates/perry-ext-bcrypt",
"crates/perry-ext-argon2",
"crates/perry-ext-jsonwebtoken",
Expand Down Expand Up @@ -460,7 +459,6 @@ perry-ffi = { path = "crates/perry-ffi", version = "0.5.1011" }
perry-ext-dotenv = { path = "crates/perry-ext-dotenv" }
perry-ext-nanoid = { path = "crates/perry-ext-nanoid" }
perry-ext-uuid = { path = "crates/perry-ext-uuid" }
perry-ext-slugify = { path = "crates/perry-ext-slugify" }
perry-ext-bcrypt = { path = "crates/perry-ext-bcrypt" }
perry-ext-argon2 = { path = "crates/perry-ext-argon2" }
perry-ext-jsonwebtoken = { path = "crates/perry-ext-jsonwebtoken" }
Expand Down
6 changes: 4 additions & 2 deletions changelog.d/5716-native-binding-governance.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@ Defined an enforceable policy for bundled native bindings: ordinary
JavaScript and TypeScript packages now have recorded upstream-source migration
targets, native/domain integrations have external-package targets, and shared
runtime APIs have explicit retain/consolidate decisions. Release builds consume
the governed inventory, while existing compatibility shims remain bundled until
their documented migration gates pass.
the governed inventory. The first completed migration removes both native
`slugify` implementations and compiles installed `slugify@1.6.9` source through
default package routing, with a Node-parity E2E covering its full option and
extension behavior.
1 change: 0 additions & 1 deletion crates/perry-api-manifest/src/entries.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ pub const NATIVE_MODULES: &[&str] = &[
"dotenv/config", // dotenv's auto-load-on-import subpath
"jsonwebtoken", // JWT sign/verify
"nanoid", // compact URL-safe ID generation
"slugify", // string → URL slug
"validator", // string validators/sanitizers
"ethers", // Ethereum library (utils/wallet/ABI)
"mongodb", // MongoDB driver
Expand Down
33 changes: 0 additions & 33 deletions crates/perry-api-manifest/src/entries/part_1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1291,39 +1291,6 @@ pub(crate) const API_MANIFEST_PART_1: &[ApiEntry] = &[
}],
TypeSpec::String,
),
// Second arg is npm slugify's replacement-or-options overload
// (string | { replacement, lower, strict, trim }) — Any, matching
// the NA_JSV dispatch slot.
method_sig(
"slugify",
"default",
false,
None,
&[
p_str("p0"),
ParamSpec::Named {
name: "p1",
ty: TypeSpec::Any,
optional: true,
},
],
TypeSpec::String,
),
method_sig(
"slugify",
"slugify",
false,
None,
&[
p_str("p0"),
ParamSpec::Named {
name: "p1",
ty: TypeSpec::Any,
optional: true,
},
],
TypeSpec::String,
),
method_sig(
"validator",
"isEmail",
Expand Down
28 changes: 0 additions & 28 deletions crates/perry-codegen/src/lower_call/native_table/utils_crypto.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,34 +157,6 @@ pub(super) const UTILS_CRYPTO_ROWS: &[NativeModSig] = &[
args: &[NA_F64],
ret: NR_STR,
},
// ========== slugify ==========
// Second arg is npm slugify's replacement-or-options overload: a
// plain string ('_') OR an options object ({ replacement, lower,
// strict, trim }). It must cross as raw NaN-box bits (NA_JSV) so
// the runtime can distinguish the two — the old NA_STR coercion
// JSON-stringified the object and its first char '{' became the
// separator ("hello{world"). Missing arg pads to TAG_UNDEFINED →
// runtime defaults ("-" separator, no lower/strict, trim).
// "default" for `import slugify from 'slugify'; slugify(s)` (HIR emits method:"default").
// "slugify" for `import { slugify } from 'slugify'; slugify(s)` (named import).
NativeModSig {
module: "slugify",
has_receiver: false,
method: "default",
class_filter: None,
runtime: "js_slugify_with_options",
args: &[NA_STR, NA_JSV],
ret: NR_STR,
},
NativeModSig {
module: "slugify",
has_receiver: false,
method: "slugify",
class_filter: None,
runtime: "js_slugify_with_options",
args: &[NA_STR, NA_JSV],
ret: NR_STR,
},
// ========== validator ==========
NativeModSig {
module: "validator",
Expand Down
2 changes: 1 addition & 1 deletion crates/perry-codegen/src/runtime_decls/stdlib_ffi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ pub fn declare_stdlib_ffi(module: &mut LlModule) {
declare_streams_events(module);
// Date, String, Object, Math, Atomics, Number, JSON, Map/Set, Error,
// Promise, text encoding, closures, NaN-boxing, GC, console, fetch, net,
// performance, async-step, slugify, class registration, runtime init/
// performance, async-step, class registration, runtime init/
// module-loader, well-known Symbol hooks, Object.groupBy, JSX adapter.
declare_core(module);
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! Core language / runtime FFI declarations (extracted from stdlib_ffi.rs):
//! Date, String, Object, Math, Atomics, Number, JSON, Map/Set, Error, Promise,
//! text encoding, closures, NaN-boxing, GC, console, fetch, net, performance,
//! async-step, slugify, class registration, runtime init/module-loader,
//! async-step, class registration, runtime init/module-loader,
//! well-known Symbol hooks, Object.groupBy, JSX runtime adapter.

use crate::module::LlModule;
Expand Down Expand Up @@ -309,10 +309,6 @@ pub(crate) fn declare_core(module: &mut LlModule) {
&[DOUBLE, DOUBLE, DOUBLE],
);

// ========== Slugify ==========
module.declare_function("js_slugify", I64, &[I64]);
module.declare_function("js_slugify_strict", I64, &[I64]);

// ========== Class registration ==========
module.declare_function("js_register_class_getter", VOID, &[I64, I64, I64, I64]);
// Refs #486: per-class setter dispatch — see object.rs::js_register_class_setter.
Expand Down
18 changes: 0 additions & 18 deletions crates/perry-ext-slugify/Cargo.toml

This file was deleted.

Loading
Loading