spiffyscore

Check-in [6dcdb96a02]
Login
Overview
Comment:Improved lexing of roman numerals, including support for minor chord recognition
Timelines: family | ancestors | descendants | both | ply
Files: files | file ages | folders
SHA1: 6dcdb96a02795827f78ff38ecbc724f9e51092ff
User & Date: spiffytech@gmail.com on 2010-11-16 16:13:25
Other Links: branch diff | manifest | tags
Context
2010-11-16
16:34
Now parses chords check-in: 3d9a81ddef user: spiffytech@gmail.com tags: ply
16:13
Improved lexing of roman numerals, including support for minor chord recognition check-in: 6dcdb96a02 user: spiffytech@gmail.com tags: ply
15:57
Now parses roman numerals I-VII instead of notes check-in: 32e6229eaa user: spiffytech@gmail.com tags: ply
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Modified parse.py from [911b321ada] to [1dcfc5e85f].

    11     11       "OCTAVE",
    12     12       "CHORD_TYPE",
    13     13   )
    14     14   
    15     15   t_ignore = " |"
    16     16   
    17     17   #t_BASENOTE = r"[A-Ga-g]"
    18         -t_BASENOTE = r"I?V?I*[^ ]"
           18  +t_BASENOTE = r"I+V?|VI*|i+v?|vi*"
    19     19   t_ACCIDENTAL = r"\^{1,2}|_{1,2}|="
    20     20   t_REST = r"z"
    21     21   t_OCTAVE = r"'+|,+"
    22     22   t_CHORD_TYPE = r"m|7|m7|0|o|\+|mb5|sus|sus4|maj7|mmaj7|7sus4|dim|dim7|7b5|m7b5|6|b6|m6|mb6|46|maj9|9|add9|7b9|m9"
    23     23   
    24     24   def t_NOTE_LENGTH(t):
    25     25       r"/?\d+"