Re: [fpc-pascal] assigning ansistring with shortstring

2006-05-27 Thread L505
> On 27 May 2006, at 09:46, Arne Hanssen wrote: > > >> setlength(last3, 3); > >> last3[1]:= filename[length(filename)-2]; > >> last3[2]:= filename[length(filename)-1]; > >> last3[3]:= filename[length(filename)]; > > > > As already explained, you must tell 'last3' its length. As you > > al

Re: [fpc-pascal] Trim repeated whitespace from a string

2006-05-27 Thread Graeme Geldenhuys
Hi, On 5/27/06, Michael Van Canneyt <[EMAIL PROTECTED]> wrote: Use Trim from sysutils and then DelSpace1 from strutils. http://www.freepascal.org/docs-html/rtl/strutils/delspace1.html It might be a good idea to look at http://www.freepascal.org/docs-html/rtl/strutils/index-5.html Just so yo

Re: [fpc-pascal] Trim repeated whitespace from a string

2006-05-27 Thread Michael Van Canneyt
On Fri, 26 May 2006, Graeme Geldenhuys wrote: > Hi, Anybody know of a function that can remove (normalize) a string by remove all beginning and ending whitespace as well as replace all repeated spaces with a single space. A bonus would be to remove tabs and newlines chars as well, but that is

Re: [fpc-pascal] rotating bits

2006-05-27 Thread Bisma Jayadi
I agree with Michael. And I think the line is clearly drawn. The FPC (and more importantly the language syntax itself) design goal, as I understand it, is to be, as much as possible, platform and architecture independent and I believe the bit rotation support can be made platform and architec

Re: [fpc-pascal] rotating bits

2006-05-27 Thread Florian Klaempfl
[EMAIL PROTECTED] wrote: > >> Michael Van Canneyt wrote: > >>Well, if we're going in that direction anyway: >>Why not include all possible assembler instructions then ? >> >>Let's be serious. You must draw the line somewhere. >>I think these instructions are so exotic, they are pollution of the >

Re: [fpc-pascal] assigning ansistring with shortstring

2006-05-27 Thread Jonas Maebe
On 27 May 2006, at 09:46, Arne Hanssen wrote: setlength(last3, 3); last3[1]:= filename[length(filename)-2]; last3[2]:= filename[length(filename)-1]; last3[3]:= filename[length(filename)]; As already explained, you must tell 'last3' its length. As you already are using a somewhat "

Re: [fpc-pascal] unit name with dots

2006-05-27 Thread mariano podesta
None of the FPC developers currently has the time nor wish to supportany of the .NET enhancements, and that includes the dot in the unit names.despite it was originally intended for .net, i don't see it as a .net specific enhancement, but it's ok. i appreciate your answer. Michael.marianop

Re: [fpc-pascal] unit name with dots

2006-05-27 Thread mariano podesta
We don't support every bug/strange thing delphi supports.ok, i understand your point. in my very humble opinion it was an interesting idea.If you want to insult people you might do it somewhere else. Thank you. it was a joke. not aiming to offend anybody.thanks,marianop

Re: [fpc-pascal] assigning ansistring with shortstring

2006-05-27 Thread Arne Hanssen
L505 wrote: > I'm lacking some memory concept here. Below program doesn't work unless > setlengths > are called first on the shortstrings. > > setlength(last3, 3); > last3[1]:= filename[length(filename)-2]; > last3[2]:= filename[length(filename)-1]; > last3[3]:= filename[length(filename)]

Re: [fpc-pascal] rotating bits

2006-05-27 Thread DSTRODT
> Michael Van Canneyt wrote:>Well, if we're going in that direction anyway: >Why not include all possible assembler instructions then ?>>Let's be serious. You must draw the line somewhere.>I think these instructions are so exotic, they are pollution of the system unit.   I agree with Micha