@LucasKauffman I've been learning a lot about it, and I agree it has cool points, but I'm not sure about converting all code to scala, including ditching XML and JSON data formats in favour of specialized scala objects ...
@this.josh It was theoretically a good idea, but it took a very bureaucratic approach to extensibility. And now it's the least-safe part of any TLS implementation.
interesting IT Sec loop: Corp IT locks down IE, HR uses third party Java app requiring Java 6 plugin, IT provides local download for the plugin, but plugin can not be installed because lockdown rules consider it insecure. Works fine on Chrome, Firefox, Opera... IT Sec fail.
@tylerl Scala is a "get shit done" language in the sense that it's the most optimal choice of language if you want those hipster devs your hired to actually write code for the JVM.
Peyton Williams Manning (born March 24, 1976) is an American football quarterback for the Denver Broncos of the National Football League (NFL). A five-time league MVP, he played for the Indianapolis Colts for 14 seasons between 1998-2011. He is a son of former NFL quarterback Archie Manning and an elder brother of New York Giants quarterback Eli Manning.
Manning played college football for the University of Tennessee, leading the Volunteers to the 1997 SEC Championship in his senior season. However, No. 3 Tennessee lost to the No. 2 Nebraska Cornhuskers 42-17 in the Orange Bowl, giving Nebraska...
other than that - spaces/tabs, braces on same line / new line, parantheses spaces / no spaces, empty argument list / no list, etc etc etc for all other silly formatting preferences.
@M'vy extra points if they indent it as if it is all part of the same block.
One interesting variant (which I don't use personally) is putting the then part in the same line as the if itself. That way they can't be torn apart by accident.
And I'm also aware that a style isn't there to suit one's personal preferences -- you can't please everyone all the time. Select one that's widely used and stick to it, if possible use tool support to enforce it.
One compromise rule could be: Braceless if is only okay if the then statement transfers control elsewhere (e.g. throws an exception, returns, breaks, etc.).
That way most accidents lead to unreachable code, which should trigger a compiler warning.
and most of my simple ifs would fall under this rule. e.g. if(x==null)throw new NullReferenceException(), if(x==y)break;
@M'vy I used to omit the braces because it was saving one line (the one with the closing brace). Under the rational reason that saving lines was increasing the amount of code that could be embraced by my eye without vertical eye movement.
@AviD I came to the conclusion that I write code not only for myself, but also for other people, and I had to write code that other people can read comfortably, too.
@AviD Actually I have had good success rereading my own code much later on, since about 2003. I still improve my coding style for people other than myself (at any space-time location).
It depends for what though, when the only purpose of the if is to pluralize something or not, depending if the index is higher than 1, it is very tempting to do a 1 liner.
The proper solution would be using the remote ip of the TCP connection by default, but allowing you to configure it differently (if you have some kind of load balancer or reverse proxy)
since it has always been an argument, and *always will be*, the only acceptable answer - is to put in some placeholder, and let each programmer format according to his/her personal preference (or ascribed dogma).
@TerryChia you're wrong. any other possible answer you try to come up with is just forcing a square peg in a round hole. There is no possible reason to force such a stupid formatting requirement - except consistency, which is amply solved by the placeholder+tool-formatting solution.
@AviD I think any large programming project has undesirable properties. These are called compromises... usually between engineering ideals and getting stuff done. That doesn't mean it's exemplary code; it also doesn't mean it's terrible.
@AviD The standard is a tab for your project. It isn't for 99% of Python / Ruby / whatever projects. Stop trying to force others to accept tabs as standard.
@TerryChia Ah, that's why I got confused. Taken from the doc: "Use underscores, not camelCase, for variable, function and method names (i.e. poll.get_unique_voters(), not poll.getUniqueVoters"
but then I'm making a subtle distinction when programming communities in general would rather argue about tabs versus spaces. I'm in the wrong f***ing job.
since it has always been an argument, and *always will be*, the only acceptable answer - is to put in some placeholder, and let each programmer format according to his/her personal preference (or ascribed dogma).
@RоryMcCune Yeah, the cool thing about RPython is that it's theoretically possible to have different compile targets. The C target is the only one actually working decently at the moment.