rust基本语法.md Rust 语言概述基本数据类型12345678910111213141516# integer# i8 i16 i32 i64 i128 # u8 u16 u32 u64 u128let x : i8 = 2;# f32 f64let y : f64 = 2.0;# true falselet z : bool = true;# tuplet tup = (1, 2, 3);let tup_a : (i32, f64, u8) = (500, 1.0, 2);# 输入输出12345# print!println!("{}", output);# format!let command = format!("clang -Xclang -ast-dump -fsyntax-only {}", f_path.to_string()); 函数函数定义123456789fn func() { // logic}fn func(a: i8, b: i8) { // param need type statement}fn func(a: int) project > cToRust #Rust rust基本语法.md https://abrance.github.io/2024/02/28/project/cToRust/rust基本语法/ Author xiaoy Posted on February 28, 2024 Licensed under cust思路.md Previous cToRust.md Next