I noticed you lost a couple of test cases in v14, so I added them back.
I also added a case where your implementation returns a different number of rows compared to vanilla:
select * from sl t1, sl t2 where t1.a = t2.a and t1.b = 1;
Please see the attached v15.
-- Alexander KuzmenkovPostgres Professional: http://www.postgrespro.comThe Russian Postgres Company