But if I've written a nested loop in an if statement or something, then I'll normally let them hang, and pop a little comment on the end of each one reminding me as to what it's closing.
You should always tuck them in; a reader should be able to infer the logic flux by looking at the indentation alone, wich a decent editor should produce automatically. That said, I'm not an espert so I might be wrong.
Name:
Anonymous2012-04-02 15:32
you could switch to a powerful, modern, and elegant scheme dialect such as javascript
Is there a latex-like code formatter that ties with a compiler?
Or even something which accepted basic XML tags?
That way all autists could have their own formatting, though they'd be niggers upon niggers because they would be arguing that only their formatting is valid and everyone else should use their's.
Name:
Anonymous2012-04-02 16:41
>>10
Lisp should've had FIOC instead of closing parentheses.
>>20
every single decent lisper has already done this
Name:
Anonymous2012-04-03 1:11
>>20
No. Get the fuck out of here with that stupid shit.
Name:
Anonymous2012-04-03 3:34
>>21
having a text editor that matches parenthesis is enough. If you want, the editor can enforce indentation via the parens.
Name:
Anonymous2012-04-03 3:39
Whoever thinks forced indentation is a good idea needs to be brutally and savagely beaten about the head and neck.
Name:
Anonymous2012-04-03 5:27
>>24
Whoever thinks forced indentation is a bad idea needs to ;};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};};}
>>18
I should have been more precise; what I actually meant is that the reader shouldn't have to count the number of parens in the clusters that tend to form at the end of lines, he should be able to tell how many lists have been closed by the change of indentation; OTOH, losing the parens that are not at the end of a line would make a lot of statements ambiguous. As to why there is no syntactic sugar nor FIOC (like closing multiple paretheses with ] ), I think it's so that you can better appreciate the power and elegance of the language; you can also more easily make your own compiler/interpreter that way; essentially, and I know CLISP guys are gonna hate me, LISP is a pretty toy language and it should stay that way.
Name:
Anonymous2012-04-03 13:35
>>28
yes. if you want to see what a proper lisp can do, especially in the right hands, look at javascript.
It's the proper Lisp style and most editors support it nicely.
Even then you can place a closing paren on an empty line (for example, if a list is incomplete or automatically generated), but it should be placed with the same alignment as the previous line, so:
(list
'(like this))
or for incomplete lists (bad style, but better than the C-like one):
(list
'(like this)
)
Name:
Anonymous2012-04-03 23:46
>>27
Short responses like that are ambiguous enough to leave the impression of having a point, but when you have a string of such short responses associated together, there is enough information to infer that you don't know what you are talking about.
Name:
Anonymous2012-04-03 23:49
>>28
yes. if you want to see what a proper dynamic langauge can do, especially in the right hands, look at this one dynamic language that I happen to like.
Name:
Anonymous2012-04-03 23:54
If M-expressions were invented, developers might all be using Lisp instead of C++.
>>33
you sound mad. i bet you use shitty languages like python
Name:
Anonymous2012-04-04 0:52
>>36
I was only a little bit mad. I use every shitty language equally.
Name:
Anonymous2012-04-04 2:53
>>32
Fuck off and die you cock sucker. I know perfectly well what I am talking about. Readability is important and denying that is a great sign of being an autistic retard. The best way to fix Lisp's problem is by allowing significant indentation. Now go lick another toilet you mental plunger.
Name:
Anonymous2012-04-04 4:58
>>38
Is any language readable with no indentation? And I mean a language with nested structures. Assembly and short perl scripts with no sub routines are not applicable, because their syntax only needs to express a sequence of one lines statements.
For me it's the stupid mistakes. Like doing:
(let (a 2)
(+ a a))
instead of:
(let ((a 2))
(+ a a))
Both of these read correctly at first to a person, but only one works.
Name:
Anonymous2012-04-04 9:10
>>23 Fixing language flaws in the editor is mindblowingly idiotic.
Computers exist to be used. You use computers to perform repetitive tasks. If you don't, you may as well return to the abacus.
>>43
Way to fuck up the correction. My dick could use some sucking.
Name:
Anonymous2012-04-04 12:17
>>45
Aww, you went to cry to your mommy and she gave you a comeback to use against those mean people on the Internet? Go scrub another midget you human toilet.
Name:
Anonymous2012-04-04 21:32
>>43 Coding is meant to be as simple as text editing.
Are you implying that it isn't?
Name:
Anonymous2012-04-05 0:02
>>47
Requiring emacs+paredit just to get a fairly comfortable coding environment means it isn't that simple.
Name:
Anonymous2012-04-05 0:14
>>43
but people use notepad and word for text editing when only newbs use it for coding.
>>50
the first is a primitive text editor that comes with the windows operating system. It has limited features, does not scale well to large files, and does not handle various styles of new lines well.
Microsoft Word is the word processor component of Microsoft Office. Is is a powerful wysisyg word processor, but should not be used for the creating of text files, which is often what is needed when programming.