X-Git-Url: http://git.ieval.ro/?p=filters.git;a=blobdiff_plain;f=jive.l;h=ff6d21f10e698cb32899fd7d19b681e69de4eedf;hp=dcb99240b2bfcc52d71eab532eeb189e6b93c10e;hb=HEAD;hpb=7e3afbbacdd24f8c3fb87599eeda32b977fe6d6c diff --git a/jive.l b/jive.l index dcb9924..ff6d21f 100644 --- a/jive.l +++ b/jive.l @@ -7,6 +7,7 @@ * * Reproduction permitted so long as this notice is retained. */ + %} %e 1700 %p 4000 @@ -16,7 +17,17 @@ %o 1500 BW [ \t\(] EW [ \t.,;!\?$\)] +%option noyywrap + +%{ + void plastc(void); + char caseify(char); + void expletive(void); + void thing(char); +%} + %% + @[Bb]egin(.*) | ".so ".*$ printf("%s", yytext); {BW}send printf("%ct'row",yytext[0]); @@ -194,12 +205,13 @@ against printf("agin'"); meta printf("meta-fuckin'"); cally printf("c'l"); %% -plastc() + +void plastc() { - unput(yytext[yyleng-1]); + unput(yytext[yyleng-1]); } -caseify(c) +char caseify(c) char c; { if (yytext[0] <= 'Z') @@ -208,7 +220,7 @@ char c; return (c); } -thing(c) +void thing(c) char c; { static short count = 0; @@ -226,7 +238,8 @@ char c; break; } } -expletive() + +void expletive() { static short count = 0; static short which = 0;