packages feed

ychr-0.1.0.0: test/golden/quoting_around_call/quoting_around_call.chr

:- module(quoting_around_call, [test/1]).

:- chr_constraint test/1.

:- function double/1.
double(N) -> N + N.

% quote/1 keeps the subtree opaque even when its head names a declared
% function: 'R' should bind to the literal term 'double(5)', not to
% the result 10. This exercises 'compileExpr's quote/1 short-circuit
% through 'R.exprToTerm', verifying that a 'CallExpr' inside a quoted
% subtree compiles as a structural compound rather than a runtime
% function call.
test(R) <=> R is quote(double(5)).