Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
5.3.0 - 日本語

Change language to:
English - Français - Português

Please note that the recommended version of Scilab is 2024.0.0. This page might be outdated.
See the recommended documentation of this function

Scilab manual >> Scilab > funptr

funptr

プリミティブのコーディング ( 上級者向け )

呼出し手順

[numptr] = funptr(name)

パラメータ

name

文字列,プリミティブの名前

numptr

プリミティブの内部ルーチン番号

説明

プリミティブ'name'の 内部的なルーチン番号numptrを取得するためのユーティリティ関数(上級者専用). numptr は,インターフェイス番号 funおよび そのインターフェイス内のプリミティブのルーチン番号 finにより numptr = 1000*fun + fin (fin < 1000) のように計算されます. numptr により, インターフェイス番号 fun = floor(numptr/1000) を得ることができます. この番号は,参照渡しの引数を有する動的インターフェイスにリンクする際に有用です (以下の例を参照).

// Suppose you want to load some codes via the dynamic 
// loading facilities offers by addinter. By default 
// arguments are passed by values but if you want to 
// pass them by reference you can do the following 
// (name being the scilab name of one of the interfaced 
// routines) :
//
// addinter(files,spnames,fcts)  // args passed by values
// num_interface = floor(funptr(name)/1000)
// intppty(num_interface)  // args now passed by reference
//
// Note that if you enter the following
//
// intppty()                
//
// you will see all the interfaces working by reference
<< funcprot Scilab getdebuginfo >>

Copyright (c) 2022-2023 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Wed Jan 26 16:25:00 CET 2011