Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid meta programming to initialize functions in module scope #26388

Merged
merged 3 commits into from
Mar 15, 2023

Commits on Mar 15, 2023

  1. Avoid meta programming to initialize functions in module scope

    Function declarations with conditions inside of them is the preferred pattern.
    sebmarkbage committed Mar 15, 2023
    Configuration menu
    Copy the full SHA
    de5b2c8 View commit details
    Browse the repository at this point in the history
  2. Favor function declarations over assignment

    Helps avoid this pattern sneaking back in.
    sebmarkbage committed Mar 15, 2023
    Configuration menu
    Copy the full SHA
    b249b5e View commit details
    Browse the repository at this point in the history
  3. Avoid extra indirection

    This is still doing feature tests in the module scope but no calls
    sebmarkbage committed Mar 15, 2023
    Configuration menu
    Copy the full SHA
    1e92969 View commit details
    Browse the repository at this point in the history