Re: [fpc-devel] [fpc-pascal] How does TFPGMap key compare work?

2021-04-22 Thread Sven Barth via fpc-devel
Ryan Joseph via fpc-devel schrieb am Fr., 23. Apr. 2021, 00:53: > > > > On Apr 21, 2021, at 11:21 PM, Sven Barth > wrote: > > > > You need to use named types, though for operators this is less useful, > because the compiler will implicitly convert different ShortString types to > find a

Re: [fpc-devel] [fpc-pascal] How does TFPGMap key compare work?

2021-04-22 Thread Ryan Joseph via fpc-devel
> On Apr 21, 2021, at 11:21 PM, Sven Barth wrote: > > You need to use named types, though for operators this is less useful, > because the compiler will implicitly convert different ShortString types to > find a suitable operator overload: Then the compiler must do this for all strings

Re: [fpc-devel] [fpc-pascal] How does TFPGMap key compare work?

2021-04-21 Thread Sven Barth via fpc-devel
Am 21.04.2021 um 20:05 schrieb Ryan Joseph via fpc-devel: On Apr 20, 2021, at 11:38 PM, Sven Barth wrote: All four string types provide built in > and < operators: On a side note how do you even make overloads (or type helpers for that matter) for short strings because String[10] isn't the

Re: [fpc-devel] [fpc-pascal] How does TFPGMap key compare work?

2021-04-21 Thread Ryan Joseph via fpc-devel
> On Apr 20, 2021, at 11:38 PM, Sven Barth wrote: > > All four string types provide built in > and < operators: On a side note how do you even make overloads (or type helpers for that matter) for short strings because String[10] isn't the same type as String[100]? Regards, Ryan