[fpc-pascal]Strange Segfault...

James Mills prologic at daisy.ods.org
Thu Jul 10 18:36:37 CEST 2003


On Thu, Jul 10, 2003 at 05:25:21PM +0100, Matt Emson wrote:
> > > procedure replace(search: String; replace: String; var s: String);
> > > procedure replace(const chars: array of char; replace: String; var s:
> String);
> >
> > A string, or a array of char?
> 
> James, this (as Marco put it) was exactly what I had in mind. The compiler
> will have to make a decision, and as a string is implicitly and array of
> sorts, you most likely get this error.
> 
> If you had tried my advice,  you would have realised this was the case quite
> quickly. I was going for the school of hard knocks version of the answer,
> rather than handing it to you on a plate :P

Well ok thanks Matt, however I kind of already had this figured out, but
was posting here to find out if there's a way around it (other than
naming two separate functions)...

Perhaps there isn't...

cheers
James

> 
> Matt
> 
> 
> 
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal

-- 
-
- James Mills
Zero Defect Software Engineers Group - ZDSEG




More information about the fpc-pascal mailing list