docs: def weld_str_find(array, sub, start, end):
      """Return index of sub in elements if found, else -1.
  
      Parameters
      ----------
      array : numpy.ndarray or WeldObject
          Input data.
      sub : str
          To check for.
      start : int
          Start index for searching.
      end : int or None
          Stop index for searching.
  
      Returns
      -------
      WeldObject
          Representation of this computation.
  
      """
      obj_id, weld_obj = create_weld_object(array)
      sub_id = get_weld_obj_id(weld_obj, sub)
  
      if end is None:
          end = 'len(e)'
      else:
          end = to_weld_literal(end, WeldLong())
  
      start = to_weld_literal(start, WeldLong())
  
      # TODO: maybe be more friendly and fix end >= len(e) to be len(e) - 1?
      weld_template = """let lenSub = len({sub});
  map({array},
      |e: vec[i8]|
          let start = {start};
          let size = {end} - start;
          let string = slice(e, start, size);
          let lenString = len(string);
          if(lenSub > lenString,
              -1L,
              # start by assuming sub is not found, until proven it is
              let words_iter_res = iterate({{0L, false}}, 
                  |p| 
                      let e_i = p.$0;
                      let pat_i = 0L;
                      # start by assuming the substring and sub are the same, until proven otherwise
                      let word_check_res = iterate({{e_i, pat_i, true}}, 
                          |q| 
                              let found = lookup(string, q.$0) == lookup({sub}, q.$1);
                              {{
                                  {{q.$0 + 1L, q.$1 + 1L, found}}, 
                                  q.$1 + 1L < lenSub &&
                                  found == true
                              }}
                      ).$2;
                      {{
                          {{p.$0 + 1L, word_check_res}}, 
                          p.$0 + lenSub < lenString &&
                          word_check_res == false
                      }}
              );
              if(words_iter_res.$1 == true,
                  words_iter_res.$0 - 1L + start,
                  -1L
              )
          )
  )"""
  
      weld_obj.weld_code = weld_template.format(array=obj_id,
                                                sub=sub_id,
                                                start=start,
                                                end=end)
  
      return weld_obj