From ceeb5453a8d8e385de49a5f72b1b395e7ca380e3 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Sat, 11 Jun 2016 21:45:37 -0300 Subject: [PATCH] gdscript tokenizer will dislike use of case, closes #4991 --- modules/gdscript/gd_tokenizer.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/gdscript/gd_tokenizer.cpp b/modules/gdscript/gd_tokenizer.cpp index 56eacfd20e7..8dd68cf95a2 100644 --- a/modules/gdscript/gd_tokenizer.cpp +++ b/modules/gdscript/gd_tokenizer.cpp @@ -79,8 +79,8 @@ const char* GDTokenizer::token_names[TK_MAX]={ "for", "do", "while", -"switch", -"case", +"switch (reserved)", +"case (reserved)", "break", "continue", "pass", @@ -874,6 +874,7 @@ void GDTokenizerText::_advance() { {TK_CF_WHILE,"while"}, {TK_CF_DO,"do"}, {TK_CF_SWITCH,"switch"}, + {TK_CF_CASE,"case"}, {TK_CF_BREAK,"break"}, {TK_CF_CONTINUE,"continue"}, {TK_CF_RETURN,"return"},