CPC G06F 40/205 (2020.01) | 9 Claims |
1. An analysis device, comprising:
processing circuitry configured to:
perform parsing on a first character string based on a grammar described in a parsing expression grammar (PEG) in which a variable is associated with a predetermined terminal symbol;
add, to the variable, an element in which a predetermined attribute is imparted to a part of the first character string, the part being a second character string analyzed as corresponding to the terminal symbol;
extract an element that is latest from elements of each predetermined attribute from the variable; and
determine whether the element extracted satisfies a predetermined condition regarding a context, preventing elements that are not latest among elements stored in the variable from being extracted.
|