This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -1376,6 +1376,8 @@ impl<T: ?Sized> Arc<T> {
13761376 /// different types. See [`mem::transmute`][transmute] for more information
13771377 /// on what restrictions apply in this case.
13781378 ///
1379+ /// The raw pointer must point to a block of memory allocated by the global allocator
1380+ ///
13791381 /// The user of `from_raw` has to make sure a specific value of `T` is only
13801382 /// dropped once.
13811383 ///
@@ -1431,7 +1433,8 @@ impl<T: ?Sized> Arc<T> {
14311433 ///
14321434 /// The pointer must have been obtained through `Arc::into_raw`, and the
14331435 /// associated `Arc` instance must be valid (i.e. the strong count must be at
1434- /// least 1) for the duration of this method.
1436+ /// least 1) for the duration of this method, and `ptr` must point to a block of memory
1437+ /// allocated by the global allocator.
14351438 ///
14361439 /// # Examples
14371440 ///
@@ -1465,7 +1468,8 @@ impl<T: ?Sized> Arc<T> {
14651468 ///
14661469 /// The pointer must have been obtained through `Arc::into_raw`, and the
14671470 /// associated `Arc` instance must be valid (i.e. the strong count must be at
1468- /// least 1) when invoking this method. This method can be used to release the final
1471+ /// least 1) when invoking this method, and `ptr` must point to a block of memory
1472+ /// allocated by the global allocator. This method can be used to release the final
14691473 /// `Arc` and backing storage, but **should not** be called after the final `Arc` has been
14701474 /// released.
14711475 ///
You can’t perform that action at this time.
0 commit comments