diff options
author | Yann Herklotz <ymherklotz@gmail.com> | 2017-03-17 15:32:22 +0000 |
---|---|---|
committer | Yann Herklotz <ymherklotz@gmail.com> | 2017-03-17 15:32:22 +0000 |
commit | 3d846f1ef6fa03a075e3b1f6cd2f021856d2846f (patch) | |
tree | 8710b643a58a782403a7b179b6d3abe2fb09c356 /c_compiler/src/c_lexer.flex | |
parent | 3d77964b5739146a5285d10543df7b51e066c239 (diff) | |
download | Compiler-3d846f1ef6fa03a075e3b1f6cd2f021856d2846f.tar.gz Compiler-3d846f1ef6fa03a075e3b1f6cd2f021856d2846f.zip |
Trying to fix segfault
Diffstat (limited to 'c_compiler/src/c_lexer.flex')
-rw-r--r-- | c_compiler/src/c_lexer.flex | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/c_compiler/src/c_lexer.flex b/c_compiler/src/c_lexer.flex index 716e1ac..6f0262e 100644 --- a/c_compiler/src/c_lexer.flex +++ b/c_compiler/src/c_lexer.flex @@ -55,8 +55,8 @@ ALL . [|] { return T_OR; } [\^] { return T_XOR; } [&] { return T_AND; } -[=][=] { return T_EQUALITY_OP; } -[!][=] { return T_EQUALITY_OP; } +[=][=] { yylval.string = new std::string(yytext); return T_EQUALITY_OP; } +[!][=] { yylval.string = new std::string(yytext); return T_EQUALITY_OP; } ([<>][=])|[<>] { return T_REL_OP; } [<>][<>] { return T_SHIFT_OP; } [*] { yylval.string = new std::string(yytext); return T_MULT; } |