2011-06-26 6 views

答えて

1

name

A word consisting solely of letters, numbers, and underscores, and beginning with a letter or underscore. Names are used as shell variable and function names. Also referred to as an identifier.

http://www.gnu.org/software/bash/manual/bashref.htmlから左側の値が識別子ではありません。それは表現です。そのため、コマンド(式全体を評価する)は無効です。

つまり、名前にアスタリスクを付けることはできません。また、何らかの数学(乗算)を行うことで変数名を生成することはできません。

+0

クール、参考に感謝! – abc

1

可変識別子の文字が無効です(アスタリスク)。

1

POSIXは、英数字とアンダースコアで構成され、数字で始まらないシェル変数名を定義します。 (これに違反する特別な変数があり、それらは常に1文字であり、ユーザー定義の変数と衝突することはありません)。

3.230 Name

In the shell command language, a word consisting solely of underscores, digits, and alphabetics from the portable character set. The first character of a name is not a digit.

関連する問題