// This enumeration delineates the kinds of operations on an archive
// that are permitted.
enum ArchiveOperation {
- NoOperation, ///< An operation hasn't been specified
Print, ///< Print the contents of the archive
Delete, ///< Delete the specified members
Move, ///< Move members to end or as given by {a,b,i} modifiers
unsigned NumPositional = 0;
// Keep track of which operation was requested
- ArchiveOperation Operation = NoOperation;
+ ArchiveOperation Operation;
for(unsigned i=0; i<Options.size(); ++i) {
switch(Options[i]) {
case ReplaceOrInsert: haveError = doReplaceOrInsert(&ErrMsg); break;
case DisplayTable: haveError = doDisplayTable(&ErrMsg); break;
case Extract: haveError = doExtract(&ErrMsg); break;
- case NoOperation:
- errs() << argv[0] << ": No operation was selected.\n";
- break;
}
if (haveError) {
errs() << argv[0] << ": " << ErrMsg << "\n";