On Thu, Jul 10, 2014 at 3:28 AM, Jonas Maebe <jonas.ma...@elis.ugent.be> wrote:
> > In FPC, this setting only depends on the {$zerobasedstrings on/off} > directive (supported in FPC 2.7.1+). The default is "off" everywhere. You > can also switch it off in Delphi for mobile targets: > http://docwiki.embarcadero.com/RADStudio/XE4/en/Zero-based_strings_(Delphi) > > They probably changed the default there for efficiency reasons (not having > to subtract 1 from string indices all the time). > > Sigh... Making a language target dependent (0-based for "mobile" and 1-based for "desktop") contradicts the concept of high-level language. http://en.wikipedia.org/wiki/High_level_language "In computer science, a high-level programming language is a programming language with strong abstraction from the details of the computer.". It goes as stupid as this: If my computer fits into a palm and/or looks fancy, it's 0-based, otherwise it's 1-based string. To make things worse, it actually has nothing to do with a target computer... but with the language marketing What was the term for it? "High level trend language"? thanks, Dmitry
_______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal