forked from ctaggart/SourceLink
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ctaggart#35 using Roslyn COM interfaces instead of MDbg
all Roslyn interfaces moved into SourceLink.SymbolStore.ComSym library using F# for SourceLink.SymbolStore library MDbg binary being used from ConsoleTest
- Loading branch information
Cameron Taggart
authored and
Chet Husk
committed
Nov 25, 2014
1 parent
881a680
commit 1b40809
Showing
37 changed files
with
280 additions
and
585 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
[<AutoOpen>] | ||
module Checksums | ||
module SourceLink.Checksums | ||
|
||
open System | ||
open System.Collections.Generic | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
namespace SourceLink | ||
|
||
open Microsoft.Samples.Debugging.SymbolStore | ||
open Microsoft.Samples.Debugging.CorSymbolStore | ||
|
||
type SequencePoint = { | ||
Offset: int | ||
Document: ISymbolDocument | ||
Line: int | ||
Column: int | ||
EndLine: int | ||
EndColumn: int | ||
} | ||
|
||
[<AutoOpen>] | ||
module MDbg = | ||
|
||
type ISymbolReader with | ||
static member Create symUnmanagedReader = | ||
SymbolBinder.GetReaderFromCOM symUnmanagedReader | ||
|
||
type ISymbolMethod with | ||
member x.SequencePoints | ||
with get() = | ||
let count = x.SequencePointCount | ||
let offsets = Array.zeroCreate count | ||
let docs = Array.zeroCreate count | ||
let lines = Array.zeroCreate count | ||
let columns = Array.zeroCreate count | ||
let endLines = Array.zeroCreate count | ||
let endColumns = Array.zeroCreate count | ||
x.GetSequencePoints(offsets, docs, lines, columns, endLines, endColumns) | ||
let points = Array.zeroCreate count | ||
for i in 0 .. count - 1 do | ||
points.[0] <- { | ||
Offset = offsets.[i] | ||
Document = docs.[i] | ||
Line = lines.[i] | ||
Column = columns.[i] | ||
EndLine = endLines.[i] | ||
EndColumn = endColumns.[i] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
[<AutoOpen>] | ||
module RootAndInfo | ||
module SourceLink.RootAndInfo | ||
|
||
open System | ||
open System.Collections.Generic | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
[<AutoOpen>] | ||
module SourceLink.SymbolStore.CorSymExt | ||
|
||
open System.IO | ||
open SourceLink.SymbolStore.CorSym | ||
|
||
type ISymUnmanagedReader with | ||
static member Create pdb = | ||
TempPdbReader.CreateRawReader pdb | ||
|
||
member x.AsReader2 = x :?> ISymUnmanagedReader2 | ||
member x.AsSourceServer = x :?> ISymUnmanagedSourceServerModule | ||
|
||
member x.Documents | ||
with get() = | ||
let mutable count = 0 | ||
x.GetDocuments(0, &count, null) | ||
let docs = Array.zeroCreate count | ||
x.GetDocuments(count, &count, docs) | ||
docs | ||
|
||
member x.GetMethodsInDocument doc = | ||
let mutable count = 0 | ||
x.AsReader2.GetMethodsInDocument(doc, 0, &count, null) | ||
let methods = Array.zeroCreate count | ||
x.AsReader2.GetMethodsInDocument(doc, count, &count, methods) | ||
methods |
Oops, something went wrong.