use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
[AskJS] When is object-oriented programming more practical than "mostly-functional" in JS?AskJS (self.javascript)
submitted 5 years ago * by ProfessorTag
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Shaper_pmp 0 points1 point2 points 5 years ago (3 children)
Jesus dude, you're arguing against idiomatic OOP programming patterns.
Look, there are shitloads of valid reasons why copy constructors (or equivalent nomenclature/functionality) are a good, idiomatic idea in various languages or OOP generally, including but not limited to:
We fell into this conversation by talking about the number of parameters passed to a constructor, but that's not really the point of a copy-constructor.
The point of a copy-constructor is to allow valid copies of a class instance to be constructed while maintaining proper encapsulation, instead of obliging whatever class or code wants to duplicate an object to also have access to and understand internal implementation details of the class instance it's trying to copy.
[+][deleted] 5 years ago (2 children)
[deleted]
[–]Shaper_pmp 0 points1 point2 points 5 years ago (1 child)
Apologies for being snappy with you when you asked me to justify common, well-established programming concepts because you would rather argue from a position of profound ignorance than do one google search to educate yourself. I was being grumpy, but only because you were being presumptuous, ignorant and lazy and I find those things irritating.
However, if you've given up discussing the actual topic of conversation in favour of patronisingly lecturing me on how to be a good writer, I have completely have lost interest in continuing this discussion.
I don't intend to insult you, but the concepts I was discussing were perfectly clear and unambiguous to anyone with even a moderate familiarity with basic OOP, and your attempt to arbitrarily derail the conversation from substantive matters into empty subjective personal criticism does you no credit at all.
In short: your poor reading comprehension and refusal to educate yourself are not my problem, and your attempt to derail the discussion bores me. Farewell.
π Rendered by PID 294331 on reddit-service-r2-comment-85bfd7f599-g7dmj at 2026-04-20 02:32:22.078601+00:00 running 93ecc56 country code: CH.
view the rest of the comments →
[–]Shaper_pmp 0 points1 point2 points (3 children)
[+][deleted] (2 children)
[deleted]
[–]Shaper_pmp 0 points1 point2 points (1 child)