The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#10
|
|||
|
|||
![]() Quote:
If you are a C programmer it might be funny. ![]() No ill intent meant. Just amusing myself. To be more on topic while I'm having fun, this is usually a hot topic, talking about declaring variables. I found alot of debate on the subject, some very amusing, when after using C for a long time, I had a need to mod some Visual Basic code. Well off I went and got vB6 and a book. Installed it and did some set up. Now if you have a C background, you can't help yourself, you declare variables, there's no way around it. So I set up the code to not allow dynamic declaration of variables and attemped a complie. It did nothing but complain. Nothing was declared. So to mod this huge piece of code I just removed the statement that made the compiler force declarations. And I was off to delveoping all the bad habits C programmers joke about. Now I use php, same thing, back to bad habits. Opps, I need a variable here and bam, there it is. I do try to init variables usually, but If you look at any code I wrote, I'm inconsistant. SO part of the amusment above was on myself, I know better and don't do it. So now php 5 seems to need Array() declared/initialized for this function to accept them. Are we going to declarations in php as a whole? Isn't there a performance benefit to delcaration and proper address space allocated without the compiler having to dynamically sort out types? I don't hang out at php.net or anywhere that discusses such things, so this thread has sparked my curiousity. |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|