-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
impr: Use UnsafeCell instead of RefCell
RefCell is not needed. Given the unsafe transmute, the RefCell provides no additional safety. It may even provide a false confidence. Switching to UnsafeCell makes it explicit that any access to the inner value needs to be carefully considered. It also avoids the runtime overhead associated with RefCell.
- Loading branch information
1 parent
85afbd3
commit 3347a8e
Showing
1 changed file
with
7 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters