包み込んでいるコンパイルされた関数についての情報を与える.
CurrentCompiledFunctionData[prop]
包み込んでいるコンパイルされた関数の型特性 prop の値を与える.
CurrentCompiledFunctionData
包み込んでいるコンパイルされた関数についての情報を与える.
CurrentCompiledFunctionData[prop]
包み込んでいるコンパイルされた関数の型特性 prop の値を与える.
詳細
- CurrentCompiledFunctionDataはコンパイルされたコードでしか使えない.
- CurrentCompiledFunctionDataへの呼び出しから返される名前はFunctionDeclarationで設定されたものである.
- CurrentCompiledFunctionData["ReturnType"]は,関数の戻り型にアクセスする便利な方法である.
- CurrentCompiledFunctionDataへの呼出しは型"CompiledFunctionData"の結果を返す.
- CurrentCompiledFunctionDataへの呼出しには包み込んでいる関数の型が含まれているので,これを関数から返すことはできない.
- 次は,サポートされる特性である.
-
"Type" 包み込んでいる関数の型 "ReturnType" 包み込んでいる関数の戻り型
例題
すべて開く すべて閉じる例 (2)
現行関数についての情報を出力する関数をコンパイルして評価する:
名前付きの関数にCurrentCompiledFunctionDataが出現する場合は以下が含まれる:
スコープ (3)
CurrentCompiledFunctionDataはコンパイルされたコードでしか使えない:
CurrentCompiledFunctionDataの結果は,名前等の情報が抽出できる関数に渡すことができる:
以下はCurrentCompiledFunctionDataが出現する関数の名前を出力する:
考えられる問題 (1)
CurrentCompiledFunctionDataへの呼出しの結果は,関数から返すことはできない:
CurrentCompiledFunctionData[]が"InertExpression"にキャストされるとコンパイルが成功する:
これが呼ばれると,結果のCompiledFunctionDataオブジェクトは戻り型が"InertExpression"であることを示す:
テクニカルノート
関連するガイド
テキスト
Wolfram Research (2025), CurrentCompiledFunctionData, Wolfram言語関数, https://reference.wolfram.com/language/ref/CurrentCompiledFunctionData.html.
CMS
Wolfram Language. 2025. "CurrentCompiledFunctionData." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/CurrentCompiledFunctionData.html.
APA
Wolfram Language. (2025). CurrentCompiledFunctionData. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/CurrentCompiledFunctionData.html
BibTeX
@misc{reference.wolfram_2025_currentcompiledfunctiondata, author="Wolfram Research", title="{CurrentCompiledFunctionData}", year="2025", howpublished="\url{https://reference.wolfram.com/language/ref/CurrentCompiledFunctionData.html}", note=[Accessed: 20-April-2026]}
BibLaTeX
@online{reference.wolfram_2025_currentcompiledfunctiondata, organization={Wolfram Research}, title={CurrentCompiledFunctionData}, year={2025}, url={https://reference.wolfram.com/language/ref/CurrentCompiledFunctionData.html}, note=[Accessed: 20-April-2026]}