Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2023-09

Issue #39746 fpwidestring case conversion string too long

2 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Tony Whyman

This issue seems to be still open after one year. There was a proposed fix: https://gitlab.com/freepascal.org/fpc/source/-/merge_requests/158. However the discussion seems to tail off without an obvious resolution.

This is a clear bug in fpwidestring and needs to be fixed. What is the status?

A workaround using the Trim function seems to work (e.g. Trim(AnsiUpperCase(s))) - I am just not sure if it works all the time.

Tony

Michael Van Canneyt
to Tony Whyman
Tony Whyman wrote 6 lines
This issue seems to be still open after one year. There was a proposed fix: https://gitlab.com/freepascal.org/fpc/source/-/merge_requests/158. However the discussion seems to tail off without an obvious resolution. This is a clear bug in fpwidestring and needs to be fixed. What is the status?
Unresolved, someone needs to take a deep dive into this;
The comments by Florian and Jonas are still unresolved:

- As far as I can see, no testcases are provided.
(a requirement for the compiler)
- I don't see a clear resolution to Jonas' remark that the len is already taking into account the null terminator.

- Unfortunately the branch can no longer be merged as-is, since trunk has evolved too much :/

The patch also mixes various issues: some things in the compiler, some things in the RTL. These should be separated out. I think that is easily doable. I'll look at applying the RTL patches separately next week if no-one did it before. It would help if there was a testcase for the compiler.

Michael.