trstr: more comments - neatvi - [fork] simple vi-type editor with UTF-8 support
 (HTM) git clone git://src.adamsgaard.dk/neatvi
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
       ---
 (DIR) commit 8fbb8b3a23c593b84d3bc4218329226d6b0cdb59
 (DIR) parent 29df1c140f074dbd0a4d61baa7256866ba32051c
 (HTM) Author: Ali Gholami Rudi <ali@rudi.ir>
       Date:   Sat, 20 Nov 2021 22:42:38 +0330
       
       rstr: more comments
       
       Diffstat:
         M rstr.c                              |      11 ++++++-----
       
       1 file changed, 6 insertions(+), 5 deletions(-)
       ---
 (DIR) diff --git a/rstr.c b/rstr.c
       t@@ -5,13 +5,14 @@
        #include "vi.h"
        
        struct rstr {
       -        struct rset *rs;        /* the compiled regular expression */
       -        char *str;                /* simple search string */
       -        int icase;
       -        int lbeg, lend;
       -        int wbeg, wend;
       +        struct rset *rs;        /* only for regex patterns */
       +        char *str;                /* for simple, non-regex patterns  */
       +        int icase;                /* ignore case */
       +        int lbeg, lend;                /* match line beg/end */
       +        int wbeg, wend;                /* match word beg/end */
        };
        
       +/* return zero if a simple pattern is given */
        static int rstr_simple(struct rstr *rs, char *re)
        {
                char *beg;