@@ -558,7 +558,7 @@ fn to_hardcoded_rust_ident(full_ty: &GodotTy) -> Option<&str> {
558558
559559 // Others
560560 ( "bool" , None ) => "bool" ,
561- ( "String" , None ) => "GodotString " ,
561+ ( "String" , None ) => "GString " ,
562562 ( "Array" , None ) => "VariantArray" ,
563563
564564 // Types needed for native structures mapping
@@ -832,11 +832,11 @@ fn to_rust_expr_inner(expr: &str, ty: &RustTy, is_inner: bool) -> TokenStream {
832832 } else {
833833 match ty {
834834 RustTy :: BuiltinIdent ( ident)
835- if ident == "GodotString " || ident == "StringName" || ident == "NodePath" =>
835+ if ident == "GString " || ident == "StringName" || ident == "NodePath" =>
836836 {
837837 quote ! { #ident:: from( #expr) }
838838 }
839- _ => quote ! { GodotString :: from( #expr) } ,
839+ _ => quote ! { GString :: from( #expr) } ,
840840 //_ => panic!("cannot map string literal \"{expr}\" to type {ty:?}"),
841841 }
842842 } ;
@@ -861,7 +861,7 @@ fn to_rust_expr_inner(expr: &str, ty: &RustTy, is_inner: bool) -> TokenStream {
861861
862862 let ( rust_ty, ctor) = match godot_ty {
863863 "NodePath" => ( "NodePath" , "from" ) ,
864- "String" => ( "GodotString " , "from" ) ,
864+ "String" => ( "GString " , "from" ) ,
865865 "StringName" => ( "StringName" , "from" ) ,
866866 "RID" => ( "Rid" , "default" ) ,
867867 "Rect2" => ( "Rect2" , "from_components" ) ,
@@ -955,7 +955,7 @@ fn gdscript_to_rust_expr() {
955955 // };
956956 // let ty_object = Some(&ty_object);
957957
958- let ty_string = RustTy :: BuiltinIdent ( ident ( "GodotString " ) ) ;
958+ let ty_string = RustTy :: BuiltinIdent ( ident ( "GString " ) ) ;
959959 let ty_string = Some ( & ty_string) ;
960960
961961 let ty_stringname = RustTy :: BuiltinIdent ( ident ( "StringName" ) ) ;
@@ -1009,12 +1009,12 @@ fn gdscript_to_rust_expr() {
10091009 //("null", ty_object, quote! { None }),
10101010
10111011 // String-likes
1012- ( "\" \" " , None , quote ! { GodotString :: from( " " ) } ) ,
1013- ( "\" {_}\" " , None , quote ! { GodotString :: from( "{_}" ) } ) ,
1012+ ( "\" \" " , None , quote ! { GString :: from( " " ) } ) ,
1013+ ( "\" {_}\" " , None , quote ! { GString :: from( "{_}" ) } ) ,
10141014 ( "&\" text\" " , None , quote ! { StringName :: from( "text" ) } ) ,
10151015 ( "^\" text\" " , None , quote ! { NodePath :: from( "text" ) } ) ,
10161016
1017- ( "\" text\" " , ty_string, quote ! { GodotString :: from( "text" ) } ) ,
1017+ ( "\" text\" " , ty_string, quote ! { GString :: from( "text" ) } ) ,
10181018 ( "\" text\" " , ty_stringname, quote ! { StringName :: from( "text" ) } ) ,
10191019 ( "\" text\" " , ty_nodepath, quote ! { NodePath :: from( "text" ) } ) ,
10201020
0 commit comments