![](https://secure.gravatar.com/avatar/16d6ad582c31e9dc90dfc0cfd8e2ead6.jpg?s=120&d=mm&r=g)
8 Jun
2008
8 Jun
'08
5:33 p.m.
Hi This code produce a crash on linux with chuck-alsa. Maybe the "logic" is not right but the crash exist. class Foo {} fun void appendCap( Foo arr[], int n ) { Foo @ aux[ arr.cap() + n ]; for( int i; i < arr.cap(); i++ ) { arr[i] @=> aux[i]; } aux @=> arr; } Foo @ vars[5]; for( int i; i < vars.cap(); i++ ) <<< vars[i] >>>; appendCap( vars, 5 ); //<<< vars[4] >>>; <<< vars.cap() >>>; <<< "End" >>>; /* this work fine fun Foo[] append( Foo arr[], int n ) { Foo @ aux[ arr.cap() + n ]; for( int i; i < arr.cap(); i++ ) { arr[i] @=> aux[i]; } return aux; } */ Yours Lucas
6089
Age (days ago)
6089
Last active (days ago)
0 comments
1 participants
participants (1)
-
lucas samaruga