1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-22 08:22:04 +03:00

Preprocessor regexp: "." now matches even line terminators. Closes #1653

This commit is contained in:
Federico Fissore
2013-11-17 22:12:07 +01:00
parent e6698e4baa
commit 84e9d70415
4 changed files with 61 additions and 1 deletions

View File

@ -257,7 +257,7 @@ public class PdePreprocessor {
// pre-processor directive
p += "|" + "(^\\s*#.*?$)";
Pattern pattern = Pattern.compile(p, Pattern.MULTILINE);
Pattern pattern = Pattern.compile(p, Pattern.MULTILINE | Pattern.DOTALL);
Matcher matcher = pattern.matcher(in);
return matcher.replaceAll(" ");
}