Issue#3044 Update minor mistakes in README.md and src/reentrancy.sw (#3045)

Closes #3044
This commit is contained in:
K1-R1 2022-10-15 09:46:23 +01:00 committed by GitHub
parent 61236752c1
commit a1d40f5888
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -4,7 +4,7 @@ The Sway Standard Library is the foundation of portable Sway software, a set of
## Usage
The standard library is made implicitly available to all Forc projects created using `forc new`. In other words, it is not required to manually specify `std` as an explicit dependency. Forc will automagically use the version of `std` that matches its version.
The standard library is made implicitly available to all Forc projects created using `forc new`. In other words, it is not required to manually specify `std` as an explicit dependency. Forc will automatically use the version of `std` that matches its version.
Importing items from the standard library can be done using the `use` keyword, just as importing items from any other Sway library. For example:

View file

@ -1,6 +1,6 @@
//! A reentrancy check for use in Sway contracts.
//! Note that this only works in internal contexts.
//! to prevent reentrancy: `assert(!is_reentrant);
//! to prevent reentrancy: `assert(!is_reentrant());`
library reentrancy;
use ::assert::assert;