"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "libs/types-common/src/Data/Qualified.hs" between
wire-server-2020-06-10.tar.gz and wire-server-2020-06-19.tar.gz

About: Wire (server) offers end-to-end encrypted messaging, file-sharing, video and voice calls, and guest rooms for external communication (back-end server).

Qualified.hs  (wire-server-2020-06-10):Qualified.hs  (wire-server-2020-06-19)
skipping to change at line 95 skipping to change at line 95
instance FromByteString (OptionallyQualified Handle) where instance FromByteString (OptionallyQualified Handle) where
parser = optionallyQualifiedParser (parser @Handle) parser = optionallyQualifiedParser (parser @Handle)
---------------------------------------------------------------------- ----------------------------------------------------------------------
-- QUALIFIED -- QUALIFIED
data Qualified a = Qualified data Qualified a = Qualified
{ _qLocalPart :: a, { _qLocalPart :: a,
_qDomain :: Domain _qDomain :: Domain
} }
deriving (Eq, Show, Generic) deriving stock (Eq, Ord, Show, Generic)
renderQualified :: (a -> Text) -> Qualified a -> Text renderQualified :: (a -> Text) -> Qualified a -> Text
renderQualified renderLocal (Qualified localPart domain) = renderQualified renderLocal (Qualified localPart domain) =
renderLocal localPart <> "@" <> domainText domain renderLocal localPart <> "@" <> domainText domain
qualifiedParser :: Atto.Parser a -> Atto.Parser (Qualified a) qualifiedParser :: Atto.Parser a -> Atto.Parser (Qualified a)
qualifiedParser localParser = qualifiedParser localParser =
Qualified <$> localParser <*> (Atto.char '@' *> parser @Domain) Qualified <$> localParser <*> (Atto.char '@' *> parser @Domain)
---------------------------------------------------------------------- ----------------------------------------------------------------------
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)