diff options
author | Łukasz Gołębiewski <lukasz.golebiewski@gmail.com> | 2020-01-23 17:43:04 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-23 17:43:04 +0100 |
commit | 8065c3c074719bd13db67b5ec74db560609a4e64 (patch) | |
tree | b4cd6715cd196eecabe488caaab6b9a24ab637a1 /README.markdown | |
parent | 1a869950eba47e30ebe84e118f404ef9a62e9cc6 (diff) | |
download | stylish-haskell-8065c3c074719bd13db67b5ec74db560609a4e64.tar.gz |
Support for records formatting (#256)
* Initial test describing simplest scenario for Data step
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* [sanity-check] Delete data defs
* Extract changeDecl
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* First green test :-)
* Cover case where there are more then one field in data type declaration
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Add case03 where a type variable is present
* Add case04 - multiple declarations
* Make case04 pass
* Extend tests with case05
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Add pending case06
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Fix case 06
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Add case07
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Add second phantom case
* Add records to config
* Make indent size configurable for records
Co-authored-by: Paweł Szulc <paul.szulc@gmail.com>
* Fix warnings in Data.hs
* Process derivings during record formatting
Co-authored-by: Paweł Szulc <paul.szulc@gmail.com>
* Do not format when context is present
Co-authored-by: Paweł Szulc <paul.szulc@gmail.com>
* Add case 11 - deriving with DerivingStrategies
* Bugfix: do not remove empty data declarations
Co-authored-by: Paweł Szulc <paul.szulc@gmail.com>
* Update README example with ability to format records
* Add case12 (Point)
* Fix case 12
* Factor out processName
* Apply hlint suggestions
* Extract constructors helper function
* Make 'indent' global
* Remove unused Stylish.records method
* Fix Config formatting in Config.hs
* Extract processConstructor function
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Refactor datas function
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Include comments with AST. Two tests are still failing...
* Fix cases 15 and 16
* Do not format records when comments within
Co-authored-by: Łukasz Gołębiewski <lukasz.golebiewski@gmail.com>
* Clean-up Data.hs
* Refactor Data.hs
Co-authored-by: Pawel Szulc <paul.szulc@gmail.com>
Diffstat (limited to 'README.markdown')
-rw-r--r-- | README.markdown | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/README.markdown b/README.markdown index 870a40c..54451cc 100644 --- a/README.markdown +++ b/README.markdown @@ -56,10 +56,7 @@ import System.Directory (doesFileExist) import qualified Data.Map as M import Data.Map ((!), keys, Map) -data Point = Point - { pointX, pointY :: Double - , pointName :: String - } deriving (Show) +data Point = Point { pointX, pointY :: Double , pointName :: String} deriving (Show) ``` into: |