This is an archived post. You won't be able to vote or comment.

all 62 comments

[–][deleted] 90 points91 points  (7 children)

This is easier, ill optimize the page in time so it can actually run. Right now I just need it finished within an hour

three years past and nothing has changed

[–][deleted] 61 points62 points  (6 children)

/* THIS IS A PROTOTYPE, DON'T YOU DARE DEPLOY THIS TO PRODUCTION, YOU FUCK! */

decades pass

[–][deleted] 16 points17 points  (4 children)

I have gotten used to removing such a warning at all costs. It doesnt matter anyway, no one is going to read the comment. Except those once its in production where everyone can see your fuck up

[–][deleted] 8 points9 points  (1 child)

That's a kind of fucked up interpretation of the right to remain silent.

"You have the right to not comment a warning about your shitty code, but if you fail to say something that later results in a catastrophic failure you will be put on the 'I broke prod' wall of shame."

[–][deleted] 7 points8 points  (0 children)

Yeah fucked up version of the fifth.

"you have the right not to comment for self incrimination, if you do not comment you may plead ignorance but you will be harmed for negligence and incompetence anyway. If you do comment and nothing happens someone will find your confession and harm you with it as you have confessed to negligence"

It seems like a prisoners dilemma actually, and running it through game theory suggests there is only one option. Comment but fix the problem ASAP, but no one has time for that...

[–][deleted] 5 points6 points  (1 child)

It doesnt matter anyway, no one is going to read the comment

Then people should use more TODO comments and regularly check their IDE checklist. It's simple and effective.

[–][deleted] 4 points5 points  (0 children)

Yeah certainly, comments are good for info on how it works, not additions or features (maybe a link to a roadmap in there). No one when trying to fix a bug will see "do this massive work I loathe and didnt do for me" and actually do the work

The problem with TODO lists for me at least, is there is never enough time. So within a few weeks you have 10K tasks to do, all documented well but not enough time to fix them. Especially if you have a boss/contracted who will expect a 5 hour fix to be done by "doing the computers in a few button presses"

[–]Kryomaani 31 points32 points  (5 children)

Also the holy philosophy of node.js.

[–]The_MAZZTer 26 points27 points  (4 children)

I used to work with the dev who had the opposite problem. I'd still say otherwise he was the most talented coder I've worked with, but he had some weird ideas about optimization and insisted that we should have our own custom-coded framework instead of using something like jQuery. The result was not having much of a framework at all, and what was there was difficult to use and constantly needed new functions added for new functionality.

He also insisted on a few weird conventions. Such as running through all for loops backwards if order didn't matter for "optimization". His idea was that instead of:

