| Class | ParseError |
| In: |
lib/optparse.rb
|
| Parent: | RuntimeError |
Base class of exceptions from OptionParser.
| Reason | = | 'parse error'.freeze | Reason which caused the error. |
| args | [R] | |
| reason | [W] |
# File lib/optparse.rb, line 1599
1599: def initialize(*args)
1600: @args = args
1601: @reason = nil
1602: end
# File lib/optparse.rb, line 1631
1631: def inspect
1632: "#<#{self.class.to_s}: #{args.join(' ')}>"
1633: end
Pushes back erred argument(s) to argv.
# File lib/optparse.rb, line 1610
1610: def recover(argv)
1611: argv[0, 0] = @args
1612: argv
1613: end