mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-11 16:06:09 +02:00
* Don't include ShortString constants into resourcestring reference table, because current design allows RTL to handle only a single string type.
git-svn-id: trunk@19038 -
This commit is contained in:
parent
fcc56d271a
commit
a9515e9446
@ -695,11 +695,16 @@ implementation
|
||||
hsym:=tconstsym(tloadnode(n).symtableentry);
|
||||
strval:=pchar(hsym.value.valueptr);
|
||||
strlength:=hsym.value.len;
|
||||
{ Link the string constant to its initializing resourcestring,
|
||||
enabling it to be (re)translated at runtime.
|
||||
{ Delphi-compatible (mis)feature:
|
||||
Link AnsiString constants to their initializing resourcestring,
|
||||
enabling them to be (re)translated at runtime.
|
||||
Wide/UnicodeString are currently rejected above (with incorrect error message).
|
||||
ShortStrings cannot be handled unless another table is built for them;
|
||||
considering this acceptable, because Delphi rejects them altogether.
|
||||
}
|
||||
if (hr.origsym.owner.symtablelevel<=main_program_level) or
|
||||
(hr.origblock=bt_const) then
|
||||
if (not is_shortstring(def)) and
|
||||
((hr.origsym.owner.symtablelevel<=main_program_level) or
|
||||
(hr.origblock=bt_const)) then
|
||||
begin
|
||||
current_asmdata.ResStrInits.Concat(
|
||||
TTCInitItem.Create(hr.origsym,hr.offset,
|
||||
|
Loading…
Reference in New Issue
Block a user