Skip to content

Commit 810646b

Browse files
committed
TVar: typos.
1 parent 8a4f225 commit 810646b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

md/tvar.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ end
9292

9393
That should work. Except we said we'd like these transfer to run concurrently,
9494
and in parallel. With a single lock like that we'll only let one transfer take
95-
place at a time. Perhaps we need more locks? We could have one per account
95+
place at a time. Perhaps we need more locks? We could have one per account:
9696

9797
```ruby
9898
a.lock.synchronize do
@@ -107,7 +107,7 @@ However this is vulnerable to deadlock. If we tried to transfer from a to b, at
107107
the same time as from b to a, it's possible that the first transfer locks a, the
108108
second transfer locks b, and then they both sit there waiting forever to get the
109109
other lock. Perhaps we can solve that by applying a total ordering to the locks
110-
- always acquire them in the same order?
110+
and always acquire them in the same order?
111111

112112
```ruby
113113
locks_needed = [a.lock, b.lock]

0 commit comments

Comments
 (0)