diff options
Diffstat (limited to 'zwgc/text_operations.c')
-rw-r--r-- | zwgc/text_operations.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/zwgc/text_operations.c b/zwgc/text_operations.c index 69db241..ba1821a 100644 --- a/zwgc/text_operations.c +++ b/zwgc/text_operations.c @@ -41,12 +41,12 @@ string lany(text_ptr, str) string lbreak(text_ptr, set) string *text_ptr; - character_class *set; + character_class set; { string result, whats_left; char *p = *text_ptr; - while (*p && !(*set)[*p]) p++; + while (*p && !set[*p]) p++; result = string_CreateFromData(*text_ptr, p - *text_ptr); whats_left = string_Copy(p); @@ -58,12 +58,12 @@ string lbreak(text_ptr, set) string lspan(text_ptr, set) string *text_ptr; - character_class *set; + character_class set; { string result, whats_left; char *p = *text_ptr; - while (*p && (*set)[*p]) p++; + while (*p && set[*p]) p++; result = string_CreateFromData(*text_ptr, p - *text_ptr); whats_left = string_Copy(p); @@ -93,13 +93,13 @@ string rany(text_ptr, str) string rbreak(text_ptr, set) string *text_ptr; - character_class *set; + character_class set; { string result, whats_left; string text = *text_ptr; char *p = text + strlen(text); - while (text<p && !(*set)[p[-1]]) p--; + while (text<p && !set[p[-1]]) p--; result = string_Copy(p); whats_left = string_CreateFromData(text, p - text); @@ -111,13 +111,13 @@ string rbreak(text_ptr, set) string rspan(text_ptr, set) string *text_ptr; - character_class *set; + character_class set; { string result, whats_left; string text = *text_ptr; char *p = text + strlen(text); - while (text<p && (*set)[p[-1]]) p--; + while (text<p && set[p[-1]]) p--; result = string_Copy(p); whats_left = string_CreateFromData(text, p - text); |