0

Well topic speak for himself, here example of a code(lex file before compilation):

%{

#include<stdio.h>
int Upperc=0;
int Lowerc=0;
%}

%%
[A-Z] {printf("Upperccase\t");Upperc++;}
[a-z] {printf("Lowerccase\t");Lowerc++;}
%%



main()
{
printf("Enter a string\n");
yylex();

printf("Upperccase=%d and Lowerccase=%d",Upperc,Lowerc);
}

for some reason when trying to run at vs13, I'm always getting syntax error: 'constant' , there is no line or any information about there error except this, please help me understand what is wrong, thanks!

user2323232
  • 249
  • 2
  • 11

1 Answers1

1

Well, as it seems after 5 hours of not understanding the problem ( and 20 minutes after posted here, that the issue was with VS13 ,after installing VS10 everything was fixed... Thank you all!

user2323232
  • 249
  • 2
  • 11