当前位置:网站首页>Rust language - cargo, crates io
Rust language - cargo, crates io
2022-07-01 18:17:00 【A pig】
release profile:
It's predefined
Customizable : Different configurations can be used , Have more control over code compilation
Every profile The configuration of is independent of others profile
cargo Two main profile:
—dev profile: For development cargo build
—release profile: Apply to Publishing cargo build --release
# Generally, the following settings are made
[profile.dev]
opt-level = 0
[profile.release]
opt-level = 3Release crate To crates.io
Use cargo doc --open The order can change crate Upload to crates.io Website and open this website
///: Documentation Comments
//!: A note describing the outer entry
pub use Export easy-to-use public API
For example, if you call a deep structure parameter
use xzc::x::z::c It's troublesome for users
We can do it in lib.rs Use in
pub use self::xzc::x::z::c
In this way, we want to import c Can be directly in main.rs Use in
use xzc::c
from crates.io Install binary crate
command :cargo install ***
边栏推荐
- Oracle TRUNC function processing date format
- Highly reliable program storage and startup control system based on anti fuse FPGA and QSPI flash
- Convert the robot's URDF file to mujoco model
- PIP version problems: PIP problems still occur when installing akshare and using Tsinghua source and Douban source
- Glidefast consulting was selected as the elite partner of servicenow in 2022
- ZABBIX alarm execute remote command
- When the fixed frequency artifact falls in love with multithreading | ros2 fixed frequency topic release demo
- 网上股票开户安全吗?是否可靠?
- Redis主从实现10秒检查与恢复
- Fresh, 2022 advanced Android interview must know 100 questions (interview questions + answer analysis)
猜你喜欢

Explain in detail the process of realizing Chinese text classification by CNN

Growing up in the competition -- (Guangyou's most handsome cub) Pikachu walking

Happy new year | 202112 monthly summary

Apache iceberg source code analysis: schema evolution

New patent applications and transfers

Heavy disclosure! Hundreds of important information systems have been invaded, and the host has become a key attack target

Kernel stray cat stray dog pet adoption platform H5 source code

Domestic spot silver should be understood

Definition of rotation axis in mujoco
![[splishsplash] about how to receive / display user parameters, MVC mode and genparam on GUI and JSON](/img/83/9bd9ce7608ebfe7207ac008b9e8ab1.png)
[splishsplash] about how to receive / display user parameters, MVC mode and genparam on GUI and JSON
随机推荐
Penetration practice vulnhub range Keyring
EasyCVR通过国标GB28181协议接入设备,出现设备自动拉流是什么原因?
Work and leisure suggestions of old programmers
Leetcode problem solving series -- continuous positive sequence with sum as s (sliding window)
Step size of ode45 and reltol abstol
APK签名流程介绍[通俗易懂]
Basic usage of shell script
DNS
聊聊项目经理最爱使用的工具
How to retrieve the password for opening Excel files
Debiasing word embeddings | talking about word embedding and deviation removal # yyds dry goods inventory #
(16) ADC conversion experiment
Quick foundation of group theory (5): generators, Kelley graphs, orbits, cyclic graphs, and "dimensions" of groups?
Penetration practice vulnhub range Nemesis
At present, where is the most formal and safe account opening for futures speculation? How to open a futures account?
The reviewboard has 500 errors when submitting a review. Solutions
Gold, silver and four job hopping, interview questions are prepared, and Ali becomes the champion
golang中的select详解
The latest software scheme of the intelligent information management system of the armed police force
Blackwich: the roadmap of decarbonization is the first step to realize the equitable energy transformation in Asia