Verified Commit 54dc4e36 authored by Camil Staps's avatar Camil Staps 🚀

Remove System._Posix dependency

parent 7ac3b5d9
......@@ -16,7 +16,6 @@ import System.CommandLine
import System.File
import System.FilePath
import System._Pointer
import System._Posix
import graph_copy_with_names
import symbols_in_program
......@@ -270,3 +269,8 @@ where
readString f
# (_,size,f) = freadi f
= freads f size
malloc :: !Int -> Pointer
malloc _ = code {
ccall malloc "I:p"
}
......@@ -9,7 +9,6 @@ import StdList
import Data._Array
import Data.Maybe
import System._Pointer
import System._Posix
import symbols_in_program
......@@ -92,3 +91,13 @@ free_to_false :: !Pointer -> Bool
free_to_false p
# n = free p
= n == 0 && n <> 0
malloc :: !Int -> Pointer
malloc _ = code {
ccall malloc "I:p"
}
free :: !Pointer -> Int
free _ = code {
ccall free "p:I"
}
......@@ -16,7 +16,6 @@ import Data.Maybe
import System.CommandLine
import System.File
import System._Pointer
import System._Posix
import Text
import symbols_in_program
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment