uroboros-diversification/src/disasm/lex.py
def char_collect_all(s, c):
    """
    Find all appearances of char in string
    :param s: haystack
    :param c: needle
    :return: list of indices
    """
    start = 0
    res = []
    clen = len(c)
    while True:
        start = s.find(c, start)
        if start == -1: break
        res.append(start)
        start += clen
    return res

    Find all appearances of char in string
    :param s: haystack
    :param c: needle
    :return: list of indices
    
Find all appearances of char in string
Find all appearances of char in string
def char_collect_all(s, c):
    start = 0
    res = []
    clen = len(c)
    while True:
        start = s.find(c, start)
        if start == -1: break
        res.append(start)
        start += clen
    return res
def char_collect_all ( s , c ) : start = 0 res = [ ] clen = len ( c ) while True : start = s . find ( c , start ) if start == - 1 : break res . append ( start ) start += clen return res
Find all appearances of char in string
Find all appearances of char in string
"""
    Find all appearances of char in string
    :param s: haystack
    :param c: needle
    :return: list of indices
    """
list of indices
list of indices
s
None
c
None