I've come to the conclusion I need to develop this rust program in much smaller steps if I'm going to get it to work
-
Show this thread
-
this would also have the effect of showing what actual changes are required in the model to introduce things like caching, various kinds of polymorphism
1 reply 0 retweets 2 likesShow this thread -
it's also been brought to my attention that I might be able to solve my object-caching problem using Rc, but I've not verified this and returning Rc<T> feels like a very big implementation detail leaking
1 reply 0 retweets 2 likesShow this thread -
thing is I picked one of the bits of git that's extremely stateful and involves storing commit pointers in lots of different structures as the first thing to do :/
1 reply 0 retweets 3 likesShow this thread -
it's possible that one solution is not to hold commit pointers, but copies of the pieces of them you care about, like their ID, parents and date
1 reply 0 retweets 3 likesShow this thread -
or, I could make commits Clone, or at least their header data. but, partly to force myself to learn how to do tricky memory stuff in rust, and partly b/c the C impl gets away with just using pointers everywhere, I don't want to do that
1 reply 0 retweets 2 likesShow this thread
Returning &T is basically the rust version, but is much more restrictive. If you want to let folks hold onto it you have to return things like Rc. It's less impl leaking and more stating guarantees
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.