Skip to content

Commit

Permalink
Release: 0.13
Browse files Browse the repository at this point in the history
  • Loading branch information
riverar committed Jan 16, 2025
1 parent c45d76d commit 11eb379
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions .github/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Start by adding `windows-core` and `microsoft-dia` dependencies to Cargo.toml:
version = "0.59"

[dependencies.microsoft-dia]
version = "0.12"
version = "0.13"
```

Make use of any DIA SDK APIs as needed.
Expand All @@ -22,16 +22,16 @@ Make use of any DIA SDK APIs as needed.
use microsoft_dia::{nsfRegularExpression, DiaSource, IDiaDataSource, SymTagFunction};
use windows_core::*;

fn main() -> windows::core::Result<()> {
fn main() -> Result<()> {
unsafe {
let source: IDiaDataSource = microsoft_dia::helpers::NoRegCoCreate(s!("msdia140.dll"), &DiaSource)?;
let executable = std::env::current_exe().unwrap();
source.loadDataForExe(&HSTRING::from(executable.as_os_str()), None, None)?;

let session = source.openSession()?;
let symbols = session.globalScope()?.findChildren(SymTagFunction, w!("sample_functions::*"), nsfRegularExpression.0 as u32)?;
let symbols = session.globalScope()?.findChildren(SymTagFunction, w!("*"), nsfRegularExpression.0 as u32)?;

println!("Function symbols found in sample_functions::* ({}):", &executable.to_string_lossy());
println!("Function symbols found in self: ({}):", &executable.to_string_lossy());

for i in 0..symbols.Count()? {
println!("\t{}", symbols.Item(i as u32)?.name()?);
Expand All @@ -40,5 +40,4 @@ fn main() -> windows::core::Result<()> {
Ok(())
}
}

```
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "microsoft-dia"
version = "0.12.0"
version = "0.13.0"
authors = ["Microsoft"]
edition = "2021"
license = "MIT OR Apache-2.0"
Expand Down

0 comments on commit 11eb379

Please sign in to comment.