From 3f99163eaa3bd7c233c552acf82f59c26aad68ca Mon Sep 17 00:00:00 2001 From: Sophie Dankel <47993817+sdankel@users.noreply.github.com> Date: Fri, 7 Jun 2024 12:56:09 -0700 Subject: [PATCH] fix: remove Forc.lock files from template projects (#6101) ## Description These projects are used as templates in `forc template` and having the lock files as part of the template could cause issues. The lock file should be generated on the fly by forc. ## Checklist - [ ] I have linked to any relevant issues. - [ ] I have commented my code, particularly in hard-to-understand areas. - [ ] I have updated the documentation where relevant (API docs, the reference, and the Sway book). - [ ] If my change requires substantial documentation changes, I have [requested support from the DevRel team](https://github.com/FuelLabs/devrel-requests/issues/new/choose) - [ ] I have added tests that prove my fix is effective or that my feature works. - [ ] I have added (or requested a maintainer to add) the necessary `Breaking*` or `New Feature` labels where relevant. - [ ] I have done my best to ensure that my PR adheres to [the Fuel Labs Code Review Standards](https://github.com/FuelLabs/rfcs/blob/master/text/code-standards/external-contributors.md). - [ ] I have requested a review from the relevant team or maintainers. --- .gitignore | 3 ++- .../blockchain-development/access_control.md | 4 ++-- .../blockchain-development/native_assets.md | 22 +++++++++---------- docs/book/src/introduction/sway_standards.md | 22 +++++++++---------- docs/book/src/reference/sway_libs.md | 4 ++-- .../access-control/ownership/Forc.lock | 13 ----------- .../src/code/examples/counter/Forc.lock | 13 ----------- .../src/code/examples/fizzbuzz/Forc.lock | 13 ----------- .../code/examples/wallet_example/Forc.lock | 13 ----------- .../language/program-types/predicate.md | 2 +- sway-lib-std/src/alloc.sw | 2 +- sway-lib-std/src/call_frames.sw | 8 +++---- swayfmt/tests/mod.rs | 4 ++-- 13 files changed, 36 insertions(+), 87 deletions(-) delete mode 100644 docs/reference/src/code/examples/access-control/ownership/Forc.lock delete mode 100644 docs/reference/src/code/examples/counter/Forc.lock delete mode 100644 docs/reference/src/code/examples/fizzbuzz/Forc.lock delete mode 100644 docs/reference/src/code/examples/wallet_example/Forc.lock diff --git a/.gitignore b/.gitignore index b58ac9c06c6..3de2d377b4e 100644 --- a/.gitignore +++ b/.gitignore @@ -30,4 +30,5 @@ sway-lsp/tests/**/Forc.lock forc-plugins/forc-debug/tests/**/Forc.lock # Generated files in example directories -examples/**/Forc.lock +examples/**/*/Forc.lock +docs/reference/src/code/examples/**/*/Forc.lock diff --git a/docs/book/src/blockchain-development/access_control.md b/docs/book/src/blockchain-development/access_control.md index ca4887f6b4c..3e8aad92479 100644 --- a/docs/book/src/blockchain-development/access_control.md +++ b/docs/book/src/blockchain-development/access_control.md @@ -27,7 +27,7 @@ The `msg_sender` function works as follows: ## Contract Ownership -Many contracts require some form of ownership for access control. The [SRC-5 Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md) has been defined to provide an interoperable interface for ownership within contracts. +Many contracts require some form of ownership for access control. The [SRC-5 Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md) has been defined to provide an interoperable interface for ownership within contracts. To accomplish this, use the [Ownership Library](https://fuellabs.github.io/sway-libs/book/ownership/index.html) to keep track of the owner. This allows setting and revoking ownership using the variants `Some(..)` and `None` respectively. This is better, safer, and more readable than using the `Identity` type directly where revoking ownership has to be done using some magic value such as `b256::zero()` or otherwise. @@ -67,7 +67,7 @@ Setting ownership can be done in one of two ways; During compile time or run tim [Sway-Libs](../reference/sway_libs.md) provides the following libraries to enable further access control. -- [Ownership Library](https://fuellabs.github.io/sway-libs/book/ownership/index.html); used to apply restrictions on functions such that only a **single** user may call them. This library provides helper functions for the [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md). +- [Ownership Library](https://fuellabs.github.io/sway-libs/book/ownership/index.html); used to apply restrictions on functions such that only a **single** user may call them. This library provides helper functions for the [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md). - [Admin Library](https://fuellabs.github.io/sway-libs/book/admin/index.html); used to apply restrictions on functions such that only a select few users may call them like a whitelist. - [Pausable Library](https://fuellabs.github.io/sway-libs/book/pausable/index.html); allows contracts to implement an emergency stop mechanism. - [Reentrancy Guard Library](https://fuellabs.github.io/sway-libs/book/reentrancy/index.html); used to detect and prevent reentrancy attacks. diff --git a/docs/book/src/blockchain-development/native_assets.md b/docs/book/src/blockchain-development/native_assets.md index 8adcf8fa72e..49b1b0bef79 100644 --- a/docs/book/src/blockchain-development/native_assets.md +++ b/docs/book/src/blockchain-development/native_assets.md @@ -14,7 +14,7 @@ On the FuelVM, _all_ assets are native and the process for sending _any_ native While you would still need a smart contract to handle the minting and burning of assets, the sending and receiving of these assets can be done independently of the asset contract. -Just like the EVM however, Fuel has a standard that describes a standard API for Native Assets using the Sway Language. The ERC-20 equivalent for the Sway Language is the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md). +Just like the EVM however, Fuel has a standard that describes a standard API for Native Assets using the Sway Language. The ERC-20 equivalent for the Sway Language is the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md). > **NOTE** It is important to note that Fuel does not have tokens. @@ -22,7 +22,7 @@ Just like the EVM however, Fuel has a standard that describes a standard API for On the EVM, an ERC-721 token or NFT is a contract that contains multiple tokens which are non-fungible with one another. -On the FuelVM, the ERC-721 equivalent is a Native Asset where each asset has a supply of one. This is defined in the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md#non-fungible-asset-restrictions) under the Non-Fungible Asset Restrictions. +On the FuelVM, the ERC-721 equivalent is a Native Asset where each asset has a supply of one. This is defined in the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md#non-fungible-asset-restrictions) under the Non-Fungible Asset Restrictions. In practice, this means all NFTs are treated the same as any other Native Asset on Fuel. When writing Sway code, no additional cases for handling non-fungible and fungible assets are required. @@ -106,7 +106,7 @@ You may also mint an asset to a specific entity with the `std::asset::mint_to()` {{#include ../../../../examples/native_asset/src/main.sw:mint_to_asset}} ``` -If you intend to allow external users to mint assets using your contract, the [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md#fn-mintrecipient-identity-vault_sub_id-subid-amount-u64) defines a standard API for minting assets. The [Sway-Libs Asset Library](https://fuellabs.github.io/sway-libs/book/asset/supply.html) also provides an additional library to support implementations of the SRC-3 Standard into your contract. +If you intend to allow external users to mint assets using your contract, the [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md#fn-mintrecipient-identity-vault_sub_id-subid-amount-u64) defines a standard API for minting assets. The [Sway-Libs Asset Library](https://fuellabs.github.io/sway-libs/book/asset/supply.html) also provides an additional library to support implementations of the SRC-3 Standard into your contract. ### Burning a Native Asset @@ -116,7 +116,7 @@ To burn an asset, the `std::asset::burn()` function must be called internally fr {{#include ../../../../examples/native_asset/src/main.sw:burn_asset}} ``` -If you intend to allow external users to burn assets using your contract, the [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md#fn-mintrecipient-identity-vault_sub_id-subid-amount-u64) defines a standard API for burning assets. The [Sway-Libs Asset Library](https://fuellabs.github.io/sway-libs/book/asset/supply.html) also provides an additional library to support implementations of the SRC-3 Standard into your contract. +If you intend to allow external users to burn assets using your contract, the [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md#fn-mintrecipient-identity-vault_sub_id-subid-amount-u64) defines a standard API for burning assets. The [Sway-Libs Asset Library](https://fuellabs.github.io/sway-libs/book/asset/supply.html) also provides an additional library to support implementations of the SRC-3 Standard into your contract. ### Transfer a Native Asset @@ -176,16 +176,16 @@ There are a number of standards developed to enable further functionality for Na We currently have the following standards for Native Assets: -- [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md) defines the implementation of a standard API for Native Assets using the Sway Language. -- [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md) is used to enable mint and burn functionality for Native Assets. -- [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-7.md) is used to store metadata for Native Assets. -- [SRC-6; Vault Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-6.md) defines the implementation of a standard API for asset vaults developed in Sway. +- [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md) defines the implementation of a standard API for Native Assets using the Sway Language. +- [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md) is used to enable mint and burn functionality for Native Assets. +- [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-7-asset-metadata.md) is used to store metadata for Native Assets. +- [SRC-6; Vault Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-6-vault.md) defines the implementation of a standard API for asset vaults developed in Sway. ## Native Asset Libraries Additional Libraries have been developed to allow you to quickly create an deploy dApps that follow the [Sway Standards](https://github.com/FuelLabs/sway-standards). -- [Asset Library](https://fuellabs.github.io/sway-libs/book/asset/index.html) provides functionality to implement the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md), [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md), and [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-7.md) standards. +- [Asset Library](https://fuellabs.github.io/sway-libs/book/asset/index.html) provides functionality to implement the [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md), [SRC-3; Mint and Burn Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md), and [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-7-asset-metadata.md) standards. @@ -193,7 +193,7 @@ Additional Libraries have been developed to allow you to quickly create an deplo In this fully fleshed out example, we show a native asset contract which mints a single asset. This is the equivalent to the ERC-20 Standard use in Ethereum. Note there are no token approval functions. -It implements the [SRC-20; Native Asset](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md), [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md), and [SRC-5; Ownership](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md) standards. It does not use any external libraries. +It implements the [SRC-20; Native Asset](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md), [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md), and [SRC-5; Ownership](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md) standards. It does not use any external libraries. ```sway // ERC20 equivalent in Sway. @@ -335,7 +335,7 @@ fn require_access_owner() { In this fully fleshed out example, we show a native asset contract which mints multiple assets. This is the equivalent to the ERC-1155 Standard use in Ethereum. Note there are no token approval functions. -It implements the [SRC-20; Native Asset](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md), [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md), and [SRC-5; Ownership](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md) standards. It does not use any external libraries. +It implements the [SRC-20; Native Asset](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md), [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md), and [SRC-5; Ownership](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md) standards. It does not use any external libraries. ```sway // ERC1155 equivalent in Sway. diff --git a/docs/book/src/introduction/sway_standards.md b/docs/book/src/introduction/sway_standards.md index d51925c00bc..e421c0c6b20 100644 --- a/docs/book/src/introduction/sway_standards.md +++ b/docs/book/src/introduction/sway_standards.md @@ -8,32 +8,32 @@ For more information on using a Sway Standard, please refer to the [Sway-Standar ### Native Asset Standards -- [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md) defines the implementation of a standard API for [Native Assets](../blockchain-development/native_assets.md) using the Sway Language. -- [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md) is used to enable mint and burn functionality for Native Assets. -- [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-7.md) is used to store metadata for [Native Assets](../blockchain-development/native_assets.md), usually as NFTs. -- [SRC-9; Metadata Keys Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-9.md) is used to store standardized metadata keys for [Native Assets](../blockchain-development/native_assets.md) in combination with the SRC-7 standard. -- [SRC-6; Vault Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-6.md) defines the implementation of a standard API for asset vaults developed in Sway. +- [SRC-20; Native Asset Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md) defines the implementation of a standard API for [Native Assets](../blockchain-development/native_assets.md) using the Sway Language. +- [SRC-3; Mint and Burn](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md) is used to enable mint and burn functionality for Native Assets. +- [SRC-7; Arbitrary Asset Metadata Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-7-asset-metadata.md) is used to store metadata for [Native Assets](../blockchain-development/native_assets.md), usually as NFTs. +- [SRC-9; Metadata Keys Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-9-metadata-keys.md) is used to store standardized metadata keys for [Native Assets](../blockchain-development/native_assets.md) in combination with the SRC-7 standard. +- [SRC-6; Vault Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-6-vault.md) defines the implementation of a standard API for asset vaults developed in Sway. ### Predicate Standards -- [SRC-13; Soulbound Address Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-13.md) defines a specific `Address` as a Soulbound Address for Soulbound Assets to become non-transferable. +- [SRC-13; Soulbound Address Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-13-soulbound-address.md) defines a specific `Address` as a Soulbound Address for Soulbound Assets to become non-transferable. ### Access Control Standards -- [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md) is used to restrict function calls to admin users in contracts. +- [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md) is used to restrict function calls to admin users in contracts. ### Contract Standards -- [SRC-12; Contract Factory](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-12.md) defines the implementation of a standard API for contract factories. +- [SRC-12; Contract Factory](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-12-contract-factory.md) defines the implementation of a standard API for contract factories. ### Bridge Standards -- [SRC-8; Bridged Asset](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-8.md) defines the metadata required for an asset bridged to the Fuel Network. -- [SRC-10; Native Bridge Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-10.md) defines the standard API for the Native Bridge between the Fuel Chain and the canonical base chain. +- [SRC-8; Bridged Asset](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-8-bridged-asset.md) defines the metadata required for an asset bridged to the Fuel Network. +- [SRC-10; Native Bridge Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-10-native-bridge.md) defines the standard API for the Native Bridge between the Fuel Chain and the canonical base chain. ### Documentation Standards -- [SRC-2; Inline Documentation](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-2.md) defines how to document your Sway files. +- [SRC-2; Inline Documentation](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-2-inline-documentation.md) defines how to document your Sway files. ## Standards Support diff --git a/docs/book/src/reference/sway_libs.md b/docs/book/src/reference/sway_libs.md index 507a15abe0d..8e5d237fe07 100644 --- a/docs/book/src/reference/sway_libs.md +++ b/docs/book/src/reference/sway_libs.md @@ -10,13 +10,13 @@ For more information on how to use a Sway-Libs library, please refer to the [Swa Asset Libraries are any libraries that use [Native Assets](../blockchain-development/native_assets.md) on the Fuel Network. -- [Asset Library](https://fuellabs.github.io/sway-libs/book/asset/index.html); provides helper functions for the [SRC-20](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-20.md), [SRC-3](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-3.md), and [SRC-7](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-7.md) standards. +- [Asset Library](https://fuellabs.github.io/sway-libs/book/asset/index.html); provides helper functions for the [SRC-20](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-20-native-asset.md), [SRC-3](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-3-minting-and-burning.md), and [SRC-7](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-7-asset-metadata.md) standards. ## Access Control and Security Libraries Access Control and Security Libraries are any libraries that are built and intended to provide additional safety when developing smart contracts. -- [Ownership Library](https://fuellabs.github.io/sway-libs/book/ownership/index.html); used to apply restrictions on functions such that only a **single** user may call them. This library provides helper functions for the [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/SRCs/src-5.md). +- [Ownership Library](https://fuellabs.github.io/sway-libs/book/ownership/index.html); used to apply restrictions on functions such that only a **single** user may call them. This library provides helper functions for the [SRC-5; Ownership Standard](https://github.com/FuelLabs/sway-standards/blob/master/docs/src/src-5-ownership.md). - [Admin Library](https://fuellabs.github.io/sway-libs/book/admin/index.html); used to apply restrictions on functions such that only a select few users may call them like a whitelist. - [Pausable Library](https://fuellabs.github.io/sway-libs/book/pausable/index.html); allows contracts to implement an emergency stop mechanism. - [Reentrancy Guard Library](https://fuellabs.github.io/sway-libs/book/reentrancy/index.html); used to detect and prevent reentrancy attacks. diff --git a/docs/reference/src/code/examples/access-control/ownership/Forc.lock b/docs/reference/src/code/examples/access-control/ownership/Forc.lock deleted file mode 100644 index 29ac8935221..00000000000 --- a/docs/reference/src/code/examples/access-control/ownership/Forc.lock +++ /dev/null @@ -1,13 +0,0 @@ -[[package]] -name = 'core' -source = 'path+from-root-AE2967028D5567DA' - -[[package]] -name = 'ownership' -source = 'member' -dependencies = ['std'] - -[[package]] -name = 'std' -source = 'git+https://github.com/fuellabs/sway?tag=v0.31.1#c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2' -dependencies = ['core'] diff --git a/docs/reference/src/code/examples/counter/Forc.lock b/docs/reference/src/code/examples/counter/Forc.lock deleted file mode 100644 index 815750e37b5..00000000000 --- a/docs/reference/src/code/examples/counter/Forc.lock +++ /dev/null @@ -1,13 +0,0 @@ -[[package]] -name = 'core' -source = 'path+from-root-AE2967028D5567DA' - -[[package]] -name = 'counter' -source = 'member' -dependencies = ['std'] - -[[package]] -name = 'std' -source = 'git+https://github.com/fuellabs/sway?tag=v0.31.1#c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2' -dependencies = ['core'] diff --git a/docs/reference/src/code/examples/fizzbuzz/Forc.lock b/docs/reference/src/code/examples/fizzbuzz/Forc.lock deleted file mode 100644 index 4052c90315a..00000000000 --- a/docs/reference/src/code/examples/fizzbuzz/Forc.lock +++ /dev/null @@ -1,13 +0,0 @@ -[[package]] -name = 'core' -source = 'path+from-root-AE2967028D5567DA' - -[[package]] -name = 'fizzbuzz' -source = 'member' -dependencies = ['std'] - -[[package]] -name = 'std' -source = 'git+https://github.com/fuellabs/sway?tag=v0.31.1#c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2' -dependencies = ['core'] diff --git a/docs/reference/src/code/examples/wallet_example/Forc.lock b/docs/reference/src/code/examples/wallet_example/Forc.lock deleted file mode 100644 index 633f2d6d9a2..00000000000 --- a/docs/reference/src/code/examples/wallet_example/Forc.lock +++ /dev/null @@ -1,13 +0,0 @@ -[[package]] -name = 'core' -source = 'path+from-root-AE2967028D5567DA' - -[[package]] -name = 'std' -source = 'git+https://github.com/fuellabs/sway?tag=v0.31.1#c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2' -dependencies = ['core'] - -[[package]] -name = 'wallet' -source = 'member' -dependencies = ['std'] diff --git a/docs/reference/src/documentation/language/program-types/predicate.md b/docs/reference/src/documentation/language/program-types/predicate.md index c267acb619f..ea715888132 100644 --- a/docs/reference/src/documentation/language/program-types/predicate.md +++ b/docs/reference/src/documentation/language/program-types/predicate.md @@ -4,7 +4,7 @@ A predicate is an executable that represents a UTXO spending condition, such as It does not need to be deployed to a blockchain because it only exists during a transaction. That being said, the predicate root is on chain as the owner of one or more UTXOs. -Predicates can neither read from nor write to any contract state. Moreover, they cannot use any [contract instructions](https://fuellabs.github.io/fuel-specs/master/vm/instruction_set.html#contract-instructions). +Predicates can neither read from nor write to any contract state. Moreover, they cannot use any [contract instructions](https://docs.fuel.network/docs/specs/fuel-vm/instruction-set/#contract-instructions). ## Transfer Coins to a Predicate diff --git a/sway-lib-std/src/alloc.sw b/sway-lib-std/src/alloc.sw index 1e0958c0b4d..9841fe5e1e1 100644 --- a/sway-lib-std/src/alloc.sw +++ b/sway-lib-std/src/alloc.sw @@ -27,7 +27,7 @@ library; /// ▴ptr ▴VM_MAX_RAM /// ``` /// For more information, see the Fuel Spec for [VM Initialization](https://fuellabs.github.io/fuel-specs/master/vm#vm-initialization) -/// and the VM Instruction Set for [Memory Allocation](https://fuellabs.github.io/fuel-specs/master/vm/instruction_set.html#aloc-allocate-memory). +/// and the VM Instruction Set for [Memory Allocation](https://docs.fuel.network/docs/specs/fuel-vm/instruction-set#aloc-allocate-memory). /// /// # Arguments /// diff --git a/sway-lib-std/src/call_frames.sw b/sway-lib-std/src/call_frames.sw index 6ae7b2cdf19..8d69188204d 100644 --- a/sway-lib-std/src/call_frames.sw +++ b/sway-lib-std/src/call_frames.sw @@ -46,7 +46,7 @@ pub fn msg_asset_id() -> AssetId { /// # Additional Information /// /// More information on data from call frames can be found in the Fuel Specs. -/// https://specs.fuel.network/master/fuel-vm/index.html?search=#call-frames +/// https://docs.fuel.network/docs/specs/fuel-vm/#call-frames /// /// # Returns /// @@ -74,7 +74,7 @@ pub fn code_size() -> u64 { /// # Additional Information /// /// More information on data from call frames can be found in the Fuel Specs. -/// https://specs.fuel.network/master/fuel-vm/index.html?search=#call-frames +/// https://docs.fuel.network/docs/specs/fuel-vm/#call-frames /// /// # Returns /// @@ -99,7 +99,7 @@ pub fn first_param() -> u64 { /// # Additional Information /// /// More information on data from call frames can be found in the Fuel Specs. -/// https://specs.fuel.network/master/fuel-vm/index.html?search=#call-frames +/// https://docs.fuel.network/docs/specs/fuel-vm/#call-frames /// /// # Returns /// @@ -141,7 +141,7 @@ where /// # Additional Information /// /// More information on data from call frames can be found in the Fuel Specs. -/// https://specs.fuel.network/master/fuel-vm/index.html?search=#call-frames +/// https://docs.fuel.network/docs/specs/fuel-vm/#call-frames /// /// # Arguments /// diff --git a/swayfmt/tests/mod.rs b/swayfmt/tests/mod.rs index b71f2f148c4..13e063d7f81 100644 --- a/swayfmt/tests/mod.rs +++ b/swayfmt/tests/mod.rs @@ -2405,7 +2405,7 @@ fn long_doc_break_new_line() { /// ▴ptr ▴VM_MAX_RAM /// ``` /// For more information, see the Fuel Spec for [VM Initialization](https://fuellabs.github.io/fuel-specs/master/vm#vm-initialization) -/// and the VM Instruction Set for [Memory Allocation](https://fuellabs.github.io/fuel-specs/master/vm/instruction_set.html#aloc-allocate-memory). +/// and the VM Instruction Set for [Memory Allocation](https://docs.fuel.network/docs/specs/fuel-vm/instruction-set#aloc-allocate-memory). /// /// # Arguments /// @@ -2499,7 +2499,7 @@ pub fn alloc_bytes(count: u64) -> raw_ptr { /// ▴ptr ▴VM_MAX_RAM /// ``` /// For more information, see the Fuel Spec for [VM Initialization](https://fuellabs.github.io/fuel-specs/master/vm#vm-initialization) -/// and the VM Instruction Set for [Memory Allocation](https://fuellabs.github.io/fuel-specs/master/vm/instruction_set.html#aloc-allocate-memory). +/// and the VM Instruction Set for [Memory Allocation](https://docs.fuel.network/docs/specs/fuel-vm/instruction-set#aloc-allocate-memory). /// /// # Arguments ///