public type Post = {
pid : Nat32; // Post Id
uid : Nat32; // Speaker's User Id
ppid : Nat32; // Parent Post Id
xid : Nat32; // Xchange Id
tid : Nat32; // Thread Id
cid : Nat32; // Conversation Id = Discourse Id = Issue Id = Topic Id, etc.
........................................
};
public type bufferPost = Buffer.Buffer<Post>;
private stable var container : Trie.Trie<Nat32, bufferPost> = Trie.empty();
Above code is giving me error !
variable container is declared stable but has non-stable type
Trie/176<Nat32/12, bufferPost/78>
So, is this due to Buffer , I am using?
Can’t we declare a Trie stable which is using buffer as its Value?
I am using Buffer to get some optimisation instead of using arrays.
To get rid of above error , only way possible is to use arrays?