Change Json Implementation (feature request #14711)
Needs RevisionPublic

Authored by jproyo on Mar 23 2018, 1:34 PM.

Details

Reviewers
bgamari
mpickering
Trac Issues
#14711
Summary

Change Json Implementation (feature request Trac #14711).
I have changed the manual Json building with a copy Cabal's Json implementation

Diff Detail

Repository
rGHC Glasgow Haskell Compiler
Branch
feature-14711
Lint
Lint WarningsExcuse: First 95 chars long is a comment which i consider important because it is the source of this implementaion. Second warning it is the same copy as Cabal's Json Implementation
SeverityLocationCodeMessage
Warningutils/hpc/HpcJson.hs:5TXT3Line Too Long
Warningutils/hpc/HpcJson.hs:171TXT3Line Too Long
Unit
No Unit Test Coverage
Build Status
Buildable 20002
Build 43067: [GHC] Linux/amd64: Continuous Integration
Build 43066: [GHC] OSX/amd64: Continuous Integration
Build 43065: [GHC] Windows/amd64: Continuous Integration
Build 43064: arc lint + arc unit
jproyo created this revision.Mar 23 2018, 1:34 PM
mpickering requested changes to this revision.Mar 23 2018, 6:21 PM
mpickering added a subscriber: mpickering.

You need to use arc diff --update to update differentials rather than creating many news ones I think?

Also, why do you not import the module from Cabal? GHC depends on Cabal so this isn't a problem.

This revision now requires changes to proceed.Mar 23 2018, 6:21 PM

You need to use arc diff --update to update differentials rather than creating many news ones I think?

Also, why do you not import the module from Cabal? GHC depends on Cabal so this isn't a problem.

Sorry for that but i have been following GHC Wiki doc and it doesnt say anything about arc diff --update https://ghc.haskell.org/trac/ghc/wiki/Phabricator

According to what discuss with @alexbiehl in #D4515 wich is the root revision of this, he purposed me to copy Cabal's one. I haven't tried to import Cabal's JSON, but i could give it a try.

BTW, is it ok to depend on Cabal's only for this? Shouldnt it be more suitable to have it is some other place this kind of things and could be imported from different modules? I know that maybe GHC already depends on Cabal and perhaps copy a module it is not the greatest idea, but i am not sure it is a great idea depends on Cabal. I dont know, just thinking aloud.

Best,

According to what discuss with @alexbiehl in #D4515 wich is the root revision of this, he purposed me to copy Cabal's one. I haven't tried to import Cabal's JSON, but i could give it a try.

Actually that JSON module is part of cabal-install (cabal.exe) which GHC _does not_ depend on. So copying is probably the way to go here.