当前位置:网站首页>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 ***
边栏推荐
- Technical secrets of ByteDance data platform: implementation and optimization of complex query based on Clickhouse
- Mujoco XML modeling
- Blackwich: the roadmap of decarbonization is the first step to realize the equitable energy transformation in Asia
- Happy new year | 202112 monthly summary
- L'ouverture d'un compte d'actions en ligne est - elle sécurisée? Fiable?
- Intel's open source deep learning tool library openvino will increase cooperation with local software and hardware parties and continue to open
- Relationship between sensor size, pixel, dpi resolution, inch and millimeter
- Kia recalls some K3 new energy with potential safety hazards
- How to write good code - Defensive Programming Guide
- MES production equipment manufacturing execution system software
猜你喜欢

Cloud picture says | distributed transaction management DTM: the little helper behind "buy buy buy"

Source code of new campus errand / campus task platform on mutual station

Kia recalls some K3 new energy with potential safety hazards

How to use JMeter function and mockjs function in metersphere interface test

Penetration practice vulnhub range Nemesis

Data warehouse (3) star model and dimension modeling of data warehouse modeling

Euler function: find the number of numbers less than or equal to N and coprime with n

Extract the compressed package file and retrieve the password

Record 3 - the state machine realizes key control and measures the number of external pulses

New patent applications and transfers
随机推荐
js如何将带有分割符的字符串转化成一个n维数组
Is the software of futures pioneer formal and safe? Which futures company is safer to choose?
SCP -i private key usage
Redis主从实现10秒检查与恢复
ACM mm 2022 video understanding challenge video classification track champion autox team technology sharing
Detailed explanation of select in golang
2022 Heilongjiang latest fire protection facility operator simulation test question bank and answers
[beauty detection artifact] come on, please show your unique skill (is this beauty worthy of the audience?)
JDBC: deep understanding of Preparedstatement and statement[easy to understand]
SQL injection vulnerability (MySQL and MSSQL features)
Petrv2: a unified framework for 3D perception of multi camera images
How to retrieve the password for opening Excel files
PHP implements sensitive word filtering system "suggestions collection"
Redis master-slave realizes 10 second check and recovery
Wechat applet blind box - docking wechat payment
Set the style of QT property sheet control
Step size of ode45 and reltol abstol
APK签名流程介绍[通俗易懂]
[PHP foundation] realize the connection between PHP and SQL database
What are the legal risks of NFT brought by stars such as curry and O'Neill?