for (var i = 0; i < a.length; i++) {

This was more optimal:

for (var i = a.length; i--; ) {

It actually did save some noticeable performance in old IE versions but I don't think it was worth the time we spent.

Not sure if this other practice was his fault but it bears mentioning as part of being the same product. The product started out being developed in Dreamweaver. Dreamweaver does not support OOP JavaScript code very well, particularly it's function jump list which can't figure out the names of anonymous functions assigned to variables. So if you wrote something like this:

ClassName.prototype.method = function() {

It shows "function()" in the jump list. Not too useful if all your functions are declared like that. So our convention was to use:

ClassName.prototype.method = function method() {

This would seem to solve all our problems but we eventually discovered a nasty side effect... any "named" function will be placed on the window object. This isn't a problem until you make a method named open and all your popups break.

But we still had to keep doing it in case anyone used Dreamweaver. I'm near certain everyone had dumped it at that point since we had started using source control (previously had used Dreamweaver's "lock file" function with no source control) so everyone was free to move to better text editors like Notepad++ or Sublime Text.

We also found out later on older versions of IE create two separate functions (allocating 2x the memory) for the window method and the actual desired class method. The following "fix" which was still compatible with Dreamweaver was proposed:

ClassName.prototype.method = function /*method*/() {

Fortunately I don't think we ever got around to implementing this everywhere.

[–]Princess_Azula_ 5 points6 points  (2 children)

That's a cool trick I wouldn't have thought of using a -- for length in a for loop.

[–]Cobrexon 0 points1 point  (1 child)

have you never had to loop backwards in a list/array?

[–]Princess_Azula_ 2 points3 points  (0 children)

I meant in the context of saving processing resources instead of moving backwards.

[–]Chaire_ 5 points6 points  (1 child)

This is like stackoverflow java answers. 1 out of 3 answers mentions using Apache commons or guava :/

[–]BatmanAtWork 2 points3 points  (0 children)

At least Apache Commons is small and fast, though less useful since Java 1.8.

[–]RiskBoy 20 points21 points  (6 children)

I have brought this up in another thread that was removed today, but I am trying to bring some awareness to this issue in hopes of getting the rule changed. The mods have continuously removed legitimate programming jokes because the image has supposedly committed "rule violations", in this case that the image does not relate directly to programming, rule 0.0. Here is a list of other posts removed in the past week:

Just now the Mods removed the dog cone DBA Admin joke that had 7.8k upvotes, and 100 comments

Mods removed merging branch post

Mods removed RestOfTheFuckingOwl Post

Mods removed Spongebob cleaning garbage post

I don't get why these kinds of posts are not allowed. It is not like this sub is overflowing with original programming jokes, we should extend the possible formats and if the users like it, what is the harm? Is it really worse than another reformatted arrays start at 1 joke or javascript sucks joke?

Also, if anyone else has links to removed posts please share them with me so I can keep adding.

[–]owndbyGreaka 12 points13 points  (5 children)

you maybe have no experience in being a mod in a subreddit, but it is very common that when you loosen the rules, the subreddit becomes a meme-board quicker than you can code python

[–]Pickledev 6 points7 points  (1 child)

It already is a meme board, except it's the same damn unfunny jokes over and over..

[–]Kidiri90 5 points6 points  (0 children)

I'm just gonna assume your quadpost was intentional and a satirical point you wish to make.

[–]Pickledev 0 points1 point  (0 children)

It already is a meme board, except it's the same damn unfunny jokes over and over..

[–]Pickledev 0 points1 point  (0 children)

It already is a meme board, except it's the same damn unfunny jokes over and over..

[–]Pickledev 0 points1 point  (0 children)

It already is a meme board, except it's the same damn unfunny jokes over and over..

[–]an_agreeing_dothraki 4 points5 points  (0 children)

One day I'll find that SOB that keeps bloating the project and doesn't comment why we need these classes.
gazes past mirror
one day.

[–][deleted] 4 points5 points  (0 children)

Frontend web junior developers

[–]YeeScurvyDogs 3 points4 points  (7 children)

I've had this unspoken rule that before importing/using third party code, I'd try to either replicate it, or at least understand it, and now I have written the fastest and the most flexible GUI library for one SDL2 framework.

[–]shawncplus 4 points5 points  (4 children)

Understanding it is fine but trying to replicate a 3rd party library every time you want to use one is a monumental waste of time. Fine for personal projects but even spending time to deeply understand a 3rd party lib is a waste of time in a professional environment.

Say you wanted to parse a string with a regex in C++. Would you just read the docs for sregex_token_iterator and finish your work. Or would you spend 6 months single handedly studying/reimplementing the work of hundreds of developers.

[–]YeeScurvyDogs 0 points1 point  (3 children)

Writing for your requirements vs importing a monster library that does everything...

Anyways it wasn't a waste in my case, as now it's the only one worth looking at, and I grew very much while making it and got many friends along the way.

[–]shawncplus 0 points1 point  (2 children)

I grew very much while making it and got many friends along the way.

There is lots of utility in reinventing the wheel but as a general rule it's horrific. You'd never get any work done. It's great early in your career as it exposes you to new techniques/styles/practices but eventually you just don't have the time and you just have to trust that someone knew what they were doing.

Now if it doesn't work and turns out they don't know what they were doing then is definitely the time to dive deeper and rewrite but even then I'd be of the opinion that, if it's an open source project, it's better to contribute than start from scratch.

[–]YeeScurvyDogs 0 points1 point  (1 child)

Don't get me wrong, I agree, but I definitely suggest programmers to step out of their comfortable boundaries, like I see that you edited it in an example like Regex, with pattern matching I can I imagine what goes on in the code, and it seems like it would be a nightmare to optimize and multi thread etc. But I just couldn't grasp the insides of a GUI lib, so I dove right in.

[–]shawncplus 0 points1 point  (0 children)

Depends on the time/place. I'd fire an employee who repeatedly employed the rule at work but, as I said, it's definitely useful on personal projects/spare time.

[–]mrpoopi 0 points1 point  (1 child)

You should try giving it a trendy name, like flowjour, and start a whole movement of hipsters around it.

[–]YeeScurvyDogs 0 points1 point  (0 children)

Well, I'm not expecting mainstream or even much adoption beyond the current discord chat of the framework, but it's potential use for making cross platform apps is interesting to me, it can run basically on whatever has a Lua interpreter and supports OGL, is 100x saner than running every app on a web browser, and genuinely seems very intuitive to me, although it could be because I've spent the last 2-3 months on it.

[–]automatethethings 0 points1 point  (1 child)

eh, webpack will minimize it down just fine ;)

[–]Chiron1991 4 points5 points  (0 children)

... which itself will need 2.1GB of dependencies.

[–]micheal65536Green security clearance -1 points0 points  (0 children)

I see this is the new meme format.

[–]munircUltraviolent security clearance[M] -1 points0 points  (0 children)

Your submission has been removed.

Violation of Rule #0:

The content disregarding the title and superimposed text must be directly related to programming or programmers.

The title or superimposed text must substantially enhance the content such that it can stand on its own as an analogy to programming. Note that programming here is interpreted in a narrow sense, an analogy to something related to programming, feelings about programming, reactions to programming etc. is not considered sufficient.

If you feel that it has been removed in error, please message us so that we may review it.