File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,6 @@ pub fn init(buffer: []u8) @This() {
16
16
};
17
17
}
18
18
19
- /// Using this at the same time as the interface returned by `threadSafeAllocator` is not thread safe.
20
19
pub fn allocator (self : * @This ()) Allocator {
21
20
return .{
22
21
.ptr = self ,
@@ -31,6 +30,7 @@ pub fn allocator(self: *@This()) Allocator {
31
30
32
31
/// Provides a lock free thread safe `Allocator` interface to the underlying `FixedBufferAllocator`
33
32
/// Using this at the same time as the interface returned by `allocator` is not thread safe.
33
+ /// Deprecated; to be removed after 0.16.0 is tagged.
34
34
pub fn threadSafeAllocator (self : * @This ()) Allocator {
35
35
return .{
36
36
.ptr = self ,
@@ -155,6 +155,7 @@ pub fn free(
155
155
assert (alloc_base <= @intFromPtr (self .bump ));
156
156
}
157
157
158
+ /// Deprecated; to be removed after 0.16.0 is tagged.
158
159
fn threadSafeAlloc (
159
160
ctx : * anyopaque ,
160
161
length : usize ,
@@ -249,6 +250,7 @@ test "works at comptime for alignments <= 1" {
249
250
}
250
251
}
251
252
253
+ // Deprecated; to be removed after 0.16.0 is tagged.
252
254
test "thread safe version" {
253
255
var buffer : [1 << 20 ]u8 = undefined ;
254
256
var bump_allocator : @This () = .init (& buffer );
You can’t perform that action at this time.
0 commit comments