mirror of
https://github.com/unisonweb/unison.git
synced 2024-09-11 10:35:57 +03:00
OverloadedRecordDot
This commit is contained in:
parent
9253dc9fa1
commit
4319a03e7b
@ -46,6 +46,7 @@ default-extensions:
|
||||
- NamedFieldPuns
|
||||
- NumericUnderscores
|
||||
- OverloadedLabels
|
||||
- OverloadedRecordDot
|
||||
- OverloadedStrings
|
||||
- PatternSynonyms
|
||||
- RankNTypes
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Util.Defns
|
||||
( Defns (..),
|
||||
DefnsF,
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Util.Nametree
|
||||
( -- * Nametree
|
||||
Nametree (..),
|
||||
|
@ -45,6 +45,7 @@ library
|
||||
NamedFieldPuns
|
||||
NumericUnderscores
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
|
@ -183,6 +183,7 @@ default-extensions:
|
||||
- MultiParamTypeClasses
|
||||
- NamedFieldPuns
|
||||
- OverloadedLabels
|
||||
- OverloadedRecordDot
|
||||
- OverloadedStrings
|
||||
- PatternSynonyms
|
||||
- RankNTypes
|
||||
|
@ -1,4 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
{-# LANGUAGE TemplateHaskell #-}
|
||||
|
||||
-- | This module is the primary interface to the Unison typechecker
|
||||
|
@ -1,4 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
{-# LANGUAGE QuantifiedConstraints #-}
|
||||
{-# LANGUAGE RecordWildCards #-}
|
||||
|
||||
|
@ -215,6 +215,7 @@ library
|
||||
MultiParamTypeClasses
|
||||
NamedFieldPuns
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
@ -406,6 +407,7 @@ test-suite parser-typechecker-tests
|
||||
MultiParamTypeClasses
|
||||
NamedFieldPuns
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
|
@ -179,6 +179,7 @@ default-extensions:
|
||||
- NamedFieldPuns
|
||||
- NumericUnderscores
|
||||
- OverloadedLabels
|
||||
- OverloadedRecordDot
|
||||
- OverloadedStrings
|
||||
- PatternSynonyms
|
||||
- RankNTypes
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Codebase.Editor.HandleInput.Merge2
|
||||
( handleMerge,
|
||||
)
|
||||
@ -25,7 +23,6 @@ import U.Codebase.Branch qualified as V2.Branch
|
||||
import U.Codebase.Causal qualified as V2.Causal
|
||||
import U.Codebase.Reference (Reference, TermReferenceId, TypeReference, TypeReferenceId)
|
||||
import U.Codebase.Referent qualified as V2 (Referent)
|
||||
import U.Codebase.Sqlite.DbId (ProjectId)
|
||||
import U.Codebase.Sqlite.Operations qualified as Operations
|
||||
import U.Codebase.Sqlite.Project (Project (..))
|
||||
import U.Codebase.Sqlite.ProjectBranch (ProjectBranch (..))
|
||||
@ -715,12 +712,9 @@ defnsToNames defns =
|
||||
theMergeFailed :: MergeInfo -> Pretty ColorText -> Branch0 IO -> Cli ()
|
||||
theMergeFailed mergeInfo prettyUnisonFile newBranch = do
|
||||
Cli.Env {writeSource} <- ask
|
||||
let currentProjectId = mergeInfo.project.projectId
|
||||
let targetBranchName = mergeInfo.projectBranches.bob.name
|
||||
let selfBranchName = mergeInfo.projectBranches.alice.name
|
||||
-- Small race condition: since picking a branch name and creating the branch happen in different
|
||||
-- transactions, creating could fail.
|
||||
temporaryBranchName <- Cli.runTransaction (findTemporaryBranchName currentProjectId targetBranchName selfBranchName)
|
||||
temporaryBranchName <- Cli.runTransaction (findTemporaryBranchName mergeInfo)
|
||||
_temporaryBranchId <-
|
||||
HandleInput.Branch.doCreateBranch'
|
||||
-- FIXME the branch we put the user on after a failed merge should be 1 causal step past the branch they came from
|
||||
@ -740,17 +734,18 @@ theMergeFailed mergeInfo prettyUnisonFile newBranch = do
|
||||
(aliceProjectAndBranchName mergeInfo)
|
||||
(bobProjectAndBranchName mergeInfo)
|
||||
|
||||
findTemporaryBranchName :: ProjectId -> ProjectBranchName -> ProjectBranchName -> Transaction ProjectBranchName
|
||||
findTemporaryBranchName projectId other self = do
|
||||
Cli.findTemporaryBranchName projectId preferred
|
||||
findTemporaryBranchName :: MergeInfo -> Transaction ProjectBranchName
|
||||
findTemporaryBranchName info = do
|
||||
-- let currentProjectId = mergeInfo.project.projectId
|
||||
Cli.findTemporaryBranchName info.project.projectId preferred
|
||||
where
|
||||
preferred :: ProjectBranchName
|
||||
preferred =
|
||||
unsafeFrom @Text $
|
||||
"merge-"
|
||||
<> into @Text other
|
||||
<> into @Text info.projectBranches.bob.name
|
||||
<> "-into-"
|
||||
<> into @Text self
|
||||
<> into @Text info.projectBranches.alice.name
|
||||
|
||||
-- Load namespace info into memory.
|
||||
--
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Codebase.Editor.HandleInput.Update2
|
||||
( handleUpdate2,
|
||||
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Codebase.Editor.HandleInput.Upgrade
|
||||
( handleUpgrade,
|
||||
)
|
||||
|
@ -166,6 +166,7 @@ library
|
||||
NamedFieldPuns
|
||||
NumericUnderscores
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
@ -305,6 +306,7 @@ executable transcripts
|
||||
NamedFieldPuns
|
||||
NumericUnderscores
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
@ -452,6 +454,7 @@ test-suite cli-tests
|
||||
NamedFieldPuns
|
||||
NumericUnderscores
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
|
@ -76,6 +76,7 @@ default-extensions:
|
||||
- NamedFieldPuns
|
||||
- NumericUnderscores
|
||||
- OverloadedLabels
|
||||
- OverloadedRecordDot
|
||||
- OverloadedStrings
|
||||
- PatternSynonyms
|
||||
- RankNTypes
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
-- | Combine two diffs together.
|
||||
module Unison.Merge.CombineDiffs
|
||||
( CombinedDiffOp (..),
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
-- | The "decl coherency check": a type declaration in a namespace is "coherent" if it satisfies both of the following
|
||||
-- criteria.
|
||||
--
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Merge.Diff
|
||||
( nameBasedNamespaceDiff,
|
||||
)
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
-- | An API for merging together two collections of library dependencies.
|
||||
module Unison.Merge.Libdeps
|
||||
( mergeLibdeps,
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Merge.PartitionCombinedDiffs
|
||||
( partitionCombinedDiffs,
|
||||
)
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Merge.TwoDiffOps
|
||||
( TwoDiffOps (..),
|
||||
make,
|
||||
|
@ -1,5 +1,3 @@
|
||||
{-# LANGUAGE OverloadedRecordDot #-}
|
||||
|
||||
module Unison.Merge.Unconflicts
|
||||
( Unconflicts (..),
|
||||
empty,
|
||||
|
@ -65,6 +65,7 @@ library
|
||||
NamedFieldPuns
|
||||
NumericUnderscores
|
||||
OverloadedLabels
|
||||
OverloadedRecordDot
|
||||
OverloadedStrings
|
||||
PatternSynonyms
|
||||
RankNTypes
|
||||
|
Loading…
Reference in New Issue
Block a user