Siddharth Angrish wrote: > Hi > > is tool declaration in Eclipse same as meta_predicate declaration in > other prologs like swi/sicstus/yap? > That is, > does the statement -> :- meta_predicate ltime(?,:). > valid in swi, etc > > mean the same in Eclipse as -> > :- tool( ltime/2 , ltime/3). > > Thanks > Siddharth > > _______________________________________________ > ECLiPSe-Users mailing list > ECLiPSe-Users_at_...2... > http://www.crosscoreop.com/mailman/listinfo/eclipse-users > The tool declaration is used to provide some similar functionality as meta_predicate for SICStus/YAP (SWI's meta_predicate is really for compatibility with SICStus), but they are not the same, because of differences in the module systems. In addition, the way the functionality is implemented is also different, for example, there is no concept that a particular argument is a goal argument in tool/2, but rather you (the programmer) are given the caller module which you can use explicitly. [and normally as a context module, i.e. using _at_/2, which is not very well distinguished in the SICStus (actually Quintus) style module systems] So you may need to use tool/2 as part of your replacement for meta_predicate, but it will probably involve other rewriting of the actual code as well. Cheers, KishReceived on Tue May 01 2007 - 17:26:51 CEST
This archive was generated by hypermail 2.3.0 : Wed Sep 25 2024 - 15:13:20 CEST