OLD | NEW |
1 // Copyright 2009 The Go Authors. All rights reserved. | 1 // Copyright 2009 The Go Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style | 2 // Use of this source code is governed by a BSD-style |
3 // license that can be found in the LICENSE file. | 3 // license that can be found in the LICENSE file. |
4 | 4 |
5 #include <bio.h> | 5 #include <bio.h> |
6 | 6 |
7 #undef OAPPEND | 7 #undef OAPPEND |
8 | 8 |
9 // avoid <ctype.h> | 9 // avoid <ctype.h> |
10 #undef isblank | 10 #undef isblank |
(...skipping 828 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
839 EXTERN Node* typesw; | 839 EXTERN Node* typesw; |
840 EXTERN Node* nblank; | 840 EXTERN Node* nblank; |
841 | 841 |
842 extern int thechar; | 842 extern int thechar; |
843 extern char* thestring; | 843 extern char* thestring; |
844 | 844 |
845 EXTERN char* hunk; | 845 EXTERN char* hunk; |
846 EXTERN int32 nhunk; | 846 EXTERN int32 nhunk; |
847 EXTERN int32 thunk; | 847 EXTERN int32 thunk; |
848 | 848 |
849 EXTERN int exporting; | |
850 EXTERN int erroring; | |
851 EXTERN int noargnames; | |
852 | |
853 EXTERN int funcdepth; | 849 EXTERN int funcdepth; |
854 EXTERN int typecheckok; | 850 EXTERN int typecheckok; |
855 EXTERN int packagequotes; | |
856 EXTERN int longsymnames; | |
857 EXTERN int compiling_runtime; | 851 EXTERN int compiling_runtime; |
858 | 852 |
859 EXTERN int rune32; | 853 EXTERN int rune32; |
860 | 854 |
861 /* | 855 /* |
862 * y.tab.c | 856 * y.tab.c |
863 */ | 857 */ |
864 int yyparse(void); | 858 int yyparse(void); |
865 | 859 |
866 /* | 860 /* |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
980 int exportname(char *s); | 974 int exportname(char *s); |
981 void exportsym(Node *n); | 975 void exportsym(Node *n); |
982 void importconst(Sym *s, Type *t, Node *n); | 976 void importconst(Sym *s, Type *t, Node *n); |
983 void importmethod(Sym *s, Type *t); | 977 void importmethod(Sym *s, Type *t); |
984 Sym* importsym(Sym *s, int op); | 978 Sym* importsym(Sym *s, int op); |
985 void importtype(Type *pt, Type *t); | 979 void importtype(Type *pt, Type *t); |
986 void importvar(Sym *s, Type *t, int ctxt); | 980 void importvar(Sym *s, Type *t, int ctxt); |
987 Type* pkgtype(Sym *s); | 981 Type* pkgtype(Sym *s); |
988 | 982 |
989 /* | 983 /* |
| 984 * fmt.c |
| 985 */ |
| 986 void fmtinstallgo(void); |
| 987 void dump(char *s, Node *n); |
| 988 void dumplist(char *s, NodeList *l); |
| 989 |
| 990 /* |
990 * gen.c | 991 * gen.c |
991 */ | 992 */ |
992 void addrescapes(Node *n); | 993 void addrescapes(Node *n); |
993 void cgen_as(Node *nl, Node *nr); | 994 void cgen_as(Node *nl, Node *nr); |
994 void cgen_callmeth(Node *n, int proc); | 995 void cgen_callmeth(Node *n, int proc); |
995 void clearlabels(void); | 996 void clearlabels(void); |
996 void checklabels(void); | 997 void checklabels(void); |
997 int dotoffset(Node *n, int *oary, Node **nn); | 998 int dotoffset(Node *n, int *oary, Node **nn); |
998 void gen(Node *n); | 999 void gen(Node *n); |
999 void genlist(NodeList *l); | 1000 void genlist(NodeList *l); |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1089 int duint32(Sym *s, int off, uint32 v); | 1090 int duint32(Sym *s, int off, uint32 v); |
1090 int duint64(Sym *s, int off, uint64 v); | 1091 int duint64(Sym *s, int off, uint64 v); |
1091 int duint8(Sym *s, int off, uint8 v); | 1092 int duint8(Sym *s, int off, uint8 v); |
1092 int duintptr(Sym *s, int off, uint64 v); | 1093 int duintptr(Sym *s, int off, uint64 v); |
1093 int dsname(Sym *s, int off, char *dat, int ndat); | 1094 int dsname(Sym *s, int off, char *dat, int ndat); |
1094 void dumpobj(void); | 1095 void dumpobj(void); |
1095 void ieeedtod(uint64 *ieee, double native); | 1096 void ieeedtod(uint64 *ieee, double native); |
1096 Sym* stringsym(char*, int); | 1097 Sym* stringsym(char*, int); |
1097 | 1098 |
1098 /* | 1099 /* |
1099 * print.c | |
1100 */ | |
1101 void exprfmt(Fmt *f, Node *n, int prec); | |
1102 void exprlistfmt(Fmt *f, NodeList *l); | |
1103 | |
1104 /* | |
1105 * range.c | 1100 * range.c |
1106 */ | 1101 */ |
1107 void typecheckrange(Node *n); | 1102 void typecheckrange(Node *n); |
1108 void walkrange(Node *n); | 1103 void walkrange(Node *n); |
1109 | 1104 |
1110 /* | 1105 /* |
1111 * reflect.c | 1106 * reflect.c |
1112 */ | 1107 */ |
1113 void dumptypestructs(void); | 1108 void dumptypestructs(void); |
1114 Type* methodfunc(Type *f, Type*); | 1109 Type* methodfunc(Type *f, Type*); |
(...skipping 12 matching lines...) Expand all Loading... |
1127 */ | 1122 */ |
1128 void anylit(int, Node *n, Node *var, NodeList **init); | 1123 void anylit(int, Node *n, Node *var, NodeList **init); |
1129 int gen_as_init(Node *n); | 1124 int gen_as_init(Node *n); |
1130 NodeList* initfix(NodeList *l); | 1125 NodeList* initfix(NodeList *l); |
1131 int oaslit(Node *n, NodeList **init); | 1126 int oaslit(Node *n, NodeList **init); |
1132 int stataddr(Node *nam, Node *n); | 1127 int stataddr(Node *nam, Node *n); |
1133 | 1128 |
1134 /* | 1129 /* |
1135 * subr.c | 1130 * subr.c |
1136 */ | 1131 */ |
1137 int Econv(Fmt *fp); | |
1138 int Jconv(Fmt *fp); | |
1139 int Lconv(Fmt *fp); | |
1140 int Nconv(Fmt *fp); | |
1141 int Oconv(Fmt *fp); | |
1142 int Sconv(Fmt *fp); | |
1143 int Tconv(Fmt *fp); | |
1144 int Vconv(Fmt *fp); | |
1145 int Zconv(Fmt *fp); | |
1146 Node* adddot(Node *n); | 1132 Node* adddot(Node *n); |
1147 int adddot1(Sym *s, Type *t, int d, Type **save, int ignorecase); | 1133 int adddot1(Sym *s, Type *t, int d, Type **save, int ignorecase); |
1148 Type* aindex(Node *b, Type *t); | 1134 Type* aindex(Node *b, Type *t); |
1149 int algtype(Type *t); | 1135 int algtype(Type *t); |
1150 void argtype(Node *on, Type *t); | 1136 void argtype(Node *on, Type *t); |
1151 Node* assignconv(Node *n, Type *t, char *context); | 1137 Node* assignconv(Node *n, Type *t, char *context); |
1152 int assignop(Type *src, Type *dst, char **why); | 1138 int assignop(Type *src, Type *dst, char **why); |
1153 void badtype(int o, Type *tl, Type *tr); | 1139 void badtype(int o, Type *tl, Type *tr); |
1154 int brcom(int a); | 1140 int brcom(int a); |
1155 int brrev(int a); | 1141 int brrev(int a); |
1156 NodeList* concat(NodeList *a, NodeList *b); | 1142 NodeList* concat(NodeList *a, NodeList *b); |
1157 int convertop(Type *src, Type *dst, char **why); | 1143 int convertop(Type *src, Type *dst, char **why); |
1158 int count(NodeList *l); | 1144 int count(NodeList *l); |
1159 int cplxsubtype(int et); | 1145 int cplxsubtype(int et); |
1160 void dump(char *s, Node *n); | |
1161 void dumplist(char *s, NodeList *l); | |
1162 int eqtype(Type *t1, Type *t2); | 1146 int eqtype(Type *t1, Type *t2); |
1163 int eqtypenoname(Type *t1, Type *t2); | 1147 int eqtypenoname(Type *t1, Type *t2); |
1164 void errorexit(void); | 1148 void errorexit(void); |
1165 void expandmeth(Sym *s, Type *t); | 1149 void expandmeth(Sym *s, Type *t); |
1166 void fatal(char *fmt, ...); | 1150 void fatal(char *fmt, ...); |
1167 void flusherrors(void); | 1151 void flusherrors(void); |
1168 void frame(int context); | 1152 void frame(int context); |
1169 Type* funcfirst(Iter *s, Type *t); | 1153 Type* funcfirst(Iter *s, Type *t); |
1170 Type* funcnext(Iter *s); | 1154 Type* funcnext(Iter *s); |
1171 void genwrapper(Type *rcvr, Type *method, Sym *newnam, int iface); | 1155 void genwrapper(Type *rcvr, Type *method, Sym *newnam, int iface); |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1340 void zfile(Biobuf *b, char *p, int n); | 1324 void zfile(Biobuf *b, char *p, int n); |
1341 void zhist(Biobuf *b, int line, vlong offset); | 1325 void zhist(Biobuf *b, int line, vlong offset); |
1342 void zname(Biobuf *b, Sym *s, int t); | 1326 void zname(Biobuf *b, Sym *s, int t); |
1343 | 1327 |
1344 #pragma varargck type "A" int | 1328 #pragma varargck type "A" int |
1345 #pragma varargck type "B" Mpint* | 1329 #pragma varargck type "B" Mpint* |
1346 #pragma varargck type "D" Addr* | 1330 #pragma varargck type "D" Addr* |
1347 #pragma varargck type "lD" Addr* | 1331 #pragma varargck type "lD" Addr* |
1348 #pragma varargck type "E" int | 1332 #pragma varargck type "E" int |
1349 #pragma varargck type "F" Mpflt* | 1333 #pragma varargck type "F" Mpflt* |
| 1334 #pragma varargck type "H" NodeList* |
1350 #pragma varargck type "J" Node* | 1335 #pragma varargck type "J" Node* |
1351 #pragma varargck type "L" int | 1336 #pragma varargck type "L" int |
1352 #pragma varargck type "L" uint | 1337 #pragma varargck type "L" uint |
1353 #pragma varargck type "N" Node* | 1338 #pragma varargck type "N" Node* |
1354 #pragma varargck type "O" uint | 1339 #pragma varargck type "O" uint |
1355 #pragma varargck type "P" Prog* | 1340 #pragma varargck type "P" Prog* |
1356 #pragma varargck type "Q" Bits | 1341 #pragma varargck type "Q" Bits |
1357 #pragma varargck type "R" int | 1342 #pragma varargck type "R" int |
1358 #pragma varargck type "S" Sym* | 1343 #pragma varargck type "S" Sym* |
1359 #pragma varargck type "lS" Sym* | 1344 #pragma varargck type "lS" Sym* |
1360 #pragma varargck type "T" Type* | 1345 #pragma varargck type "T" Type* |
1361 #pragma varargck type "lT" Type* | 1346 #pragma varargck type "lT" Type* |
1362 #pragma varargck type "V" Val* | 1347 #pragma varargck type "V" Val* |
1363 #pragma varargck type "Y" char* | 1348 #pragma varargck type "Y" char* |
1364 #pragma varargck type "Z" Strlit* | 1349 #pragma varargck type "Z" Strlit* |
OLD | NEW |