Leaders snarfblam Posted August 27, 2004 Leaders Posted August 27, 2004 Is there any difference in speed or overhead between function (or sub) calls and property (set and get) calls in .NET? Or are they essentially the same? Quote [sIGPIC]e[/sIGPIC]
Administrators PlausiblyDamp Posted August 27, 2004 Administrators Posted August 27, 2004 Behind the scenes they are all the same, use whichever makes for cleaner code. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
Leaders snarfblam Posted August 27, 2004 Author Leaders Posted August 27, 2004 By they are all the same, do you mean they are equally fast? because i am making a somewhat cpu demanding game and every cpu cycle counts. Quote [sIGPIC]e[/sIGPIC]
Arch4ngel Posted August 27, 2004 Posted August 27, 2004 They are both the same. The IL that is generated will be exactly the same. It's just a different way to "see" your code. It will be generated the same way however. Quote "If someone say : "Die mortal !"... don't stay to see if he isn't." - Unknown "Learning to program is like going out with a new girl friend. There's always something that wasn't mentioned in the documentation..." - Me "A drunk girl is like an animal... it scream at everything like a cat and roll in the grass like a dog." - Me after seeing my girlfriend drunk and some of her drunk friend. C# TO VB TRANSLATOR
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.