-
Notifications
You must be signed in to change notification settings - Fork 0
/
test-input-function-params.output.ref
128 lines (90 loc) · 2.72 KB
/
test-input-function-params.output.ref
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
// functions with parameters
variable myFuncParam1(variable var1){
variable var1
};
variable myFuncParam2(variable var1, string str1){
string str1
variable var1
};
struct myStructType{;
variable v1;
};
/// This function has structure parameters, which are always call-by-reference
///@param w1 input wave
///@param str1 fancy version string
///@param myStruct1 first working struct
///@param myStruct2 second working struct
///@param myStruct3 third working struct
variable myFuncParam3(WaveText w1, string str1, myStructType* myStruct1, myStructType* myStruct2, myStructType* myStruct3){
struct myStructType& myStruct1
struct myStructType & myStruct2
struct myStructType &myStruct3
WaveText w1
string str1
};
variable myFuncParam4(myStructType* param){
struct myStructType& param
};
// normal parameters using call-by-reference
variable myFuncParam5(myStructType* param, string* str1 = defaultValue){
struct myStructType& param
string& str1
};
// multiple return value syntax, introduced with IP8
std::tuple<int64, variable> myFuncParam6(int64 in){
return [out1, out2]
};
std::tuple<int64, myStructType, WaveText> myFuncParam7(int64 in, variable opt = defaultValue){
return [out, s, textwave]
};
std::tuple<string, string> myFuncParam8(string fileName, string fileFilter = defaultValue, string message = defaultValue){
return ["", ""]
};
std::tuple<DFREF> ReturnSomeFolder(){
};
// function modifiers
static variable myFuncS1(){
};
static variable myFuncS2(variable var){
variable var
};
[[ threadsafe ]] static variable myFuncST1(){
};
[[ threadsafe ]] static variable myFuncST2(variable var){
variable var
};
[[ override ]] variable myFuncSTO1(){
};
[[ override ]] variable myFuncSTO2(variable var){
variable var
};
// and this is not a function declaration
SomeStuff Function notAFunc();
variable Proto(){
};
variable Test1(variable a, string s, wave w, dfref d, Proto f, RECTF* st, int i, int64 i64, uint64 ui64, double do, complex c, variable opt = defaultValue){
};
variable Test2(variable* a, Proto f, string* s = defaultValue){
};
variable Test3(struct* RECTF, string s = defaultValue){
};
string TestWithNastyPrefix(WaveRefWave waverefs){
WaveRefWave waveRefs
};
struct MyStruct{;
int32 count;
};
variable PA_ApplyPulseSortingOrder(wave setIndices, MyStruct* myStruct){
};
variable PA_GatherSettings(string win, MyStruct* myStruct){
string win
STRUCT MyStruct &myStruct
};
string MyFuncWithOnlyOptionalParameters(variable channelType = defaultValue){
};
variable MyFunc(WaveComplex wv){
};
std::tuple<WAVE, WaveText> MyFuncyFunc(WaveDoubleOrNull param1, WaveTextOrNull param2, WaveIntegerOrNull param2, WaveRealOrNull param3, WaveComplexOrNull param4){
};
variable Func(variable b, variable c){
};