Tree-gel and loop-gel conversions in nonlinear polymerization