• 0 Posts
  • 7 Comments
Joined 1 year ago
cake
Cake day: July 10th, 2023

help-circle
  • jameseb@lemm.eetoRust@programming.devRust Container Cheat Sheet
    link
    fedilink
    English
    arrow-up
    6
    ·
    edit-2
    4 months ago
    1. Why does it say where T: Sized for references &T? A reference can definitely point to an unsized type, e.g. &str.

    I think the point being made is that the layout shown only applies for Sized T. Layouts for &[T] and &dyn Trait are shown elsewhere on the sheet. &str is noted under &[T].

    Edit: although, similar considerations would apply to other pointer types, but that isn’t noted on the sheet except for Box<[T]>




  • 25 isn’t too young, and makes sense if you have focused on education and career. I followed a similar path in that I spent a lot of time in education, only starting to properly consider courting someone around the age of 25 or 26 after I finished my PhD. Things were complicated somewhat by Covid, but I got married last year at the age of 30.

    As to losing weight, I can’t speak much from experience on that, but losing some weight may be a good idea, as much for your own health as anything else. Unless you are really overweight (in which case it is a medical issue that you should address), I think you shouldn’t worry too much about it in terms of dating.