Skip to content

Commit 9d06d4a

Browse files
committed
[Tcl] Add changed file missed recent commit
This should have been in 6f4adde
1 parent 3e01997 commit 9d06d4a

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Examples/test-suite/li_std_vector.i

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,3 +140,13 @@ std::vector<std::string> RevStringVec (const std::vector<std::string> &In)
140140
return(result);
141141
}
142142
%}
143+
144+
// regression test for Tcl typecheck bug with empty list fixed in 4.2.0
145+
%inline %{
146+
int sum(const std::vector<int> &v) {
147+
return std::accumulate(v.begin(),v.end(),0);
148+
}
149+
int sum(int v) {
150+
return v;
151+
}
152+
%}

0 commit comments

Comments
 (0)