Skip to content

Optimization #37

@TechnoGeek01

Description

@TechnoGeek01
  • Wherever there is a "if" statement that doesn't contain "else" statement, we can simplify it into a single line without the curly braces. To add a note, it might make sense to keep it otherwise in certain places.
  • Need to reconsider our function naming conventions. For example, _isTokenManager(address _rwdToken) in BaseFarm.sol seems as if it returns a bool but actually it reverts on a specific condition.
  • We need to explore a concept called "Test Harnesses" for testing internal functions using foundry.
  • Test case optimization #41 (comment)
  • Use either named returns or normal returns. Don't use both in a single function as its redundant. Also use the same pattern across all the contracts for consistency.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions