Skip to content

reduce function for cclist? #305

Closed
@nilsbecker

Description

@nilsbecker

does CCList need this function:

fun f -> function
| [] -> None
| h::t -> Some (CCList.fold_left f h t)

? i've seen this called 'reduce'. it's just a minor specialization of fold but is quite frequent in my personal experience.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions