Excerpt from:  Bill Blogs in C#
.
November 02, 2007

Yet another good explanation on the pitfalls of Finalization

Brian Grunkmeyer has written a rather deep article for the BCL weblog that discusses many of the pitfalls that surround finalization, dispose, and weird things that can happen during the birth, death, and possible resurrection of an object:

 http://blogs.msdn.com/bclteam/archive/2007/10/30/dispose-pattern-and-object-lifetime-brian-grunkemeyer.aspx

 Some of the important points he covers:

. What happens if an object's constructor thorws an exception?

. What happens if an object's finalizer is called as part of an AppDomain unloading?

. Why should I care?

. What can I do to prevent exceptions and application terminations?

Topic Tags:  ,

Syndication OptionsRSS (Rich Site Summary) Feed Atom Feed OPML (Outline Processor Language) Feed MYST-ML (MyST Markup Language) Content Feed MS-Office Smart Tag Subscription