Re: [Gambas-user] Request for comments about a language change

2014-05-31 Thread B Bruen
The only possible problem I can think of is where the enumerated set "becomes" null during the iteration. But quick testing shows that the iteration is done on a copy of the set as at when the For Each is first entered. On the other hand, you might want the enumeration to "automatically end" in

Re: [Gambas-user] Request for comments about a language change

2014-05-31 Thread Jussi Lahtinen
Oh, of course all enumerable classes, I was thinking command ENUM... I try to think whether there could be situation where this would hide error in code. If for some error you pass Null object to this: Public Function CountLargeObjects(hArrayOfObjects As Object[]) As Integer Dim hObject As Obje

Re: [Gambas-user] Request for comments about a language change

2014-05-31 Thread B Bruen
> On Sat, May 31, 2014 at 2:38 PM, Benoît Minisini < > gam...@users.sourceforge.net> wrote: > > > Hi people, > > > > Does anybody have an objection against the following change: > > > > "For Each Value In Enumeration" raise an error if `Enumeration` is NULL. > > > > I suggest that instead it does

Re: [Gambas-user] Request for comments about a language change

2014-05-31 Thread Jussi Lahtinen
Maybe I'm missing something, but why there would be empty enums? I use it only to declare constants. So, at least I can't see any problems from this. Jussi On Sat, May 31, 2014 at 2:38 PM, Benoît Minisini < gam...@users.sourceforge.net> wrote: > Hi people, > > Does anybody have an objection ag

[Gambas-user] Request for comments about a language change

2014-05-31 Thread Benoît Minisini
Hi people, Does anybody have an objection against the following change: "For Each Value In Enumeration" raise an error if `Enumeration` is NULL. I suggest that instead it does nothing, as if Enumeration was a void array. What do you think? -- Benoît Minisini -