From 94a89d51f353c330cddf4112803d21a99a55225c Mon Sep 17 00:00:00 2001 From: qining Date: Wed, 27 Apr 2016 10:17:30 -0400 Subject: [PATCH] add .err file for eof_missing test --- Test/baseResults/preprocessor.eof_missing.vert.err | 0 glslang/MachineIndependent/Scan.h | 6 ++++-- 2 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 Test/baseResults/preprocessor.eof_missing.vert.err diff --git a/Test/baseResults/preprocessor.eof_missing.vert.err b/Test/baseResults/preprocessor.eof_missing.vert.err new file mode 100644 index 00000000..e69de29b diff --git a/glslang/MachineIndependent/Scan.h b/glslang/MachineIndependent/Scan.h index 5532fc31..1cc437cb 100644 --- a/glslang/MachineIndependent/Scan.h +++ b/glslang/MachineIndependent/Scan.h @@ -122,7 +122,7 @@ public: // go back one character void unget() { - // Do not roll back if we reached the end of the file. + // Do not roll back once we've reached the end of the file. if (endOfFileReached) return; if (currentChar > 0) { @@ -255,7 +255,9 @@ protected: bool singleLogical; // treats the strings as a single logical string. // locations will be reported from the first string. - bool endOfFileReached; // set to true once peak() returns EndOfFile. + // set to true once peak() returns EndOfFile, so that we won't roll back + // once we've reached EndOfFile. + bool endOfFileReached; }; } // end namespace glslang