Mercurial > hg > octave-nkf
annotate libinterp/corefcn/defun-dld.h @ 20830:b65888ec820e draft default tip gccjit
dmalcom gcc jit import
author | Stefan Mahr <dac922@gmx.de> |
---|---|
date | Fri, 27 Feb 2015 16:59:36 +0100 |
parents | 4197fc428c7d |
children |
rev | line source |
---|---|
525 | 1 /* |
2 | |
19898
4197fc428c7d
maint: Update copyright notices for 2015.
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
3 Copyright (C) 1994-2015 John W. Eaton |
525 | 4 |
5 This file is part of Octave. | |
6 | |
7 Octave is free software; you can redistribute it and/or modify it | |
8 under the terms of the GNU General Public License as published by the | |
7016 | 9 Free Software Foundation; either version 3 of the License, or (at your |
10 option) any later version. | |
525 | 11 |
12 Octave is distributed in the hope that it will be useful, but WITHOUT | |
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
15 for more details. | |
16 | |
17 You should have received a copy of the GNU General Public License | |
7016 | 18 along with Octave; see the file COPYING. If not, see |
19 <http://www.gnu.org/licenses/>. | |
525 | 20 |
21 */ | |
22 | |
23 #if !defined (octave_defun_dld_h) | |
24 #define octave_defun_dld_h 1 | |
25 | |
26 #if defined (octave_defun_h) | |
27 #error defun.h and defun-dld.h both included in same file! | |
28 #endif | |
29 | |
30 #include "defun-int.h" | |
31 | |
550 | 32 // Define a builtin function that may be loaded dynamically at run |
33 // time. | |
34 // | |
35 // If Octave is not configured for dynamic linking of builtin | |
2968 | 36 // functions, this is the same as DEFUN, except that it will generate |
37 // an extra externally visible function. | |
2465 | 38 // |
2968 | 39 // The first DECLARE_FUN is for the benefit of the installer function |
40 // and the second is for the definition of the function. | |
550 | 41 |
2465 | 42 #if defined (MAKE_BUILTINS) |
3295 | 43 |
2465 | 44 #define DEFUN_DLD(name, args_name, nargout_name, doc) \ |
8746
5dd06f19e9be
handle commands in the lexer
John W. Eaton <jwe@octave.org>
parents:
7996
diff
changeset
|
45 DEFUN_DLD_INTERNAL (name, args_name, nargout_name, doc) |
5796 | 46 |
15466
d174210ce1ec
use ' instead of ` in error messages, warnings and most comments
John W. Eaton <jwe@octave.org>
parents:
14138
diff
changeset
|
47 // This one can be used when 'name' cannot be used directly (if it is |
5796 | 48 // already defined as a macro). In that case, name is already a |
49 // quoted string, and the internal name of the function must be passed | |
7996
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
50 // too (the convention is to use a prefix of "F", so "foo" becomes |
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
51 // "Ffoo") as well as the name of the generated installer function |
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
52 // (the convention is to use a prefix of "G", so "foo" becomes "Gfoo"). |
5796 | 53 |
7996
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
54 #define DEFUNX_DLD(name, fname, gname, args_name, nargout_name, doc) \ |
8746
5dd06f19e9be
handle commands in the lexer
John W. Eaton <jwe@octave.org>
parents:
7996
diff
changeset
|
55 DEFUNX_DLD_INTERNAL (name, fname, args_name, nargout_name, doc) |
3295 | 56 |
2465 | 57 #else |
3295 | 58 |
1957 | 59 #define DEFUN_DLD(name, args_name, nargout_name, doc) \ |
15421
cd6ce11b9c57
backout changeset 2e5ba861898f
John W. Eaton <jwe@octave.org>
parents:
15398
diff
changeset
|
60 DECLARE_FUN (name, args_name, nargout_name); \ |
2968 | 61 DEFINE_FUN_INSTALLER_FUN (name, doc) \ |
15421
cd6ce11b9c57
backout changeset 2e5ba861898f
John W. Eaton <jwe@octave.org>
parents:
15398
diff
changeset
|
62 DECLARE_FUN (name, args_name, nargout_name) |
3295 | 63 |
7996
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
64 #define DEFUNX_DLD(name, fname, gname, args_name, nargout_name, doc) \ |
15421
cd6ce11b9c57
backout changeset 2e5ba861898f
John W. Eaton <jwe@octave.org>
parents:
15398
diff
changeset
|
65 DECLARE_FUNX (fname, args_name, nargout_name); \ |
7996
6a7db240b3a3
configure.in: eliminate CXX_ABI and OCTAVE_CXX_PREPEND_UNDERSCORE
John W. Eaton <jwe@octave.org>
parents:
7336
diff
changeset
|
66 DEFINE_FUNX_INSTALLER_FUN (name, fname, gname, doc) \ |
15421
cd6ce11b9c57
backout changeset 2e5ba861898f
John W. Eaton <jwe@octave.org>
parents:
15398
diff
changeset
|
67 DECLARE_FUNX (fname, args_name, nargout_name) |
5796 | 68 |
703 | 69 #endif |
525 | 70 |
71 #endif |