Opened 8 years ago

Closed 7 years ago

#383 closed defect (fixed)

Konami code detection takes quadratic time in number of keystrokes

Reported by: andersk Owned by:
Priority: minor Milestone:
Component: pony Keywords:
Cc:

Description

scripts-pony/scripts/templates/master.mak has a very inefficient Konami code detection easter egg that appends all keystrokes to a JavaScript? array. It should be rewritten to use the obvious 11-state Knuth–Morris–Pratt FSM.

This now also affects XVM, who copied this code.

Change History (1)

comment:1 Changed 7 years ago by andersk

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.