Seeker04 / plwm

An X11 window manager written in Prolog
MIT License
1 stars 0 forks source link

List related optimizations with deterministic predicates #18

Open Seeker04 opened 8 months ago

Seeker04 commented 8 months ago

We could replace member/2 calls with memberchk/2 at many places.

There are other ‘chk’variant predicates that can be looked into.

once/1 could also be utilized more, most likely.

These changes would not only slightly optimize for performance, but would also signal the intent that we do not want backtracking for multiple solutions at certain places.