PureScript also has a foreign-object library, which effectively just wraps around JS objects in the JS backend. This library is not yet ported to PureNix, but you can imagine it would be straightforward(?) to port. (There is also a library called just foreign that is somewhat related depending on what you're trying to do.)
In cabal2nixWithoutIFD, I implemented my own AttrSet type:
This type of thing would ideally go into some sort of nix-builtins library instead.
There is also ordered-collections, which I believe is more similar to Haskell's Map type, and may be what you're looking for. This library also hasn't been ported to PureNix.
PureScript has built-in extensible records, which might work for you depending on what you're trying to do: https://github.com/purescript/documentation/blob/master/language/Records.md. PureNix compiles PureScript's built-in records to Nix attrsets.
PureScript also has a
foreign-object
library, which effectively just wraps around JS objects in the JS backend. This library is not yet ported to PureNix, but you can imagine it would be straightforward(?) to port. (There is also a library called justforeign
that is somewhat related depending on what you're trying to do.)In
cabal2nixWithoutIFD
, I implemented my ownAttrSet
type:https://github.com/cdepillabout/cabal2nixWithoutIFD/blob/484515bdec2ccf9dfc02b9a442b801bc2d17b9cc/purescript-parser-combinator/src/NixBuiltins.purs#L6-L8
This type of thing would ideally go into some sort of
nix-builtins
library instead.There is also
ordered-collections
, which I believe is more similar to Haskell'sMap
type, and may be what you're looking for. This library also hasn't been ported to PureNix.