Skip to content

Feature req: being able to use MFC Collections in std algorithms #1

Description

@jpj-verstappen

Nice work on the range based for loops! Working like a charm.
I would like to use the MFC collection classes in the std algorithms, like std::all_of. Looks like I need an iterator for the begin and the end of the array I'm using (CTypedPtrArray).
Can someone give an example of how to implement this?

Usage example:

CTypedPtrArray<CObArray, CAppointment*> appointmentArr;
bool bAllAppointmentsToday = std::all_of(...begin..., ....end..., 
    [](CAppointment* app) { return app->IsToday(); });
assert(bAllAppointmentsToday);

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