Boost logo

Boost Users :

Subject: Re: [Boost-users] Boost Program Options: Just curiosity, why double dashes ?
From: Stephen Nuchia (snuchia_at_[hidden])
Date: 2009-12-01 09:20:42

The reasons given are sufficient but perhaps not as informative as they
could have been.

The "old way" is a single dash with single-letter options. When
multiple options are given it is conventional to accept them all strung
together after one dash. So
        ls -lrt
means the same thing as
        ls -l -r -t

In some cases, optional parameters were introduced using a dash, a
letter, and then a symbol or file name (fragment) as in
        cc -lm foo.c
where the "m" is the name of a library (the math funcitons of the
standard C library).

So when you've run out of letters or gotten tired of explaining the ones
that don't make sense and you want to go to words or phrases as options,
what do you do? The answer chosen to that question is that we double
the dashes.


Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at