Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Backofen, Rainer
amdis
Commits
49bb4f10
Commit
49bb4f10
authored
Aug 07, 2012
by
Praetorius, Simon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vector operations
parent
1ed23fa5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
extensions/VectorOperations.h
extensions/VectorOperations.h
+8
-0
No files found.
extensions/VectorOperations.h
View file @
49bb4f10
...
...
@@ -93,6 +93,14 @@ namespace vector_operations {
size_t
num_rows
(
const
std
::
vector
<
T
>
&
v
)
{
return
static_cast
<
size_t
>
(
v
.
size
());
};
template
<
typename
T
>
size_t
num_rows
(
T
&
v
)
{
return
1
;
};
template
<
typename
T
>
size_t
num_rows
(
const
T
&
v
)
{
return
1
;
};
// num_rows/num_cols for matrix types
template
<
typename
T
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment