Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected existence_error message #2740

Open
flexoron opened this issue Jan 2, 2025 · 3 comments
Open

Unexpected existence_error message #2740

flexoron opened this issue Jan 2, 2025 · 3 comments

Comments

@flexoron
Copy link

flexoron commented Jan 2, 2025

$ scryer-prolog -f
?- [user]. t :- (a(1)*a(2)). a(X):-write(X). a(X):-write(X). end_of_file.
?- t.
   error(existence_error(procedure,(*)/2),(*)/2). % Expected

?- [user]. t :- (a(1)*->a(2)). a(X):-write(X). a(X):-write(X). end_of_file.
?- % Prompt unexpected, expecting: % Warning: overwriting t/0 or better % Error: Syntax error: Operator expected
?- t.
   error(existence_error(procedure,(*)/2),(*)/2). % Unexpected
?- halt.

$ scryer-prolog -f
?- [user]. t :- (a(1)*->a(2)). a(X):-write(X). a(X):-write(X). end_of_file.
?- % Prompt unexpected, expecting: Syntax error: Operator expected
?- t.
   error(existence_error(procedure,t/0),t/0). % Unexpected
?-
@hurufu
Copy link
Contributor

hurufu commented Jan 2, 2025

Yes, I would expect error(syntax_error(incomplete_reduction),read_term/3:2) error message.

@flexoron
Copy link
Author

flexoron commented Jan 2, 2025

Is there a reason why no hint appended?
error(syntax_error(incomplete_reduction),read_term/3:2, operator expected

@hurufu
Copy link
Contributor

hurufu commented Jan 2, 2025

No, there is no reason, I just posted minimal message that I would consider "correct" (modulo line number).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants