[mercury-users] append for list skeletons

Robert Colvin robert at svrc.uq.edu.au
Tue Jul 31 19:18:24 AEST 2001


Hi, I just wanted to check that I understand the manual - it says that it is
not possible to implement append(in_listskel, in_listskel, out_listskel),
ie where the lists are lists of uninstantiated variables.  Therefore the
naive/inefficient implementation of reverse

rev([], []).
rev([H|T], R) :- 
    append(RT, [H], R), rev(T, RT).

will not be implementable for list skeletons?

Thanks,
Rob

ps.- thanks Robert and Richard for help with natural numbers last week

--------------------------------------------------------------------------
mercury-users mailing list
post:  mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the users mailing list