this is a very reasonable workaround. thanks.
On Sun, Feb 2, 2014 at 1:59 PM, Perry R Cook <[email protected]> wrote: > Further research shows that this also fails, > for either fred[10] or fred[]: > > Mandolin bob[10]; > UGen fred[10]; > > bob @=> fred; > > but this works just fine: > > Mandolin bob[10]; > UGen fred[10]; > > 0 => int i; > while (i < bob.cap()) (bob[i]) => fred[i++]; > > So it appears that object array copies require > identical objects and structures, but individual > object assignment is OK via the class structure. > > Maybe Ge/Spencer can pipe in here on the specifics. > > PRC > > ----- Original Message ----- > Not exactly sure why this is failing. > Also tried declaring Blit osc[], but nope. > Here's a fix for now, assigning all elements > individually: > > BlitSquare pls[10]; > BlitSaw saw[10]; > Blit osc[10]; > if (myVariable) { > for (0 => int i; i < pls.cap(); i++) > pls[i] => osc[i]; > } else { > for (0 => int i; i < pls.cap(); i++) > saw[i] => osc[i]; > } > > > 1. how do I assign a Blit array with a BlitSquare array? > (George Locke) > _______________________________________________ > chuck-users mailing list > [email protected] > https://lists.cs.princeton.edu/mailman/listinfo/chuck-users >
_______________________________________________ chuck-users mailing list [email protected] https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
