ketAdd :: Bucket a -> a -> IO () -> IO (Bucket a)
bucketAdd (Bucket weaks) x finalizer = do
  weak <- mkWeakPtr x (Just finalizer)

newBucket :: a -> IO () -> IO (Bucket a)
newBucket =
  bucketAdd (Bucket [])
newBucket =
  bucketAdd (Bucket [])