There have been multiple accounts created with the sole purpose of posting advertisement posts or replies containing unsolicited advertising.

Accounts which solely post advertisements, or persistently post them may be terminated.

programmer_humor

This magazine is from a federated server and may be incomplete. Browse more on the original instance.

Blackmist , in Hate it when that happens

No, there’s one other person, it was 14 years ago, and the only response was themselves saying “nvm, figured it out”

Mesa ,
@Mesa@programming.dev avatar

Marked as solution.

Underwaterbob , in Hate it when that happens

Or when you have a problem that seems adjacent to another problem that many people have, but their solution doesn’t work for your niche case.

zarkanian ,
@zarkanian@sh.itjust.works avatar

This happens much more often than the other one.

photonic_sorcerer , in Teenagers.

Okay so this place being coded by dumbasses is a security issue, right?

onlinepersona ,

Hey at least you’re not hosting it! And alternatives are being worked on like PyFed (PieFed?), another thing in Java, Mbin, and probably others.

Anti Commercial AI thingyCC BY-NC-SA 4.0

Batman ,

We hooked up chatgpt to do code reviews so this is no longer a problem. The Children yearn for the stack

deadbeef79000 , in No matter how smart you're, end user is smarter than you

That contraction upsets me on some base level.

neurospice , in No matter how smart you're, end user is smarter than you

This antimeme has hurt my soul

makingStuffForFun , in No matter how smart you're, end user is smarter than you
@makingStuffForFun@lemmy.ml avatar

I get the feeling the meme creator is a senior dev. Putting themselves right up there. At the top.

FlaminGoku ,

Head in the clouds, no idea what’s going on?

makingStuffForFun ,
@makingStuffForFun@lemmy.ml avatar

Ahhh now I get it. Nice.

alexdeathway , in When everyone became paranoid
@alexdeathway@programming.dev avatar

My Firefox package updates are usually slow, limiting downloads to <500kb. So, whenever the download speed used to drop, I knew Firefox released an update.

So when the XZ articles started popping up, the first thing I did was verify all sources.

programming.dev/post/12370824

stepanzak , in No matter how smart you're, end user is smarter than you

I have no idea what am I looking at

TheAgeOfSuperboredom , in What are variables and semicolons for actually?

Yeah, semicolons are ugly anyway and they’d ruin the beautiful expression of your code.

OpenStars ,
@OpenStars@startrek.website avatar

POV: your project manager went in an “cleaned” it all up by removing them - your (sic) welcome! 😜

dohpaz42 ,
@dohpaz42@lemmy.world avatar

On a more serious note, does rust suffer some of the same issues as JavaScript when it comes to omitting semicolons?

Deebster ,
@Deebster@programming.dev avatar

No…?

marcos ,

Do not expect to find anything like Javascript craziness on other languages. Or you’ll be severely disappointed.

FizzyOrange ,

There are plenty of languages with warts at least as bad as JavaScript’s. Bash, PHP, C, even relatively sane languages like Python still have huge issues like implicit variable declaration.

SpaceNoodle ,

JS and PHP are by themselves in a special ring of hell.

TadoTheRustacean OP ,

Bash is a bigger one. Luckily there’s nushell

jubilationtcornpone ,

<span style="color:#323232;">for (const item in items) { }
</span>

!=


<span style="color:#323232;">for (const item of items) { }
</span>
xigoi ,
@xigoi@lemmy.sdf.org avatar

Still better than


<span style="color:#323232;">for _, item in ipairs(items)
</span>
TheAgeOfSuperboredom ,

Nope. In Rust, a semicolon denotes a statement while a lack of semicolon is an expression so you can’t just omit them at will. This does lead to cool things though like if/else blocks being able to produce values if they end in an expression. But the expression type is checked so you’re less likely to make a mistake. You can see an example here: doc.rust-lang.org/rust-by-example/…/if_else.html

In JavaScript I never skip semicolons because I’ve seen those subtle bugs.

sudo , in Teenagers.

Manic episode, part 3

colournoun , in What are variables and semicolons for actually?

Isn’t this basically how lisp works?

TheAgeOfSuperboredom ,

Yup! Also languages in the ML family and others I’m sure.

