Results 1 to 4 of 4

Thread: Does C Sharp provide automatic garbage collection ?

  1. #1
    Join Date
    Dec 2010
    Posts
    37

    Does C Sharp provide automatic garbage collection ?

    I have heard about a lot of features about the object oriented language being used and its advantages over the procedural code, I was a bit concerned about the garbage collection feature of the language being used in many programming language , I know that this feature is provided by languages like Java and PHP but was not sure about the C# language, I also wanted to know about sum extra features of this language.

  2. #2
    Join Date
    Apr 2009
    Posts
    488

    Re: Does C Sharp provide automatic garbage collection ?

    Yes it is one of the greatest advantage of this language , the C # indeed provides the feature of automatic garbage collection , it is a feature in which if there is any object or a method that is initialized but if in case it is not used then it is gone to automatic garbage collection and the space occupied by that member is saved due to this feature.

  3. #3
    Join Date
    May 2009
    Posts
    539

    Re: Does C Sharp provide automatic garbage collection ?

    Yes apart from the garbage collection it has additional features as :
    • In C# you will not be able to perform any unsafe casts like convert long to a float.
    • In this language the value type of data types are automatically initialized to zeros and if in case the data type is of reference type then it is initialized to null

    • Arrays are marked or index to the zero position and are always checked.

    • The arrays are always checked for overflows .

  4. #4
    Join Date
    May 2009
    Posts
    637

    Re: Does C Sharp provide automatic garbage collection ?

    I too am ware about the automatic garbage collection of this language but here are some more features in it :

    • Pointers are not there in C# programming language it makes the use of Delegates instead .
    • 2. Unsafe Operations that are not safe such as direct memory manipulation is not permitted at all .
    • 3. The scope resolution operator is not used in the C# language.
    • 4. Since it is one of the .NET based language , it derives the characteristics of automatic memory management as well and the as said it uses the feature of garbage collection.

Similar Threads

  1. Sharp 007SH Hybrid An 3D Clamshell Android Phone by Sharp
    By jackalz in forum Web News & Trends
    Replies: 3
    Last Post: 22-05-2011, 07:28 AM
  2. How to Force Garbage Collection In Java?
    By Sheenas in forum Software Development
    Replies: 6
    Last Post: 28-04-2011, 01:30 PM
  3. JAVA - What is garbage collection
    By Bhim in forum Software Development
    Replies: 5
    Last Post: 28-04-2011, 01:13 PM
  4. Java - help with Garbage Collection
    By Messenger in forum Software Development
    Replies: 4
    Last Post: 23-07-2010, 10:18 AM
  5. What is the Garbage Collection in PHP?
    By Emma.J in forum Software Development
    Replies: 5
    Last Post: 04-03-2010, 01:40 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,714,000,983.74202 seconds with 16 queries