summaryrefslogtreecommitdiff
path: root/weave/inline_tools.py
diff options
context:
space:
mode:
authorEric Jones <eric@enthought.com>2002-01-04 03:40:54 +0000
committerEric Jones <eric@enthought.com>2002-01-04 03:40:54 +0000
commit06d067a4c9382426c8755cdcc39c3ce2ebf38706 (patch)
treec36bc0209a11a26cbe1de4cf1eefd916f2a28633 /weave/inline_tools.py
parentdfa34a79638600346b06aab7d157db855d22a1ba (diff)
downloadnumpy-06d067a4c9382426c8755cdcc39c3ce2ebf38706.tar.gz
changed inline() args so that arg_names defaults to an empty list. THis allows you to run C code that doesn't need any arguments without supplying any.
Diffstat (limited to 'weave/inline_tools.py')
-rw-r--r--weave/inline_tools.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/weave/inline_tools.py b/weave/inline_tools.py
index bebff23d3..bde673afd 100644
--- a/weave/inline_tools.py
+++ b/weave/inline_tools.py
@@ -130,7 +130,7 @@ class inline_ext_module(ext_tools.ext_module):
self._build_information.append(inline_info.inline_info())
function_cache = {}
-def inline(code,arg_names,local_dict = None, global_dict = None,
+def inline(code,arg_names=[],local_dict = None, global_dict = None,
force = 0,
compiler='',
verbose = 0,
@@ -157,8 +157,9 @@ def inline(code,arg_names,local_dict = None, global_dict = None,
code -- string. A string of valid C++ code. It should not specify a
return statement. Instead it should assign results that
need to be returned to Python in the return_val.
- arg_names -- list of strings. A list of Python variable names that
- should be transferred from Python into the C/C++ code.
+ arg_names -- optional. list of strings. A list of Python variable names
+ that should be transferred from Python into the C/C++
+ code. It defaults to an empty string.
local_dict -- optional. dictionary. If specified, it is a dictionary
of values that should be used as the local scope for the
C/C++ code. If local_dict is not specified the local