|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: iSCSI: Re: range separatorBill Studenmund wrote: > > Well, there probably won't be that many parsers. One set-of-numbers parser > can be used for all the number-expecting cases. Yes, that's why I was mentioning contex-free grammars to describe the values which the variables can take, since then it is really easy to see what the terminals are (aka tokens, primitives), and one would need to have an integer, and string parser, the rest is left to the key's handler/negotiator. As in: > > > and _THEN_ you'd abstractize into > > integer value, or > > string value, or > > range. > > > > Note, that a range is > > a string (we know this already) of > > <integer><range symbol><integer> to use context > > free grammar (stripped down version :-). [cut] > > So the Target will know that it is a range, > > but it doesn't matter... it will have to check > > the context anyway... > > Won't the parser already have to have figured out the context anyway? We > have to know if the key is: 1) valid, and 2) appropriate for this phase > already, don't we? After figuring that out, is it hard to know if we > expect a string or one or more numbers? Yes, of course. I was merely trying to show that we cannot escape from the variable's context. Once we all recognize this fact we'd see that we could overload certain symbols to denote ranges. I mean certain, since overloading the comma will not be that wise as in the _future_ we may want to have a list of ranges (e.g. for choosing a bit as in ``OurBitRange=1-4,13-16''). -- Luben
Home Last updated: Thu Mar 21 21:18:14 2002 9264 messages in chronological order |