Frank Mulvenny said:
It is definately a useful facility to have. In fact, since developing
software involves debugging it, we are already developing software in
the debugger.
No, we're not. THere is no runtime information available when we're
typing code-text.
E&C extends the power and flexibility of that debugging
process. Also, E&C is useful even outside the context of debugging as
such. One can use it to explore the facilities of some utility classes
perhaps - in a live situation. Can be very useful again.
I don't see why. Edit&Continue is about altering code at runtime
and immediately (well, after the recompile) see the effect of that
altering. That's it.
Of course, reading your code to try and work out the problem is
a good way of debugging - that's a no-brainer.
But it's not neccesarily the only or quickest way in all cases.
quickest? how do you measure that? I like to write code that is
solid and bugfree. And I want to proof that not by stepping through a
debugger but by other means, like the ones we all learned during our CS
study.
This argument is one of a long line of obsolete arguments. It is the
direct descendent of that old chestnut:
"Writing your program, and having to send it
off to the computer to be batch executed, and
getting the results the next day is good
because it forces you to make sure it doesnt
have bugs."
Pure hairshirt mentality, with a soupcon of elitism.
So, you think the people who write OS kernels use E&C? Ever
debugged an OS kernel? Or ever thought of how a remote debugger works when
you're debugging that ASP.NET website application? How are you going
implement E&C in these situations? You can't. And especially debugging
ASP.NET applications is common these days.
Read the article in the url above about debugging software. Then
come back and tell me you use E&C through all the 4 categories of bugs.
I'm pretty sure you don't use E&C nor WONT use E&C in 3 of the 4
categories, which are the majority of bugs in software.
What other debugging facilities are beyond the pale and to be used only
by the plebians I wonder?
Changing the value of a variable?
Being able to see the value of a variable?
Altering the execution point?
Of course all these things are acceptable, because these are all useful
time-saving things to be able to do.
And if it is 'morally' acceptable for one to be able to alter the state
of a program by changing variables, why not code?
If I tell you I never alter variables in a debugger, do you believe
me?
The same could be said for compile errors, so therefore perhaps we
shouldnt have fast compilers that let us use the compiler as a crutch to
find our coding errors. This is the same argument as is being made
against E&C.
If there was some kind of runtime analysis software we could use,
it would a big step forward. It would be great to have pre/post conditions
in the code itself, so the compiler could check them, so we could use
compile time to highlight bugs.
Of course we can live without E&C, and no doubt many other developments
of the past decades.
It's not about if we can live with or without having it, it's
about:
1) There is a limited amount of time. Microsoft has stated in the
VS.NET newsgroup friday that there was a choice: OR refactoring OR E&C in
C#. They clearly made the choice for refactoring in C# and E&C in VB.NET
2) E&C encourages developers to use it as THE debugging tool for
their software, while these developers should be encouraged to debug by
reading their code and test the code against the algorithms they
implemented. Look at the developers using E&C: are they reading their code
and see with pre/post conditions if their code matches a PROVED algorithm?
10 to 1 they don't: they alter code in the debugger, re-run the method and
hope the values they see now in the locals window are the ones that should
be there.
I have found it to be very useful. It's not essential, but then neither
are fast compilers, or intellisense. Or syntax colouring. However, all
these things are useful so long as one can avoid having an elitist
philosophy that considers them fit only for 'bad programmers'.
I don't see what the relation between intellisense and E&C is. You
clearly do not understand what debugging is all about, or for that matter,
what 'programming' stands for. Hint: not typing in code.
I presume you're talking about a previous thread in some discussion
forum. Do you have a link?
see the blog link above
Sorry, but your reply has displayed a quite disgusting degree of
condescension and arrogance.
Hmm, having an opinion is being arrogant? Why? I can explain and
have explained it why E&C is bad debugging practise and should be avoided
and if a tool DOES make you avoid it (because it doesn't have the feature)
you as the developer will be a better software engineer in the end.
I am disapointed that you should feel the need to resort to this kind of
stuff. You seem to have a hair-trigger superiority complex! ;-)
Well, from time to time I get a little tired of the people who
think they are professionals (I'm not talking about you personally) but
show a lack of knowledge about what software engineering is all about. And
instead of bashing these people that they're not what they think they are,
which is rude and counterproductive, it's better to educate them and show
them why they're wrong and how they can improve their skills and knowledge
and THUS their software they're making. About a decade ago, my mentor at
the uni spend extra time to enlighen me why the ideas I had about
designing / engineering software were not that good and also told me why.
I'll never forget that, and if I can open other people's eyes I won't stop
doing so. So, no, this is not about being arrogant. Yes I personally think
I'm very good at software engineering, but not the best. No wonder, since
I do it for a loooong time already. What's wrong with trying to teach some
knowledge I learned during the past 10 years?
Try and remember that in the end, the presence of E&C facility does no
harm to the 'real programmers' such as yourself, who will at no point be
required to lower themselves to making use of it.
Frank, even if MS was able to implement all the features in the
world into vs.net, I still would be writing these texts. It's not about a
silly feature I won't use and you will. It's about the philosophy behind
the REASON why you would use the feature and I won't.
FB