Mercurial > repos > rhope
changeset 117:4d089503fb51
Performance optimization
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Thu, 14 Oct 2010 22:37:20 -0400 |
parents | 60906f8803ef |
children | b3f56e1d54a0 |
files | nworker_c.rhope |
diffstat | 1 files changed, 11 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/nworker_c.rhope Wed Oct 13 02:51:56 2010 -0400 +++ b/nworker_c.rhope Thu Oct 14 22:37:20 2010 -0400 @@ -39,7 +39,9 @@ }{ [cond]Empty? { - out <- [set]Subsets <<[ [[set]Subsets>>]Set[[cond]To String, cond] ] + [cond]Simple? + { out <- [set]Variables <<[ Combine[[set]Variables >>, [cond]Variables >>] ] } + { out <- [set]Subsets <<[ [[set]Subsets>>]Set[[cond]To String, cond] ] } }{ out <- set } @@ -94,6 +96,14 @@ } } +Simple?@Condition Set[set:simple,not simple] +{ + ,not simple <- If[[Length[[set]Variables >>]]=[1]] + { + simple,not simple <- If[[Blueprint Of[[set]Subsets >>]]=[Empty Dictionary()]] + } +} + For Backend@Condition Set[set:out,none] { firstvar <- [[set]Variables >>]First