Version Used: Visual Studio 15.4.3
Steps to Reproduce:
Using this piece of code:
public async Task QueueFeedUpdate(Feed feed)
{
string message = JsonConvert.SerializeObject(feed);
if (CloudStorageAccount.TryParse(_connectionString, out CloudStorageAccount account))
{
var client = account.CreateCloudQueueClient();
var queue = client.GetQueueReference("UpdateFeedItems");
await queue.AddMessageAsync(new CloudQueueMessage(message));
}
}
CloudQueueMessage
(line 8)Expected Behavior:
Squiggle should go back to line 8 after the last )
Actual Behavior:
Squiggle goes to line 9 next to }
.
The actual minimum reproducible code can be further reduced to this:
public void Test()
{
var t = new object();
var c = new object();
}
Fascinating. @gafter It looks like the IDE is just reporting the character given by the compiler (though i'm not 100% sure of that). Could this be an incremental bug?
Note: the easiest repro i have is as follows:
First, to see the expected case, just compile/paste the following code:
```c#
class C
{
public void Test()
{
var t = new object();
var c = new object()
}
}
Here, the error is correctly reported at the end of the second ```new object()```. Now, to repro the bug, instead start with:
```c#
class C
{
public void Test()
{
var t = new object()
var c = new object()
}
}
(note: no semicolons). There will be two errors, both after "new object()". Now type ;
after the first "new object()". Instead of getting the errors from the expected case, the error is reported on the }
.
Looks like an issue with the incremental parser.
w00t! I found an unreported bug! 馃槃
@gafter feel free to rename the issue to something more technical than red squiggles.
@MaximRouiller I like red squiggles.
w00t! I found an unreported bug! 馃槃
Congrats. I highly respect your ability to notice something so subtle!
@CyrusNajmabadi Yet my wife wonders how I can lose my keys in my house while I had them in my hands 5 minutes ago.
Any progress on this? Can we close?
The bug still exists. It isn't serious, so I'm marking it as up-for-grabs.
Looks like the kind of bug that isn't serious enough to fix in a hurry yet would be hard to fix in a timely manner. 馃槀
Most helpful comment
@MaximRouiller I like red squiggles.