Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement
From: Edward G. Nilges (spinoza1111_at_yahoo.com)
Date: 06/17/04
- Next message: Randy Howard: "Re: Hash algo for 3 ints (x, y, z)"
- Previous message: Bill Godfrey: "Re: alpha-numeric permutations"
- In reply to: Programmer Dude: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Next in thread: Randy Howard: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Reply: Randy Howard: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Reply: Programmer Dude: "Regular Expressions and BNF"
- Reply: Programmer Dude: "Vile Hypocrasy (was: something else)"
- Reply: Christopher Barber: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 16 Jun 2004 16:05:44 -0700
Programmer Dude <Chris@Sonnack.com> wrote in message news:<uvm0d0dsojbk0p81r4hqlqvo2vt8nrqg30@4ax.com>...
> Edward G. Nilges writes:
>
> >> (You did not consider the twin complications of quotation and
> >> escape codes,
> >
> > (((\"[^\"]*\")|[\"]*)*,((\"[^\"]*\")|[\"]*)*)* probably handles
> > quotes.
>
> 1. You generally don't need to escape double-quotes unless your
> regex is in a C-ish language string. You certainly don't need
> them here.
>
> 2. I think you probably meant [^"]* rather than ["]* to match fields
> not enclosed by quotes. Note, too, that ["]* is the same as "*.
>
> 3. The above won't match: "foo" , "bar"
> because no allowance was made for spaces outside the quotes.
>
> 4. It's often nice to allow single-quotes as well as double-quotes.
>
> 5. OFF THE TOP OF MY HEAD, I'm not sure it's necessary to match
> two fields. I suspect it's doable with one. It is certainly
> the case that your code version of the regex didn't need to
> have two field spanning loops, but I'll give you leeway assuming
> the code was just implementing the regex as is.
>
> > Escapes are easy to add.
>
> Yeah? Let's see you do it.
Let's see your Mama do it: she did me last week.
Chris, Fascism is the nightmare of childhood. This was Adorno's dark
vision when he realized that dialectically, regression appears not
among the lumpenproletariat, but at the putative zenith, as where
highly-placed university administrators cooperated with the
eradication of Jews from German universities, using the language of
the streets, which I use above in response to your drunken posts.
In fact, the ease of making errors in regular expressions is a concern
of mine since I make errors in regular expressions, although I have
used them since the 1970s; precisely by means of making errors do we
progress: thugs don't realize this because drunken thugs can never
make errors and must set norms for others (like the clown who laid
into me at the Oak Street Beach for wearing Speedos). The notation is
in terms of computer science regressive and gnomic.
This is why my book contains a tool not only for testing regular
expressions but also for documenting and storing them.
Probably because you're drunk, you're playing a silly man's game,
because of course I could merely copy correct regular expressions in
response.
I have in fact found that expressing the regular expression pattern in
Backus Naur Form (which is always possible) and writing by hand a
recursive descent algorithm results in clearer solutions.
You do need to replicate the pattern on either side of the comma
because you need to express the fact that the comma separates like
patterns. Most formalisms allow you to name patterns to make the
replication easier.
Your point (3) is correct and easily fixed.
I will respond to your other points later if you behave yourself.
- Next message: Randy Howard: "Re: Hash algo for 3 ints (x, y, z)"
- Previous message: Bill Godfrey: "Re: alpha-numeric permutations"
- In reply to: Programmer Dude: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Next in thread: Randy Howard: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Reply: Randy Howard: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Reply: Programmer Dude: "Regular Expressions and BNF"
- Reply: Programmer Dude: "Vile Hypocrasy (was: something else)"
- Reply: Christopher Barber: "Re: [OT] Re: Chris Sonnack on VB.Net's putative Set statement"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|