Permalink
Browse files

First import

  • Loading branch information...
0 parents commit f61f0c001e7f1e82458de080c0155197de6847a6 @fd committed Feb 19, 2013
Showing with 57,473 additions and 0 deletions.
  1. +2 −0 .gitignore
  2. +21 −0 .travis.yml
  3. +27 −0 LICENCE.md
  4. +993 −0 lang/ast/ast.go
  5. +50 −0 lang/ast/ast_test.go
  6. +332 −0 lang/ast/commentmap.go
  7. +143 −0 lang/ast/commentmap_test.go
  8. +136 −0 lang/ast/example_test.go
  9. +445 −0 lang/ast/filter.go
  10. +134 −0 lang/ast/import.go
  11. +251 −0 lang/ast/print.go
  12. +97 −0 lang/ast/print_test.go
  13. +174 −0 lang/ast/resolve.go
  14. +162 −0 lang/ast/scope.go
  15. +381 −0 lang/ast/walk.go
  16. +1,043 −0 lang/build/build.go
  17. +119 −0 lang/build/build_test.go
  18. +431 −0 lang/build/deps_test.go
  19. +120 −0 lang/build/doc.go
  20. +238 −0 lang/build/read.go
  21. +226 −0 lang/build/read_test.go
  22. +8 −0 lang/build/syslist.go
  23. +62 −0 lang/build/syslist_test.go
  24. +5 −0 lang/build/testdata/other/file/file.go
  25. +11 −0 lang/build/testdata/other/main.go
  26. +30 −0 lang/cmd/go/bootstrap.go
  27. +1,909 −0 lang/cmd/go/build.go
  28. +225 −0 lang/cmd/go/clean.go
  29. +63 −0 lang/cmd/go/discovery.go
  30. +797 −0 lang/cmd/go/doc.go
  31. +91 −0 lang/cmd/go/env.go
  32. +30 −0 lang/cmd/go/fix.go
  33. +73 −0 lang/cmd/go/fmt.go
  34. +401 −0 lang/cmd/go/get.go
  35. +238 −0 lang/cmd/go/help.go
  36. +87 −0 lang/cmd/go/http.go
  37. +171 −0 lang/cmd/go/list.go
  38. +568 −0 lang/cmd/go/main.go
  39. +36 −0 lang/cmd/go/match_test.go
  40. +8 −0 lang/cmd/go/mkdoc.sh
  41. +733 −0 lang/cmd/go/pkg.go
  42. +91 −0 lang/cmd/go/run.go
  43. +23 −0 lang/cmd/go/script
  44. +352 −0 lang/cmd/go/script.txt
  45. +31 −0 lang/cmd/go/signal.go
  46. +13 −0 lang/cmd/go/signal_notunix.go
  47. +14 −0 lang/cmd/go/signal_unix.go
  48. +100 −0 lang/cmd/go/tag_test.go
  49. +193 −0 lang/cmd/go/test.bash
  50. +856 −0 lang/cmd/go/test.go
  51. +3 −0 lang/cmd/go/testdata/errmsg/x.go
  52. +3 −0 lang/cmd/go/testdata/errmsg/x1_test.go
  53. +3 −0 lang/cmd/go/testdata/errmsg/x_test.go
  54. +7 −0 lang/cmd/go/testdata/local/easy.go
  55. +7 −0 lang/cmd/go/testdata/local/easysub/easysub.go
  56. +9 −0 lang/cmd/go/testdata/local/easysub/main.go
  57. +7 −0 lang/cmd/go/testdata/local/hard.go
  58. +12 −0 lang/cmd/go/testdata/local/sub/sub.go
  59. +7 −0 lang/cmd/go/testdata/local/sub/sub/subsub.go
  60. +5 −0 lang/cmd/go/testdata/src/go-cmd-test/helloworld.go
  61. +3 −0 lang/cmd/go/testdata/testimport/p.go
  62. +3 −0 lang/cmd/go/testdata/testimport/p1/p1.go
  63. +3 −0 lang/cmd/go/testdata/testimport/p2/p2.go
  64. +13 −0 lang/cmd/go/testdata/testimport/p_test.go
  65. +15 −0 lang/cmd/go/testdata/testimport/x_test.go
  66. +242 −0 lang/cmd/go/testflag.go
  67. +135 −0 lang/cmd/go/tool.go
  68. +678 −0 lang/cmd/go/vcs.go
  69. +25 −0 lang/cmd/go/version.go
  70. +37 −0 lang/cmd/go/vet.go
  71. +61 −0 lang/cmd/godoc/README.godoc-app
  72. +69 −0 lang/cmd/godoc/appinit.go
  73. +494 −0 lang/cmd/godoc/codewalk.go
  74. +329 −0 lang/cmd/godoc/dirtrees.go
  75. +130 −0 lang/cmd/godoc/doc.go
  76. +564 −0 lang/cmd/godoc/filesystem.go
  77. +360 −0 lang/cmd/godoc/format.go
  78. +1,519 −0 lang/cmd/godoc/godoc.go
  79. +1,075 −0 lang/cmd/godoc/index.go
  80. +466 −0 lang/cmd/godoc/main.go
  81. +68 −0 lang/cmd/godoc/parser.go
  82. +35 −0 lang/cmd/godoc/play-appengine.go
  83. +41 −0 lang/cmd/godoc/play-local.go
  84. +52 −0 lang/cmd/godoc/play.go
  85. +140 −0 lang/cmd/godoc/setup-godoc-app.bash
  86. +112 −0 lang/cmd/godoc/snippet.go
  87. +179 −0 lang/cmd/godoc/spec.go
  88. +182 −0 lang/cmd/godoc/template.go
  89. +88 −0 lang/cmd/godoc/throttle.go
  90. +93 −0 lang/cmd/godoc/utils.go
  91. +236 −0 lang/cmd/godoc/zip.go
  92. +77 −0 lang/cmd/gofmt/doc.go
  93. +361 −0 lang/cmd/gofmt/gofmt.go
  94. +132 −0 lang/cmd/gofmt/gofmt_test.go
  95. +159 −0 lang/cmd/gofmt/long_test.go
  96. +295 −0 lang/cmd/gofmt/rewrite.go
  97. +117 −0 lang/cmd/gofmt/simplify.go
  98. +4 −0 lang/cmd/gofmt/testdata/.gitattributes
  99. +9 −0 lang/cmd/gofmt/testdata/comments.golden
  100. +9 −0 lang/cmd/gofmt/testdata/comments.input
  101. +202 −0 lang/cmd/gofmt/testdata/composites.golden
  102. +202 −0 lang/cmd/gofmt/testdata/composites.input
  103. +12 −0 lang/cmd/gofmt/testdata/crlf.golden
  104. +12 −0 lang/cmd/gofmt/testdata/crlf.input
  105. +108 −0 lang/cmd/gofmt/testdata/import.golden
  106. +108 −0 lang/cmd/gofmt/testdata/import.input
  107. +9 −0 lang/cmd/gofmt/testdata/old.golden
  108. +8 −0 lang/cmd/gofmt/testdata/old.input
  109. +12 −0 lang/cmd/gofmt/testdata/rewrite1.golden
  110. +12 −0 lang/cmd/gofmt/testdata/rewrite1.input
  111. +10 −0 lang/cmd/gofmt/testdata/rewrite2.golden
  112. +10 −0 lang/cmd/gofmt/testdata/rewrite2.input
  113. +12 −0 lang/cmd/gofmt/testdata/rewrite3.golden
  114. +12 −0 lang/cmd/gofmt/testdata/rewrite3.input
  115. +74 −0 lang/cmd/gofmt/testdata/rewrite4.golden
  116. +74 −0 lang/cmd/gofmt/testdata/rewrite4.input
  117. +15 −0 lang/cmd/gofmt/testdata/rewrite5.golden
  118. +15 −0 lang/cmd/gofmt/testdata/rewrite5.input
  119. +58 −0 lang/cmd/gofmt/testdata/slices1.golden
  120. +58 −0 lang/cmd/gofmt/testdata/slices1.input
  121. +61 −0 lang/cmd/gofmt/testdata/slices2.golden
  122. +61 −0 lang/cmd/gofmt/testdata/slices2.input
  123. +3 −0 lang/cmd/gofmt/testdata/stdin1.golden
  124. +3 −0 lang/cmd/gofmt/testdata/stdin1.golden.gofmt
  125. +3 −0 lang/cmd/gofmt/testdata/stdin1.input
  126. +3 −0 lang/cmd/gofmt/testdata/stdin1.input.gofmt
  127. +11 −0 lang/cmd/gofmt/testdata/stdin2.golden
  128. +10 −0 lang/cmd/gofmt/testdata/stdin2.golden.gofmt
  129. +11 −0 lang/cmd/gofmt/testdata/stdin2.input
  130. +11 −0 lang/cmd/gofmt/testdata/stdin2.input.gofmt
  131. +6 −0 lang/cmd/gofmt/testdata/stdin3.golden
  132. +7 −0 lang/cmd/gofmt/testdata/stdin3.golden.gofmt
  133. +4 −0 lang/cmd/gofmt/testdata/stdin3.input
  134. +7 −0 lang/cmd/gofmt/testdata/stdin3.input.gofmt
  135. +3 −0 lang/cmd/gofmt/testdata/stdin4.golden
  136. +3 −0 lang/cmd/gofmt/testdata/stdin4.golden.gofmt
  137. +3 −0 lang/cmd/gofmt/testdata/stdin4.input
  138. +3 −0 lang/cmd/gofmt/testdata/stdin4.input.gofmt
  139. +60 −0 lang/cmd/gofmt/testdata/typeswitch.golden
  140. +60 −0 lang/cmd/gofmt/testdata/typeswitch.input
  141. +7 −0 lang/doc/Makefile
  142. +442 −0 lang/doc/comment.go
  143. +109 −0 lang/doc/comment_test.go
  144. +97 −0 lang/doc/doc.go
  145. +136 −0 lang/doc/doc_test.go
  146. +332 −0 lang/doc/example.go
  147. +111 −0 lang/doc/example_test.go
  148. +199 −0 lang/doc/exports.go
  149. +105 −0 lang/doc/filter.go
  150. +113 −0 lang/doc/headscan.go
  151. +802 −0 lang/doc/reader.go
  152. +73 −0 lang/doc/synopsis.go
  153. +49 −0 lang/doc/synopsis_test.go
  154. +13 −0 lang/doc/testdata/a.0.golden
  155. +13 −0 lang/doc/testdata/a.1.golden
  156. +13 −0 lang/doc/testdata/a.2.golden
  157. +8 −0 lang/doc/testdata/a0.go
  158. +8 −0 lang/doc/testdata/a1.go
  159. +71 −0 lang/doc/testdata/b.0.golden
  160. +83 −0 lang/doc/testdata/b.1.golden
  161. +71 −0 lang/doc/testdata/b.2.golden
  162. +58 −0 lang/doc/testdata/b.go
  163. +293 −0 lang/doc/testdata/benchmark.go
  164. +48 −0 lang/doc/testdata/c.0.golden
  165. +48 −0 lang/doc/testdata/c.1.golden
  166. +48 −0 lang/doc/testdata/c.2.golden
  167. +62 −0 lang/doc/testdata/c.go
  168. +104 −0 lang/doc/testdata/d.0.golden
  169. +104 −0 lang/doc/testdata/d.1.golden
  170. +104 −0 lang/doc/testdata/d.2.golden
  171. +57 −0 lang/doc/testdata/d1.go
  172. +45 −0 lang/doc/testdata/d2.go
  173. +109 −0 lang/doc/testdata/e.0.golden
  174. +144 −0 lang/doc/testdata/e.1.golden
  175. +130 −0 lang/doc/testdata/e.2.golden
  176. +147 −0 lang/doc/testdata/e.go
  177. +30 −0 lang/doc/testdata/error1.0.golden
  178. +32 −0 lang/doc/testdata/error1.1.golden
  179. +30 −0 lang/doc/testdata/error1.2.golden
  180. +24 −0 lang/doc/testdata/error1.go
  181. +27 −0 lang/doc/testdata/error2.0.golden
  182. +37 −0 lang/doc/testdata/error2.1.golden
  183. +27 −0 lang/doc/testdata/error2.2.golden
  184. +29 −0 lang/doc/testdata/error2.go
  185. +81 −0 lang/doc/testdata/example.go
  186. +13 −0 lang/doc/testdata/f.0.golden
  187. +16 −0 lang/doc/testdata/f.1.golden
  188. +13 −0 lang/doc/testdata/f.2.golden
  189. +14 −0 lang/doc/testdata/f.go
  190. +65 −0 lang/doc/testdata/template.txt
  191. +156 −0 lang/doc/testdata/testing.0.golden
  192. +298 −0 lang/doc/testdata/testing.1.golden
  193. +156 −0 lang/doc/testdata/testing.2.golden
  194. +404 −0 lang/doc/testdata/testing.go
  195. +200 −0 lang/format/format.go
  196. +125 −0 lang/format/format_test.go
  197. +166 −0 lang/parser/error_test.go
  198. +34 −0 lang/parser/example_test.go
  199. +172 −0 lang/parser/interface.go
  200. +2,392 −0 lang/parser/parser.go
  201. +411 −0 lang/parser/parser_test.go
  202. +30 −0 lang/parser/performance_test.go
  203. +80 −0 lang/parser/short_test.go
  204. +19 −0 lang/parser/testdata/commas.src
  205. +46 −0 lang/parser/testdata/issue3106.src
  206. +67 −0 lang/printer/example_test.go
  207. +1,575 −0 lang/printer/nodes.go
  208. +58 −0 lang/printer/performance_test.go
  209. +1,262 −0 lang/printer/printer.go
  210. +569 −0 lang/printer/printer_test.go
  211. +638 −0 lang/printer/testdata/comments.golden
  212. +642 −0 lang/printer/testdata/comments.input
  213. +56 −0 lang/printer/testdata/comments.x
  214. +79 −0 lang/printer/testdata/comments2.golden
  215. +79 −0 lang/printer/testdata/comments2.input
  216. +914 −0 lang/printer/testdata/declarations.golden
  217. +923 −0 lang/printer/testdata/declarations.input
  218. +5 −0 lang/printer/testdata/empty.golden
  219. +5 −0 lang/printer/testdata/empty.input
  220. +664 −0 lang/printer/testdata/expressions.golden
  221. +693 −0 lang/printer/testdata/expressions.input
  222. +664 −0 lang/printer/testdata/expressions.raw
  223. +275 −0 lang/printer/testdata/linebreaks.golden
  224. +271 −0 lang/printer/testdata/linebreaks.input
  225. +2,153 −0 lang/printer/testdata/parser.go
  226. +85 −0 lang/printer/testdata/slow.golden
  227. +85 −0 lang/printer/testdata/slow.input
  228. +635 −0 lang/printer/testdata/statements.golden
  229. +550 −0 lang/printer/testdata/statements.input
  230. +126 −0 lang/scanner/errors.go
  231. +46 −0 lang/scanner/example_test.go
  232. +727 −0 lang/scanner/scanner.go
  233. +745 −0 lang/scanner/scanner_test.go
  234. +437 −0 lang/token/position.go
  235. +232 −0 lang/token/position_test.go
  236. +56 −0 lang/token/serialize.go
  237. +111 −0 lang/token/serialize_test.go
  238. +308 −0 lang/token/token.go
  239. +96 −0 lang/types/api.go
  240. +457 −0 lang/types/builtins.go
  241. +454 −0 lang/types/check.go
  242. +253 −0 lang/types/check_test.go
  243. +734 −0 lang/types/const.go
  244. +41 −0 lang/types/conversions.go
  245. +318 −0 lang/types/errors.go
  246. +111 −0 lang/types/exportdata.go
  247. +1,334 −0 lang/types/expr.go
  248. +908 −0 lang/types/gcimporter.go
  249. +181 −0 lang/types/gcimporter_test.go
  250. +155 −0 lang/types/objects.go
  251. +393 −0 lang/types/operand.go
  252. +303 −0 lang/types/predicates.go
  253. +177 −0 lang/types/resolve.go
  254. +167 −0 lang/types/resolver_test.go
  255. +59 −0 lang/types/scope.go
  256. +721 −0 lang/types/stmt.go
  257. +302 −0 lang/types/testdata/builtins.src
  258. +215 −0 lang/types/testdata/const0.src
  259. +18 −0 lang/types/testdata/conversions.src
  260. +177 −0 lang/types/testdata/decls0.src
  261. +132 −0 lang/types/testdata/decls1.src
  262. +67 −0 lang/types/testdata/decls2a.src
  263. +28 −0 lang/types/testdata/decls2b.src
  264. +231 −0 lang/types/testdata/decls3.src
  265. +89 −0 lang/types/testdata/exports.go
  266. +151 −0 lang/types/testdata/expr0.src
  267. +7 −0 lang/types/testdata/expr1.src
  268. +23 −0 lang/types/testdata/expr2.src
  269. +367 −0 lang/types/testdata/expr3.src
  270. +274 −0 lang/types/testdata/stmt0.src
  271. +231 −0 lang/types/types.go
  272. +171 −0 lang/types/types_test.go
  273. +137 −0 lang/types/universe.go
@@ -0,0 +1,2 @@
+/example/db
+*.test
@@ -0,0 +1,21 @@
+---
+language: go
+
+before_install:
+ - sudo apt-get update -qq > apt-get.out || (cat apt-get.out && exit 1)
+ - sudo apt-get install bzr mercurial git libyaml-dev cmake -qq >> apt-get.out || (cat apt-get.out && exit 1)
+
+services:
+ - redis-server
+
+install:
+ - mkdir -p $GOPATH/src/simplex.sh
+ - mv * $GOPATH/src/simplex.sh
+ - pushd $GOPATH/src/simplex.sh
+ - make
+ - popd
+
+script:
+ - pushd $GOPATH/src/simplex.sh
+ - make test
+ - popd
@@ -0,0 +1,27 @@
+Copyright (c) 2013 The Simplex Authors. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Oops, something went wrong. Retry.

0 comments on commit f61f0c0

Please sign in to comment.