bastikr / boolean.py

Implements boolean algebra in one module.
BSD 2-Clause "Simplified" License
76 stars 34 forks source link

Add sort keyword argument to DualBase simplify() #90

Closed steven-esser closed 4 years ago

steven-esser commented 4 years ago

This commit adds a "sort" keyword argument to the simplify() function of the DualBase class. This allows simplification of boolean algebra expressions to be completed correctly, but does not sort the final expression. This is needed for various applications where maintaining order matters.

Signed-off-by: Steven Esser sesser@nexb.com

steven-esser commented 4 years ago

@pombredanne and @bastikr ping

pombredanne commented 4 years ago

@majurg Thanks! the various applications you mentioned I reckon being https://github.com/nexB/license-expression/ as use in scancode-toolkit and deltacode ;)

This is neat and clean... merging.