From 0d2060717a21653deb3db03ba5b3fe62aa4c098e Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Mon, 7 Apr 2025 15:35:13 -0400 Subject: Remove table.bump() --- docs/tables.md | 25 ------------------------- 1 file changed, 25 deletions(-) (limited to 'docs') diff --git a/docs/tables.md b/docs/tables.md index c0376f38..ee2603f5 100644 --- a/docs/tables.md +++ b/docs/tables.md @@ -152,37 +152,12 @@ iterating over any of the new values. ## Table Methods -- [`func bump(t:&{K=V}, key: K, amount: Int = 1 -> Void)`](#bump) - [`func clear(t:&{K=V})`](#clear) - [`func get(t:{K=V}, key: K -> V?)`](#get) - [`func has(t:{K=V}, key: K -> Bool)`](#has) - [`func remove(t:{K=V}, key: K -> Void)`](#remove) - [`func set(t:{K=V}, key: K, value: V -> Void)`](#set) -### `bump` -Increments the value associated with a key by a specified amount. If the key is -not already in the table, its value will be assumed to be zero. - -```tomo -func bump(t:&{K=V}, key: K, amount: Int = 1 -> Void) -``` - -- `t`: The reference to the table. -- `key`: The key whose value is to be incremented. -- `amount`: The amount to increment the value by (default: 1). - -**Returns:** -Nothing. - -**Example:** -```tomo ->> t := {"A"=1} -t.bump("A") -t.bump("B", 10) ->> t -= {"A"=2, "B"=10} -``` - --- ### `clear` -- cgit v1.2.3