Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-22 Thread Graeme Geldenhuys
On 2016-06-22 18:18, Dennis Poon wrote: > can we do it in descending order without a user defined enumerator? Not as far as I know - I believe it is a one directional iterator (or so the interface suggests). There are tons of limitations with the for..in construct. Years back I implemented an

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-22 Thread Dennis Poon
I saw your document on for x in ListX loop and would like to reconfirm that it is always iterated in ascending order, right? can we do it in descending order without a user defined enumerator? i.e. for simple enumerated type, is there a construct to iterate through it in descending order?

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Jürgen Hestermann
Am 2016-06-21 um 17:16 schrieb Sven Barth: > It was decided some time ago when mode Delphi was switched to H+ (due to Delphi compatibility) that mode ObjFPC won't be switched, cause for that mode we value backwards compatibility higher than the user not having to write a switch. This is quite

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Sven Barth
Am 21.06.2016 15:21 schrieb "Michalis Kamburelis" : > > 2016-06-21 15:03 GMT+02:00 Sven Barth : > > Am 21.06.2016 12:31 schrieb "Michalis Kamburelis" > > : > >> Current FPC defaults: > >> > >> - Help people who

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Michalis Kamburelis
2016-06-21 15:03 GMT+02:00 Sven Barth : > Am 21.06.2016 12:31 schrieb "Michalis Kamburelis" > : >> Current FPC defaults: >> >> - Help people who except the {$mode fpc} to be default (so they write >> code without classes and a lot of other new

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Sven Barth
Am 21.06.2016 12:31 schrieb "Michalis Kamburelis" : > Current FPC defaults: > > - Help people who except the {$mode fpc} to be default (so they write > code without classes and a lot of other new features), > - Or people who expect that string is by default ShortString

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Michalis Kamburelis
>> I even expect a bit further. These {$MODE OBJFPC}, {$H+}, and {$J-} >> directives should be the *default* directives for every new FPC >> programs/units. We're now using Free Pascal compiler on 2016. Why do we need >> to explicitly declare Free Pascal mode in a Free Pascal program? In 21st >>

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Karoly Balogh (Charlie/SGR)
Hi, On Tue, 21 Jun 2016, Mr Bee wrote: > > Maybe a little bit offtopic, but I have a question regarding the > >compiler directives: is there a way to tell Lazarus to use these > >directives in every new unit? No clue about Lazarus, but one can put -mOBJFPC in his compiler config file (same with

Re: [fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Sven Barth
Am 21.06.2016 08:58 schrieb "Mr Bee" : > > > Maybe a little bit offtopic, but I have a question regarding the compiler directives: is there a way to tell Lazarus to use these directives in every new unit? > > I even expect a bit further. These {$MODE OBJFPC}, {$H+}, and {$J-}

[fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Mr Bee
> Maybe a little bit offtopic, but I have a question regarding the compiler >directives: is there a way to tell Lazarus to use these directives in every >new unit? I even expect a bit further. These {$MODE OBJFPC}, {$H+}, and {$J-} >directives should be the *default* directives for every new

[fpc-pascal] Bls: Bls: Quick Modern Object Pascal Introduction, for Programmers

2016-06-21 Thread Mr Bee
> I definitely *do not want* to explain to any new programmer what a "writeable >constant" is... This concept should remain buried :) Exactly! I also don't >understand why the {$MODE OBJFPC} uses the {$J+} as the default. :) –Mr Bee Pada Selasa, 21 Juni 2016 12:47, Michalis Kamburelis