mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-05-05 21:33:43 +02:00

o support for copying value parameters at the callee side if they were passed by reference in hlcg o JVM g_concatcopy() implementation for arrays o moved code to get length of an array from njvminl to hlcgcpu so it can be reused elsewhere as well o export array copy helpers from system unit for use when assigning one array to another o some generic support for types that are normally not implicit pointers, but which are for the JVM target (such as normal arrays) * handle assigning nil to a dynamic array by generating a setlength(x,0) node instead of by hardcoding a call to fpc_dynarray_clear, so target-specific code can handle it if required * hook up gethltemp() for JVM ttgjvm so array temps are properly allocated git-svn-id: branches/jvmbackend@18388 -
55 lines
1.3 KiB
ObjectPascal
55 lines
1.3 KiB
ObjectPascal
{
|
|
Copyright (c) 2011 by Jonas Maebe
|
|
|
|
Generate JVM assembler for nodes that handle loads and assignments
|
|
|
|
This program is free software; you can redistribute it and/or modify
|
|
it under the terms of the GNU General Public License as published by
|
|
the Free Software Foundation; either version 2 of the License, or
|
|
(at your option) any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program; if not, write to the Free Software
|
|
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
|
|
****************************************************************************
|
|
}
|
|
unit njvmld;
|
|
|
|
{$I fpcdefs.inc}
|
|
|
|
interface
|
|
|
|
uses
|
|
node, ncgld;
|
|
|
|
type
|
|
tjvmloadnode = class(tcgloadnode)
|
|
function is_addr_param_load: boolean; override;
|
|
end;
|
|
|
|
implementation
|
|
|
|
uses
|
|
nld,
|
|
symsym,
|
|
jvmdef;
|
|
|
|
function tjvmloadnode.is_addr_param_load: boolean;
|
|
begin
|
|
result:=
|
|
inherited and
|
|
not jvmimplicitpointertype(tparavarsym(symtableentry).vardef);
|
|
end;
|
|
|
|
|
|
begin
|
|
cloadnode:=tjvmloadnode;
|
|
end.
|
|
|