docs: backtick parameter references in API comments
This commit is contained in:
@@ -10,7 +10,7 @@ ArrayList proc($T type) type {
|
||||
}
|
||||
}
|
||||
|
||||
#! retain allocator for later growth and cleanup; this call does not allocate.
|
||||
#! retain `allocator` for later growth and cleanup; this call does not allocate.
|
||||
init proc($T type, allocator mem.Allocator) ArrayList(T) {
|
||||
return ArrayList(T) {
|
||||
items = mem.empty(T),
|
||||
|
||||
@@ -29,7 +29,7 @@ StringHashMap proc($V type) type {
|
||||
return HashMap([]u8, V, str_hash, str_eql)
|
||||
}
|
||||
|
||||
#! retain allocator for later growth and cleanup; this call does not allocate.
|
||||
#! retain `allocator` for later growth and cleanup; this call does not allocate.
|
||||
init proc(
|
||||
$K, $V type,
|
||||
$hash_key proc(key K) usize,
|
||||
|
||||
+2
-2
@@ -26,7 +26,7 @@ raw_alloc proc(
|
||||
}
|
||||
|
||||
#! resize caller-owned storage with its original allocator and alignment.
|
||||
#! on allocation failure with nonzero new_size, original storage remains caller-owned; release the result with raw_free.
|
||||
#! on allocation failure with nonzero `new_size`, original storage remains caller-owned; release the result with raw_free.
|
||||
raw_realloc proc(
|
||||
allocator Allocator,
|
||||
memory ?*mut u8,
|
||||
@@ -54,7 +54,7 @@ eql proc($T type, left, right []T) bool {
|
||||
}
|
||||
|
||||
#! assign `value` to each slice element, preserving its typed value rather than repeating a byte.
|
||||
#! an empty destination is a no-op.
|
||||
#! an empty `destination` is a no-op.
|
||||
set proc($T type, destination []mut T, value T) void {
|
||||
for (0..destination.len) |i| destination[i] = value
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user