Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

iter_long does not work properly #189

Open
@djstrong

Description

@djstrong
automaton = ahocorasick.Automaton()    input='👨‍👨‍👦'    for c in input:        automaton.add_word(c, c)    automaton.add_word(input, input)    automaton.make_automaton()    for end_index, value in automaton.iter_long(input):        end_index += 1        start_index = end_index - len(value)        print('FOUND', start_index, end_index, value)

Response is:

FOUND 1 2 ‍FOUND 3 4 ‍FOUND 4 5 👦

It should found one match:0 5 👨‍👨‍👦

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp