Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge remote-tracking branch 'origin/master' into type-nats

Conflicts:
	tests/typecheck/should_compile/all.T
  • Loading branch information...
commit 141953e2c1c69a3fff85b0b483bf6a5786dfd88f 2 parents 080d920 + a6adff8
@yav yav authored
Showing with 1,420 additions and 1,012 deletions.
  1. +86 −0 .gitignore
  2. +5 −5 config/ghc
  3. +31 −19 driver/runtests.py
  4. +9 −11 driver/testglobals.py
  5. +285 −363 driver/testlib.py
  6. +14 −2 mk/boilerplate.mk
  7. +10 −0 mk/test.mk
  8. +2 −1  tests/Makefile
  9. +1 −1  tests/annotations/should_compile/all.T
  10. +2 −2 tests/annotations/should_fail/annfail01.stderr
  11. +2 −2 tests/annotations/should_fail/annfail02.stderr
  12. +3 −2 tests/annotations/should_fail/annfail03.stderr
  13. +3 −2 tests/annotations/should_fail/annfail04.stderr
  14. +1 −1  tests/annotations/should_fail/annfail06.hs
  15. +3 −2 tests/annotations/should_fail/annfail06.stderr
  16. +2 −2 tests/annotations/should_fail/annfail07.stderr
  17. +1 −1  tests/annotations/should_fail/annfail08.stderr
  18. +2 −2 tests/annotations/should_fail/annfail09.stderr
  19. +9 −9 tests/annotations/should_fail/annfail10.stderr
  20. +2 −2 tests/annotations/should_fail/annfail11.stderr
  21. +3 −3 tests/annotations/should_run/all.T
  22. +17 −17 tests/array/should_run/all.T
  23. +1 −1  tests/arrows/should_compile/all.T
  24. +6 −6 tests/arrows/should_fail/T5380.stderr
  25. +1 −1  tests/arrows/should_fail/all.T
  26. +2 −2 tests/arrows/should_fail/arrowfail001.stderr
  27. +1 −1  tests/arrows/should_fail/arrowfail002.stderr
  28. +1 −1  tests/arrows/should_fail/arrowfail004.stderr
  29. +2 −2 tests/arrows/should_run/all.T
  30. +0 −5 tests/cabal/1750.stderr
  31. +0 −4 tests/cabal/1750.stdout
  32. +0 −4 tests/cabal/1750A.pkg
  33. +0 −4 tests/cabal/1750B.pkg
  34. +11 −11 tests/cabal/Makefile
  35. +5 −0 tests/cabal/T1750.stderr
  36. +4 −0 tests/cabal/T1750.stdout
  37. +4 −0 tests/cabal/T1750A.pkg
  38. +4 −0 tests/cabal/T1750B.pkg
  39. +8 −8 tests/cabal/all.T
  40. +4 −1 tests/cabal/cabal01/all.T
  41. +2 −2 tests/codeGen/should_compile/Makefile
  42. 0  tests/codeGen/should_compile/{1916.hs → T1916.hs}
  43. 0  tests/codeGen/should_compile/{2388.hs → T2388.hs}
  44. 0  tests/codeGen/should_compile/{2578.hs → T2578.hs}
  45. 0  tests/codeGen/should_compile/{3132.hs → T3132.hs}
  46. 0  tests/codeGen/should_compile/{3579.hs → T3579.hs}
  47. +7 −7 tests/codeGen/should_compile/all.T
  48. +3 −3 tests/codeGen/should_gen_asm/all.T
  49. +0 −1  tests/codeGen/should_run/5626.stderr
  50. 0  tests/codeGen/should_run/{1852.hs → T1852.hs}
  51. 0  tests/codeGen/should_run/{1852.stdout → T1852.stdout}
  52. 0  tests/codeGen/should_run/{1861.hs → T1861.hs}
  53. 0  tests/codeGen/should_run/{1861.stdout → T1861.stdout}
  54. 0  tests/codeGen/should_run/{2080.hs → T2080.hs}
  55. 0  tests/codeGen/should_run/{2080.stdout → T2080.stdout}
  56. 0  tests/codeGen/should_run/{2838.hs → T2838.hs}
  57. 0  tests/codeGen/should_run/{2838.stdout → T2838.stdout}
  58. 0  tests/codeGen/should_run/{2838.stdout-ws-64 → T2838.stdout-ws-64}
  59. 0  tests/codeGen/should_run/{3207.hs → T3207.hs}
  60. 0  tests/codeGen/should_run/{3207.stdout → T3207.stdout}
  61. 0  tests/codeGen/should_run/{3561.hs → T3561.hs}
  62. 0  tests/codeGen/should_run/{3561.stdout → T3561.stdout}
  63. 0  tests/codeGen/should_run/{3677.hs → T3677.hs}
  64. 0  tests/codeGen/should_run/{3677.stdout → T3677.stdout}
  65. 0  tests/codeGen/should_run/{4441.hs → T4441.hs}
  66. 0  tests/codeGen/should_run/{4441.stdout → T4441.stdout}
  67. 0  tests/codeGen/should_run/{5129.hs → T5129.hs}
  68. 0  tests/codeGen/should_run/{5149.hs → T5149.hs}
  69. 0  tests/codeGen/should_run/{5149.stdout → T5149.stdout}
  70. 0  tests/codeGen/should_run/{5149_cmm.cmm → T5149_cmm.cmm}
  71. 0  tests/codeGen/should_run/{5626.hs → T5626.hs}
  72. +1 −0  tests/codeGen/should_run/T5626.stderr
  73. 0  tests/codeGen/should_run/{5747.hs → T5747.hs}
  74. 0  tests/codeGen/should_run/{5747.stdout → T5747.stdout}
  75. 0  tests/codeGen/should_run/{5785.hs → T5785.hs}
  76. 0  tests/codeGen/should_run/{5785.stdout → T5785.stdout}
  77. 0  tests/codeGen/should_run/{6146.hs → T6146.hs}
  78. 0  tests/codeGen/should_run/{6146.stdin → T6146.stdin}
  79. 0  tests/codeGen/should_run/{6146.stdout → T6146.stdout}
  80. +111 −0 tests/codeGen/should_run/T7600.hs
  81. +2 −0  tests/codeGen/should_run/T7600.stdout
  82. +83 −0 tests/codeGen/should_run/T7600_A.hs
  83. +24 −20 tests/codeGen/should_run/all.T
  84. +1 −1  tests/codeGen/should_run/cgrun055.hs
  85. +1 −1  tests/codeGen/should_run/cgrun064.hs
  86. +1 −1  tests/codeGen/should_run/cgrun068.hs
  87. +1 −1  tests/codeGen/should_run/cgrun070.hs
  88. 0  tests/{rts/5644 → concurrent/T2317}/Makefile
  89. 0  tests/concurrent/{2317/2317.hs → T2317/T2317.hs}
  90. 0  tests/concurrent/{2317/2317.stdout → T2317/T2317.stdout}
  91. +3 −3 tests/concurrent/{2317 → T2317}/all.T
  92. +1 −1  tests/concurrent/prog001/all.T
  93. +1 −1  tests/concurrent/prog002/all.T
  94. +4 −4 tests/concurrent/prog003/TestRun.hs
  95. +1 −1  tests/concurrent/prog003/all.T
  96. +0 −8 tests/concurrent/should_run/4030.hs
  97. +0 −1  tests/concurrent/should_run/4030.stderr
  98. +0 −1  tests/concurrent/should_run/5611.stderr
  99. +0 −1  tests/concurrent/should_run/5866.stderr
  100. 0  tests/concurrent/should_run/{1980.hs → T1980.hs}
  101. +1 −1  tests/concurrent/should_run/{2910.hs → T2910.hs}
  102. 0  tests/concurrent/should_run/{2910a.stdout → T2910.stdout}
  103. 0  tests/concurrent/should_run/{2910a.hs → T2910a.hs}
  104. 0  tests/concurrent/should_run/{2910.stdout → T2910a.stdout}
  105. +3 −2 tests/concurrent/should_run/{3279.hs → T3279.hs}
  106. 0  tests/concurrent/should_run/{3279.stdout → T3279.stdout}
  107. 0  tests/concurrent/should_run/{3429.hs → T3429.hs}
  108. 0  tests/concurrent/should_run/{3429.stdout → T3429.stdout}
  109. 0  tests/concurrent/should_run/{367.hs → T367.hs}
  110. 0  tests/concurrent/should_run/{367_letnoescape.stdout → T367.stdout}
  111. 0  tests/concurrent/should_run/{367_letnoescape.hs → T367_letnoescape.hs}
  112. 0  tests/concurrent/should_run/{367.stdout → T367_letnoescape.stdout}
  113. +8 −0 tests/concurrent/should_run/T4030.hs
  114. +1 −0  tests/concurrent/should_run/T4030.stderr
  115. 0  tests/concurrent/should_run/{4262.hs → T4262.hs}
  116. 0  tests/concurrent/should_run/{4262.stdout → T4262.stdout}
  117. 0  tests/concurrent/should_run/{4811.hs → T4811.hs}
  118. 0  tests/concurrent/should_run/{4813.hs → T4813.hs}
  119. 0  tests/concurrent/should_run/{5238.hs → T5238.hs}
  120. 0  tests/concurrent/should_run/{5238.stdout → T5238.stdout}
  121. 0  tests/concurrent/should_run/{5421.hs → T5421.hs}
  122. 0  tests/concurrent/should_run/{5558.hs → T5558.hs}
  123. 0  tests/concurrent/should_run/{5611.hs → T5611.hs}
  124. +1 −0  tests/concurrent/should_run/T5611.stderr
  125. 0  tests/concurrent/should_run/{5611.stdout → T5611.stdout}
  126. 0  tests/concurrent/should_run/{5866.hs → T5866.hs}
  127. +1 −0  tests/concurrent/should_run/T5866.stderr
  128. +40 −41 tests/concurrent/should_run/all.T
  129. +1 −0  tests/concurrent/should_run/conc039.hs
  130. +1 −0  tests/concurrent/should_run/conc040.hs
  131. +3 −3 tests/concurrent/should_run/conc069.hs
  132. +4 −4 tests/concurrent/should_run/conc069.stdout
  133. +5 −3 tests/concurrent/should_run/mask002.hs
  134. +5 −5 tests/concurrent/should_run/throwto002.hs
  135. +3 −3 tests/concurrent/should_run/throwto003.hs
  136. +1 −1  tests/cpranal/should_compile/all.T
  137. +3 −3 tests/deSugar/should_compile/GadtOverlap.stderr
  138. +3 −3 tests/deSugar/should_compile/T2395.stderr
  139. +1 −1  tests/deSugar/should_compile/T2431.stderr
  140. +4 −4 tests/deSugar/should_compile/T5117.stderr
  141. +11 −0 tests/deSugar/should_compile/T7669.hs
  142. +3 −3 tests/deSugar/should_compile/all.T
  143. +8 −8 tests/deSugar/should_compile/ds002.stderr-ghc
  144. +5 −5 tests/deSugar/should_compile/ds003.stderr-ghc
  145. +6 −6 tests/deSugar/should_compile/ds019.stderr-ghc
  146. +14 −14 tests/deSugar/should_compile/ds020.stderr-ghc
  147. +5 −5 tests/deSugar/should_compile/ds022.stderr-ghc
  148. +5 −5 tests/deSugar/should_compile/ds041.stderr-ghc
  149. +9 −9 tests/deSugar/should_compile/ds051.stderr-ghc
  150. +1 −1  tests/deSugar/should_compile/ds053.stderr-ghc
  151. +3 −3 tests/deSugar/should_compile/ds056.stderr
  152. +0 −14 tests/deSugar/should_compile/ds061.hs
  153. +4 −4 tests/deSugar/should_run/all.T
  154. +6 −0 tests/deriving/should_compile/Makefile
  155. +8 −0 tests/deriving/should_compile/T1133.hs
  156. +4 −0 tests/deriving/should_compile/T1133.hs-boot
  157. +1 −1  tests/deriving/should_compile/T2378.hs
  158. +3 −8 tests/deriving/should_compile/T3965.hs
  159. +1 −1  tests/deriving/should_compile/T4302.hs
  160. +21 −0 tests/deriving/should_compile/T7710.hs
  161. +6 −0 tests/deriving/should_compile/all.T
  162. +1 −1  tests/deriving/should_compile/drv021.hs
  163. +13 −0 tests/deriving/should_compile/drv021.stderr
  164. +3 −3 tests/deriving/{should_fail/drvfail010.hs → should_compile/drv022.hs}
  165. +5 −0 tests/deriving/should_fail/Makefile
  166. +6 −0 tests/deriving/should_fail/T1133A.hs
  167. +4 −0 tests/deriving/should_fail/T1133A.hs-boot
  168. +7 −0 tests/deriving/should_fail/T1133A.stderr
  169. +6 −6 tests/deriving/should_fail/T2394.stderr
  170. +10 −10 tests/deriving/should_fail/T2604.stderr
  171. +5 −5 tests/deriving/should_fail/T2701.stderr
  172. +6 −6 tests/deriving/should_fail/T2721.stderr
  173. +6 −6 tests/deriving/should_fail/T3101.stderr
  174. +3 −3 tests/deriving/should_fail/T3833.stderr
  175. +3 −3 tests/deriving/should_fail/T3834.stderr
  176. +7 −7 tests/deriving/should_fail/T4528.stderr
  177. +10 −10 tests/deriving/should_fail/T5287.stderr
  178. +5 −5 tests/deriving/should_fail/T5478.stderr
  179. +5 −5 tests/deriving/should_fail/T5686.stderr
  180. +4 −4 tests/deriving/should_fail/T5922.stderr
  181. +4 −2 tests/deriving/should_fail/all.T
  182. +6 −6 tests/deriving/should_fail/drvfail-foldable-traversable1.stderr
  183. +5 −5 tests/deriving/should_fail/drvfail-functor1.stderr
  184. +12 −12 tests/deriving/should_fail/drvfail-functor2.stderr
  185. +5 −5 tests/deriving/should_fail/drvfail005.stderr
  186. +23 −23 tests/deriving/should_fail/drvfail009.stderr
  187. +0 −11 tests/deriving/should_fail/drvfail010.stderr
  188. +0 −1  tests/deriving/should_fail/drvfail010.stderr-hugs
  189. +5 −5 tests/deriving/should_fail/drvfail011.stderr
  190. +1 −1  tests/deriving/should_fail/drvfail014.hs
  191. +9 −9 tests/deriving/should_fail/drvfail014.stderr
  192. +13 −13 tests/deriving/should_fail/drvfail015.stderr
  193. +17 −17 tests/deriving/should_run/all.T
  194. +2 −1  tests/dph/classes/dph-classes.T
  195. +1 −1  tests/dph/diophantine/dph-diophantine.T
  196. +2 −2 tests/dph/dotp/dph-dotp.T
  197. +33 −0 tests/dph/modules/ExportList.hs
  198. 0  tests/{concurrent/2317 → dph/modules}/Makefile
  199. +6 −0 tests/dph/modules/dph-ExportList-vseg-fast.stderr
  200. +8 −0 tests/dph/modules/dph-modules.T
  201. +4 −4 tests/dph/nbody/dph-nbody.T
  202. +1 −1  tests/dph/primespj/dph-primespj.T
  203. +4 −4 tests/dph/quickhull/dph-quickhull.T
  204. +2 −2 tests/dph/smvm/dph-smvm.T
  205. +2 −0  tests/dph/words/WordsVect.hs
  206. +2 −2 tests/dph/words/dph-words.T
  207. +0 −2  tests/driver/1372/1372.stderr
  208. +0 −5 tests/driver/1372/all.T
  209. +0 −4 tests/driver/2499.stderr
  210. +15 −6 tests/driver/Makefile
  211. +1 −1  tests/driver/{1372 → T1372}/Makefile
  212. +2 −0  tests/driver/T1372/T1372.stderr
  213. +5 −0 tests/driver/T1372/all.T
  214. 0  tests/driver/{1372 → T1372}/p1/A1.hs
  215. 0  tests/driver/{1372 → T1372}/p1/A2.hs
  216. 0  tests/driver/{1372/p2 → T1372/p1}/Setup.hs
  217. 0  tests/driver/{1372 → T1372}/p1/p1.cabal
  218. 0  tests/driver/{1372 → T1372}/p2/Main.hs
  219. 0  tests/driver/{1372/p1 → T1372/p2}/Setup.hs
  220. 0  tests/driver/{1372 → T1372}/p2/p2.cabal
  221. 0  tests/driver/{1959 → T1959}/B.hs
  222. 0  tests/driver/{1959 → T1959}/C.hs
  223. 0  tests/driver/{1959 → T1959}/D.hs
  224. 0  tests/driver/{1959 → T1959}/E1.hs
  225. 0  tests/driver/{1959 → T1959}/E2.hs
  226. 0  tests/driver/{1959 → T1959}/Makefile
  227. 0  tests/driver/{1959/1959.stdout → T1959/T1959.stdout}
  228. +1 −1  tests/driver/{1959 → T1959}/test.T
  229. 0  tests/driver/{2464.hs → T2464.hs}
  230. +1 −1  tests/driver/{2464.stderr → T2464.stderr}
  231. 0  tests/driver/{2499.hs → T2499.hs}
  232. +4 −0 tests/driver/T2499.stderr
  233. +5 −0 tests/driver/T2507.hs
  234. +5 −0 tests/driver/T2507.stderr
  235. 0  tests/driver/{2566.stderr → T2566.stderr}
  236. +1 −1  tests/driver/{3674.hs → T3674.hs}
  237. 0  tests/driver/{3674_pre.hs → T3674_pre.hs}
  238. +1 −1  tests/driver/{437 → T437}/Makefile
  239. 0  tests/driver/{437/437.stderr → T437/T437.stderr}
  240. 0  tests/driver/{437/437.stdout → T437/T437.stdout}
  241. 0  tests/driver/{437 → T437}/Test.hs
  242. 0  tests/driver/{437 → T437}/Test2.hs
  243. +2 −2 tests/driver/{437 → T437}/all.T
  244. +3 −1 tests/driver/T4437.hs
  245. +2 −2 tests/driver/T5147/T5147.stderr
  246. 0  tests/driver/{5313.hs → T5313.hs}
  247. +5 −0 tests/driver/T6037.hs
  248. +5 −0 tests/driver/T6037.stderr
  249. +12 −9 tests/driver/all.T
  250. +2 −2 tests/driver/bug1677/bug1677.stderr
  251. +1 −1  tests/driver/driver063.stderr
  252. +3 −2 tests/driver/dynamicToo/all.T
  253. +1 −1  tests/driver/dynamic_flags_001/all.T
  254. +11 −5 tests/driver/dynamic_flags_002/all.T
  255. +1 −1  tests/driver/recomp001/all.T
  256. +1 −1  tests/driver/recomp001/recomp001.stderr
  257. +1 −1  tests/driver/recomp002/all.T
  258. +1 −1  tests/driver/recomp005/all.T
  259. +2 −2 tests/driver/recomp005/recomp005.stderr
  260. +2 −1  tests/driver/recomp006/all.T
  261. +1 −1  tests/driver/recomp007/all.T
  262. +1 −1  tests/driver/recomp008/all.T
  263. +16 −16 tests/driver/werror.stderr
  264. +2 −2 tests/dynlibs/all.T
  265. +1 −1  tests/esc/all.T
  266. 0  tests/ffi/should_compile/{1357.hs → T1357.hs}
  267. +1 −1  tests/ffi/should_compile/{1357.stderr → T1357.stderr}
  268. 0  tests/ffi/should_compile/{3624.hs → T3624.hs}
  269. 0  tests/ffi/should_compile/{3742.hs → T3742.hs}
  270. +4 −4 tests/ffi/should_compile/all.T
  271. +5 −1 tests/ffi/should_fail/all.T
  272. +0 −1  tests/ffi/should_run/7170.stderr
  273. +8 −8 tests/ffi/should_run/Makefile
  274. 0  tests/ffi/should_run/{1288_ghci.hs → T1288.hs}
  275. 0  tests/ffi/should_run/{2276_ghci.stdout → T1288.stdout}
  276. 0  tests/ffi/should_run/{2276_ghci_c.c → T1288_c.c}
  277. 0  tests/ffi/should_run/{1288.hs → T1288_ghci.hs}
  278. 0  tests/ffi/should_run/{2276.stdout → T1288_ghci.stdout}
  279. 0  tests/ffi/should_run/{2276_c.c → T1288_ghci_c.c}
  280. 0  tests/ffi/should_run/{1679.hs → T1679.hs}
  281. 0  tests/ffi/should_run/{1679.stdout → T1679.stdout}
  282. 0  tests/ffi/should_run/{2276_ghci.hs → T2276.hs}
  283. 0  tests/ffi/should_run/{1288_ghci.stdout → T2276.stdout}
  284. 0  tests/ffi/should_run/{1288_ghci_c.c → T2276_c.c}
  285. 0  tests/ffi/should_run/{2276.hs → T2276_ghci.hs}
  286. 0  tests/ffi/should_run/{1288.stdout → T2276_ghci.stdout}
  287. 0  tests/ffi/should_run/{1288_c.c → T2276_ghci_c.c}
  288. 0  tests/ffi/should_run/{2469.hs → T2469.hs}
  289. 0  tests/ffi/should_run/{2594.hs → T2594.hs}
  290. 0  tests/ffi/should_run/{2594.stdout → T2594.stdout}
  291. +1 −1  tests/ffi/should_run/{2594_c.c → T2594_c.c}
  292. 0  tests/ffi/should_run/{2594_c.h → T2594_c.h}
  293. 0  tests/ffi/should_run/{2917a.hs → T2917a.hs}
  294. 0  tests/ffi/should_run/{4038.hs → T4038.hs}
  295. 0  tests/ffi/should_run/{4038.stdout → T4038.stdout}
  296. 0  tests/ffi/should_run/{4221.hs → T4221.hs}
  297. 0  tests/ffi/should_run/{4221.stdout → T4221.stdout}
  298. 0  tests/ffi/should_run/{4221_c.c → T4221_c.c}
  299. 0  tests/ffi/should_run/{5402.hs → T5402.hs}
  300. +1 −1  tests/ffi/should_run/{5402_main.c → T5402_main.c}
Sorry, we could not display the entire diff because too many files (1,412) changed.
View
86 .gitignore
@@ -1194,3 +1194,89 @@ tests/rts/T6006
tests/simplCore/should_run/T5915
tests/simplCore/should_run/T5920
tests/simplCore/should_run/T5997
+
+tests/codeGen/should_run/T5900
+tests/codeGen/should_run/T7163
+tests/codeGen/should_run/T7361
+tests/codeGen/should_run/T7600
+tests/codeGen/should_run/Word2Float64
+tests/concurrent/should_run/367
+tests/concurrent/should_run/367_letnoescape
+tests/deSugar/should_run/DsLambdaCase
+tests/deSugar/should_run/DsMultiWayIf
+tests/dph/nbody/dph-nbody-copy-fast
+tests/dph/nbody/dph-nbody-copy-opt
+tests/driver/T7060dump/
+tests/driver/dynamicToo/A001.dyn_hi
+tests/driver/dynamicToo/A001.dyn_o
+tests/driver/dynamicToo/B001.dyn_hi
+tests/driver/dynamicToo/B001.dyn_o
+tests/driver/dynamicToo/C001.dyn_hi
+tests/driver/dynamicToo/C001.dyn_o
+tests/driver/dynamicToo/d001
+tests/driver/dynamicToo/s001
+tests/driver/objc/objc-hi
+tests/driver/objc/objcpp-hi
+tests/driver/recomp012/Foo.hs
+tests/driver/recomp012/Main
+tests/driver/recomp012/Main.hs
+tests/driver/recomp012/MyBool.hs
+tests/ext-core/T7239.hcr
+tests/ffi/should_run/7170
+tests/ffi/should_run/T4012
+tests/ghc-api/T7478/A
+tests/ghc-api/T7478/T7478
+tests/lib/integer/IntegerConversionRules.simpl
+tests/lib/integer/gcdInteger
+tests/mdo/should_fail/mdofail006
+tests/mdo/should_run/mdorun004
+tests/mdo/should_run/mdorun005
+tests/numeric/should_run/T7014
+tests/numeric/should_run/T7014.simpl
+tests/numeric/should_run/T7233
+tests/optasm-log
+tests/optllvm-32-log
+tests/optllvm-log
+tests/parser/should_compile/T7476/Main.imports
+tests/parser/should_compile/T7476/T7476
+tests/parser/should_run/ParserMultiWayIf
+tests/perf/compiler/T5837.comp.stats
+tests/perf/should_run/Conversions
+tests/perf/should_run/Conversions.stats
+tests/perf/should_run/T7257
+tests/perf/should_run/T7257.stats
+tests/perf/should_run/T7436
+tests/perf/should_run/T7436.stats
+tests/perf/should_run/T7507
+tests/plugins/simple-plugin/pkg.plugins01/
+tests/plugins/simple-plugin/pkg.plugins02/
+tests/plugins/simple-plugin/pkg.plugins03/
+tests/rts/7087
+tests/rts/T7037
+tests/rts/T7037_main
+tests/rts/T7040
+tests/rts/T7160
+tests/rts/T7227
+tests/rts/T7227.stat
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly01/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly02/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly03/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly04/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly05/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly06/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly07/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly08/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly09/
+tests/safeHaskell/check/pkg01/pdb.ImpSafeOnly10/
+tests/safeHaskell/check/pkg01/pdb.safePkg01/
+tests/simplCore/should_compile/T4138.simpl
+tests/simplCore/should_run/T7101
+tests/th/T5555
+tests/th/T7064
+tests/th/TH_StringPrimL
+tests/typecheck/should_run/T5751
+tests/typecheck/should_run/T5913
+tests/typecheck/should_run/T6117
+tests/typecheck/should_run/T7023
+tests/typecheck/should_run/T7126
+
View
10 config/ghc
@@ -80,7 +80,7 @@ if (ghc_with_llvm == 1):
config.in_tree_compiler = in_tree_compiler
config.clean_only = clean_only
-config.way_flags = {
+config.way_flags = lambda name : {
'normal' : [],
'g1' : [],
'optasm' : ['-O', '-fasm'],
@@ -97,7 +97,7 @@ config.way_flags = {
'threaded1_ls' : ['-threaded', '-debug'],
'threaded2' : ['-O', '-threaded', '-eventlog'],
'threaded2_hT' : ['-O', '-threaded'],
- 'hpc' : ['-O', '-fhpc' ],
+ 'hpc' : ['-O', '-fhpc', '-hpcdir', '.hpc.' + name ],
'prof_hc_hb' : ['-O', '-prof', '-static', '-auto-all'],
'prof_hb' : ['-O', '-prof', '-static', '-auto-all'],
'prof_hd' : ['-O', '-prof', '-static', '-auto-all'],
@@ -153,15 +153,15 @@ config.way_rts_flags = {
prof_ways = map (lambda x: x[0], \
filter(lambda x: '-prof' in x[1], \
- config.way_flags.items()))
+ config.way_flags('dummy_name').items()))
threaded_ways = map (lambda x: x[0], \
filter(lambda x: '-threaded' in x[1] or 'ghci' == x[0], \
- config.way_flags.items()))
+ config.way_flags('dummy_name').items()))
opt_ways = map (lambda x: x[0], \
filter(lambda x: '-O' in x[1], \
- config.way_flags.items()))
+ config.way_flags('dummy_name').items()))
def get_compiler_info():
# This should really not go through the shell
View
50 driver/runtests.py
@@ -207,9 +207,6 @@
global testopts_local
testopts_local.x = TestOptions()
-global thisdir_testopts
-thisdir_testopts = getThisDirTestOpts()
-
if config.use_threads:
t.lock = threading.Lock()
t.thread_pool = threading.Condition(t.lock)
@@ -257,24 +254,39 @@
t.n_framework_failures = t.n_framework_failures + 1
traceback.print_exc()
-# Now run all the tests
-if config.use_threads:
- t.running_threads=0
-for oneTest in parallelTests:
- oneTest()
-if config.use_threads:
- t.thread_pool.acquire()
- while t.running_threads>0:
- t.thread_pool.wait()
- t.thread_pool.release()
-config.use_threads = False
-for oneTest in aloneTests:
- oneTest()
+if config.list_broken:
+ global brokens
+ print ''
+ print 'Broken tests:'
+ print (' '.join(map (lambda (b, d, n) : '#' + str(b) + '(' + d + '/' + n + ')', brokens)))
+ print ''
+
+ if t.n_framework_failures != 0:
+ print 'WARNING:', str(t.n_framework_failures), 'framework failures!'
+ print ''
+else:
+ # Now run all the tests
+ if config.use_threads:
+ t.running_threads=0
+ for oneTest in parallelTests:
+ if stopping():
+ break
+ oneTest()
+ if config.use_threads:
+ t.thread_pool.acquire()
+ while t.running_threads>0:
+ t.thread_pool.wait()
+ t.thread_pool.release()
+ config.use_threads = False
+ for oneTest in aloneTests:
+ if stopping():
+ break
+ oneTest()
-summary(t, sys.stdout)
+ summary(t, sys.stdout)
-if config.output_summary != '':
- summary(t, open(config.output_summary, 'w'))
+ if config.output_summary != '':
+ summary(t, open(config.output_summary, 'w'))
sys.exit(0)
View
20 driver/testglobals.py
@@ -48,6 +48,8 @@ def __init__(self):
# run the "fast" version of the test suite
self.fast = 0
+ self.list_broken = False
+
# Compiler type (ghc, hugs, nhc, etc.)
self.compiler_type = ''
@@ -214,17 +216,6 @@ def __init__(self):
self.compiler_stats_range_fields = {}
self.stats_range_fields = {}
- # TODO: deprecate this in favour of compiler_stats_range_fields
- #
- # which -t numeric fields do we want to look at, and what bounds must
- # they fall within?
- # Elements of these lists should be things like
- # ('bytes allocated',
- # 9300000000,
- # 9400000000)
- self.compiler_stats_num_fields = {}
- self.stats_num_fields = {}
-
# should we run this test alone, i.e. not run it in parallel with
# any other threads
self.alone = False
@@ -237,6 +228,9 @@ def __init__(self):
self.objc_src = 0
self.objcpp_src = 0
+ # Does this test use a .cmm file?
+ self.cmm_src = 0
+
# Should we put .hi/.o files in a subdirectory?
self.outputdir = None
@@ -271,3 +265,7 @@ def __init__(self):
global default_testopts
default_testopts = TestOptions()
+# (bug, directory, name) of tests marked broken
+global brokens
+brokens = []
+
View
648 driver/testlib.py
@@ -15,7 +15,7 @@
import copy
import glob
import types
-import math
+from math import ceil, trunc
have_subprocess = False
try:
@@ -32,15 +32,13 @@
import threading
import thread
-# Options valid for all the tests in the current "directory". After
-# each test, we reset the options to these. To change the options for
-# multiple tests, the function setTestOpts() below can be used to alter
-# these options.
-global thisdir_testopts
-thisdir_testopts = TestOptions()
-
-def getThisDirTestOpts():
- return thisdir_testopts
+global wantToStop
+wantToStop = False
+def stopNow():
+ global wantToStop
+ wantToStop = True
+def stopping():
+ return wantToStop
# Options valid for the current test only (these get reset to
# testdir_testopts after each test).
@@ -63,7 +61,8 @@ def setLocalTestOpts(opts):
# This can be called at the top of a file of tests, to set default test options
# for the following tests.
def setTestOpts( f ):
- f( thisdir_testopts );
+ global thisdir_settings
+ thisdir_settings = [thisdir_settings, f]
# -----------------------------------------------------------------------------
# Canned setup functions for common cases. eg. for a test you might say
@@ -76,23 +75,23 @@ def setTestOpts( f ):
#
# to expect failure for this test.
-def normal( opts ):
+def normal( name, opts ):
return;
-def skip( opts ):
+def skip( name, opts ):
opts.skip = 1
-def expect_fail( opts ):
+def expect_fail( name, opts ):
opts.expect = 'fail';
def reqlib( lib ):
- return lambda opts, l=lib: _reqlib (opts, l )
+ return lambda name, opts, l=lib: _reqlib (name, opts, l )
# Cache the results of looking to see if we have a library or not.
# This makes quite a difference, especially on Windows.
have_lib = {}
-def _reqlib( opts, lib ):
+def _reqlib( name, opts, lib ):
if have_lib.has_key(lib):
got_it = have_lib[lib]
else:
@@ -115,370 +114,267 @@ def _reqlib( opts, lib ):
if not got_it:
opts.expect = 'missing-lib'
-def req_profiling( opts ):
+def req_profiling( name, opts ):
if not config.have_profiling:
opts.expect = 'fail'
-def req_shared_libs( opts ):
+def req_shared_libs( name, opts ):
if not config.have_shared_libs:
opts.expect = 'fail'
-def req_interp( opts ):
+def req_interp( name, opts ):
if not config.have_interp:
opts.expect = 'fail'
-def req_smp( opts ):
+def req_smp( name, opts ):
if not config.have_smp:
opts.expect = 'fail'
-def expect_broken( bug ):
- return lambda opts, b=bug: _expect_broken (opts, b )
-
-def _expect_broken( opts, bug ):
- opts.expect = 'fail';
-
-def ignore_output( opts ):
+def ignore_output( name, opts ):
opts.ignore_output = 1
-def no_stdin( opts ):
+def no_stdin( name, opts ):
opts.no_stdin = 1
-def combined_output( opts ):
+def combined_output( name, opts ):
opts.combined_output = True
# -----
def expect_fail_for( ways ):
- return lambda opts, w=ways: _expect_fail_for( opts, w )
+ return lambda name, opts, w=ways: _expect_fail_for( name, opts, w )
-def _expect_fail_for( opts, ways ):
+def _expect_fail_for( name, opts, ways ):
opts.expect_fail_for = ways
+def expect_broken( bug ):
+ return lambda name, opts, b=bug: _expect_broken (name, opts, b )
+
+def _expect_broken( name, opts, bug ):
+ record_broken(name, opts, bug)
+ opts.expect = 'fail';
+
def expect_broken_for( bug, ways ):
- return lambda opts, b=bug, w=ways: _expect_broken_for( opts, b, w )
+ return lambda name, opts, b=bug, w=ways: _expect_broken_for( name, opts, b, w )
-def _expect_broken_for( opts, bug, ways ):
+def _expect_broken_for( name, opts, bug, ways ):
+ record_broken(name, opts, bug)
opts.expect_fail_for = ways
+def record_broken(name, opts, bug):
+ global brokens
+ me = (bug, opts.testdir, name)
+ if not me in brokens:
+ brokens.append(me)
+
# -----
def omit_ways( ways ):
- return lambda opts, w=ways: _omit_ways( opts, w )
+ return lambda name, opts, w=ways: _omit_ways( name, opts, w )
-def _omit_ways( opts, ways ):
+def _omit_ways( name, opts, ways ):
opts.omit_ways = ways
# -----
def only_ways( ways ):
- return lambda opts, w=ways: _only_ways( opts, w )
+ return lambda name, opts, w=ways: _only_ways( name, opts, w )
-def _only_ways( opts, ways ):
+def _only_ways( name, opts, ways ):
opts.only_ways = ways
# -----
def extra_ways( ways ):
- return lambda opts, w=ways: _extra_ways( opts, w )
+ return lambda name, opts, w=ways: _extra_ways( name, opts, w )
-def _extra_ways( opts, ways ):
+def _extra_ways( name, opts, ways ):
opts.extra_ways = ways
# -----
def omit_compiler_types( compiler_types ):
- return lambda opts, c=compiler_types: _omit_compiler_types(opts, c)
+ return lambda name, opts, c=compiler_types: _omit_compiler_types(name, opts, c)
-def _omit_compiler_types( opts, compiler_types ):
+def _omit_compiler_types( name, opts, compiler_types ):
if config.compiler_type in compiler_types:
opts.skip = 1
# -----
def only_compiler_types( compiler_types ):
- return lambda opts, c=compiler_types: _only_compiler_types(opts, c)
+ return lambda name, opts, c=compiler_types: _only_compiler_types(name, opts, c)
-def _only_compiler_types( opts, compiler_types ):
+def _only_compiler_types( name, opts, compiler_types ):
if config.compiler_type not in compiler_types:
opts.skip = 1
# -----
def set_stdin( file ):
- return lambda opts, f=file: _set_stdin(opts, f);
+ return lambda name, opts, f=file: _set_stdin(name, opts, f);
-def _set_stdin( opts, f ):
+def _set_stdin( name, opts, f ):
opts.stdin = f
# -----
def exit_code( val ):
- return lambda opts, v=val: _exit_code(opts, v);
+ return lambda name, opts, v=val: _exit_code(name, opts, v);
-def _exit_code( opts, v ):
+def _exit_code( name, opts, v ):
opts.exit_code = v
# -----
def timeout_multiplier( val ):
- return lambda opts, v=val: _timeout_multiplier(opts, v)
+ return lambda name, opts, v=val: _timeout_multiplier(name, opts, v)
-def _timeout_multiplier( opts, v ):
+def _timeout_multiplier( name, opts, v ):
opts.timeout_multiplier = v
# -----
def extra_run_opts( val ):
- return lambda opts, v=val: _extra_run_opts(opts, v);
+ return lambda name, opts, v=val: _extra_run_opts(name, opts, v);
-def _extra_run_opts( opts, v ):
+def _extra_run_opts( name, opts, v ):
opts.extra_run_opts = v
# -----
def extra_hc_opts( val ):
- return lambda opts, v=val: _extra_hc_opts(opts, v);
+ return lambda name, opts, v=val: _extra_hc_opts(name, opts, v);
-def _extra_hc_opts( opts, v ):
+def _extra_hc_opts( name, opts, v ):
opts.extra_hc_opts = v
# -----
def extra_clean( files ):
- return lambda opts, v=files: _extra_clean(opts, v);
+ return lambda name, opts, v=files: _extra_clean(name, opts, v);
-def _extra_clean( opts, v ):
+def _extra_clean( name, opts, v ):
opts.clean_files = v
# -----
-def stats_num_field( field, min, max ):
- return lambda opts, f=field, x=min, y=max: _stats_num_field(opts, f, x, y);
-
-def _stats_num_field( opts, f, x, y ):
- # copy the dictionary, as the config gets shared between all tests
- opts.stats_num_fields = opts.stats_num_fields.copy()
- opts.stats_num_fields[f] = (x, y)
-
-def compiler_stats_num_field( field, min, max ):
- return lambda opts, f=field, x=min, y=max: _compiler_stats_num_field(opts, f, x, y);
+def stats_num_field( field, expecteds ):
+ return lambda name, opts, f=field, e=expecteds: _stats_num_field(name, opts, f, e);
-def _compiler_stats_num_field( opts, f, x, y ):
- # copy the dictionary, as the config gets shared between all tests
- opts.compiler_stats_num_fields = opts.compiler_stats_num_fields.copy()
- opts.compiler_stats_num_fields[f] = (x, y)
-
-# -----
+def _stats_num_field( name, opts, field, expecteds ):
+ if field in opts.stats_range_fields:
+ framework_fail(name, 'duplicate-numfield', 'Duplicate ' + field + ' num_field check')
-def stats_range_field( field, min, max ):
- return lambda opts, f=field, x=min, y=max: _stats_range_field(opts, f, x, y);
+ if type(expecteds) is types.ListType:
+ for (b, expected, dev) in expecteds:
+ if b:
+ opts.stats_range_fields[field] = (expected, dev)
+ return
+ framework_fail(name, 'numfield-no-expected', 'No expected value found for ' + field + ' in num_field check')
-def _stats_range_field( opts, f, x, y ):
- # copy the dictionary, as the config gets shared between all tests
- opts.stats_range_fields = opts.stats_range_fields.copy()
- opts.stats_range_fields[f] = (x, y)
-
-def compiler_stats_range_field( field, min, max ):
- return lambda opts, f=field, x=min, y=max: _compiler_stats_range_field(opts, f, x, y);
-
-def _compiler_stats_range_field( opts, f, x, y ):
- # copy the dictionary, as the config gets shared between all tests
- opts.compiler_stats_range_fields = opts.compiler_stats_range_fields.copy()
- opts.compiler_stats_range_fields[f] = (x, y)
+ else:
+ (expected, dev) = expecteds
+ opts.stats_range_fields[field] = (expected, dev)
-# -----
+def compiler_stats_num_field( field, expecteds ):
+ return lambda name, opts, f=field, e=expecteds: _compiler_stats_num_field(name, opts, f, e);
-def skip_if_no_ghci(opts):
- if not ('ghci' in config.run_ways):
- opts.skip = 1
+def _compiler_stats_num_field( name, opts, field, expecteds ):
+ if field in opts.compiler_stats_range_fields:
+ framework_fail(name, 'duplicate-numfield', 'Duplicate ' + field + ' num_field check')
-# ----
+ for (b, expected, dev) in expecteds:
+ if b:
+ opts.compiler_stats_range_fields[field] = (expected, dev)
+ return
-def skip_if_fast(opts):
- if config.fast:
- opts.skip = 1
+ framework_fail(name, 'numfield-no-expected', 'No expected value found for ' + field + ' in num_field check')
# -----
-def if_platform( plat, f ):
- if config.platform == plat:
- return f
- else:
- return normal
-
-def unless_platform( plat, f ):
- if config.platform != plat:
- return f
- else:
- return normal
-
-def if_os( os, f ):
- if config.os == os:
- return f
- else:
- return normal
-
-def unless_os( os, f ):
- if config.os == os:
- return normal
- else:
- return f
-
-def if_arch( arch, f ):
- if config.arch == arch:
+def when(b, f):
+ # When list_brokens is on, we want to see all expect_broken calls,
+ # so we always do f
+ if b or config.list_broken:
return f
else:
return normal
-def unless_arch( arch, f ):
- if config.arch == arch:
- return normal
- else:
- return f
+def unless(b, f):
+ return when(not b, f)
-def if_wordsize( ws, f ):
- if config.wordsize == str(ws):
- return f
- else:
- return normal
-
-def unless_wordsize( ws, f ):
- if config.wordsize == str(ws):
- return normal
- else:
- return f
+def doing_ghci():
+ return 'ghci' in config.run_ways
-def if_unregisterised( f ):
- if config.unregisterised:
- return f
- else:
- return normal
+def ghci_dynamic( ):
+ return config.ghc_dynamic_by_default
-def unless_unregisterised( f ):
- if config.unregisterised:
- return normal
- else:
- return f
+def fast():
+ return config.fast
-def if_msys( f ):
- if config.msys:
- return f
- else:
- return normal
+def platform( plat ):
+ return config.platform == plat
-def if_cygwin( f ):
- if config.cygwin:
- return f
- else:
- return normal
+def opsys( os ):
+ return config.os == os
-def when_have_vanilla( f ):
- if config.have_vanilla:
- return f
- else:
- return normal
+def arch( arch ):
+ return config.arch == arch
-def unless_have_vanilla( f ):
- if config.have_vanilla:
- return normal
- else:
- return f
+def wordsize( ws ):
+ return config.wordsize == str(ws)
-def when_have_dynamic( f ):
- if config.have_dynamic:
- return f
- else:
- return normal
+def msys( ):
+ return config.msys
-def unless_have_dynamic( f ):
- if config.have_dynamic:
- return normal
- else:
- return f
+def cygwin( ):
+ return config.cygwin
-def when_have_profiling( f ):
- if config.have_profiling:
- return f
- else:
- return normal
+def have_vanilla( ):
+ return config.have_vanilla
-def unless_have_profiling( f ):
- if config.have_profiling:
- return normal
- else:
- return f
+def have_dynamic( ):
+ return config.have_dynamic
-# ---
+def have_profiling( ):
+ return config.have_profiling
-def if_ghci_dynamic( f ):
- if config.ghc_dynamic_by_default:
- return f
- else:
- return normal
+def in_tree_compiler( ):
+ return config.in_tree_compiler
-def if_in_tree_compiler( f ):
- if config.in_tree_compiler:
- return f
- else:
- return normal
+def compiler_type( compiler ):
+ return config.compiler_type == compiler
-def unless_in_tree_compiler( f ):
- if config.in_tree_compiler:
- return normal
- else:
- return f
+def compiler_lt( compiler, version ):
+ return config.compiler_type == compiler and \
+ version_lt(config.compiler_version, version)
-def if_compiler_type( compiler, f ):
- if config.compiler_type == compiler:
- return f
- else:
- return normal
+def compiler_le( compiler, version ):
+ return config.compiler_type == compiler and \
+ version_le(config.compiler_version, version)
-def if_compiler_profiled( f ):
- if config.compiler_profiled:
- return f
- else:
- return normal
+def compiler_gt( compiler, version ):
+ return config.compiler_type == compiler and \
+ version_gt(config.compiler_version, version)
-def unless_compiler_profiled( f ):
- if config.compiler_profiled:
- return normal
- else:
- return f
+def compiler_ge( compiler, version ):
+ return config.compiler_type == compiler and \
+ version_ge(config.compiler_version, version)
-def if_compiler_lt( compiler, version, f ):
- if config.compiler_type == compiler and \
- version_lt(config.compiler_version, version):
- return f
- else:
- return normal
+def unregisterised( ):
+ return config.unregisterised
-def if_compiler_le( compiler, version, f ):
- if config.compiler_type == compiler and \
- version_le(config.compiler_version, version):
- return f
- else:
- return normal
+def compiler_profiled( ):
+ return config.compiler_profiled
-def if_compiler_gt( compiler, version, f ):
- if config.compiler_type == compiler and \
- version_gt(config.compiler_version, version):
- return f
- else:
- return normal
+def compiler_debugged( ):
+ return config.compiler_debugged
-def if_compiler_ge( compiler, version, f ):
- if config.compiler_type == compiler and \
- version_ge(config.compiler_version, version):
- return f
- else:
- return normal
+def tag( t ):
+ return t in config.compiler_tags
-def if_compiler_debugged( f ):
- if config.compiler_debugged:
- return f
- else:
- return normal
+# ---
def namebase( nb ):
return lambda opts, nb=nb: _namebase(opts, nb)
@@ -488,99 +384,89 @@ def _namebase( opts, nb ):
# ---
-def if_tag( tag, f ):
- if tag in config.compiler_tags:
- return f
- else:
- return normal
-
-def unless_tag( tag, f ):
- if not (tag in config.compiler_tags):
- return f
- else:
- return normal
-
-# ---
-def high_memory_usage(opts):
+def high_memory_usage(name, opts):
opts.alone = True
# ---
-def literate( opts ):
+def literate( name, opts ):
opts.literate = 1;
-def c_src( opts ):
+def c_src( name, opts ):
opts.c_src = 1;
-def objc_src( opts ):
+def objc_src( name, opts ):
opts.objc_src = 1;
-def objcpp_src( opts ):
+def objcpp_src( name, opts ):
opts.objcpp_src = 1;
+def cmm_src( name, opts ):
+ opts.cmm_src = 1;
+
def outputdir( odir ):
- return lambda opts, d=odir: _outputdir(opts, d)
+ return lambda name, opts, d=odir: _outputdir(name, opts, d)
-def _outputdir( opts, odir ):
+def _outputdir( name, opts, odir ):
opts.outputdir = odir;
# ----
def pre_cmd( cmd ):
- return lambda opts, c=cmd: _pre_cmd(opts, cmd)
+ return lambda name, opts, c=cmd: _pre_cmd(name, opts, cmd)
-def _pre_cmd( opts, cmd ):
+def _pre_cmd( name, opts, cmd ):
opts.pre_cmd = cmd
# ----
def clean_cmd( cmd ):
- return lambda opts, c=cmd: _clean_cmd(opts, cmd)
+ return lambda name, opts, c=cmd: _clean_cmd(name, opts, cmd)
-def _clean_cmd( opts, cmd ):
+def _clean_cmd( name, opts, cmd ):
opts.clean_cmd = cmd
# ----
def cmd_prefix( prefix ):
- return lambda opts, p=prefix: _cmd_prefix(opts, prefix)
+ return lambda name, opts, p=prefix: _cmd_prefix(name, opts, prefix)
-def _cmd_prefix( opts, prefix ):
+def _cmd_prefix( name, opts, prefix ):
opts.cmd_wrapper = lambda cmd, p=prefix: p + ' ' + cmd;
# ----
def cmd_wrapper( fun ):
- return lambda opts, f=fun: _cmd_wrapper(opts, fun)
+ return lambda name, opts, f=fun: _cmd_wrapper(name, opts, fun)
-def _cmd_wrapper( opts, fun ):
+def _cmd_wrapper( name, opts, fun ):
opts.cmd_wrapper = fun
# ----
def compile_cmd_prefix( prefix ):
- return lambda opts, p=prefix: _compile_cmd_prefix(opts, prefix)
+ return lambda name, opts, p=prefix: _compile_cmd_prefix(name, opts, prefix)
-def _compile_cmd_prefix( opts, prefix ):
+def _compile_cmd_prefix( name, opts, prefix ):
opts.compile_cmd_prefix = prefix
# ----
-def normalise_slashes( opts ):
+def normalise_slashes( name, opts ):
opts.extra_normaliser = normalise_slashes_
-def normalise_exe( opts ):
+def normalise_exe( name, opts ):
opts.extra_normaliser = normalise_exe_
def normalise_fun( fun ):
- return lambda opts, f=fun: _normalise_fun(opts, f)
+ return lambda name, opts, f=fun: _normalise_fun(name, opts, f)
-def _normalise_fun( opts, f ):
+def _normalise_fun( name, opts, f ):
opts.extra_normaliser = f
def normalise_errmsg_fun( fun ):
- return lambda opts, f=fun: _normalise_errmsg_fun(opts, f)
+ return lambda name, opts, f=fun: _normalise_errmsg_fun(name, opts, f)
-def _normalise_errmsg_fun( opts, f ):
+def _normalise_errmsg_fun( name, opts, f ):
opts.extra_errmsg_normaliser = f
def two_normalisers(f, g):
@@ -589,25 +475,25 @@ def two_normalisers(f, g):
# ----
# Function for composing two opt-fns together
-def composes( fs ):
- return reduce(lambda f, g: compose(f, g), fs)
-
-def compose( f, g ):
- return lambda opts, f=f, g=g: _compose(opts,f,g)
-
-def _compose( opts, f, g ):
- f(opts)
- g(opts)
+def executeSetups(fs, name, opts):
+ if type(fs) is types.ListType:
+ # If we have a list of setups, then execute each one
+ map (lambda f : executeSetups(f, name, opts), fs)
+ else:
+ # fs is a single function, so just apply it
+ fs(name, opts)
# -----------------------------------------------------------------------------
# The current directory of tests
def newTestDir( dir ):
- global thisdir_testopts
+ global thisdir_settings
# reset the options for this test directory
- thisdir_testopts = copy.copy(default_testopts)
- thisdir_testopts.testdir = dir
- thisdir_testopts.compiler_always_flags = config.compiler_always_flags
+ thisdir_settings = lambda name, opts, dir=dir: _newTestDir( name, opts, dir )
+
+def _newTestDir( name, opts, dir ):
+ opts.testdir = dir
+ opts.compiler_always_flags = config.compiler_always_flags
# -----------------------------------------------------------------------------
# Actually doing tests
@@ -640,14 +526,18 @@ def test (name, setup, func, args):
global aloneTests
global parallelTests
global allTestNames
+ global thisdir_settings
if name in allTestNames:
framework_fail(name, 'duplicate', 'There are multiple tests with this name')
- myTestOpts = copy.copy(thisdir_testopts)
+ if not re.match('^[0-9]*[a-zA-Z][a-zA-Z0-9._-]*$', name):
+ framework_fail(name, 'bad_name', 'This test has an invalid name')
- if type(setup) is types.ListType:
- setup = composes(setup)
+ # Make a deep copy of the default_testopts, as we need our own copy
+ # of any dictionaries etc inside it. Otherwise, if one test modifies
+ # them, all tests will see the modified version!
+ myTestOpts = copy.deepcopy(default_testopts)
- setup(myTestOpts)
+ executeSetups([thisdir_settings, setup], name, myTestOpts)
thisTest = lambda : runTest(myTestOpts, name, func, args)
if myTestOpts.alone:
@@ -721,6 +611,8 @@ def test_common_work (name, opts, func, args):
if not config.clean_only:
# Run the required tests...
for way in do_ways:
+ if stopping():
+ break
do_test (name, way, func, args)
for way in all_ways:
@@ -757,6 +649,11 @@ def test_common_work (name, opts, func, args):
pass
try:
+ shutil.rmtree(in_testdir('.hpc.' + name))
+ except:
+ pass
+
+ try:
cleanCmd = getTestOpts().clean_cmd
if cleanCmd != None:
result = runCmdFor(name, 'cd ' + getTestOpts().testdir + ' && ' + cleanCmd)
@@ -877,6 +774,8 @@ def do_test(name, way, func, args):
t.expected_failures[name] = [way]
else:
framework_fail(name, way, 'bad result ' + passFail)
+ except KeyboardInterrupt:
+ stopNow()
except:
framework_fail(name, way, 'do_test exception')
traceback.print_exc()
@@ -916,7 +815,7 @@ def skiptest (name, way):
def framework_fail( name, way, reason ):
full_name = name + '(' + way + ')'
- print '*** framework failure for', full_name, reason, ':'
+ print '*** framework failure for', full_name, reason
t.n_framework_failures = t.n_framework_failures + 1
if name in t.framework_failures:
t.framework_failures[name].append(way)
@@ -1099,15 +998,14 @@ def multi_compile_and_run( name, way, top_mod, extra_mods, extra_hc_opts ):
def stats( name, way, stats_file ):
opts = getTestOpts()
- return checkStats(stats_file, opts.stats_range_fields
- , opts.stats_num_fields)
+ return checkStats(stats_file, opts.stats_range_fields)
# -----------------------------------------------------------------------------
# Check -t stats info
-def checkStats(stats_file, range_fields, num_fields):
+def checkStats(stats_file, range_fields):
result = passed()
- if len(num_fields) + len(range_fields) > 0:
+ if len(range_fields) > 0:
f = open(in_testdir(stats_file))
contents = f.read()
f.close()
@@ -1119,36 +1017,31 @@ def checkStats(stats_file, range_fields, num_fields):
result = failBecause('no such stats field')
val = int(m.group(1))
- min = expected * ((100 - float(dev))/100);
- max = expected * ((100 + float(dev))/100);
-
- if val < min:
- print field, val, 'is more than ' + repr(dev) + '%'
- print 'less than the exepected value', expected
- print 'If this is because you have improved GHC, please'
- print 'update the test so that GHC doesn\'t regress again'
- result = failBecause('stat too good')
- if val > max:
- print field, val, 'is more than ' + repr(dev) + '% greater than the expected value,', expected, max
- result = failBecause('stat not good enough')
-
- # ToDo: remove all uses of this, and delete it
- for (field, (min, max)) in num_fields.items():
- m = re.search('\("' + field + '", "([0-9]+)"\)', contents)
- if m == None:
- print 'Failed to find field: ', field
- result = failBecause('no such stats field')
- val = int(m.group(1))
+ lowerBound = trunc( expected * ((100 - float(dev))/100));
+ upperBound = trunc(0.5 + ceil(expected * ((100 + float(dev))/100)));
- if val < min:
- print field, val, 'is less than minimum allowed', min
- print 'If this is because you have improved GHC, please'
- print 'update the test so that GHC doesn\'t regress again'
+ if val < lowerBound:
+ print field, 'value is too low:'
+ print '(If this is because you have improved GHC, please'
+ print 'update the test so that GHC doesn\'t regress again)'
result = failBecause('stat too good')
- if val > max:
- print field, val, 'is more than maximum allowed', max
+ if val > upperBound:
+ print field, 'value is too high:'
result = failBecause('stat not good enough')
+ if val < lowerBound or val > upperBound:
+ valStr = str(val)
+ valLen = len(valStr)
+ expectedStr = str(expected)
+ expectedLen = len(expectedStr)
+ length = max(map (lambda x : len(str(x)), [expected, lowerBound, upperBound, val]))
+ def display(descr, val, extra):
+ print descr, string.rjust(str(val), length), extra
+ display(' Expected ' + field + ':', expected, '+/-' + str(dev) + '%')
+ display(' Lower bound ' + field + ':', lowerBound, '')
+ display(' Upper bound ' + field + ':', upperBound, '')
+ display(' Actual ' + field + ':', val, '')
+
return result
# -----------------------------------------------------------------------------
@@ -1199,13 +1092,14 @@ def simple_build( name, way, extra_hc_opts, should_fail, top_mod, link, addsuf,
to_do = '-c' # just compile
stats_file = name + '.comp.stats'
- if len(opts.compiler_stats_num_fields) + len(opts.compiler_stats_range_fields) > 0:
+ if len(opts.compiler_stats_range_fields) > 0:
extra_hc_opts += ' +RTS -V0 -t' + stats_file + ' --machine-readable -RTS'
# Required by GHC 7.3+, harmless for earlier versions:
if (getTestOpts().c_src or
getTestOpts().objc_src or
- getTestOpts().objcpp_src):
+ getTestOpts().objcpp_src or
+ getTestOpts().cmm_src):
extra_hc_opts += ' -no-hs-main '
if getTestOpts().compile_cmd_prefix == '':
@@ -1223,7 +1117,7 @@ def simple_build( name, way, extra_hc_opts, should_fail, top_mod, link, addsuf,
+ config.compiler + "' " \
+ join(comp_flags,' ') + ' ' \
+ to_do + ' ' + srcname + ' ' \
- + join(config.way_flags[way],' ') + ' ' \
+ + join(config.way_flags(name)[way],' ') + ' ' \
+ extra_hc_opts + ' ' \
+ opts.extra_hc_opts + ' ' \
+ '>' + errname + ' 2>&1'
@@ -1237,8 +1131,7 @@ def simple_build( name, way, extra_hc_opts, should_fail, top_mod, link, addsuf,
# ToDo: if the sub-shell was killed by ^C, then exit
- statsResult = checkStats(stats_file, opts.compiler_stats_range_fields
- , opts.compiler_stats_num_fields)
+ statsResult = checkStats(stats_file, opts.compiler_stats_range_fields)
if badResult(statsResult):
return statsResult
@@ -1284,7 +1177,7 @@ def simple_run( name, way, prog, args ):
my_rts_flags = rts_flags(way)
stats_file = name + '.stats'
- if len(opts.stats_num_fields) + len(opts.stats_range_fields) > 0:
+ if len(opts.stats_range_fields) > 0:
args += ' +RTS -V0 -t' + stats_file + ' --machine-readable -RTS'
if opts.no_stdin:
@@ -1338,8 +1231,7 @@ def simple_run( name, way, prog, args ):
if check_prof and not check_prof_ok(name):
return failBecause('bad profile')
- return checkStats(stats_file, opts.stats_range_fields
- , opts.stats_num_fields)
+ return checkStats(stats_file, opts.stats_range_fields)
def rts_flags(way):
if (way == ''):
@@ -1409,7 +1301,7 @@ def interpreter_run( name, way, extra_hc_opts, compile_only, top_mod ):
cmd = "'" + config.compiler + "' " \
+ join(flags,' ') + ' ' \
+ srcname + ' ' \
- + join(config.way_flags[way],' ') + ' ' \
+ + join(config.way_flags(name)[way],' ') + ' ' \
+ extra_hc_opts + ' ' \
+ getTestOpts().extra_hc_opts + ' ' \
+ '<' + scriptname + ' 1>' + outname + ' 2>' + errname
@@ -1505,7 +1397,7 @@ def extcore_run( name, way, extra_hc_opts, compile_only, top_mod ):
cmd = 'cd ' + getTestOpts().testdir + " && '" \
+ config.compiler + "' " \
+ join(flags,' ') + ' ' \
- + join(config.way_flags[way],' ') + ' ' \
+ + join(config.way_flags(name)[way],' ') + ' ' \
+ extra_hc_opts + ' ' \
+ getTestOpts().extra_hc_opts \
+ to_do \
@@ -1530,7 +1422,7 @@ def extcore_run( name, way, extra_hc_opts, compile_only, top_mod ):
deplist2 = string.replace(deplist,'.lhs,', '.hcr');
to_compile = string.replace(deplist2,'.hs,', '.hcr');
- flags = join(filter(lambda f: f != '-fext-core',config.way_flags[way]),' ')
+ flags = join(filter(lambda f: f != '-fext-core',config.way_flags(name)[way]),' ')
if getTestOpts().outputdir != None:
flags.extend(["-outputdir", getTestOpts().outputdir])
@@ -1602,7 +1494,7 @@ def norm(str):
return normalise_errmsg(str)
return compare_outputs('stderr', \
- two_normalisers(norm, getTestOpts().extra_normaliser), \
+ two_normalisers(norm, getTestOpts().extra_errmsg_normaliser), \
expected_stderr_file, actual_stderr_file)
def dump_stderr( name ):
@@ -1848,6 +1740,15 @@ def rawSystem(cmd_and_args):
else:
return os.spawnv(os.P_WAIT, cmd_and_args[0], cmd_and_args)
+# Note that this doesn't handle the timeout itself; it is just used for
+# commands that have timeout handling built-in.
+def rawSystemWithTimeout(cmd_and_args):
+ r = rawSystem(cmd_and_args)
+ if r == 98:
+ # The python timeout program uses 98 to signal that ^C was pressed
+ stopNow()
+ return r
+
# cmd is a complex command in Bourne-shell syntax
# e.g (cd . && 'c:/users/simonpj/darcs/HEAD/compiler/stage1/ghc-inplace' ...etc)
# Hence it must ultimately be run by a Bourne shell
@@ -1867,7 +1768,7 @@ def runCmd( cmd ):
assert config.timeout_prog!=''
if config.timeout_prog != '':
- r = rawSystem([config.timeout_prog, str(config.timeout), cmd])
+ r = rawSystemWithTimeout([config.timeout_prog, str(config.timeout), cmd])
else:
r = os.system(cmd)
return r << 8
@@ -1878,18 +1779,19 @@ def runCmdFor( name, cmd, timeout_multiplier=1.0 ):
if config.os == 'mingw32':
# On MinGW, we will always have timeout
assert config.timeout_prog!=''
- timeout = int(math.ceil(config.timeout * timeout_multiplier))
+ timeout = int(ceil(config.timeout * timeout_multiplier))
if config.timeout_prog != '':
if config.check_files_written:
fn = name + ".strace"
- r = rawSystem(["strace", "-o", fn, "-fF", "-e", "creat,open,chdir,clone,vfork",
- config.timeout_prog, str(timeout),
- cmd])
+ r = rawSystemWithTimeout(
+ ["strace", "-o", fn, "-fF",
+ "-e", "creat,open,chdir,clone,vfork",
+ config.timeout_prog, str(timeout), cmd])
addTestFilesWritten(name, fn)
rm_no_fail(fn)
else:
- r = rawSystem([config.timeout_prog, str(timeout), cmd])
+ r = rawSystemWithTimeout([config.timeout_prog, str(timeout), cmd])
else:
r = os.system(cmd)
return r << 8
@@ -2111,6 +2013,8 @@ def add_suffix( name, suffix ):
def add_hs_lhs_suffix(name):
if getTestOpts().c_src:
return add_suffix(name, 'c')
+ elif getTestOpts().cmm_src:
+ return add_suffix(name, 'cmm')
elif getTestOpts().objc_src:
return add_suffix(name, 'm')
elif getTestOpts().objcpp_src:
@@ -2201,25 +2105,28 @@ def findTFiles_(path):
def summary(t, file):
file.write('\n')
- file.write('OVERALL SUMMARY for test run started at ' \
- + t.start_time + '\n'\
- + string.rjust(`t.total_tests`, 8) \
- + ' total tests, which gave rise to\n' \
- + string.rjust(`t.total_test_cases`, 8) \
- + ' test cases, of which\n' \
- + string.rjust(`t.n_framework_failures`, 8) \
- + ' caused framework failures\n' \
+ printUnexpectedTests(file, [t.unexpected_passes, t.unexpected_failures])
+ file.write('OVERALL SUMMARY for test run started at '
+ + t.start_time + '\n'
+ + string.rjust(`t.total_tests`, 8)
+ + ' total tests, which gave rise to\n'
+ + string.rjust(`t.total_test_cases`, 8)
+ + ' test cases, of which\n'
+ string.rjust(`t.n_tests_skipped`, 8)
- + ' were skipped\n\n' \
- + string.rjust(`t.n_expected_passes`, 8)
- + ' expected passes\n' \
+ + ' were skipped\n'
+ + '\n'
+ string.rjust(`t.n_missing_libs`, 8)
- + ' had missing libraries\n' \
- + string.rjust(`t.n_expected_failures`, 8) \
- + ' expected failures\n' \
- + string.rjust(`t.n_unexpected_passes`, 8) \
+ + ' had missing libraries\n'
+ + string.rjust(`t.n_expected_passes`, 8)
+ + ' expected passes\n'
+ + string.rjust(`t.n_expected_failures`, 8)
+ + ' expected failures\n'
+ + '\n'
+ + string.rjust(`t.n_framework_failures`, 8)
+ + ' caused framework failures\n'
+ + string.rjust(`t.n_unexpected_passes`, 8)
+ ' unexpected passes\n'
- + string.rjust(`t.n_unexpected_failures`, 8) \
+ + string.rjust(`t.n_unexpected_failures`, 8)
+ ' unexpected failures\n'
+ '\n')
@@ -2234,6 +2141,21 @@ def summary(t, file):
if config.check_files_written:
checkForFilesWrittenProblems(file)
+ if stopping():
+ file.write('WARNING: Testsuite run was terminated early\n')
+
+def printUnexpectedTests(file, testInfoss):
+ unexpected = []
+ for testInfos in testInfoss:
+ directories = testInfos.keys()
+ for directory in directories:
+ tests = testInfos[directory].keys()
+ unexpected += tests
+ if unexpected != []:
+ file.write('Unexpected results from:\n')
+ file.write('TEST="' + ' '.join(unexpected) + '"\n')
+ file.write('\n')
+
def printPassingTestInfosSummary(file, testInfos):
directories = testInfos.keys()
directories.sort()
View
16 mk/boilerplate.mk
@@ -66,9 +66,21 @@ IN_TREE_COMPILER = NO
# passed in by the user, but
# which ghc == /usr/bin/ghc
# which /usr/bin/ghc == /usr/bin/ghc
-# so we can just always 'which' it. We need to use 'override' in order
-# to override a value given on the commandline.
+# so on unix-like platforms we can just always 'which' it.
+# However, on cygwin, we can't just use which:
+# $ which c:/ghc/ghc-7.4.1/bin/ghc.exe
+# which: no ghc.exe in (./c:/ghc/ghc-7.4.1/bin)
+# so we start off by using realpath, and if that succeeds then we use
+# that value. Otherwise we fall back on 'which'.
+#
+# Note also that we need to use 'override' in order to override a
+# value given on the commandline.
+TEST_HC_REALPATH := $(realpath $(TEST_HC))
+ifeq "$(TEST_HC_REALPATH)" ""
override TEST_HC := $(shell which '$(TEST_HC)')
+else
+override TEST_HC := $(TEST_HC_REALPATH)
+endif
endif
# We can't use $(dir ...) here as TEST_HC might be in a path
View
10 mk/test.mk
@@ -175,6 +175,12 @@ endif
RUNTEST_OPTS += \
$(EXTRA_RUNTEST_OPTS)
+ifeq "$(list_broken)" "YES"
+set_list_broken = -e config.list_broken=True
+else
+set_list_broken =
+endif
+
ifeq "$(fast)" "YES"
setfast = -e config.fast=1
else
@@ -209,6 +215,7 @@ test: $(TIMEOUT_PROGRAM)
$(patsubst %, --only=%, $(TESTS)) \
$(patsubst %, --way=%, $(WAY)) \
$(patsubst %, --skipway=%, $(SKIPWAY)) \
+ $(set_list_broken) \
$(setfast) \
$(setaccept)
@@ -220,3 +227,6 @@ accept:
fast:
$(MAKE) fast=YES
+list_broken:
+ $(MAKE) list_broken=YES
+
View
3  tests/Makefile
@@ -3,7 +3,8 @@ include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk
# The libraries that we actually know about. We don't want to test
-# extralibs that are in our tree but which we haven't built.
+# extralibs that are in our tree but which we haven't built, and
+# we don't want to test unix on Windows or Win32 on non-Windows.
LIBRARIES := $(shell '$(GHC_PKG)' list --simple-output --names-only)
ifeq "$(findstring base,$(LIBRARIES))" ""
View
2  tests/annotations/should_compile/all.T
@@ -1,5 +1,5 @@
-setTestOpts(if_compiler_profiled(skip))
+setTestOpts(when(compiler_profiled(), skip))
# Annotations, like Template Haskell, require runtime evaluation. In
# order for this to work with profiling, we would have to build the
View
4 tests/annotations/should_fail/annfail01.stderr
@@ -1,4 +1,4 @@
-annfail01.hs:4:1: Not in scope: type constructor or class `Foo'
+annfail01.hs:4:1: Not in scope: type constructor or class Foo
-annfail01.hs:5:1: Not in scope: `f'
+annfail01.hs:5:1: Not in scope: ‛f’
View
4 tests/annotations/should_fail/annfail02.stderr
@@ -1,4 +1,4 @@
-annfail02.hs:6:1: Not in scope: data constructor `Foo'
+annfail02.hs:6:1: Not in scope: data constructor Foo
-annfail02.hs:7:1: Not in scope: type constructor or class `Bar'
+annfail02.hs:7:1: Not in scope: type constructor or class Bar
View
5 tests/annotations/should_fail/annfail03.stderr
@@ -1,7 +1,8 @@
annfail03.hs:17:1:
- GHC stage restriction: instance for `Data InModule'
- is used in a top-level splice or annotation,
+ GHC stage restriction:
+ instance for ‛Data
+ InModule’ is used in a top-level splice or annotation,
and must be imported, not defined locally
In the expression: InModule
In the annotation: {-# ANN f InModule #-}
View
5 tests/annotations/should_fail/annfail04.stderr
@@ -1,7 +1,8 @@
annfail04.hs:14:12:
- GHC stage restriction: instance for `Thing Int'
- is used in a top-level splice or annotation,
+ GHC stage restriction:
+ instance for ‛Thing
+ Int’ is used in a top-level splice or annotation,
and must be imported, not defined locally
In the expression: (thing :: Int)
In the annotation: {-# ANN f (thing :: Int) #-}
View
2  tests/annotations/should_fail/annfail06.hs
@@ -7,7 +7,7 @@ import Data.Data
import Data.Typeable
instance Typeable InstancesInWrongModule where
- typeOf _ = undefined
+ typeRep _ = undefined
instance Data InstancesInWrongModule where
gfoldl = undefined
View
5 tests/annotations/should_fail/annfail06.stderr
@@ -1,7 +1,8 @@
annfail06.hs:21:1:
- GHC stage restriction: instance for `Data InstancesInWrongModule'
- is used in a top-level splice or annotation,
+ GHC stage restriction:
+ instance for ‛Data
+ InstancesInWrongModule’ is used in a top-level splice or annotation,
and must be imported, not defined locally
In the expression: InstancesInWrongModule
In the annotation: {-# ANN f InstancesInWrongModule #-}
View
4 tests/annotations/should_fail/annfail07.stderr
@@ -1,6 +1,6 @@
annfail07.hs:9:17:
- Couldn't match expected type `[a0]' with actual type `Bool'
- In the first argument of `head', namely `True'
+ Couldn't match expected type [a0] with actual type Bool
+ In the first argument of head, namely True
In the expression: (head True)
In the annotation: {-# ANN f (head True) #-}
View
2  tests/annotations/should_fail/annfail08.stderr
@@ -6,6 +6,6 @@ annfail08.hs:9:1:
In the annotation: {-# ANN f (id + 1) #-}
annfail08.hs:9:15:
- No instance for (Num (a0 -> a0)) arising from a use of `+'
+ No instance for (Num (a0 -> a0)) arising from a use of ‛+’
In the expression: (id + 1)
In the annotation: {-# ANN f (id + 1) #-}
View
4 tests/annotations/should_fail/annfail09.stderr
@@ -1,7 +1,7 @@
annfail09.hs:11:11:
- GHC stage restriction: `g'
- is used in a top-level splice or annotation,
+ GHC stage restriction:
+ ‛g’ is used in a top-level splice or annotation,
and must be imported, not defined locally
In the expression: g
In the annotation: {-# ANN f g #-}
View
18 tests/annotations/should_fail/annfail10.stderr
@@ -1,27 +1,27 @@
annfail10.hs:9:1:
No instance for (Data.Data.Data a0) arising from an annotation
- The type variable `a0' is ambiguous
+ The type variable ‛a0’ is ambiguous
Note: there are several potential instances:
- instance Data.Data.Data () -- Defined in `Data.Data'
+ instance Data.Data.Data () -- Defined in Data.Data
instance (Data.Data.Data a, Data.Data.Data b) =>
Data.Data.Data (a, b)
- -- Defined in `Data.Data'
+ -- Defined in Data.Data
instance (Data.Data.Data a, Data.Data.Data b, Data.Data.Data c) =>
Data.Data.Data (a, b, c)
- -- Defined in `Data.Data'
+ -- Defined in Data.Data
...plus 27 others
In the expression: 1
In the annotation: {-# ANN f 1 #-}
annfail10.hs:9:11:
- No instance for (Num a0) arising from the literal `1'
- The type variable `a0' is ambiguous
+ No instance for (Num a0) arising from the literal ‛1’
+ The type variable ‛a0’ is ambiguous
Note: there are several potential instances:
- instance Num Double -- Defined in `GHC.Float'
- instance Num Float -- Defined in `GHC.Float'
+ instance Num Double -- Defined in GHC.Float
+ instance Num Float -- Defined in GHC.Float
instance Integral a => Num (GHC.Real.Ratio a)
- -- Defined in `GHC.Real'
+ -- Defined in GHC.Real
...plus 11 others
In the expression: 1
In the annotation: {-# ANN f 1 #-}
View
4 tests/annotations/should_fail/annfail11.stderr
@@ -1,4 +1,4 @@
-annfail11.hs:3:1: Not in scope: `length'
+annfail11.hs:3:1: Not in scope: length
-annfail11.hs:4:1: Not in scope: type constructor or class `Integer'
+annfail11.hs:4:1: Not in scope: type constructor or class Integer
View
6 tests/annotations/should_run/all.T
@@ -1,6 +1,6 @@
-setTestOpts(if_compiler_profiled(skip))
+setTestOpts(when(compiler_profiled(), skip))
# These tests are very slow due to their use of package GHC
-setTestOpts(skip_if_fast)
+setTestOpts(when(fast(), skip))
# Annotations, like Template Haskell, require runtime evaluation. In
# order for this to work with profiling, we would have to build the
@@ -10,7 +10,7 @@ test('annrun01',
[extra_clean(['Annrun01_Help.hi', 'Annrun01_Help.o',
'annrun01.hi', 'annrun01.o',
'Config.hs', 'Config.hi', 'Config.o']),
- pre_cmd('$MAKE -s config'),
+ pre_cmd('$MAKE -s --no-print-directory config'),
omit_ways(['profasm','profthreaded', 'dyn'])],
multimod_compile_and_run,
['annrun01', '-package ghc']
View
34 tests/array/should_run/all.T
@@ -4,23 +4,23 @@
# extra run flags
# expected process return value, if not zero
-test('arr001', skip_if_fast, compile_and_run, [''])
-test('arr002', skip_if_fast, compile_and_run, [''])
-test('arr003', compose(skip_if_fast,exit_code(1)), compile_and_run, [''])
-test('arr004', compose(skip_if_fast,exit_code(1)), compile_and_run, [''])
-test('arr005', skip_if_fast, compile_and_run, [''])
-test('arr006', skip_if_fast, compile_and_run, [''])
-test('arr007', compose(skip_if_fast,exit_code(1)), compile_and_run, [''])
-test('arr008', compose(skip_if_fast,exit_code(1)), compile_and_run, [''])
-test('arr009', skip_if_fast, compile_and_run, [''])
-test('arr010', skip_if_fast, compile_and_run, [''])
-test('arr011', skip_if_fast, compile_and_run, [''])
-test('arr012', skip_if_fast, compile_and_run, [''])
-test('arr013', skip_if_fast, compile_and_run, [''])
-test('arr014', skip_if_fast, compile_and_run, [''])
-test('arr015', skip_if_fast, compile_and_run, [''])
+test('arr001', when(fast(), skip), compile_and_run, [''])
+test('arr002', when(fast(), skip), compile_and_run, [''])
+test('arr003', [when(fast(), skip),exit_code(1)], compile_and_run, [''])
+test('arr004', [when(fast(), skip),exit_code(1)], compile_and_run, [''])
+test('arr005', when(fast(), skip), compile_and_run, [''])
+test('arr006', when(fast(), skip), compile_and_run, [''])
+test('arr007', [when(fast(), skip),exit_code(1)], compile_and_run, [''])
+test('arr008', [when(fast(), skip),exit_code(1)], compile_and_run, [''])
+test('arr009', when(fast(), skip), compile_and_run, [''])
+test('arr010', when(fast(), skip), compile_and_run, [''])
+test('arr011', when(fast(), skip), compile_and_run, [''])
+test('arr012', when(fast(), skip), compile_and_run, [''])
+test('arr013', when(fast(), skip), compile_and_run, [''])
+test('arr014', when(fast(), skip), compile_and_run, [''])
+test('arr015', when(fast(), skip), compile_and_run, [''])
test('arr016', reqlib('random'), compile_and_run, [''])
-test('arr017', skip_if_fast, compile_and_run, [''])
-test('arr018', skip_if_fast, compile_and_run, [''])
+test('arr017', when(fast(), skip), compile_and_run, [''])
+test('arr018', when(fast(), skip), compile_and_run, [''])
test('arr019', normal, compile_and_run, [''])
test('arr020', normal, compile_and_run, [''])
View
2  tests/arrows/should_compile/all.T
@@ -16,5 +16,5 @@ test('arrowrec1', normal, compile, [''])
test('arrowpat', normal, compile, [''])
test('T3964', normal, compile, [''])
test('T5283', normal, compile, [''])
-test('T5267', expect_broken(5605), compile, [''])
+test('T5267', expect_broken(5267), compile, [''])
test('T5022', normal, compile, [''])
View
12 tests/arrows/should_fail/T5380.stderr
@@ -1,7 +1,7 @@
T5380.hs:7:27:
- Couldn't match expected type `Bool' with actual type `not_bool'
- `not_bool' is a rigid type variable bound by
+ Couldn't match expected type Bool with actual type not_bool
+ not_bool is a rigid type variable bound by
the type signature for
testB :: not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:10
@@ -11,12 +11,12 @@ T5380.hs:7:27:
b :: not_bool (bound at T5380.hs:7:7)
In the expression: b
In the expression: proc () -> if b then f -< () else f -< ()
- In an equation for `testB':
+ In an equation for testB:
testB b f = proc () -> if b then f -< () else f -< ()
T5380.hs:7:34:
- Couldn't match type `not_unit' with `()'
- `not_unit' is a rigid type variable bound by
+ Couldn't match type not_unit with ‛()’
+ not_unit is a rigid type variable bound by
the type signature for
testB :: not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:10
@@ -27,5 +27,5 @@ T5380.hs:7:34:
(bound at T5380.hs:7:1)
In the expression: f
In the expression: proc () -> if b then f -< () else f -< ()
- In an equation for `testB':
+ In an equation for testB:
testB b f = proc () -> if b then f -< () else f -< ()
View
2  tests/arrows/should_fail/all.T
@@ -1,7 +1,7 @@
setTestOpts(only_compiler_types(['ghc']))
test('arrowfail001',
- if_compiler_debugged(expect_broken(5267)),
+ when(compiler_debugged(), expect_broken(5267)),
compile_fail,
[''])
# arrowfail001 gets an ASSERT error in the stage1 compiler
View
4 tests/arrows/should_fail/arrowfail001.stderr
@@ -1,7 +1,7 @@
arrowfail001.hs:16:36:
- No instance for (Foo a) arising from a use of `foo'
+ No instance for (Foo a) arising from a use of foo
In the expression: foo
In the expression: proc x -> case x of { Bar a -> foo -< a }
- In an equation for `get':
+ In an equation for get:
get = proc x -> case x of { Bar a -> foo -< a }
View
2  tests/arrows/should_fail/arrowfail002.stderr
@@ -1,2 +1,2 @@
-arrowfail002.hs:6:17: Not in scope: `x'
+arrowfail002.hs:6:17: Not in scope: ‛x’
View
2  tests/arrows/should_fail/arrowfail004.stderr
@@ -3,5 +3,5 @@ arrowfail004.hs:12:15:
Proc patterns cannot use existential or GADT data constructors
In the pattern: T x
In the expression: proc (T x) -> do { returnA -< T x }
- In an equation for `panic':
+ In an equation for panic:
panic = proc (T x) -> do { returnA -< T x }
View
4 tests/arrows/should_run/all.T
@@ -1,8 +1,8 @@
setTestOpts(only_compiler_types(['ghc']))
test('arrowrun001', normal, compile_and_run, [''])
-test('arrowrun002', skip_if_fast, compile_and_run, [''])