Skip to content

Commit 7ba003c

Browse files
committed
Docs fixes.
1 parent 6c88d63 commit 7ba003c

2 files changed

Lines changed: 29 additions & 4 deletions

File tree

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,29 @@ fn main() {
3838
}
3939
```
4040

41+
...and it will emit something like the following:
42+
43+
```
44+
Some(
45+
Info {
46+
sdk: Some(
47+
SdkInfo {
48+
major_version: 10,
49+
root: "C:\\Program Files (x86)\\Windows Kits\\10\\Lib\\10.0.22000.0",
50+
um_lib_path: "C:\\Program Files (x86)\\Windows Kits\\10\\Lib\\10.0.22000.0\\um\\x64",
51+
ucrt_lib_path: "C:\\Program Files (x86)\\Windows Kits\\10\\Lib\\10.0.22000.0\\ucrt\\x64",
52+
},
53+
),
54+
toolchain: Some(
55+
ToolchainInfo {
56+
exe_path: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.36.32532\\bin\\Hostx64\\x64",
57+
lib_path: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.36.32532\\lib\\x64",
58+
},
59+
),
60+
},
61+
)
62+
```
63+
4164
## Implementation notes
4265

4366
One of the goals for this implementation was to be as dependency-free

src/lib.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
//! If your need is bigger than this, you might go check the
3434
//! [cc](https://crates.io/crates/cc) crate.
3535
36+
#![deny(missing_docs)]
37+
3638
#[cfg(not(target_os = "windows"))]
3739
compile_error!("This crate only supports Windows.");
3840

@@ -79,7 +81,7 @@ pub struct SdkInfo {
7981
///
8082
/// **IMPORTANT**: If you have multiple versions of Visual Studio
8183
/// installed, we return the first one, rather than the newest. This
82-
/// solves the baspic problem for now, but can be easily expanded in
84+
/// solves the basic problem for now, but can be easily expanded in
8385
/// the future.
8486
#[derive(Debug)]
8587
pub struct ToolchainInfo {
@@ -250,9 +252,9 @@ const SDK_VERSIONS: [(u8, &str, fn(&Path) -> Option<Version>); 2] = [
250252

251253
fn find_windows_kit() -> Option<(u8, PathBuf)> {
252254
// Information about the Windows 10 and Windows 8 development kits
253-
// is stored in the same place in the registry. We open a key to
254-
// that place, first checking preferentially for a Windows 10 kit,
255-
// then, if that's not found, a Windows 8 kit.
255+
// is stored in the same place in the registry. We open a key to
256+
// that place, first checking preferentially for a Windows 10 kit,
257+
// then, if that's not found, a Windows 8 kit.
256258
let mut main_key = RegKey::zeroed();
257259
let err = unsafe {
258260
RegOpenKeyExA(

0 commit comments

Comments
 (0)