For some reason, this just sparked an ancient memory of the Geek Code, which was a sort of signature block you could append to your emails and online bios to show off how much of a geek you were in the geekiest fashion possible.
"Try" is too hopeful. "fuck_around" makes it clear that you know what you're doing is dangerous but you're going to do it anyhow. I know that in some languages wrapping a lot of code in exception blocks is the norm, but I don't like that. I think it should be something you only use rarely, and when you do it's because you know you're doing something that's not safe in some way.
"Catch" has never satisfied me. I mean, I know what it does, but it doesn't seem to relate to "try". Really, if "try" doesn't succeed, the corresponding block should be "fail". But, then you'd have the confusion of a block named "fail", which isn't ideal. But "find_out" pairs perfectly with "fuck_around" and makes it clear that if you got there it's because something went wrong.
I also like "yeet". Partly it's fun for comedic value. But, it's also good because "throw" feels like a casual game of catch in the park. "Yeet" feels more like it's out of control, if you hit a "throw" your code isn't carefully handing off its state, it's hitting the eject button and hoping
... show more
Yeah, I love that one.
"Try" is too hopeful. "fuck_around" makes it clear that you know what you're doing is dangerous but you're going to do it anyhow. I know that in some languages wrapping a lot of code in exception blocks is the norm, but I don't like that. I think it should be something you only use rarely, and when you do it's because you know you're doing something that's not safe in some way.
"Catch" has never satisfied me. I mean, I know what it does, but it doesn't seem to relate to "try". Really, if "try" doesn't succeed, the corresponding block should be "fail". But, then you'd have the confusion of a block named "fail", which isn't ideal. But "find_out" pairs perfectly with "fuck_around" and makes it clear that if you got there it's because something went wrong.
I also like "yeet". Partly it's fun for comedic value. But, it's also good because "throw" feels like a casual game of catch in the park. "Yeet" feels more like it's out of control, if you hit a "throw" your code isn't carefully handing off its state, it's hitting the eject button and hoping for the best. You hope there's an exception handler higher up the stack that will do the right thing, but it also might just bubble all the way up to the top and spit out a nasty exception for the user.
I visualized "try" as watching a young child climb something that might be out of their comfort zone, so you're letting them, but stay ready to "catch" them if something goes wrong. I suppose "throw" would be if they soiled themselves in their fall, you can throw them back into the arms of their loving parent for cleaning.
But fuck_around, find_out and yeet would be fantastic.
Sure! It doesn't do anything yet, I just have a text file with how I'm intending to architect it.
It quite literally started ~~two~~ four (edit: I can't keep track of time) days ago.
I'll configure a repo, stick this in a file, and push it. I'll reply with another comment so you (and others) can look it up.
I've come up with some crazy stuff. Instead of something like "class" to indicate a class, it's
🏫 Followed by the emoji name of the class like 🖼️📁. So it will need to be able to handle operators in the name it's amazingly gross! Properties and methods will also be emoji names, like to get the 🖼️📁 "File Name" it would be 📁💳.
I was kind of being sarcastic. I haven’t written a compiler since I rode my dinosaur to college. Still it’s a funny idea. Could probably do it in C using a bunch of pound defines.
Aside from how Microsoft stole it, fucked the standard library, fucked the naming conventions, etc. You would never just “throw” without specifying what you were throwing.
To be honest I’m just playing into the meme of Java.
My understanding is it’s academically great, but a pain in practice.
For reference we use C# .Net, Entity Framework with GraphQL and React TypeScript for our enterprise applications and I really like C# now, but when I first started I’d only really used Node.js and some Java.
I started my career in Java and transitioned to c# a few years in and c# is much better imo, especially now that .Net can be run in Linux.
I run a team for a large project (13 deployable components apis/ Windows services/ desktop applications/ websites/mobile) that has mix of vb.net/c# .net framework 4.8 and .net 6 soon to be 8 with angular for Web and wpf for desktop. Slowly but surely working to kill off our legacy code and consolidate.
Some of the older vb code (that existed long before I joined the project let alone became the lead dev) is so bad that a bug fix for nhibernate that stopped silently failing and began throwing exceptions breaks everything if we try to update to a later version. it's such a tangled mess and I'm probably the only one on my team that could unfuck it(but I didn't have the time to do it) it's not even worth fixing even though our version of nhibernate has a CVE with rating of 9/10 (we don't actually use anything that is affected from the finding thankfully) and are just biding our time till we kill off the offending apps.
Ohh and I h
... show more
I started my career in Java and transitioned to c# a few years in and c# is much better imo, especially now that .Net can be run in Linux.
I run a team for a large project (13 deployable components apis/ Windows services/ desktop applications/ websites/mobile) that has mix of vb.net/c# .net framework 4.8 and .net 6 soon to be 8 with angular for Web and wpf for desktop. Slowly but surely working to kill off our legacy code and consolidate.
Some of the older vb code (that existed long before I joined the project let alone became the lead dev) is so bad that a bug fix for nhibernate that stopped silently failing and began throwing exceptions breaks everything if we try to update to a later version. it's such a tangled mess and I'm probably the only one on my team that could unfuck it(but I didn't have the time to do it) it's not even worth fixing even though our version of nhibernate has a CVE with rating of 9/10 (we don't actually use anything that is affected from the finding thankfully) and are just biding our time till we kill off the offending apps.
Ohh and I have a new PM that isn't technical and likes to email me his chat GPT queries and results about technical things.
This is incorrect. The C# is valid. Throw in a catch statement simply rethrows the caught exception. Source: I've been writing C# for 20 years, also the docs.
I won't act like MS absolutely didn't steal core concepts and syntax from Java, but I've always thought C# was much more thoughtfully designed. Anders Hejlsberg is a good language designer, TypeScript is also a really excellent language.
Use the C# throw statement to signal an occurrence of an exception. Use the C# try statements to catch and process exceptions occurred in a block of code.
In Java you would say “throw e;” (to rethrow the same exception you just caught.)
You wouldn’t just say “throw”
Or you could also throw some other exception. But the syntax requires you specify what it is you are throwing. (And sane in C++, where you could throw any object, even a primitive.)
Wildly, in C# you can do either and it has different results. I believe a bare throw doesn't append to the stack trace, it keeps the original trace intact, while throw e updates the stack trace (stored on the exception object) with the catch and rethrow.
In C#, you can only throw objects whose class derives from Exception.
You can do either, but you usually do neither. The best way is to throw a new exception for your situation and add the caught exception as an inner exception. Because rethrowing resets the stack trace, removing the context from an exception message that is often pretty vague, and "bouncing" with throw; doesn't tell the next exception handler that you already handled (part of) the exception.
Florida is basically the unofficial US Capitol now, so it would be confusing and ambiguous to have it associated with the traditional forms of unexpected insanity. Now it's going to be an entirely new kind of unexpected insanity, so Ohio has been selected to represent the old kind of unexpected insanity that Florida used to represent.
It's because we are depressed nihilists who have given up on pretty much everything, running on gallows homour to a point where we are meming youth slang. Don't worry, we're fine haha... Ha...
RVGamer06
in reply to Sjmarf • • •like this
massive_bereavement and Get_Off_My_WLAN like this.
SubArcticTundra
in reply to RVGamer06 • • •9point6
in reply to Sjmarf • • •esoteric programming language
Contributors to Wikimedia projects (Wikimedia Foundation, Inc.)like this
magic_lobster_party, xep, fistac0rpse, massive_bereavement, Get_Off_My_WLAN and timlyo like this.
Demigodrick
in reply to 9point6 • • •A perfectly reasonable language. None of this Gen Z rubbish.
Something something better times. Shakes stick at sky.
like this
massive_bereavement, Get_Off_My_WLAN and timlyo like this.
EntirelyUnlovable
in reply to Demigodrick • • •agentshags
in reply to EntirelyUnlovable • • •My 21 year old is pretty into rust and html. Does that count?
I'm pretty ignorant on most of it. In my youth, I just dabbled trying to lean basic on a c64 and AMOS on the Amiga though, so maybe not lol
e: I think I missed the joke, probably because I'm old lol
cobysev
in reply to 9point6 • • •For some reason, this just sparked an ancient memory of the Geek Code, which was a sort of signature block you could append to your emails and online bios to show off how much of a geek you were in the geekiest fashion possible.
Goddamn I'm old.
Geek Code - Wikipedia
Contributors to Wikimedia projects (Wikimedia Foundation, Inc.)like this
timlyo likes this.
Rob Bos
in reply to cobysev • • •Remember it spawning a bunch of copycats? For a while every community had their own code block. I wrote one for a usenet group i was in at the time.
alt.sysadmin and alt.sysadmin.recovery both had em iirc...
AnUnusualRelic
in reply to cobysev • • •brokenlcd
in reply to Sjmarf • • •like this
fistac0rpse, massive_bereavement and Get_Off_My_WLAN like this.
magic_lobster_party
in reply to brokenlcd • • •like this
massive_bereavement and Get_Off_My_WLAN like this.
The Ramen Dutchman
in reply to magic_lobster_party • • •Quacksalber
in reply to Sjmarf • • •yeet
instead ofreturn
...like this
massive_bereavement, InvestBurnout and DarkenLM like this.
nialv7
in reply to Quacksalber • • •yeet_expr - The Rust Unstable Book
doc.rust-lang.orgwise_pancake
in reply to nialv7 • • •𝒎𝒂𝒏𝒊𝒆𝒍
in reply to Sjmarf • • •like this
massive_bereavement likes this.
ScruffyDucky
in reply to Sjmarf • • •For programmers who need action (cross-generational):
lhartikk.github.io/ArnoldC/
ArnoldC
lhartikk.github.iolike this
massive_bereavement and DarkenLM like this.
pigup
in reply to ScruffyDucky • • •Destide
in reply to Sjmarf • • •like this
massive_bereavement, Get_Off_My_WLAN and Ⓜ3️⃣3️⃣ 🌌 like this.
Whelks_chance
in reply to Sjmarf • • •rtxn
in reply to Whelks_chance • • •like this
Get_Off_My_WLAN likes this.
Whelks_chance
in reply to rtxn • • •mogoh
in reply to Sjmarf • • •like this
DarkenLM likes this.
Bizzle
in reply to mogoh • • •like this
DarkenLM likes this.
Amanduh
in reply to Bizzle • • •kabi
in reply to Amanduh • • •darkdemize
in reply to Bizzle • • •mogoh
in reply to Bizzle • • •BeardedGingerWonder
in reply to mogoh • • •Dyskolos
in reply to Sjmarf • • •like this
DarkenLM and timlyo like this.
noughtnaut
in reply to Dyskolos • • •yeet
keyword, I'm really friggin' diggin' this. [modernisation required]like this
DarkenLM and timlyo like this.
enumerator4829
in reply to noughtnaut • • •The future is now!
Dyskolos
in reply to noughtnaut • • •Hadriscus
in reply to Dyskolos • • •Dyskolos
in reply to Hadriscus • • •jballs
in reply to Dyskolos • • •Until it got to
Well played.
Match!!
in reply to jballs • • •Dyskolos
in reply to jballs • • •Lka1988
in reply to jballs • • •merc
in reply to Dyskolos • • •Yeah, I love that one.
"Try" is too hopeful. "fuck_around" makes it clear that you know what you're doing is dangerous but you're going to do it anyhow. I know that in some languages wrapping a lot of code in exception blocks is the norm, but I don't like that. I think it should be something you only use rarely, and when you do it's because you know you're doing something that's not safe in some way.
"Catch" has never satisfied me. I mean, I know what it does, but it doesn't seem to relate to "try". Really, if "try" doesn't succeed, the corresponding block should be "fail". But, then you'd have the confusion of a block named "fail", which isn't ideal. But "find_out" pairs perfectly with "fuck_around" and makes it clear that if you got there it's because something went wrong.
I also like "yeet". Partly it's fun for comedic value. But, it's also good because "throw" feels like a casual game of catch in the park. "Yeet" feels more like it's out of control, if you hit a "throw" your code isn't carefully handing off its state, it's hitting the eject button and hoping
... show moreYeah, I love that one.
"Try" is too hopeful. "fuck_around" makes it clear that you know what you're doing is dangerous but you're going to do it anyhow. I know that in some languages wrapping a lot of code in exception blocks is the norm, but I don't like that. I think it should be something you only use rarely, and when you do it's because you know you're doing something that's not safe in some way.
"Catch" has never satisfied me. I mean, I know what it does, but it doesn't seem to relate to "try". Really, if "try" doesn't succeed, the corresponding block should be "fail". But, then you'd have the confusion of a block named "fail", which isn't ideal. But "find_out" pairs perfectly with "fuck_around" and makes it clear that if you got there it's because something went wrong.
I also like "yeet". Partly it's fun for comedic value. But, it's also good because "throw" feels like a casual game of catch in the park. "Yeet" feels more like it's out of control, if you hit a "throw" your code isn't carefully handing off its state, it's hitting the eject button and hoping for the best. You hope there's an exception handler higher up the stack that will do the right thing, but it also might just bubble all the way up to the top and spit out a nasty exception for the user.
underreacting
in reply to merc • • •I visualized "try" as watching a young child climb something that might be out of their comfort zone, so you're letting them, but stay ready to "catch" them if something goes wrong. I suppose "throw" would be if they soiled themselves in their fall, you can throw them back into the arms of their loving parent for cleaning.
But fuck_around, find_out and yeet would be fantastic.
Psaldorn
in reply to Sjmarf • • •ratios
I need this and I'm an elder millenialintrovertcatto
in reply to Psaldorn • • •Psaldorn
in reply to introvertcatto • • •peoplebeproblems
in reply to Sjmarf • • •jaybone
in reply to peoplebeproblems • • •peoplebeproblems
in reply to jaybone • • •Haven't published it yet.
Here are comparisons:
⚖️
🐲
🐲⚖️
⚖️🐲
🚫🐲⚖️
jaybone
in reply to peoplebeproblems • • •Post the GitHub repo.
I will help you make this happen.
peoplebeproblems
in reply to jaybone • • •Sure! It doesn't do anything yet, I just have a text file with how I'm intending to architect it.
It quite literally started ~~two~~ four (edit: I can't keep track of time) days ago.
I'll configure a repo, stick this in a file, and push it.
I'll reply with another comment so you (and others) can look it up.
I've come up with some crazy stuff. Instead of something like "class" to indicate a class, it's
🏫 Followed by the emoji name of the class like 🖼️📁. So it will need to be able to handle operators in the name it's amazingly gross! Properties and methods will also be emoji names, like to get the 🖼️📁 "File Name" it would be 📁💳.
jaybone
in reply to peoplebeproblems • • •peoplebeproblems
in reply to jaybone • • •I was thinking Rust, but that works too.
Because then I could call the Language Spoons.
It would as uncomfortable to use as it is to watch Rusty Spoons
jaybone
in reply to Sjmarf • • •stetech
in reply to jaybone • • •C# is basically Java and from what I can tell, this looks approximately valid.
Variables can always* be named freely to your liking.
*You used to have to stick to the Latin alphabet, but that’s increasingly not the case anymore. Emoji-named variables FTW!
jaybone
in reply to stetech • • •No it’s not “basically Java”
Aside from how Microsoft stole it, fucked the standard library, fucked the naming conventions, etc. You would never just “throw” without specifying what you were throwing.
dependencyinjection
in reply to jaybone • • •jaybone
in reply to dependencyinjection • • •dependencyinjection
in reply to jaybone • • •To be honest I’m just playing into the meme of Java.
My understanding is it’s academically great, but a pain in practice.
For reference we use C# .Net, Entity Framework with GraphQL and React TypeScript for our enterprise applications and I really like C# now, but when I first started I’d only really used Node.js and some Java.
jaybone
in reply to dependencyinjection • • •Zannsolo
in reply to jaybone • • •Zannsolo
in reply to dependencyinjection • • •I started my career in Java and transitioned to c# a few years in and c# is much better imo, especially now that .Net can be run in Linux.
I run a team for a large project (13 deployable components apis/ Windows services/ desktop applications/ websites/mobile) that has mix of vb.net/c# .net framework 4.8 and .net 6 soon to be 8 with angular for Web and wpf for desktop. Slowly but surely working to kill off our legacy code and consolidate.
Some of the older vb code (that existed long before I joined the project let alone became the lead dev) is so bad that a bug fix for nhibernate that stopped silently failing and began throwing exceptions breaks everything if we try to update to a later version. it's such a tangled mess and I'm probably the only one on my team that could unfuck it(but I didn't have the time to do it) it's not even worth fixing even though our version of nhibernate has a CVE with rating of 9/10 (we don't actually use anything that is affected from the finding thankfully) and are just biding our time till we kill off the offending apps.
Ohh and I h
... show moreI started my career in Java and transitioned to c# a few years in and c# is much better imo, especially now that .Net can be run in Linux.
I run a team for a large project (13 deployable components apis/ Windows services/ desktop applications/ websites/mobile) that has mix of vb.net/c# .net framework 4.8 and .net 6 soon to be 8 with angular for Web and wpf for desktop. Slowly but surely working to kill off our legacy code and consolidate.
Some of the older vb code (that existed long before I joined the project let alone became the lead dev) is so bad that a bug fix for nhibernate that stopped silently failing and began throwing exceptions breaks everything if we try to update to a later version. it's such a tangled mess and I'm probably the only one on my team that could unfuck it(but I didn't have the time to do it) it's not even worth fixing even though our version of nhibernate has a CVE with rating of 9/10 (we don't actually use anything that is affected from the finding thankfully) and are just biding our time till we kill off the offending apps.
Ohh and I have a new PM that isn't technical and likes to email me his chat GPT queries and results about technical things.
dependencyinjection
in reply to jaybone • • •CodexArcanum
in reply to jaybone • • •This is incorrect. The C# is valid. Throw in a catch statement simply rethrows the caught exception. Source: I've been writing C# for 20 years, also the docs.
I won't act like MS absolutely didn't steal core concepts and syntax from Java, but I've always thought C# was much more thoughtfully designed. Anders Hejlsberg is a good language designer, TypeScript is also a really excellent language.
Exception-handling statements - throw and try, catch, finally - C# reference
learn.microsoft.comjaybone
in reply to CodexArcanum • • •In Java you would say “throw e;” (to rethrow the same exception you just caught.)
You wouldn’t just say “throw”
Or you could also throw some other exception. But the syntax requires you specify what it is you are throwing. (And sane in C++, where you could throw any object, even a primitive.)
So that was my question.
CodexArcanum
in reply to jaybone • • •Wildly, in C# you can do either and it has different results. I believe a bare
throw
doesn't append to the stack trace, it keeps the original trace intact, whilethrow e
updates the stack trace (stored on the exception object) with the catch and rethrow.In C#, you can only throw objects whose class derives from Exception.
Hoimo
in reply to CodexArcanum • • •throw;
doesn't tell the next exception handler that you already handled (part of) the exception.dependencyinjection
in reply to stetech • • •MystikIncarnate
in reply to Sjmarf • • •Clay_pidgin
in reply to MystikIncarnate • • •I have many gray hairs, but here's what I know.
like this
DarkenLM likes this.
dependencyinjection
in reply to Clay_pidgin • • •You missed
Also got many grey hairs but I like to know what people mean and language evolves. Our generation did it too you get me blud.
Clay_pidgin
in reply to dependencyinjection • • •dependencyinjection
in reply to Clay_pidgin • • •introvertcatto
in reply to dependencyinjection • • •MystikIncarnate
in reply to introvertcatto • • •cecilkorik
in reply to MystikIncarnate • • •Clay_pidgin
in reply to dependencyinjection • • •It's recognized by the yoots as the worst state, so being Ohio is bad!
It's worse than "mid", which is meh.
AeonFelis
in reply to Sjmarf • • •Kazumara
in reply to AeonFelis • • •lowkey period
we can't be sureMatch!!
in reply to Sjmarf • • •katy ✨
in reply to Sjmarf • • •admin
in reply to katy ✨ • • •Scrubbles
in reply to Sjmarf • • •Ugh. Just
its_giving rizz ratios vibe;
No more needless nesting plz
TwilightKiddy
in reply to Scrubbles • • •Considering
vibe
is probalbyfloat
, I doubt any exceptions can be thrown there, you can eliminate another useless scope.Even if it's not
float
, I'd consider burning alive anyone who overrides an operator like this anyway.Lemminary
in reply to TwilightKiddy • • •Float
? Do you meanfax
? Get with the program, old manTwilightKiddy
in reply to Lemminary • • •period
andfax
intentionally, I commend the effort.rumba
in reply to Scrubbles • • •cows_are_underrated
in reply to rumba • • •rumba
in reply to cows_are_underrated • • •JokeDeity
in reply to Sjmarf • • •ulterno
in reply to Sjmarf • • •I got all of it No Tea
Ⓜ3️⃣3️⃣ 🌌
in reply to Sjmarf • •Programmer Humor reshared this.
Lightfire228
in reply to Sjmarf • • •yeet;
as an aliasthrow;
is hilariouslike this
Ⓜ3️⃣3️⃣ 🌌 likes this.
BeardedGingerWonder
in reply to Lightfire228 • • •Ropianos
in reply to BeardedGingerWonder • • •Jezza
in reply to Lightfire228 • • •Funnily enough, that is a keyword in rust.
(it's a placeholder to remove any bikeshedding)
yeet_expr - The Rust Unstable Book
doc.rust-lang.orgratel
in reply to Lightfire228 • • •GitHub - face-hh/bussin: An esolang in TypeScript, for heaven's sake.
GitHubiAvicenna
in reply to Sjmarf • • •like this
Ⓜ3️⃣3️⃣ 🌌 likes this.
straightjorkin
in reply to Sjmarf • • •Lemminary
in reply to straightjorkin • • •rumba
in reply to Sjmarf • • •Aliasing no_cap and cap to true and false.....
I might have to steal that.....
sheepishly
in reply to Sjmarf • • •Psythik
in reply to sheepishly • • •UnfortunateShort
in reply to Psythik • • •JakenVeina
in reply to Sjmarf • • •InFerNo
in reply to Sjmarf • • •WhiskyTangoFoxtrot
in reply to Sjmarf • • •mcqtom
in reply to Sjmarf • • •phlegmy
in reply to mcqtom • • •kamen
in reply to Sjmarf • • •Ⓜ3️⃣3️⃣ 🌌 likes this.