users-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: what's the corresponding predcate as atomic_list_concat in swi


From: Sean Charles
Subject: Re: what's the corresponding predcate as atomic_list_concat in swi
Date: Wed, 26 Jun 2013 07:39:53 +0100

Hi z_axis,

I looked long and hard and I couldn't find anything suitably matched in the 
atom and character code sections … sorry.

I think somebody that *knows* the language has an opportunity to hand-roll 
something at this point… I will also try to do this as an exercise, it will be 
good to try.

My initial thought would be to use a stream writing to an atom, then write each 
atom in the original list plus the intervening comma for all but the last atom. 

    open_output_atom_stream ...
    write_term_to_atom  … each list member plus a comma
    close_output_atom_stream ...

Simples. Except I just have to do it. And if it could be used "backwards" to 
split the atom then so much the better, like SWI.

I am sure somebody else will do it first but I like the look of this so I shall 
try as well.

Sean.




On 26 Jun 2013, at 03:15, z_axis <address@hidden> wrote:

> It seems there is just atomic_concat in gprolog ?
> Mime-Version: 1.0
> Content-Type: Text/Plain; charset=iso-8859-7
> Content-Transfer-Encoding: base64
> X-CM-TRANSID:C8CowEApvUUWT8pR28F5Cw--.21S2
> X-Coremail-Antispam: 1Uf129KBjDUn29KB7ZKAUJUUUUU529EdanIXcx71UUUUU7v73
>       VFW2AGmfu7bjvjm3AaLaJ3UbIYCTnIWIevJa73UjIFyTuYvjxU2t8nUUUUU
> X-CM-SenderInfo: x2bd5xrv6rljoofrz/1tbiThZIZlEAFN07UAABsE
> 
> ZV4o8C5pKSArIDEgPSAwDQo=
> 
> 
> _______________________________________________
> Users-prolog mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/users-prolog




reply via email to

[Prev in Thread] Current Thread [Next in Thread]