Zagorath , in No matter how smart you're, end user is smarter than you
@Zagorath@aussie.zone avatar

Like @deadbeef79000, I was bothered by the contraction. So I decided to Google it in the hopes of explaining why exactly it’s wrong, in case you’re a second-language speaker.

I honestly thought there would be a simple explanation, but it turns out that there doesn’t seem to be one. I found one Reddit thread which linked to a now-defunct blog (luckily, [it’s still available through the Wayback Machine), another that linked to an earlier Reddit thread, inside of which was yet another link to an even earlier thread. Here’s the most recent of the threads in that chain if anyone wants to read it. But below is quoted the important bit from that archived blog post:

You CAN end a sentence with a contraction if it is a Type 2 (Verb-Negative), both in speaking and writing. You are always in safe territory when you end a sentence with a negative contraction.

Examples:

  • No, I don’t.
  • I’m a student, but she isn’t.

For a Type 3 (Modal + “have”), English expert Eugene Mohr says in his article in TESOL Quarterly, “The Independence of Contractions”, that “no contraction takes place if….have occupies the final position” in a sentence. HOWEVER, Mohr limits his explanations to contractions in written language, not spoken. In informal speech, native speakers often contract a modal with “have” at the end of a sentence. So, while it looks funny written out, you will hear people end a sentence this way.

Example:

  • I didn’t go to church, but I should’ve.

Last, and most importantly, you CANNOT end a sentence with contraction if it is a Type 1 (Pronoun-Verb). Not in formal English, not in informal English – never! In this case, you must write out the entire verb that follows the pronoun. So take a look at the contraction at the end of your sentence. Does it contain a pronoun? If it does, then break it up into its two original words.

  • INCORRECT: Yes, we’re.
  • CORRECT: Yes, we are.

But the bottom line is yeah, the title here uses a contraction in a way that is not permitted by standard English prosody.

Scoopta ,
@Scoopta@programming.dev avatar

Tom Scott actually has a video about this which also talks about why you can’t end sentences with contractions. youtu.be/CkZyZFa5qO0

Zagorath ,
@Zagorath@aussie.zone avatar

Ahh yes, I knew I remembered hearing about this somewhere before, but couldn’t remember where. Tom Scott’s videos on linguistics are excellent.

victorz ,

This is God’s work. ❤️👌

deadbeef79000 ,

Thank you that’s a brilliant explanation.

Re-reading the headline, the second phrase starts with an implicit “your” too. Just to make it more confusing ;-)

Zagorath ,
@Zagorath@aussie.zone avatar

the second phrase starts with an implicit “your” too

Could be. Personally I interpreted it as an implicit “the”. Doesn’t change the meaning either way.

Lmaydev ,

It’s just one of those secret rules that we all pickup and use when it’s our first language.

Like the order of adjectives.

Zagorath ,
@Zagorath@aussie.zone avatar

Yeah for sure it is. The biggest difference is that there’s a fairly simple way to explain the adjectival order: “opinion, size, age, shape, colour, origin, material, purpose”. It’s apparently very difficult to explain when you can and cannot use contractions in a concise way.

DumbAceDragon , in What are variables and semicolons for actually?
@DumbAceDragon@sh.itjust.works avatar

Finally, pure functional rust.

marcos , in What are variables and semicolons for actually?

Rust’s semicolon means something like “There’s nothing to see here! Move along! Move along!”, so yeah, you don’t actually need any.

FizzyOrange , in What are variables and semicolons for actually?

Neat FP style. Pretty verbose though. Someone should invent a terser syntax so you don’t need to write do_two_things everywhere. It’s a common operation so maybe it could even be a single character.

jendrik ,

Like a semicolon? No, too boring. What about >>=

TadoTheRustacean OP ,

If you know about rust you know it’s a programmable programming language, meaning that you can make macros. There could be a macro that would do that but 1. Macros is rust code to write rust code so they have the complexity of rust squared 2. I said to myself the only macros I will allow myself to use in this challenge is println and allow

tatterdemalion ,
@tatterdemalion@programming.dev avatar

; is just a monad after all

  • All
  • Subscribed
  • Moderated
  • Favorites
  • [email protected]
  • random
  • lifeLocal
  • goranko
  • All magazines