-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wildmatch: rename constants and update prototype
- All exported constants now have a prefix WM_ - Do not rely on FNM_* constants, use the WM_ counterparts - Remove TRUE and FALSE to follow Git's coding style - While at it, turn flags type from int to unsigned int - Add an (unused yet) argument to carry extra information so that we don't have to change the prototype again later when we need to pass other stuff to wildmatch Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
- Loading branch information
Nguyễn Thái Ngọc Duy
authored and
Junio C Hamano
committed
Jan 1, 2013
1 parent
b6a3d33
commit 9b3497c
Showing
4 changed files
with
62 additions
and
55 deletions.
There are no files selected for viewing
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
/* wildmatch.h */ | ||
#ifndef WILDMATCH_H | ||
#define WILDMATCH_H | ||
|
||
#define ABORT_MALFORMED 2 | ||
#define NOMATCH 1 | ||
#define MATCH 0 | ||
#define ABORT_ALL -1 | ||
#define ABORT_TO_STARSTAR -2 | ||
#define WM_CASEFOLD 1 | ||
|
||
int wildmatch(const char *pattern, const char *text, int flags); | ||
#define WM_ABORT_MALFORMED 2 | ||
#define WM_NOMATCH 1 | ||
#define WM_MATCH 0 | ||
#define WM_ABORT_ALL -1 | ||
#define WM_ABORT_TO_STARSTAR -2 | ||
|
||
struct wildopts; | ||
|
||
int wildmatch(const char *pattern, const char *text, | ||
unsigned int flags, | ||
struct wildopts *wo); | ||
#endif |