diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 5fca30ebe..d453b6487 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -360,8 +360,6 @@ jobs: path: tests/escrow - cmd: cd tests/pyth && anchor test --skip-lint && npx tsc --noEmit path: tests/pyth - - cmd: cd tests/realloc && anchor test --skip-lint && npx tsc --noEmit - path: tests/realloc - cmd: cd tests/system-accounts && anchor test --skip-lint path: tests/system-accounts - cmd: cd tests/misc && anchor test --skip-lint && npx tsc --noEmit diff --git a/CHANGELOG.md b/CHANGELOG.md index ce426da67..3ef147b62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,7 +12,6 @@ The minor version will be incremented upon a breaking change and the patch versi ### Features -* lang: Add `realloc`, `realloc::payer`, and `realloc::zero` as a new constraint group for program accounts ([#1943](https://github.com/project-serum/anchor/pull/1943)). * lang: Add `PartialEq` and `Eq` for `anchor_lang::Error` ([#1544](https://github.com/project-serum/anchor/pull/1544)). * cli: Add `--skip-build` to `anchor publish` ([#1786](https://github. com/project-serum/anchor/pull/1841)). diff --git a/lang/derive/accounts/src/lib.rs b/lang/derive/accounts/src/lib.rs index 5ab883e27..1c94ced5a 100644 --- a/lang/derive/accounts/src/lib.rs +++ b/lang/derive/accounts/src/lib.rs @@ -44,7 +44,6 @@ use syn::parse_macro_input; /// /// - [Normal Constraints](#normal-constraints) /// - [SPL Constraints](#spl-constraints) -/// /// # Normal Constraints ///
-/// #[account(realloc = <space>, realloc::payer = <target>, realloc::zero = <bool>)]
-/// |
-///
-/// Used to realloc
-/// program account space at the beginning of an instruction.
-/// -/// The account must be marked as mut and applied to either Account or AccountLoader types.
-/// -/// If the change in account data length is additive, lamports will be transferred from the realloc::payer into the
-/// program account in order to maintain rent exemption. Likewise, if the change is subtractive, lamports will be transferred from
-/// the program account back into the realloc::payer .
-/// -/// The realloc::zero constraint is required in order to determine whether the new memory should be zero initialized after
-/// reallocation. Please read the documentation on the AccountInfo::realloc function linked above to understand the
-/// caveats regarding compute units when providing true false to this flag.
-/// -/// Example: -/// -/// #[derive(Accounts)] -/// pub struct Example { -/// #[account(mut)] -/// pub payer: Signer<'info>, -/// #[account( -/// mut, -/// seeds = [b"example"], -/// bump, -/// realloc = 8 + std::mem::size_of::-/// |
-///