• Octopus1348@lemy.lol
      link
      fedilink
      arrow-up
      37
      ·
      1 year ago

      It will also complain that trying to break into the castle is unsafe, so you have to tell it that you know.

      • CanadaPlus@futurology.today
        link
        fedilink
        English
        arrow-up
        8
        ·
        edit-2
        1 year ago

        “Alright, but you better be outside of a properly locked up and OSHA-compliant castle with the princess by the time I get back, or I’m not compiling”

        And then you do that, but you miss a smoldering ember from one of the castles torches, and everything including the horse and princess catches fire. Next time, pick an escape plan that only requires unsafe for the drawbridge.

        There’s a totally safe way to do it too, I guess, but it involves building a series of replacement castles, and it’s also totally ugly and sinfully slow.

    • wolo
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      You can use std::mem::swap to get ownership of the princess, but you need another princess to fill her place in the tower.