Skip to content

error_code per operation complex the interface too much #2

@lichray

Description

@lichray

That does not feel good. But a 'traditional' global error code makes thread-safe coding hard.

My suggestions are:

  1. Add an error_code member to directory_entry, *directory_iterator, and provide a member function like is_valid() for user to check the status;
  2. Move the non-member operational functions into a context class, so that the error code can be managed in the same way.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions