Can you declare a C++ type destructor in C# like ~MyClass() ?

Answer Posted / mr vinod kumar

Yes, but what's the point, since it will call Finalize(), and Finalize() has no guarantees when the memory will be cleaned up, plus, it introduces additional load on the garbage collector.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is parallel programming in c#?

571


What is parsing?

605


what is IDisposal interface

783


Explain the difference between class and interface in .net?

497


Can we set image Source dynamically using C# in WPF application?

721






What is the difference between continue and break statement?

615


Define xslt.

628


What is the benefit of interface in c#?

565


What is use of singleton class in c#?

568


What is extension method in c sharp?

558


What is the difference between c and c sharp?

622


Why is ienumerable used?

580


What is the namespace for the thread class?

594


What is toint32 c#?

710


What do u mean by delegation of authority?

623