mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-10-21 02:21:42 +02:00
* allow the varargs directive in combination with stdcall as well, resolves #27299
git-svn-id: trunk@29496 -
This commit is contained in:
parent
681c1afe6c
commit
d25dbec070
@ -977,10 +977,10 @@ parser_w_skipped_fields_after=03177_W_Some fields coming after "$1" were not ini
|
||||
% You can leave some fields at the end of a type constant record uninitialized
|
||||
% (The compiler will initialize them to zero automatically). This may be the cause
|
||||
% of subtle problems.
|
||||
parser_e_varargs_need_cdecl_and_external=03178_E_VarArgs directive (or '...' in MacPas) without CDecl/CPPDecl/MWPascal and External
|
||||
parser_e_varargs_need_cdecl_and_external=03178_E_VarArgs directive (or '...' in MacPas) without CDecl/CPPDecl/MWPascal/StdCall and External
|
||||
% The varargs directive (or the ``...'' varargs parameter in MacPas mode) can only be
|
||||
% used with procedures or functions that are declared with \var{external} and one of
|
||||
% \var{cdecl}, \var{cppdecl} and \var{mwpascal}. This functionality
|
||||
% \var{cdecl}, \var{cppdecl}, \var{stdcall} and \var{mwpascal}. This functionality
|
||||
% is only supported to provide a compatible interface to C functions like printf.
|
||||
parser_e_self_call_by_value=03179_E_Self must be a normal (call-by-value) parameter
|
||||
% You cannot declare \var{Self} as a const or var parameter, it must always be
|
||||
|
@ -1003,7 +1003,7 @@ const
|
||||
option_info=11024;
|
||||
option_help_pages=11025;
|
||||
|
||||
MsgTxtSize = 74679;
|
||||
MsgTxtSize = 74687;
|
||||
|
||||
MsgIdxMax : array[1..20] of longint=(
|
||||
26,99,340,123,95,57,126,29,202,64,
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1134,7 +1134,7 @@ implementation
|
||||
end;
|
||||
single_type(pd.returndef,[stoAllowSpecialization]);
|
||||
|
||||
// Issue #24863, commented out for now because it breaks building of RTL and needs extensive
|
||||
// Issue #24863, enabled only for the main progra commented out for now because it breaks building of RTL and needs extensive
|
||||
// testing and/or RTL patching.
|
||||
{
|
||||
if ((pd.returndef=cvarianttype) or (pd.returndef=colevarianttype)) and
|
||||
@ -2487,7 +2487,7 @@ const
|
||||
handler : nil;
|
||||
pocall : pocall_none;
|
||||
pooption : [po_varargs];
|
||||
mutexclpocall : [pocall_internproc,pocall_stdcall,pocall_register,
|
||||
mutexclpocall : [pocall_internproc,pocall_register,
|
||||
pocall_far16,pocall_oldfpccall,pocall_mwpascal];
|
||||
mutexclpotype : [];
|
||||
mutexclpo : [po_assembler,po_interrupt,po_inline]
|
||||
@ -2920,7 +2920,7 @@ const
|
||||
{ for objcclasses this is checked later, because the entire
|
||||
class may be external. }
|
||||
is_objc_class_or_protocol(tprocdef(pd).struct)) and
|
||||
not(pd.proccalloption in (cdecl_pocalls + [pocall_mwpascal])) then
|
||||
not(pd.proccalloption in (cdecl_pocalls + [pocall_mwpascal,pocall_stdcall])) then
|
||||
Message(parser_e_varargs_need_cdecl_and_external);
|
||||
end
|
||||
else
|
||||
@ -2928,7 +2928,7 @@ const
|
||||
{ both must be defined now }
|
||||
if not((po_external in pd.procoptions) or
|
||||
(pd.typ=procvardef)) or
|
||||
not(pd.proccalloption in (cdecl_pocalls + [pocall_mwpascal])) then
|
||||
not(pd.proccalloption in (cdecl_pocalls + [pocall_mwpascal,pocall_stdcall])) then
|
||||
Message(parser_e_varargs_need_cdecl_and_external);
|
||||
end;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user