Git Product home page Git Product logo

Comments (6)

CriesofCarrots avatar CriesofCarrots commented on July 20, 2024 1

Technically not necessary but the consistency is nice

Allowing non-rent-exempt wrapped SOL accounts requires a bit of special casing, since rent debits will not be reflected in the account's amount field. So yay, glad that seems fine to you.

I think we need a rent_exempt_reserve field, like Stake accounts:

Agreed, we'll need that for wrapped SOL, so Account structs. I think we can leave that out of Mint and Multisig, since there's no way to withdraw lamports from those accounts.

from solana-program-library.

CriesofCarrots avatar CriesofCarrots commented on July 20, 2024

Mints too

from solana-program-library.

mvines avatar mvines commented on July 20, 2024

and multisigs!

from solana-program-library.

CriesofCarrots avatar CriesofCarrots commented on July 20, 2024

One effect of this change is that wrapped SOL accounts cannot hold less wrapped SOL than the account rent-exempt minimum balance. Any concerns about this?

from solana-program-library.

mvines avatar mvines commented on July 20, 2024

Seems fine to me. Technically not necessary but the consistency is nice. Here's a fun edge case:

  1. Wrap the rent-exempt amount of SOL
  2. Transfer 1 lamport to another token account
  3. Now the source account is no longer rent-exempt.

from solana-program-library.

mvines avatar mvines commented on July 20, 2024

I think we need a rent_exempt_reserve field, like Stake accounts:
https://github.com/solana-labs/solana/blob/57174cdabed9821b529ed359eab759f7b28f52c4/programs/stake/src/stake_state.rs#L130

from solana-program-library.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.