Pricefield | Lemmy
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
@[email protected] to Programmer [email protected]English • 1 year ago

Happens all the time

sh.itjust.works

message-square
23
fedilink
517

Happens all the time

sh.itjust.works

@[email protected] to Programmer [email protected]English • 1 year ago
message-square
23
fedilink
alert-triangle
You must log in or register to comment.
  • @[email protected]
    link
    fedilink
    73•1 year ago

    I do enjoy the rust compiler error messages. They are nicely formatted

    • shameless
      link
      fedilink
      23•1 year ago

      I’m trying to learn rust and so far this has definitely made it so much more accessible.

      Not to mention their super useful “rustlings” training which has these nice little challenges to get you used to language and syntax

    • @[email protected]
      link
      fedilink
      6•1 year ago

      Yeah, but to observe such error messages you’ll basically need to wait for 20 mins for it to compile.

      • @[email protected]
        link
        fedilink
        6•1 year ago

        No? The steps are compiled once and afterwards your project just gets compiled. Besides, rust-analyzer exists.

  • @[email protected]
    link
    fedilink
    127•1 year ago

    Lol, it took me a while to realize it’s the compiler essentially saying “how high”.

  • @[email protected]
    link
    fedilink
    33•1 year ago

    WRONG, PRIVATE!

    Now drop and give me int(ceil(19.9))!

  • @[email protected]
    link
    fedilink
    49•1 year ago

    That’s what makes us humans different from computers. We don’t ask how high, we just do it. Now, if it were a C pointer it would jump anywhere from 0 to 2^32-1. That’s why C is more suited for artificial intelligence than it might initially seem. Thanks for coming to my tedx talk

    • @[email protected]
      link
      fedilink
      6•1 year ago

      Pointers are ackshully 48 bits on amd64 (which is most PCs and servers)

      • @[email protected]
        link
        fedilink
        5•
        edit-2
        1 year ago

        I was mostly joking about a stray pointer of type uint32_t*

        So the size of the pointer itself doesn’t matter

      • @[email protected]
        link
        fedilink
        5•1 year ago

        Well ackshully newer CPUs support 5-level-paging which uses 56 bits.

  • @[email protected]
    link
    fedilink
    13•1 year ago

    Height should be a float

    • @[email protected]
      link
      fedilink
      1•1 year ago

      But then wouldn’t it be fly(height: f64) instead of jump(height: i32)?

    • @[email protected]
      link
      fedilink
      English
      4•1 year ago

      Chad quantised rust

    • @[email protected]
      link
      fedilink
      11•
      edit-2
      1 year ago

      I don’t know Rust but jump typically moves the program counter, where the height represents the number of instructions to move

      • @[email protected]
        link
        fedilink
        14•1 year ago

        Afaik rust doesn’t have functions like that as they lead to unsafe code that’s impossible to check variable lifetimes for. I think OP created the jump function.

        • @[email protected]
          link
          fedilink
          14•1 year ago

          They created it. The compiler says the jump function is in src/main.rs

    • @[email protected]
      link
      fedilink
      2•1 year ago

      Never use floats.

    • @[email protected]OP
      link
      fedilink
      6•1 year ago

      It’s height in centimeters

      • @[email protected]
        link
        fedilink
        1•1 year ago

        deleted by creator

  • @[email protected]
    link
    fedilink
    English
    37•1 year ago

    i dislike rust, but have to give them credit for helpful error messages. not quite racket level but impressive

    • @[email protected]
      link
      fedilink
      6•1 year ago

      What made you dislike it?

      • @[email protected]
        link
        fedilink
        English
        3•1 year ago

        the syntax.

  • @[email protected]
    link
    fedilink
    English
    3•1 year ago

    Huh, usually they ask ‘jump where?’

  • @[email protected]
    link
    fedilink
    1•5 months ago

    People who wanna see mee hihiii : http://adfoc.us/870511108889439

Programmer [email protected]

[email protected]
Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: [email protected]

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics
  • 60 users / day
  • 314 users / week
  • 1.24K users / month
  • 4.42K users / 6 months
  • 3 subscribers
  • 1.57K Posts
  • 55.8K Comments
  • Modlog
  • mods:
  • Feyter
  • adr1an
  • @[email protected]
  • Pierre-Yves Lapersonne
  • UI: 0.18.4
  • BE: 0.18.2
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org