
Optimizing, Debugging, and Testing • Chapter 11 543
have some performance advantages.This is because the Value types such as these
are allocated on the stack where they are accessed and removed quickly with very
little overhead. Objects passed by reference are allocated on the heap, which
requires interaction with the Garbage Collector and in turn generates greater
overhead.
Strings
Strings in Visual Basic .NET are objects. But the difference is that you cannot
modify a String object.That is to say they are immutable.Traditionally, if you
modified a string, you actually modified the specific string. Now, when you
modify a string (perhaps replace the middle ...