@sidd_harth0_5h4h my roommate who is a cat, not a pet cat haha
re: ⚠️ i've been writing python for most of my time on earth ⚠️
@vaporeon_ @monorail @The_T normally in OOP, object instantiation logic is contained within a constructor, but Python decided to split the process into two steps:
1) __new__ is a function which returns the instantiated object,
2) __init__ is a function that receives the instantiated object and and initializes its state
It is very rare that a Python programmer ever use __new__. In 99% of cases, what you would put in a constructor in some other language is put in the __init__ method when you use Python.
You can override __new__, however, so that it returns anything you want. You typically do this when you subclass immutable types. Because, if you try to manipulate a subclassed immutable object in the __init__ function, well you can't. Because its immutable. So you have to override the creation of the object itself, typically by calling the superclass's constructor, in the __new__ method.
@aescling it was a good video
@cam you're bringing me back to my "watching street vendors make chai masala" phase
definitely not an image of clodsire holding a gun
@aescling @Satsuma @vaporeon_ @Lady figure it out and help me.
@aescling @Satsuma @vaporeon_ @Lady thats fine
@vaporeon_ @aescling @Lady damn i need to report website boy for this
@Satsuma @aescling @Lady @vaporeon_ fine, ill do it my fucking self
@aescling @vaporeon_ @Lady I know we can do it technically, I specifically am asking you to add it to our frontend.
@vaporeon_ yeah i reported @aescling and @Lady daily for it but they still haven't fixed it
@cam holy shit once i noticed the eggy crust i pogged irl
@vaporeon_ shit
@aescling @vaporeon_ reported.
@vaporeon_ even more specifically, I had to write C++ as an undergrad in college for my physics research and when reading something that the creator of the language (Rene Brun) wrote, they mentioned you could iterate over some data using a construct like the following:
for (TList&& thing: listOfThings) { /* use the thing /* }
and then Brun was like "if you're not familiar with the double ampersand syntax, its a relatively new language feature called an rvalue reference" and I was like "the fuck is an rvalue reference"
So then I started reading and then eventually got to this web page: https://en.cppreference.com/w/cpp/language/value_category.html
and my poor undergraduate mind was just like o______________________________________o so I gave up on it.
But it lingered in my mind for years later as a Thing That I Could Not Understand. It ate away at me. I tried again later in grad school, only to go o______________________________________o again. Maybe this was simply beyond me.
Flash forward a couple more years and now I'm a software engineer. Then they made me do C++ for work. I'm like, "I'm more familiar with software these days maybe finally I'll undestand it" so I researched it again only to go o____________________________________o once again.
But no, this cannot be! I WILL do it!! I WILL FIND OUT!!!! So i kept at it for months afterwards and he we are.
@vaporeon_ I would much rather my legacy involve Beautiful javascript instead of Nightmare c++
the clodvestigator
i answer to Caleb, Clodsire, Clodboy, Clod, and Bumby. very leftist.
videogame enjoyer. mathematics hobbyist and recovering physicist. recovering software engineer. professional wonk. prophet of The Truth. the walking embodiment of "not diagnosed, but somethings wrong". i like animals that wear cowboy hats.
number of fat cock awards received: 56
header is by @vaporeon_
"i regret ever allowing him here" ~aescling
"oh you're one of those weird movie likers" ~Ti
30+
he/him
sgraMrt