Start to play around with TH :)
This commit is contained in:
parent
1155905be3
commit
76df52c554
@ -57,6 +57,7 @@ library
|
||||
, HushGP.PushTests.IntTests
|
||||
, HushGP.PushTests.GenericTests
|
||||
, HushGP.PushTests.UtilTests
|
||||
, HushGP.TH
|
||||
|
||||
-- Modules included in this library but not exported.
|
||||
-- other-modules:
|
||||
|
2
TODO.md
2
TODO.md
@ -15,7 +15,7 @@
|
||||
- [X] Standardize the pattern matching parameter names, such as c1 : cs
|
||||
- [ ] Write unit/quickcheck tests for all of the instructions
|
||||
- [ ] Use template haskell to generate function lists
|
||||
- [ ] Move utility functions to their own file
|
||||
- [X] Move utility functions to their own file
|
||||
|
||||
## PushGP TODO
|
||||
- [ ] Implement a Plushy genome translator
|
||||
|
12
src/HushGP/TH.hs
Normal file
12
src/HushGP/TH.hs
Normal file
@ -0,0 +1,12 @@
|
||||
{-# LANGUAGE TemplateHaskell #-}
|
||||
module HushGP.TH where
|
||||
|
||||
import System.IO
|
||||
|
||||
thTest :: IO ()
|
||||
thTest = do
|
||||
handle <- openFile "src/HushGP/Instructions/IntInstructions.hs" ReadMode
|
||||
let list = hGetContents handle
|
||||
toPrint <- list
|
||||
print toPrint
|
||||
hClose handle
|
Loading…
x
Reference in New Issue
Block a user