src/Lexer.cc

changeset 99
44c0c7f31ae8
parent 89
029a330a9bef
child 103
48472c0678cc
--- a/src/Lexer.cc	Sun Feb 09 04:13:15 2014 +0200
+++ b/src/Lexer.cc	Sun Feb 09 14:30:18 2014 +0200
@@ -286,6 +286,20 @@
 
 // =============================================================================
 //
+bool Lexer::PeekNextType (EToken req)
+{
+	Iterator pos = mTokenPosition;
+	bool result = false;
+
+	if (GetNext() && GetTokenType() == req)
+		result = true;
+
+	mTokenPosition = pos;
+	return result;
+}
+
+// =============================================================================
+//
 Lexer* Lexer::GetCurrentLexer()
 {
 	return gMainLexer;

mercurial