Rust学习笔记
安装Rust && Cargo
Chapter 1
println!
calls a Rust macro. If it had called a function instead, it would be entered as println (without the !)cargo new
andcargo build
: to create and build a projectcargo run
can compile the code and then run the resultant executable all in one commandcargo check
quickly checks your code to make sure it compiles but doesn’t produce an executablecargo build --release
: compile with optimizations. This command will create an executable in target/release
Chapter 2
to be continued …