[Pas2js] Possible feature? keep the original JS overload behavior
Mattias Gaertner
nc-gaertnma at netcologne.de
Fri Dec 21 21:39:13 CET 2018
On Fri, 21 Dec 2018 17:16:58 -0300
silvioprog <silvioprog at gmail.com> wrote:
> On Fri, Dec 21, 2018 at 4:59 PM silvioprog <silvioprog at gmail.com>
> wrote:
>
> > On Fri, Dec 21, 2018 at 4:54 PM Mattias Gaertner via Pas2js <
> > pas2js at lists.freepascal.org> wrote:
> >
> >> On Fri, 21 Dec 2018 20:17:04 +0100 (CET)
> >> Michael Van Canneyt <michael at freepascal.org> wrote:
> >
> >
> Dudes, possible ideas I checked with other friends:
>
> - *nodefaults* - new keyword: it allows to omit the default arguments
> in a single external or assembler function.
The Delphi IDE barks on that. And Lazarus needs to be adapted too.
Maybe better "misuse" a calling convention like stdcall?
> Note: since the 'nodefaults' was defined to 'bar', you can declare
> default params using the short way "a,b: integer = 0" or the verbose
> one "a: integer = 0; b: integer = 0".
The modifier is read *after* parsing the parameter list.
Breaking the rule of one param per default value is a different topic.
Mattias
More information about the Pas2js
mailing list