Skip to content

Minor issues #380

Description

@Bronek
  1. Possible library gap — opt.transform(id) on optional<copack<>> compiles as a no-op, but opt | fn::transform(id) is rejected: transform.hpp has no empty-copack arm mirroring transform_error.hpp:82-88, and no test pins it either way.
  2. value_or on expected<void, copack<>> is a hard error (value_or.hpp:31-35)
  3. conjoin should SFINAE-exclude carrier types from argument list - otherwise they get silently wrapped into a pack which is unlikely to be what the user expected. We cannot also refer to a .value() of a fallible carrier inside a function, as that could thrown an exception.
  4. conjon and disjoin should have an overload taking only carriers, by requires clause.
  5. Define expected_unit type alias (see also point 2)
  6. Add defaulted operator== and operator<=> to pack

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingrelease-0.1Planned for release 0.1

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions