Some weird preceding printing occurring #15

Closed
opened 2017-03-08 06:25:49 +01:00 by ElvishJerricco · 3 comments
ElvishJerricco commented 2017-03-08 06:25:49 +01:00 (Migrated from github.com)

Simple test case:

-- Test.hs
module Test where

data X = X

Output:

$ brittany Test.hs
["","","data X = X"]
-- Test.hs
module Test where

data X = X

Not sure what that's about...

Simple test case: ```haskell -- Test.hs module Test where data X = X ``` Output: ``` $ brittany Test.hs ["","","data X = X"] -- Test.hs module Test where data X = X ``` Not sure what that's about...
lspitzner commented 2017-03-08 15:01:01 +01:00 (Migrated from github.com)

Thanks. Never noticed, because my default testing ignores stderr. Now I wonder if I can make git warn me when making any commit containing non-commented "trace" strings.. someone must have written such a hook already.

Thanks. Never noticed, because my default testing ignores stderr. Now I wonder if I can make git warn me when making any commit containing non-commented "trace" strings.. someone must have written such a hook already.
tfausak commented 2017-03-08 15:04:25 +01:00 (Migrated from github.com)

You could write your own trace functions and mark them as deprecated like undefined in ClassyPrelude.

You could write your own `trace` functions and mark them as deprecated like [`undefined` in ClassyPrelude](https://www.stackage.org/haddock/lts-8.4/classy-prelude-1.2.0.1/ClassyPrelude.html#v:undefined).
lspitzner commented 2017-03-08 15:26:20 +01:00 (Migrated from github.com)

Yeah that is certainly a better idea than hooks. I'll have to add something along those lines to qualified-prelude.

Yeah that is certainly a better idea than hooks. I'll have to add something along those lines to qualified-prelude.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: hexagoxel/brittany#15
There is no content yet.