OLD | NEW |
1 // Copyright 2011 The Go Authors. All rights reserved. | 1 // Copyright 2011 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 // +build api_tool | 5 // +build api_tool |
6 | 6 |
7 // Binary api computes the exported API of a set of Go packages. | 7 // Binary api computes the exported API of a set of Go packages. |
8 package main | 8 package main |
9 | 9 |
10 import ( | 10 import ( |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 " mspan struct{};" + | 398 " mspan struct{};" + |
399 " mutex struct{};" + | 399 " mutex struct{};" + |
400 " note struct{};" + | 400 " note struct{};" + |
401 " slicetype struct{};" + | 401 " slicetype struct{};" + |
402 " stkframe struct{};" + | 402 " stkframe struct{};" + |
403 " sudog struct{};" + | 403 " sudog struct{};" + |
404 " waitq struct{};" + | 404 " waitq struct{};" + |
405 " wincallbackcontext struct{};" + | 405 " wincallbackcontext struct{};" + |
406 " _select struct{}; " + | 406 " _select struct{}; " + |
407 "); " + | 407 "); " + |
408 » » » "const ( cb_max = 2000 )" | 408 » » » "const (" + |
| 409 » » » " cb_max = 2000;" + |
| 410 » » » " _Gidle = 1;" + |
| 411 » » » " _Grunnable = 2;" + |
| 412 » » » " _Grunning = 3;" + |
| 413 » » » " _Gsyscall = 4;" + |
| 414 » » » " _Gwaiting = 5;" + |
| 415 » » » " _Gdead = 6;" + |
| 416 » » » " _Genqueue = 7;" + |
| 417 » » » " _Gcopystack = 8;" + |
| 418 » » » ")" |
409 f, err = parser.ParseFile(fset, filename, src, 0) | 419 f, err = parser.ParseFile(fset, filename, src, 0) |
410 if err != nil { | 420 if err != nil { |
411 log.Fatalf("incorrect generated file: %s", err) | 421 log.Fatalf("incorrect generated file: %s", err) |
412 } | 422 } |
413 } | 423 } |
414 | 424 |
415 if f == nil { | 425 if f == nil { |
416 f, err = parser.ParseFile(fset, filename, nil, 0) | 426 f, err = parser.ParseFile(fset, filename, nil, 0) |
417 if err != nil { | 427 if err != nil { |
418 return nil, err | 428 return nil, err |
(...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
884 | 894 |
885 if _, dup := w.features[f]; dup { | 895 if _, dup := w.features[f]; dup { |
886 panic("duplicate feature inserted: " + f) | 896 panic("duplicate feature inserted: " + f) |
887 } | 897 } |
888 w.features[f] = true | 898 w.features[f] = true |
889 | 899 |
890 if *verbose { | 900 if *verbose { |
891 log.Printf("feature: %s", f) | 901 log.Printf("feature: %s", f) |
892 } | 902 } |
893 } | 903 } |
OLD | NEW |