RegEx Help (REALbasic network user group Mailinglist archive)
Back to the thread list
Previous thread: A Video Introduction to SQLite (was REALSQLDatabase)
Next thread: navigating within a school network
| Win32 API Declares - Berg, Heath | |||
| RegEx Help - Thomas Cunningham | |||
| Re: RegEx Help - Steve Garman | |||
| Re: RegEx Help - Steve Garman | |||
| Re: RegEx Help - Thomas Cunningham | |||
| RegEx Help |
| Date: 04.06.06 06:07 (Sat, 03 Jun 2006 19:07:33 -1000) |
| From: Thomas Cunningham |
|
Howdy,
Boy me and RegEx just don't get along - blah! :) Looking for some help. I'm looking for one search pattern that matches the two prototypes below. This pattern, (\w*)\s(APIENTRY)\s(\w*)\s matches this the way I require, GLAPI void APIENTRY glWindowPos2fv (const GLfloat *); 1) void 2) APIENTRY 3) glWindowPos2fv I need the search pattern that also returns this, 1) GLvoid* 2) APIENTRY 3) glMapBuffer from this text, GLAPI GLvoid* APIENTRY glMapBuffer (GLenum, GLenum); Any idea's? Thank you. |
| Re: RegEx Help |
| Date: 04.06.06 08:28 (Sun, 4 Jun 2006 08:28:20 +0100) |
| From: Steve Garman |
|
Are you looking for:
(\w*\*?)\s(APIENTRY)\s(\w*)\s |
| Re: RegEx Help |
| Date: 04.06.06 08:40 (Sun, 4 Jun 2006 08:40:07 +0100) |
| From: Steve Garman |
|
On Sun, 4 Jun 2006 08:28:20 +0100 REALbasic NUG was sent the following email
> Are you looking for: > (\w*\*?)\s(APIENTRY)\s(\w*)\s Unless you also want to include pointers to pointers, in which case this might be preferable: (\w*\**)\s(APIENTRY)\s(\w*)\s |
| Re: RegEx Help |
| Date: 05.06.06 03:18 (Sun, 04 Jun 2006 16:18:37 -1000) |
| From: Thomas Cunningham |
|
>> Are you looking for:
> >> (\w*\*?)\s(APIENTRY)\s(\w*)\s > > Unless you also want to include pointers to pointers, in which case > this > might be preferable: > > (\w*\**)\s(APIENTRY)\s(\w*)\s Thank you Steve! That does it nicely. Works a treat, as I think you put it. ;) Of all the silly, cryptic and obfuscated schemes in computer programming, RegEx gets my vote for top dog. :) |