Posted: Fri Aug 18, 2006 10:01 am
ole wrote:Wow, that's confusing, i would never mix like that.
A community of PHP developers offering assistance, advice, discussion, and friendship.
http://forums.devnetwork.net/
ole wrote:Wow, that's confusing, i would never mix like that.
Code: Select all
if (($a == 0) && ($b == 1) && ($c == 2))Code: Select all
while (($pos = strpos($a, $b)) !== false) //etc
if (($num = func_num_args()) != 0) echo $num;Hockey wrote:...underscores...Can I get an all in favour or all opposed vote?
Err.. camelcaps for file naming? I'd go with an underscore rather than camelcaps, since filenames are case sensitive.ole wrote:I'm with Feyd. Underscores in constants that's it, no hypens either, camelCaps all the way!
One word: consistency. As long as the class is named accordingly, then I'll deal with whatever is chosen. But considering I use camelcase for class names, it's pretty simple that I'd choose camelcase for filenames too.Hockey wrote:Ok fare enough, but can you justify with an answer why you want to use camel caps in filenames?
You you can't keep your case consistent then you aren't a very good C/C++ programmer!Hockey wrote:I stated my reasons for using small case always using underscore to seperate words...it has to do with case-sensitivity, in switching from Windows to Linux servers and referencing files and accidently forgetting to capitalize a letter...

ACROStuff; DNASha256; HKYSilly. Pretty simple.Hockey wrote:Also with camelcase, my concern (nothing else - Like I said i'm open to change) is what happens when you encounter an acronym? It's common practice in every industry to capitalize acronyms, but that could make files looks ugly and what about editors, listing toosl, etc which force CAPS or lowercase? The semantic behind using CamelCase is lost...???
Sorry, I don't see any more issues. I don't see any less either; I don't really see any issues either way.Hockey wrote:The way I see there are more issues with using camelcase in files names than just using lowercase and underscores to seperate words...???

I can agree with that logic...One word: consistency.
Thats why conventions are so importantYou you can't keep your case consistent then you aren't a very good C/C++ programmer!
Savage looking files names if you ask meACROStuff; DNASha256; HKYSilly. Pretty simple.
You're the first to bring up this "need." No moderator that I know of has ever brought up that we "need" a convention on the boards, and we can't expect anyone to follow it here. The only time an agreed upon convention becomes (mildly) important is when we're working on projects with other programmers, and even then, you can't expect it to be 100% the same for everyone. That's what beautifiers are for.Hockey wrote:I think this way will would eventually hammer out the ideal convention document.
Hmmm...ok thenfeyd wrote:You're the first to bring up this "need." No moderator that I know of has ever brought up that we "need" a convention on the boards, and we can't expect anyone to follow it here. The only time an agreed upon convention becomes (mildly) important is when we're working on projects with other programmers, and even then, you can't expect it to be 100% the same for everyone. That's what beautifiers are for.Hockey wrote:I think this way will would eventually hammer out the ideal convention document.
If you can't tell, all along I've pretty much sided with Arborint about this being a silly discussion. We know we aren't likely to sway each other in any one direction, we like the things we like for whatever reason. Now, that being said.. I don't think the moderators will do the poll creation for you. I think you're approaching being an island in this case. I don't know, it's up to the other moderators if they want to do it. But that's the feeling I'm predicting.
edit: You originally asked for my opinion on the various parts, and I will continue to do that, but in ratifying a codestyle, I will not be apart of. Sorry if you find that disappointing or infuriating, I just think the subject of conventions where it's impossible to enforce or ridiculous to even try is just patently silly.
Every project I've worked on has had conventions. They were, overall, specific and custom to that project. I have no general problem with conventions, after all, I have my own code conventions. But I don't find them important enough to make them outside of a specific project. There are far more important things pressing for me to care too much about how many spaces my tabs are and where I place a brace.Hockey wrote:You've clearly worked on projects without standard conventions and had acceptable results...
Excellent.Hockey wrote:I still appreciate your input...
Maybe there's a threshold that I've gone through that allows me to accept pretty much whatever's thrown at me where I just don't really care about it as much.Hockey wrote:as I'm trying to remain as open minded as possible in coming to a conclusion about conventions.
