Skip to content

Commit af5e454

Browse files
committed
Change type signature for laco_is_match
1 parent 3843de5 commit af5e454

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/util.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ void laco_kill(LacoState* laco, int status, const char* message) {
2727
exit(status);
2828
}
2929

30-
int laco_is_match(const char** matches, const char* test_string) {
30+
bool laco_is_match(const char** matches, const char* test_string) {
3131
int i;
3232
char* match;
3333

src/util.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
#ifndef LACO_UTIL_H
22
#define LACO_UTIL_H
33

4+
#include <stdbool.h>
5+
46
struct LacoState;
57

68
/**
@@ -36,7 +38,7 @@ void laco_report_error(struct LacoState* laco, int status);
3638
* Checks if the test string matches any of the string in matches and
3739
* returns 1 if true, and 0 if false.
3840
*/
39-
int laco_is_match(const char** matches, const char* test_string);
41+
bool laco_is_match(const char** matches, const char* test_string);
4042

4143
/**
4244
* Break the provided string into an array of strings that are between the

0 commit comments

Comments
 (0)