Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread Chet Ramey
On 1/30/12 2:24 PM, DJ Mills wrote: >> How is `INTEGER' any clearer? Integer constants can be specified as octal >> or hex. > > Well, ok. The quoted section from the man page specifies a decimal. How about `decimal whole number between 2 and 64'? -- ``The lyf so short, the craft so long to ler

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread Linda Walsh
DJ Mills wrote: OK. �How about if that sentence began with `When specifying n, the digits greater ...'? declare -i foo; foo=20#a2; echo "$foo" 202 [base#]n, 'base' is a INTEGER 2-64, then '#', followed by the number. --- Slightly more exact/pedantic, how about: Syntax for integer cons

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread DJ Mills
> How is `INTEGER' any clearer?  Integer constants can be specified as octal > or hex. Well, ok. The quoted section from the man page specifies a decimal.

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread Chet Ramey
> > OK.  How about if that sentence began with `When specifying n, the > > digits greater ...'? > > declare -i foo; foo=20#a2; echo "$foo" > 202 > > [base#]n, 'base' is a INTEGER 2-64, then '#', followed by the number. How is `INTEGER' any clearer? Integer constants can be specified as octal or

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread Pierre Gaston
On Mon, Jan 30, 2012 at 9:02 PM, Linda Walsh wrote: > > > DJ Mills wrote: > >>> OK. �How about if that sentence began with `When specifying n, the >>> digits greater ...'? >> >> >> declare -i foo; foo=20#a2; echo "$foo" >> 202 >> >> [base#]n, 'base' is a INTEGER 2-64, then '#', followed by the num

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread Linda Walsh
DJ Mills wrote: OK. �How about if that sentence began with `When specifying n, the digits greater ...'? declare -i foo; foo=20#a2; echo "$foo" 202 [base#]n, 'base' is a INTEGER 2-64, then '#', followed by the number. ^^^ That's much more clear!

Re: bash man page needs more examples...(i.e. >0)

2012-01-30 Thread DJ Mills
> OK.  How about if that sentence began with `When specifying n, the > digits greater ...'? declare -i foo; foo=20#a2; echo "$foo" 202 [base#]n, 'base' is a INTEGER 2-64, then '#', followed by the number.

Re: bash man page needs more examples...(i.e. >0)

2012-01-29 Thread Chet Ramey
On 1/28/12 9:45 PM, Linda Walsh wrote: > The part that says: > digits greater than 9 are represented > by the lowercase letters, the uppercase letters, @, and _, in that > order. OK. How about if that sentence began with `When specifying n, the digits greater ...'? --

Re: bash man page needs more examples...(i.e. >0)

2012-01-29 Thread Roger
> On Sat, Jan 28, 2012 at 06:45:34PM -0800, Linda Walsh wrote: >Andreas Schwab wrote: >> Linda Walsh writes: >> >> >>> var=0a32; echo $var >>> -bash: 0a32: value too great for base (error token is "0a32") >>> >> >> Which part of "Constants with a leading 0 are interpreted as octal >> numbe

Re: bash man page needs more examples...(i.e. >0)

2012-01-29 Thread Andreas Schwab
Linda Walsh writes: > The part that says: > digits greater than 9 are represented > by the lowercase letters, the uppercase letters, @, and _, in > that > order. >Again, What part of that do you not get? Which part of "decimal number" did you not understand? Andre

Re: bash man page needs more examples...(i.e. >0)

2012-01-29 Thread Linda Walsh
Andreas Schwab wrote: Linda Walsh writes: var=0a32; echo $var -bash: 0a32: value too great for base (error token is "0a32") Which part of "Constants with a leading 0 are interpreted as octal numbers" did you not understand? The part that said the ones that start with 0 and are fol

Re: bash man page needs more examples...(i.e. >0)

2012-01-28 Thread Andreas Schwab
Linda Walsh writes: > var=0a32; echo $var > -bash: 0a32: value too great for base (error token is "0a32") Which part of "Constants with a leading 0 are interpreted as octal numbers" did you not understand? > var=a#32; echo $var > -bash: a#32: syntax error: invalid arithmetic operator (error tok

bash man page needs more examples...(i.e. >0)

2012-01-28 Thread Linda Walsh
reading the section no constants: Constants with a leading 0 are interpreted as octal numbers. A leading 0x or 0X denotes hexadecimal. Otherwise, numbers take the form [base#]n, where base is a decimal number between 2 and 64 representing the arithmetic base,