mirror of
https://github.com/simplex-chat/simplexmq.git
synced 2026-04-01 16:05:55 +00:00
ConsPtr compat for 8.10
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
{-# LANGUAGE CApiFFI #-}
|
||||
{-# LANGUAGE CPP #-}
|
||||
{-# LANGUAGE DataKinds #-}
|
||||
{-# LANGUAGE GADTs #-}
|
||||
{-# LANGUAGE PatternSynonyms #-}
|
||||
{-# LANGUAGE ScopedTypeVariables #-}
|
||||
{-# OPTIONS_GHC -Wno-unrecognised-pragmas #-}
|
||||
|
||||
@@ -10,9 +12,16 @@ module Simplex.Messaging.Crypto.NaCl.Bindings where
|
||||
|
||||
import Data.ByteArray (ScrubbedBytes)
|
||||
import Foreign
|
||||
import Foreign.C.ConstPtr
|
||||
import Foreign.C.Types
|
||||
|
||||
#if MIN_VERSION_base(4,18,0)
|
||||
import Foreign.C.ConstPtr
|
||||
#else
|
||||
type ConstPtr = Ptr
|
||||
pattern ConstPtr :: p -> p
|
||||
pattern ConstPtr p = p
|
||||
#endif
|
||||
|
||||
crypto_box_PUBLICKEYBYTES :: Num a => a
|
||||
crypto_box_PUBLICKEYBYTES = 32
|
||||
|
||||
|
||||
Reference in New Issue
Block a user