More propagation of numeric types (#6177)

Signed-off-by: Nick Cameron <nrc@ncameron.org>
This commit is contained in:
Nick Cameron
2025-04-07 19:02:41 +12:00
committed by GitHub
parent bc22d888ee
commit be05dd7ba1
24 changed files with 631 additions and 350 deletions

View File

@ -764,14 +764,14 @@ fn rust_type_to_openapi_type(t: &str) -> String {
t = format!("[{inner_type}]")
}
if t == "f64" {
if t == "f64" || t == "TyF64" {
return "number".to_string();
} else if t == "u32" {
return "integer".to_string();
} else if t == "str" {
return "string".to_string();
} else {
return t.replace("f64", "number").to_string();
return t.replace("f64", "number").replace("TyF64", "number").to_string();
}
}