Hi Aditya, I guess you will need to free it?
пн, 28 мая 2018 г., 7:19 aditya siram <[email protected]>: > Hi, > I have the following simplified version of assiging to a stack variable > and am getting the following error: > > "linear component of the following type is abandoned: > [S2Eapp(S2Ecst(option_vt0ype_bool_vtype); S2Eapp(S2Ecst(g0int_t0ype); [1]), > S2Evar(b$8622$8623(14297)))]" > > I searched around and the only reference I see to this error is about > using a global variable in a function scope. > > Any help is appreciated. > > Thanks! > -deech > extern fun add1( > n : Option_vt(int) > ) : Option_vt(int) > > implement add1(n) = > let > fun add1_( n:Option_vt(int), res: &Option_vt(int) >> Option_vt(int) ) > : void = > case+ n of > | ~Some_vt(i) => res := Some_vt(i+1) > | ~None_vt() => () > var res : Option_vt(int) = None_vt() > val () = add1_(n,res) > in > res > end > > > -- > You received this message because you are subscribed to the Google Groups > "ats-lang-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/ats-lang-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ats-lang-users/e51eb3bb-a5cb-4615-a87b-f2aa275fc5a4%40googlegroups.com > <https://groups.google.com/d/msgid/ats-lang-users/e51eb3bb-a5cb-4615-a87b-f2aa275fc5a4%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "ats-lang-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/ats-lang-users. To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/CAKO6%3DqjaTmndR5MJbXrsnA1iv15f9KUuAONqQqOG1kJ03aqYAQ%40mail.gmail.com.
