Register - Login
Views: 95203097
Main - Memberlist - Active users - Calendar - Wiki - IRC Chat - Online users
Ranks - Rules/FAQ - Stats - Latest Posts - Color Chart - Smilies
09-24-18 02:11:33 AM

Jul - Craziness Domain - Oops! All comments New poll - New thread - New reply
Pages: 1 2Next newer thread | Next older thread
Xkeeper

Level: 244


Posts: 23139/23358
EXP: 228608862
For next: 1578404

Since: 07-03-07

Pronouns: they/them, she/her, etc.

Since last post: 2 days
Last activity: 6 hours

Posted on 01-26-18 01:31:06 AM Link | Quote
I never understood why more people don't use Lua comments like this:


--[[

...

--]]



I don't know where I got the habit, but I'm glad I did.
Trace Bullet
User
Level: 10


Posts: 12/18
EXP: 4274
For next: 140

Since: 02-25-10

From: Indiana

Since last post: 144 days
Last activity: 3 days

Posted on 01-26-18 01:43:50 AM Link | Quote

/// <summary>
/// I live in C# land, so my comments tend to get fancy summary tags.
/// </summary>
Xenesis
Actually a Doctor
Level: 94


Posts: 2411/2530
EXP: 8124472
For next: 232185

Since: 07-28-07

Pronouns: he/him
From: The Land of Kangaroos and Drop Bears

Since last post: 2 days
Last activity: 1 day

Posted on 01-26-18 01:58:18 AM Link | Quote
;The only code I know how to write is pretty much ASM
;so that's the only comments I really use.

#although I've dabbled in a bit of python now.
#Huzzah for commenting styles I guess?
Kawaii-e

Red Koopa
Collecting Dust and Games
Level: 25


Posts: 71/122
EXP: 85871
For next: 3749

Since: 08-12-07

From: Rhinefalls

Since last post: 1 day
Last activity: 7 hours

Posted on 01-26-18 04:55:28 AM Link | Quote
Originally posted by Xkeeper
I never understood why more people don't use Lua comments like this:


--[[

...

--]]



I don't know where I got the habit, but I'm glad I did.


Then 'Ill start getting into the habit now.
-- But mostly only comment out single lines anyway.
Sanqui
1750
🦉
Level: 77


Posts: 1653/1750
EXP: 4141147
For next: 49982

Since: 12-20-09

Pronouns: any
From: Czechia (NEW!)

Since last post: 7 days
Last activity: 5 days

Posted on 01-26-18 06:44:57 AM Link | Quote
"""In Python, you can sometimes comment out chunks of code like this.

Technically, it's just a block string literal. Nothing is done with it, so it just goes away, much like a comment."""
Xkeeper

Level: 244


Posts: 23159/23358
EXP: 228608862
For next: 1578404

Since: 07-03-07

Pronouns: they/them, she/her, etc.

Since last post: 2 days
Last activity: 6 hours

Posted on 01-26-18 07:40:53 PM (last edited by Xkeeper at 01-26-18 07:41:07 PM) Link | Quote
You can do that in PHP, too, but not quite as nicely. I found out that particular trick when my idiot former boss wrote code like this:


while (true) {
...
"this is some cool code showing a neat thing";
}



...because it turned out that it was just copied and hacked from an example, and he removed almost all of the code from it:


while (true) {
...
if (fart) {
print "this is some cool code showing a neat thing";
lots_of_other_crap()
for (many lines) {}
}
}



marrub

Level: 9


Posts: 9/32
EXP: 2823
For next: 339

Since: 01-23-18


Since last post: 14 days
Last activity: 7 days

Posted on 01-26-18 09:10:52 PM Link | Quote

/+ D has some
/+ pretty sweet nested comments. +/
It's a nice language.
+/

/// DDoc also makes documentation easy with these.
Pages: 1 2Next newer thread | Next older thread
Jul - Craziness Domain - Oops! All comments New poll - New thread - New reply




Rusted Logic

Acmlmboard - commit 5d36857 [2018-03-03]
©2000-2018 Acmlm, Xkeeper, Inuyasha, et al.

27 database queries.
Query execution time: 0.147386 seconds
Script execution time: 0.011465 seconds
Total render time: 0.158850 seconds
Memory used: 786432