SDF Chatter
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
N3Cr0@lemmy.world to Programmer Humor@lemmy.ml · 6 months ago

carrot.py

lemmy.world

message-square
96
fedilink
1.34K

carrot.py

lemmy.world

N3Cr0@lemmy.world to Programmer Humor@lemmy.ml · 6 months ago
message-square
96
fedilink
  • tetris11@lemmy.ml
    link
    fedilink
    arrow-up
    163
    ·
    6 months ago

    Workaround: Potato peeler extends peeler, so just cast your carrots as potatoes before you peel them, and then cast them back to carrot afterwards

    • thisfro@slrpnk.net
      link
      fedilink
      arrow-up
      75
      ·
      6 months ago

      To cast them, it uses libvegs however. It is not available in any standard package libraries, so just quickly build it from source

      • NaibofTabr@infosec.pub
        link
        fedilink
        English
        arrow-up
        61
        ·
        6 months ago

        Yeah but the current build of libvegs has some conflicts with libfruit, so if you need to use both you have to build libvegs in a different directory and then simlink it in /lib.

        • driving_crooner@lemmy.eco.br
          link
          fedilink
          arrow-up
          44
          arrow-down
          1
          ·
          6 months ago

          Tomato keep being casted as fruit, even that for any practical purpose it should be as vegetable

          • tetris11@lemmy.ml
            link
            fedilink
            arrow-up
            33
            ·
            edit-2
            6 months ago

            That’s it, let’s re-write the entire backend in C++ to make use of multiple inheritance to tackle this one use-case!

            What do you mean “this is overkill”? Do you have any idea how many tomatoes go into a fucking salad!?

            • thisfro@slrpnk.net
              link
              fedilink
              arrow-up
              22
              ·
              6 months ago

              Someone should do it in rust now

        • CaptDust@sh.itjust.works
          link
          fedilink
          arrow-up
          11
          ·
          6 months ago

          Maybe cooking isn’t for me.

        • Tiefling IRL@lemmy.blahaj.zone
          link
          fedilink
          arrow-up
          6
          ·
          6 months ago

          Yeah but that’s all my replacement’s problem to deal with

    • ThunderComplex@lemmy.today
      link
      fedilink
      arrow-up
      28
      ·
      6 months ago

      Unfortunately, casting from potato to carrot is a narrowing conversion so your new carrot will lose some properties

      • tetris11@lemmy.ml
        link
        fedilink
        arrow-up
        24
        ·
        6 months ago

        You say “potato” I say “caroto”

    • mesamunefire@lemmy.world
      link
      fedilink
      English
      arrow-up
      15
      ·
      6 months ago

      I hate that I understand this. Well done.

    • tumblechinchilla@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      13
      ·
      6 months ago

      Internal screaming.

    • mindbleach@sh.itjust.works
      link
      fedilink
      arrow-up
      9
      ·
      6 months ago

      If you forget the second step, well, that’s what sweet potatoes are.

Programmer Humor@lemmy.ml

programmerhumor@lemmy.ml

Subscribe from Remote Instance

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: !programmerhumor@lemmy.ml

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.
Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 208 users / day
  • 524 users / week
  • 1.8K users / month
  • 10.5K users / 6 months
  • 437 local subscribers
  • 35.6K subscribers
  • 1.72K Posts
  • 38.1K Comments
  • Modlog
  • mods:
  • AgreeableLandscape@lemmy.ml
  • cat_programmer@lemmy.ml
  • BE: 0.19.8
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org