Created
January 29, 2024 07:45
-
-
Save garlic0x1/20a2c5485714e394d5151d6c4e6fdf01 to your computer and use it in GitHub Desktop.
Glob match with CFFI
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(cffi:defcfun ("fnmatch" fnmatch) :int | |
(pattern :string) | |
(string :string) | |
(flags :int)) | |
(defun glob-match (pattern string &optional (flags 4)) | |
(= 0 (fnmatch pattern string flags))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment