Replies: 3 comments 4 replies
-
Currently, the implementation enumerates all Unicode code points, please have a look at the source code: scryer-prolog/src/lib/charsio.pl Line 155 in 3fa6b69 I think it is well worth thinking about partially evaluating this predicate at compilation or code generation time, especially for those classes of characters where this would significantly reduce the runtime and not significantly increase the compilation time! |
Beta Was this translation helpful? Give feedback.
-
Yep, filed a similar issue here: #2329 |
Beta Was this translation helpful? Give feedback.
-
I think that it is possible to formulate |
Beta Was this translation helpful? Give feedback.
-
While working through some problems, I encountered some strangeness.
I would think that using
charsio:char_type/2
would be the best way to describe a relationship between a character and a set of characters, but when I was working on this problem, usingchar_type(D, decimal_digit)
was unforgivably slow when it came to parsing numbers. Take a look and please replicate for yourself:Considering the amount of Scryer code I've seen that uses
char_type/2
for parsing, this seems a little problematic. I'm wondering if I'm missing something, like a flag I'm supposed to set?Edit: Updated to most recent master commit 3fa6b69
Beta Was this translation helpful? Give feedback.
All reactions