Skip to content

Commit

Permalink
Update move.md (MystenLabs#958)
Browse files Browse the repository at this point in the history
* Update move.md

Fix link to ObjectOwner.move by making absolute
Fix link to TicTacToeV2 > SharedTicTacToe

* Update move.md

Fix README link, capitalization of GitHub
  • Loading branch information
Clay-Mysten authored Mar 19, 2022
1 parent 63fc386 commit 7f992bd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions doc/src/build/move.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Move is an open source language for writing safe smart contracts. It
was originally developed at Facebook to power the [Diem](https://github.com/diem/diem)
blockchain. However, Move was designed as a platform-agnostic language
to enable common libraries, tooling, and developer communities across
blockchains with vastly different data and execution models. [Sui](../../../README.md),
blockchains with vastly different data and execution models. [Sui](https://github.com/MystenLabs/sui/blob/main/README.md),
[0L](https://github.com/OLSF/libra), and
[Starcoin](https://github.com/starcoinorg/starcoin) are using Move,
and there are also plans to integrate the language in several upcoming
Expand All @@ -23,7 +23,7 @@ and existing platforms (e.g.,


The Move language documentation is available in the
[Move Github](https://github.com/diem/move) repository and includes a
[Move GitHub](https://github.com/diem/move) repository and includes a
[tutorial](https://github.com/diem/move/blob/main/language/documentation/tutorial/README.md)
and a
[book](https://github.com/diem/move/blob/main/language/documentation/book/src/SUMMARY.md)
Expand Down Expand Up @@ -939,7 +939,7 @@ This call also requires to have the `child_ref` as proof of original ownership.
After this transfer, the object will be owned by `recipient`.
More examples of how objects can be transferred and owned can be found in
[ObjectOwner.move](../../../sui_core/src/unit_tests/data/object_owner/sources/ObjectOwner.move).
[ObjectOwner.move](https://github.com/MystenLabs/sui/tree/main/sui_core/src/unit_tests/data/object_owner/sources/ObjectOwner.move).
**Freeze an object**
To make an object `obj` shared and immutable, one can call:
Expand All @@ -957,7 +957,7 @@ Transfer::share_object(obj);
```
After this call, `obj` stays mutable, but becomes shared by everyone, i.e. anyone can send a transaction to mutate this object. However, such an object cannot be deleted, transferred or embedded in another object as a field.
Shared mutable object can be powerful in that it will make programming a lot simpler in many cases. However shared object is also more expensive to use: it requires a full sequencer (a.k.a. a consensus engine) to order the transactions that touch the shared object, which means longer latency/lower throughput and higher gas cost. One can see the difference of the two programming schemes between not using shared object vs using shared object by looking at the two different implementations of TicTacToe: [No Shared Object](https://github.com/MystenLabs/sui/tree/main/sui_programmability/examples/games/sources/TicTacToe.move) vs. [Shared Object](https://github.com/MystenLabs/sui/tree/main/sui_programmability/examples/games/sources/TicTacToeV2.move).
Shared mutable object can be powerful in that it will make programming a lot simpler in many cases. However shared object is also more expensive to use: it requires a full sequencer (a.k.a. a consensus engine) to order the transactions that touch the shared object, which means longer latency/lower throughput and higher gas cost. One can see the difference of the two programming schemes between not using shared object vs using shared object by looking at the two different implementations of TicTacToe: [No Shared Object](https://github.com/MystenLabs/sui/blob/main/sui_programmability/examples/games/sources/TicTacToe.move) vs. [Shared Object](https://github.com/MystenLabs/sui/blob/main/sui_programmability/examples/games/sources/SharedTicTacToe.move).
### Transaction Context
`TxContext` module provides a few important APIs that operate based on the current transaction context.
Expand Down

0 comments on commit 7f992bd

Please sign in to comment.