Skip to content

get_size should return an option instead of panicking. #50

@FractalFir

Description

@FractalFir

Currently, get_size panics if it is used on an unsupported type. This is not documented anywhere, and confusing. Returning None(or better yet, an Err) would clearly indicate this is an unsupported operation, allowing for it's more graceful handling.

Additionally, get_size panic's for some commonly used types, including bools . This makes using it cumbersome.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions