case文と引数処理

Limboのcase文はCのswitch文よりもシェルのcaseのパターンマッチングに近い。breakを書く必要はない。

以下はyacc.bから引数処理のコード。Argモジュールが使われている。先頭からマッチングしていき、'*'はワイルドカード

	arg := Arg.init(argv);
	while(c := arg.opt()){
		case c{
		'v' or 'V' =>
			vflag++;
		'D' =>
			yydebug = arg.arg();
		'd' =>
			dflag++;
		'n' =>
			stacksize = int arg.arg();
		'o' =>
			ytab++;
			ytabc = arg.arg();
		's' =>
			stem++;
			stemc = arg.arg();
		'm' =>
			suppressmod++;
		* =>
			usage();
		}
	}