@@ -116,7 +116,7 @@ impl ArtifactEmitter for RustStructEmitter {
116116/// 2024 strict + reserved-future); a `&str` slot from the canonical layer
117117/// can never need a non-identifier escape since names are sourced from
118118/// Rails / Odoo identifiers.
119- fn escape_rust_ident ( name : & str ) -> String {
119+ pub ( crate ) fn escape_rust_ident ( name : & str ) -> String {
120120 const RESERVED : & [ & str ] = & [
121121 // Rust 2015+ strict keywords:
122122 "as" , "break" , "const" , "continue" , "crate" , "else" , "enum" , "extern" ,
@@ -142,7 +142,7 @@ fn escape_rust_ident(name: &str) -> String {
142142/// today. Each `op-*` / `rm-*` consumer is free to specialise (e.g.
143143/// `Decimal` vs `f64` for monetary slots) downstream. The point is the
144144/// canonical contract round-trips; precision is a per-consumer concern.
145- fn rails_to_rust_type ( t : Option < & str > ) -> String {
145+ pub ( crate ) fn rails_to_rust_type ( t : Option < & str > ) -> String {
146146 match t {
147147 Some ( "string" ) | Some ( "text" ) => "String" . into ( ) ,
148148 Some ( "integer" ) | Some ( "big_integer" ) | Some ( "bigint" ) => "i64" . into ( ) ,
@@ -155,7 +155,7 @@ fn rails_to_rust_type(t: Option<&str>) -> String {
155155 }
156156}
157157
158- fn edge_rust_type ( a : & ogar_vocab:: Association ) -> String {
158+ pub ( crate ) fn edge_rust_type ( a : & ogar_vocab:: Association ) -> String {
159159 // Coarse: `belongs_to` / `has_one` → `Option<u64>` (FK id),
160160 // `has_many` / `habtm` → `Vec<u64>`. The concrete `op-*` / `rm-*`
161161 // consumer can swap these for typed references downstream.
0 commit comments