Skip to content

add copy constructors and/or move semantics to support modern C++ auto expresions #50

@weegreenblobbie

Description

@weegreenblobbie

I'd love to write this:

    auto parser = args::ArgumentParser(
        "Benchmark a BFS graph search on a knureon complex"
    );

    auto help = args::HelpFlag(
        parser,
        "help",
        "Display this help menu",
        {'h', "help"}
    );

    auto args::ValueFlag<uint32_t>(
        parser,
        "seed",
        "The seed to initialize the random number generator",
        {"seed"}
    );

    auto scale = args::ValueFlag<uint32_t>(
        parser,
        "scale",
        "The logarithm base two of the number of vertices",
        {'s', "scale"}
    );

    auto edgefactor = args::ValueFlag<uint32_t>(
        parser,
        "edgefactor",
        "The ratio of the graph’s edge count to its vertex count",
        {'e', "edgefactor"}
    );

as I find it easier to read and encourages the use of auto everywhere.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions