Parse a srcsrv
stream from a Windows PDB file and look up file
paths to see how the source for these paths can be obtained:
SourceRetrievalMethod::Download
),SourceRetrievalMethod::ExecuteCommand
)```rust use srcsrv::{SrcSrvStream, SourceRetrievalMethod};
if let Ok(srcsrvstream) = pdb.namedstream(b"srcsrv") { let stream = SrcSrvStream::parse(srcsrvstream.asslice())?; let url = match stream.sourceforpath( r#"C:\build\renderdoc\renderdoc\data\glsl\gltexsample.h"#, r#"C:\Debugger\Cached Sources"#, )? { SourceRetrievalMethod::Download { url } => Some(url), _ => None, }; asserteq!(url, Some("https://raw.githubusercontent.com/baldurk/renderdoc/v1.15/renderdoc/data/glsl/gltexsample.h".tostring())); }
```
Licensed under either of
LICENSE-APACHE
or http://www.apache.org/licenses/LICENSE-2.0)LICENSE-MIT
or http://opensource.org/licenses/MIT)at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.