What is the difference between managed and unmanaged code?
Answer Posted / sudhir singh
MANAGED CODE is what Visual Basic .NET and C# compilers create. It runs on the CLR (Common Language Runtime), which, among other things, offers services like garbage collection, run-time type checking, and reference checking. So, think of it as, "My code is managed by the CLR."
Visual Basic and C# can only produce managed code, so, if you're writing an application in one of those languages you are writing an application managed by the CLR. If you are writing an application in Visual C++ .NET you can produce managed code if you like, but it's optional.
UNMANAGED CODE compiles straight to machine code. So, by that definition all code compiled by traditional C/C++ compilers is 'unmanaged code'. Also, since it compiles to machine code and not an intermediate language it is non-portable.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is .net framework & its benefits?
why DotNetFramework is included in building a software
Explain Model, view and Controllers in Asp.Net MVC?
what is more complex to implement property, methods or event? how can I define criteria to compare the difficulty of implementation between them? for example the number of methods wanted to implements property is 2 methods. how many methods I need it to implements events?
What is object service? : Entity framework
What is definingquery in entity framework? : Entity framework
What are the two ways to add constraints to a route?
What is a model in android?
What is net framework 3.0 ?
I want ask from plz smaple example code for Biztalkk server
Which are the important namespaces used in ASP.Net MVC?
which are the key concepts of entity data model?
i have done enough testing in life but now stated developing intereset in development work,Can i think of entering into development work that too in >Net after more then 4 years of testing experiece?
Will the name change be reflected in any of the existing .net framework 2.0 apis, assemblies, or namespaces?
Explain the methods used to render the views in mvc?