Move Full from fmt to parse and reorganize confusingly-named Module ast type

This commit is contained in:
Joshua Warner 2024-08-06 19:03:08 -07:00
parent 698bbc3cf1
commit d25c048d48
No known key found for this signature in database
GPG key ID: 89AD497003F93FDD
47 changed files with 1759 additions and 1776 deletions

View file

@ -74,7 +74,7 @@ pub fn highlight(text: &str) -> Vec<Loc<Token>> {
let header_keywords = HEADER_KEYWORDS.iter().copied().collect::<HashSet<_>>();
let body_keywords = KEYWORDS.iter().copied().collect::<HashSet<_>>();
if let Ok((_prog, _, new_state)) = crate::module::header().parse(&arena, state.clone(), 0) {
if let Ok((_prog, _, new_state)) = crate::header::header().parse(&arena, state.clone(), 0) {
let inner_state =
State::new(text[..state.bytes().len() - new_state.bytes().len()].as_bytes());
highlight_inner(&arena, inner_state, &mut tokens, &header_keywords);