From 574f1f780eed39be19e7aeb5cd04066980458740 Mon Sep 17 00:00:00 2001 From: Tad Hardesty Date: Mon, 15 Jul 2019 18:09:10 -0700 Subject: [PATCH] Allow #including .dme files --- src/dreammaker/preprocessor.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/dreammaker/preprocessor.rs b/src/dreammaker/preprocessor.rs index eedba07b..c65e7479 100644 --- a/src/dreammaker/preprocessor.rs +++ b/src/dreammaker/preprocessor.rs @@ -732,6 +732,7 @@ impl<'ctx> Preprocessor<'ctx> { Some("dmf") => FileType::DMF, Some("dms") => FileType::DMS, Some("dm") => FileType::DM, + Some("dme") => FileType::DM, Some(ext) => { self.context.register_error(DMError::new( self.last_input_loc, @@ -747,8 +748,6 @@ impl<'ctx> Preprocessor<'ctx> { FileType::DMM => self.maps.push(candidate), FileType::DMF => self.skins.push(candidate), FileType::DMS => self.scripts.push(candidate), - // TODO: warn if a file is double-included, and - // don't include it a second time FileType::DM => match self.prepare_include_file(candidate) { Ok(include) => { // A phantom newline keeps the include