Skip to main content

parse_key

Function parse_key 

Source
pub fn parse_key(text: &str) -> Result<KeyReading, MusicError>
Expand description

Parses a key name.

A key is major or minor. A mode name such as A dorian is a scale, so read it through the scale entries.

ยงErrors

MusicError::UnknownKey for text no branch of the grammar accepts, such as 13A, Z or the chord Am7.