Skip to content

private parameter for hasproperty #61237

@jakobjpeters

Description

@jakobjpeters

hasproperty is implemented as:

hasproperty(x, s::Symbol) = s in propertynames(x)

If one wants to check hasproperty for a private name (such as a non-public name in a module), they currently need to do s in propertynames(x, true). This change would allow hasproperty(x, s, true) instead, which is otherwise unintuitive until one looks at the implementation for hasproperty.

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