Can higher order Prolog help closure expansion?

生来就可爱ヽ(ⅴ<●) 提交于 2021-01-05 07:28:18

问题


If I enter this code in SWI-Prolog:

goal_expansion(println(X), (write(X), nl)).
test :- call(println, 'Hello World!').

Listing shows me this result:

test :-
    call('__aux_wrapper_8a89205eca9a6ffb31dd01cc968a2aa022fa1f49', 'Hello World!').

'__aux_wrapper_8a89205eca9a6ffb31dd01cc968a2aa022fa1f49'(A) :-
    write(A),
    nl.

Would a higher order Prolog do the same? Are there higher order
Prologs that have goal expansion and/or closure expansion?

来源:https://stackoverflow.com/questions/65289298/can-higher-order-prolog-help-closure-expansion

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!