But im to lazy to write it myself ;) A string matching function that can match a string using a mask containing * and ? wildcards.

string     db "this is a test",0
mask       db "*is*t?st",0

invoke lstrmatch, addr string, addr mask
.IF eax==NULL
   ; match
   ; no match
Has anyone written a function that can do this?
Posted on 2001-05-10 05:59:00 by Zynaps
I think it would be necessary to limit the meaning of "*" and "?" in such a routine. You might scan the web for the word "grep", which means a string- search (or search-and-replace) function with pattern-matching. I remember a program called MEGREP which was part of MASM around 1990, but I don't think the source is public. A pattern-matching routine is tough to write because it should be reentrant, i.e. it should call itself. Larry
Posted on 2001-05-12 03:02:00 by Larry Hammick