function(int a);
That script will prevent me to send this post?
Printable View
function(int a);
That script will prevent me to send this post?
That's the point. It's not operational. it used to be, but now it's not.
For that one-liner you posted, it's ok, cause it's not messy etc, but some people had childish infactuations with posting 1,000,000, slight exaggeration, line chunks of code with no tags. I don't know about anyone else, but I couldn't read them!!
What about an auto tagger?
>What about an auto tagger?
Only if it can be explicitly overridden. I doubt I'm the only one who cares about the presentation of a post, and automatic solutions tend to hurt that.
How could the thing know where the code starts and ends?eg -
something me ( "Who knows what this does! It could be a function or someone's opinion" ); and some people know when to use ;'s instead of ,'s. haha
me.extra lines;
it would be nice, but hard to standardise unless everyone used the same rules, and if they won't put the tags on themselves, granted, it's very hard to do, they won't conform!
That's it! Cprog Style Guidelines! Any post that fails to follow them is automatically tossed into the bit bucket. And of course, the style guidelines will reflect my style because I'm just that awesome. :)
I agree, your style reflects mine ... or is it mine reflects yours ... Why don't you write up the standards for CBoard for us then :)
I wouldn't mind a fixed style even if it didn't reflect mine. Some forums actually have that, don't they?
The only thing that I really don't like is the ANSI style when it comes to how curly braces are placed.
ugh!Code:void function()
{
blabla...
}
WHAT! Have you no shame? Are you a
Kida person? I hate them ... I'm going to have to reconsider putting MURK on my site ;)Code:void function(){
blabla...
}
Ok, ok. Darn! I will change my whole coding style just not to lose this opportunity ;)
Another international crisis avoided! Phfew!
(I normally hate using them, but) lol
There can be a checkbox for it.Quote:
Only if it can be explicitly overridden. I doubt I'm the only one who cares about the presentation of a post, and automatic solutions tend to hurt that.
>> it would be nice, but hard to standardise unless everyone used the same rules, and if they won't put the tags on themselves, granted, it's very hard to do, they won't conform!
IMO, If they won't use the tags, they won'y check the box!! Especially the 'newbs'.
EDIT - I can't believe you voted against it, siavoshkc! (sorry to everyone else), but which would you prefer to look at?
Code from here
orCode:int Stuff::save(Stuff *sPtr)
{
ofstream outfile("Outfile.txt");
if( !outfile )
{
cerr << "Couldn't open file" << endl;
return 1;
}
outfile << sPtr->string << endl << sPtr->stringTwo << endl << sPtr->num << endl;
outfile.close(); // I don't trust destructors
return 0;
}
int main()
{
Stuff stuffObject;
strcpy(stuffObject.string, "Hello");
strcpy(stuffObject.stringTwo, "Yo");
stuffObject.num = 10;
stuffObject.save(&stuffObject);
return 0;
}
int Stuff::save(Stuff *sPtr)
{
ofstream outfile("Outfile.txt");
if( !outfile )
{
cerr << "Couldn't open file" << endl;
return 1;
}
outfile << sPtr->string << endl
<< sPtr->stringTwo << endl
<< sPtr->num << endl;
outfile.close(); // I don't trust destructors
return 0;
}
int main()
{
Stuff stuffObject;
strcpy(stuffObject.string, "Hello");
strcpy(stuffObject.stringTwo, "Yo");
stuffObject.num = 10;
stuffObject.save(&stuffObject);
return 0;
}
there's no option!!
Honestly,
Sure, code tags make the board look prettier, but we can tell the difference between code or text without the tags.
EDIT:
Although, the fact that the code tags support indenting is nice.
It shouldn't be enforced. If someone brings in their code sloppiely, then they just risk having people stay away from their post. So they decided.
True, but I personally won't look at code without tags (slight exaggeration, but not by far!!) - it takes four seconds to code tag something. Even if it's not formatted, or whatever, it's nice to distinguish code from not-code at a glance!