"Edit and continue" not working in functions with LINQ

I've started to use LINQ and feel that query expression are very powerfull.
Unfortunately , when in debugger I've tried to  Edit and continue, it gave me an error
Modifying a 'method' which contains a query expression will prevent the debug session from continuing while Edit and Continue is enabled. 
The post Orcas - Edit and continued not working when linq used - MSDN Forums explains that "it is a limitation of the environment in which Edit and Continue operates".
 
I've submitted suggession to MS - please vote to push MS to improve  E&C support.
Sometimes I feel, that E&C in VB6 was better.
 
As a workaround I will try not to keep LINQ queries inside big function, but refactor them into small functions. Unfortunately it makes Language-INtegrated Queries not so-good in integration with language.
 
By the way I am using refactoring from VS and Refactor! for ASP.NET , and extract function works better from VS; Refactor! not always correctly declares parameters.
  • Share This Post:
  • Share on Twitter
  • Share on Facebook
  • Share on Technorati
posted @ Wednesday, January 07, 2009 10:25 PM
Print

Comments on this entry:

# re: "Edit and continue" not working in functions with LINQ

Left by Christopher Scholten at 7/22/2009 1:04 PM
Gravatar
You got my vote...

# re: "Edit and continue" not working in functions with LINQ

Left by Shiva at 5/17/2010 1:12 PM
Gravatar
Thanks! I was getting this error too, and was puzzled at first because I didn't get the prompt asking to rollback edits or restart debugging in other methods in my class, only in 1 particular method.

Then I looked at the error in the Error List window and it mentions "query" and I wondered if it was not working because the LINQ query was inside the method I was debugging.

Finally I searched for the error msg to confirm it and landed on your blog post. Good to know, and I am with you on the EnC in VB 6 being much better ;)

Your comment:



(not displayed)


 
 
 
 
 

Live Comment Preview:

 
«February»
SunMonTueWedThuFriSat
2930311234
567891011
12131415161718
19202122232425
26272829123
45678910