comparison tl1trans/tl1trans.pl @ 7:c95d28c5aaf2 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Thu, 12 Nov 2020 11:46:20 +0900
parents 1896f63eedc1
children
comparison
equal deleted inserted replaced
6:1896f63eedc1 7:c95d28c5aaf2
59 if (eof) { 59 if (eof) {
60 &proto; 60 &proto;
61 exit 1; 61 exit 1;
62 } 62 }
63 $_ = <>; 63 $_ = <>;
64 s/^\%.*//; 64 s/\%.*//;
65 s/\$([0-9A-Z]+)/0x\1/g; # will replce inside of string
65 } 66 }
66 67
67 # get declaration 68 # get declaration
68 sub getDecl { 69 sub getDecl {
69 decl : while(1) { 70 decl : while(1) {
109 #include <stdio.h> 110 #include <stdio.h>
110 #include <string.h> 111 #include <string.h>
111 #include <unistd.h> 112 #include <unistd.h>
112 #include "proto.h" 113 #include "proto.h"
113 114
115 extern char GET(int);
114 $gvar; 116 $gvar;
115 $array; 117 $array;
116 118
117 int main(int ac, char *av[]) { 119 int main(int ac, char *av[]) {
118 { 120 {