LEFT | RIGHT |
(no file at all) | |
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 <u.h> | 5 #include <u.h> |
6 #include <libc.h> | 6 #include <libc.h> |
7 #include "go.h" | 7 #include "go.h" |
8 #include "md5.h" | 8 #include "md5.h" |
9 #include "y.tab.h" | 9 #include "y.tab.h" |
10 #include "yerr.h" | 10 #include "yerr.h" |
(...skipping 1465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1476 free(p); | 1476 free(p); |
1477 return md5sum(&d); | 1477 return md5sum(&d); |
1478 } | 1478 } |
1479 | 1479 |
1480 Type* | 1480 Type* |
1481 ptrto(Type *t) | 1481 ptrto(Type *t) |
1482 { | 1482 { |
1483 Type *t1; | 1483 Type *t1; |
1484 | 1484 |
1485 if(tptr == 0) | 1485 if(tptr == 0) |
1486 » » fatal("ptrto: nil"); | 1486 » » fatal("ptrto: no tptr"); |
1487 t1 = typ(tptr); | 1487 t1 = typ(tptr); |
1488 t1->type = t; | 1488 t1->type = t; |
1489 t1->width = widthptr; | 1489 t1->width = widthptr; |
1490 t1->align = widthptr; | 1490 t1->align = widthptr; |
1491 return t1; | 1491 return t1; |
1492 } | 1492 } |
1493 | 1493 |
1494 void | 1494 void |
1495 frame(int context) | 1495 frame(int context) |
1496 { | 1496 { |
(...skipping 1476 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2973 Strlit* | 2973 Strlit* |
2974 strlit(char *s) | 2974 strlit(char *s) |
2975 { | 2975 { |
2976 Strlit *t; | 2976 Strlit *t; |
2977 ········ | 2977 ········ |
2978 t = mal(sizeof *t + strlen(s)); | 2978 t = mal(sizeof *t + strlen(s)); |
2979 strcpy(t->s, s); | 2979 strcpy(t->s, s); |
2980 t->len = strlen(s); | 2980 t->len = strlen(s); |
2981 return t; | 2981 return t; |
2982 } | 2982 } |
LEFT | RIGHT |