Mercurial > hg > octave-nkf
annotate libinterp/octave-value/ov-fcn-inline.h @ 15195:2fc554ffbc28
split libinterp from src
* libinterp: New directory. Move all files from src directory here
except Makefile.am, main.cc, main-cli.cc, mkoctfile.in.cc,
mkoctfilr.in.sh, octave-config.in.cc, octave-config.in.sh.
* libinterp/Makefile.am: New file, extracted from src/Makefile.am.
* src/Makefile.am: Delete everything except targets and definitions
needed to build and link main and utility programs.
* Makefile.am (SUBDIRS): Include libinterp in the list.
* autogen.sh: Run config-module.sh in libinterp/dldfcn directory, not
src/dldfcn directory.
* configure.ac (AC_CONFIG_SRCDIR): Use libinterp/octave.cc, not
src/octave.cc.
(DL_LDFLAGS, LIBOCTINTERP): Use libinterp, not src.
(AC_CONFIG_FILES): Include libinterp/Makefile in the list.
* find-docstring-files.sh: Look in libinterp, not src.
* gui/src/Makefile.am (liboctgui_la_CPPFLAGS): Find header files in
libinterp, not src.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sat, 18 Aug 2012 16:23:39 -0400 |
parents | src/octave-value/ov-fcn-inline.h@46b19589b593 |
children | d63878346099 |
rev | line source |
---|---|
4933 | 1 /* |
2 | |
14138
72c96de7a403
maint: update copyright notices for 2012
John W. Eaton <jwe@octave.org>
parents:
11586
diff
changeset
|
3 Copyright (C) 2004-2012 David Bateman |
4933 | 4 |
7016 | 5 This file is part of Octave. |
4933 | 6 |
7016 | 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 | |
9 Free Software Foundation; either version 3 of the License, or (at your | |
10 option) any later version. | |
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. | |
4933 | 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/>. | |
4933 | 20 |
21 */ | |
22 | |
23 #if !defined (octave_fcn_inline_h) | |
24 #define octave_fcn_inline_h 1 | |
25 | |
8950
d865363208d6
include <iosfwd> instead of <iostream> in header files
John W. Eaton <jwe@octave.org>
parents:
8920
diff
changeset
|
26 #include <iosfwd> |
4933 | 27 #include <string> |
28 | |
29 #include "oct-alloc.h" | |
30 | |
31 #include "ov-base.h" | |
32 #include "ov-base-mat.h" | |
33 #include "ov-fcn.h" | |
34 #include "ov-typeinfo.h" | |
35 #include "symtab.h" | |
36 #include "ov-fcn-handle.h" | |
37 | |
38 // Inline functions. | |
39 | |
40 class | |
7867
f6fffa74b9b5
Export additional symbols: octave_fcn_inline, octave_fcn_handle, read_binary_data, save_binary_data.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
7017
diff
changeset
|
41 OCTINTERP_API |
4933 | 42 octave_fcn_inline : public octave_fcn_handle |
43 { | |
44 public: | |
45 | |
46 octave_fcn_inline (void) | |
4967 | 47 : octave_fcn_handle (), iftext (), ifargs () { } |
4933 | 48 |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
49 octave_fcn_inline (const std::string& f, const string_vector& a, |
10313 | 50 const std::string& n = std::string ()); |
4933 | 51 |
4967 | 52 octave_fcn_inline (const octave_fcn_inline& fi) |
53 : octave_fcn_handle (fi), iftext (fi.iftext), ifargs (fi.ifargs) { } | |
54 | |
4933 | 55 ~octave_fcn_inline (void) { } |
56 | |
5759 | 57 octave_base_value *clone (void) const { return new octave_fcn_inline (*this); } |
58 octave_base_value *empty_clone (void) const { return new octave_fcn_inline (); } | |
4967 | 59 |
4954 | 60 bool is_inline_function (void) const { return true; } |
61 | |
4933 | 62 octave_fcn_inline *fcn_inline_value (bool = false) { return this; } |
63 | |
64 std::string fcn_text (void) const { return iftext; } | |
65 | |
66 string_vector fcn_arg_names (void) const { return ifargs; } | |
67 | |
5279 | 68 octave_value convert_to_str_internal (bool, bool, char) const; |
4933 | 69 |
10742
604e13a89c7f
initial code for structs rewrite
Jaroslav Hajek <highegg@gmail.com>
parents:
10313
diff
changeset
|
70 octave_map map_value (void) const; |
6625 | 71 |
6974 | 72 bool save_ascii (std::ostream& os); |
4972 | 73 |
74 bool load_ascii (std::istream& is); | |
75 | |
76 bool save_binary (std::ostream& os, bool& save_as_floats); | |
77 | |
11586
12df7854fa7c
strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
78 bool load_binary (std::istream& is, bool swap, |
10313 | 79 oct_mach_info::float_format fmt); |
4972 | 80 |
81 #if defined (HAVE_HDF5) | |
82 bool save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats); | |
83 | |
9881
b3089dba88bf
Remove HDF5 cruft for older versions of HDF5
Kacper Kowalik
parents:
8950
diff
changeset
|
84 bool load_hdf5 (hid_t loc_id, const char *name); |
4972 | 85 #endif |
86 | |
4933 | 87 void print (std::ostream& os, bool pr_as_read_syntax = false) const; |
88 | |
89 void print_raw (std::ostream& os, bool pr_as_read_syntax = false) const; | |
90 | |
91 private: | |
92 | |
93 DECLARE_OCTAVE_ALLOCATOR | |
94 | |
95 DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA | |
96 | |
97 // The expression of an inline function. | |
98 std::string iftext; | |
99 | |
100 // The args of an inline function. | |
101 string_vector ifargs; | |
102 }; | |
103 | |
104 #endif |