Skip to content

EE: Comment characters should be ignored in strings and XML literals #1453

Open
@ManishJayaswal

Description

Ported from TFS WorkItem: 1120198


Repro Steps:

1. F5 the following

 

class C
{
    static object F(string s)
    {
        return new object();
    }
    static void Main()
    {
        System.Diagnostics.Debugger.Break();
    }
}

 

2. Evaluate F("//") in the Watch window

3. Right-click on the expression and "Add Watch"

 

Result: Invalid expression

 


 

Same issue exists with VB with strings and XML literals:

 

Imports System.Xml.Linq
Class C
    Shared Function F(x As XElement) As Object
        Return New Object()
    End Function
    Shared Sub Main()
        System.Diagnostics.Debugger.Break()
    End Sub
End Class

 



Revisions:

  1. Created By Chuck Stoner (2/5/2015 9:01:14 AM)

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions