Commit Graph

1299 Commits

Author SHA1 Message Date
Neil Brown
6a979f3cb1 Added a command-line option for turning on the usage checking 2008-01-29 22:50:51 +00:00
Neil Brown
5a7e6976d1 Added a typename decorator to a template type to keep the C++ compiler happy 2008-01-29 21:39:04 +00:00
Neil Brown
46f054ff98 Put back an include directive for boost tuples that must have been accidentally removed 2008-01-29 21:38:42 +00:00
Neil Brown
efe1985dd1 Fixed a problem with the compile-cgtests not being executable 2008-01-29 21:38:20 +00:00
Neil Brown
4194942670 Fixed the URL for the cgtests to point to the corresponding old revision in the CS projects repository 2008-01-29 21:37:47 +00:00
Neil Brown
d783edf8ef Corrected checkInitVar so that it only checks nodes that are actually connected to the given startNode 2008-01-29 21:06:32 +00:00
Neil Brown
95d99706e3 Readjusted the parameters of flowAlgorithm so that the initial value for the starting node is passed in more obviously (since that was the only use of initVal, which has now been removed) 2008-01-29 21:05:37 +00:00
Neil Brown
28fd400d89 Adjusted the FlowGraph tests to check the roots of the graph, and added in the new root nodes where appropriate 2008-01-29 20:06:33 +00:00
Neil Brown
12b1617fec Added a new labelling function to FlowGraph for labelling the arguments of functions/processes 2008-01-29 20:05:38 +00:00
Neil Brown
355481cafa Turned on more compiler warnings 2008-01-29 17:22:29 +00:00
Neil Brown
2b62520013 Improved the readability of the uninitialised-variables warning 2008-01-29 17:12:16 +00:00
Neil Brown
d0b1b3d464 Changed checkPlainVarUsage and checkInitVar to apply only to plain variables 2008-01-29 16:58:46 +00:00
Neil Brown
24e6e35e82 Corrected the checkInitVar function to work properly 2008-01-29 12:49:16 +00:00
Neil Brown
5567d8cee0 Changed FlowGraph to keep a record of all the root nodes in the tree and return them in a list 2008-01-29 12:46:14 +00:00
Neil Brown
0a1270f109 Corrected a comment in FlowAlgorithms 2008-01-29 12:44:06 +00:00
Neil Brown
48384746d0 Added a function to check the parameters passed to a proc call against each other for safe usage (CREW) 2008-01-29 12:00:32 +00:00
Neil Brown
4bbb3f86d7 Added support for processing the variables passed to procs in getVarProc 2008-01-29 12:00:02 +00:00
Neil Brown
00a9dfc89b Added more usage checks for proc and function calls 2008-01-29 11:59:08 +00:00
Neil Brown
f26b3309a3 Added a new file of testcases for testing passed parameters 2008-01-29 11:39:04 +00:00
Neil Brown
a73884058d Added a line to the Makefile.am to ensure that the files needed for documentation and testing go into the distribution 2008-01-29 11:37:35 +00:00
Neil Brown
118e68bb1e Added usage checking for parallel assignments using the existing functions 2008-01-29 11:22:05 +00:00
Neil Brown
78a29de1d4 Added a couple of notes about replicators 2008-01-28 17:36:43 +00:00
Neil Brown
ebf99b08e0 Fixed some tests in RainUsageCheckTest 2008-01-28 17:30:31 +00:00
Neil Brown
7959faea40 Added support for checking for plain variables breaking CREW when used in parallel 2008-01-28 17:26:26 +00:00
Neil Brown
a1db6f989a Added support for printing out a Set of Var using showCode 2008-01-28 17:24:58 +00:00
Neil Brown
edc3a7e910 Removed the die function (that has no source position) and as far as possible replaced all its uses with dieP and a valid position 2008-01-28 17:21:13 +00:00
Neil Brown
d94f10ef77 Changed the instance of Ord for the Var type in UsageCheckUtils to use the ordering for A.Variable contained in OrdAST 2008-01-28 15:24:43 +00:00
Neil Brown
f03702d937 Added an automatically-generated OrdAST module that provides an ordering for AST elements, ignoring Meta tags 2008-01-28 15:23:53 +00:00
Neil Brown
0f085b8d81 Added Ord instances for all simple types (all no-argument constructors) in the AST module 2008-01-28 15:22:58 +00:00
Neil Brown
7a30a2ceb5 Moved the usageCheckPass function into the new Check module 2008-01-28 13:15:36 +00:00
Neil Brown
51d02559d0 Renamed the RainUsageCheck module to Check, intended to be the primary module for usage checking 2008-01-28 13:12:10 +00:00
Neil Brown
5a3141a3a8 Corrected a comment in RainUsageCheck 2008-01-28 13:08:41 +00:00
Neil Brown
55e60c7209 Moved checkPar and findReachDef to a new UsageCheckAlgorithms module 2008-01-28 13:07:28 +00:00
Neil Brown
5ff006f75d Renamed the UsageCheck module to UsageCheckUtils 2008-01-28 12:59:22 +00:00
Neil Brown
8f1215080c Changed checkArrayUsage to be a function ready to feed into checkPar, rather than one that uses it 2008-01-28 12:54:21 +00:00
Neil Brown
168e5b5cc1 Added a function for joining two functions for checkPar together, and fixed the comment on checkPar 2008-01-28 12:53:46 +00:00
Neil Brown
efc69a97cf Moved all the modules related to usage-checking into a new checks directory 2008-01-28 12:25:00 +00:00
Neil Brown
56af03f577 Rearranged the lists of source files in Makefile.am into one-per-line, alphabetical order 2008-01-28 12:21:24 +00:00
Neil Brown
c13a388b91 Corrected the Makefile so that the GHC 6.8.x-only flags actually work on GHC 6.8.x 2008-01-28 12:07:58 +00:00
Neil Brown
2120b830dc Corrected the use of the -fno-warn-tabs flag in the alex files so that it works under GHC 6.6.x 2008-01-28 12:03:03 +00:00
Neil Brown
9cd2da3b0e A large change to alter RainUsageCheck to use the code in UsageCheck
Previously there was near-duplicate code in UsageCheck adapted from RainUsageCheck.  This patch removed the duplicate code on the RainUsageCheck side, and resulting in changing the rest of the module (and its corresponding test module) to use the new UsageCheck version of the code.  The net effect is to almost completely unify the passes in RainUsageCheck (which aren't really Rain-specific anyway), UsageCheck and ArrayUsageCheck.
2008-01-27 23:53:42 +00:00
Neil Brown
060c26da84 Added to the export list of UsageCheck 2008-01-27 23:52:06 +00:00
Neil Brown
ad7b4e9736 Began trying to fix the customVarCompare function in UsageCheck 2008-01-27 23:51:49 +00:00
Neil Brown
668ed9531e Fiddled with the Show/showCode capabilities of the newtype Var in UsageCheck 2008-01-27 23:51:16 +00:00
Neil Brown
4a8653cc41 Added the monads to the export list of ShowCode 2008-01-27 23:47:41 +00:00
Neil Brown
1cc731a7d8 Changed a little code to use the more appropriate fromMaybe function rather than maybe 2008-01-27 18:37:02 +00:00
Neil Brown
349d3c5811 Merged makeEquations with makeReplicatedEquations and adjusted the tests accordingly 2008-01-27 16:53:07 +00:00
Neil Brown
5a69459668 Added a few more parallel assignment tests 2008-01-27 16:50:30 +00:00
Neil Brown
7276c3cc4a Added proper support for sequential items in non-replicated PARs in the array usage checking 2008-01-27 01:43:42 +00:00
Neil Brown
d37253d2af Improved the error message given by ArrayUsageCheck 2008-01-26 22:57:01 +00:00