News for hackers. Stuff that matters.
Re:Four years with Rust by mr_luc on Thursday December 22, 2016 @09:58AM (#13237598)
> there's usually one central thing that is Rc'd,

Right.

In my case, I was using the nphysics library, which for unsurprising reasons uses Rc for entity handles.

Similarly, in my app's code, I used nphysics' proximity and contact handlers to watch for events that indicated a change in status. Those handlers needed to initialize/set values in a HashMap accessible (and periodically cleared by) the main sim loop -- 'one central thing' that is Rc'd.

It's not sprinkled everywhere in your codebase, and for obvious reasons most libraries don't need to use it. But in applications, a central loop + library-provided callbacks + some Rc'd state of doesn't seem too uncommon.

There are no comments on this comment yet.