Repro:
- Open VisualFSharp.sln
- Open SignatureHelp.fs
- Put a breakoint on line 123(
let startOfArgs = ...)
- Launch a hive of VS where you can debug
- Enter the following source code:
type C() =
static member M(x, y, z) = ()
C.M(1)
- Place cursor after the
1 on the last line
- Press the comma character (
,) so that Signature Help is triggered
Note that there are some locals, and critically you can observe the value of applicableSpan:

Now try to get the source code that matches this span by:
- Opening the Immediate Window
- Entering the following:
sourceText.GetSubText(applicableSpan)
You will observe that sourceText doesn't exist. Indeed, it wasn't even in the locals window.

However, note that sourceText is a parameter to this method and it is clearly accessible.
We are losing debug info on every do! call in the method.
To test this, place a breakpoint on line 89 (do! Option.guard (methods.Length > 0 ...). When it is broken there, you'll see that sourceText is available:

Repro:
let startOfArgs = ...)1on the last line,) so that Signature Help is triggeredNote that there are some locals, and critically you can observe the value of
applicableSpan:Now try to get the source code that matches this span by:
sourceText.GetSubText(applicableSpan)You will observe that
sourceTextdoesn't exist. Indeed, it wasn't even in the locals window.However, note that
sourceTextis a parameter to this method and it is clearly accessible.We are losing debug info on every
do!call in the method.To test this, place a breakpoint on line 89 (
do! Option.guard (methods.Length > 0 ...). When it is broken there, you'll see thatsourceTextis available: