官术网_书友最值得收藏!

rustdoc versus Cargo

As with the other operations provided by Cargo, when documentation is created, it acts as a wrapper for rustdoc. The only difference is that with rustdoc you have to specify the directory that the source file sits in. Cargo acts dumb in this case, and creates the documentation for all source files.

In its simplest form, the rustdoc command is used as follows:

cargo doc
rustdoc src/main.rs  

Cargo does have the advantage of creating the doc structure within the root folder, whereas rustdoc creates the structure within the target (which is removed with cargo clean).

主站蜘蛛池模板: 贵港市| 晋宁县| 库伦旗| 正镶白旗| 乡宁县| 宾阳县| 枣强县| 平湖市| 平塘县| 温宿县| 万年县| 历史| 文登市| 玉龙| 漳浦县| 新密市| 会昌县| 砚山县| 怀柔区| 绥化市| 浙江省| 永寿县| 宜兰市| 礼泉县| 张家界市| 迭部县| 丰都县| 濮阳县| 淮滨县| 鄄城县| 崇文区| 永顺县| 鄱阳县| 东城区| 筠连县| 河南省| 吴忠市| 琼结县| 漳浦县| 都兰县| 登封市|