Skip to content

Improve error message on illegal casts #52

@hostilefork

Description

@hostilefork

If you write:

Integer value = 10;
Float illegalFloat = static_cast<Float>(value);

The error message that comes back says:

error: call of overloaded 'Float(ren::Integer&)' is ambiguous

Really what it should say is "you can't do that". (Although whether you can do this specific case or not is up for debate in #7) Is there some static_assert or otherwise that could give a better message?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions