It'd be handy if there were wildcard based equivalents to $regex() and $regsubex(). They're two of the most powerful and useful identifiers in mIRC IMO and yet a lot of people can't use them because they don't understand regular expressions.

A slightly extended wildcard syntax would be easy enough for beginners to pick up and would still be very useful. The extension being that * would behave ungreedily and ** would be greedy.

Code:
$wildmatch([name], text, wildmask)
$wildref([name], N)
$wildsub([name], text, wildmask, subtext)


No additional back-referencing syntax would be needed, it'd just be implicit around any wildcard, and all matches/substitutions would be "global".

Edit: Oh, adjoining wildcards would count as a single back-reference (so things like ??? create a single reference and ?* can be used to reference one-or-more characters)

Last edited by starbucks_mafia; 21/05/07 11:05 PM.

Spelling mistakes, grammatical errors, and stupid comments are intentional.