Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Timo Koch
dune-common
Commits
c993c5ac
Commit
c993c5ac
authored
15 years ago
by
Jorrit Fahlke
Browse files
Options
Downloads
Patches
Plain Diff
Fix doxygen error
[[Imported from SVN: r5754]]
parent
9196695b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dune/common/forloop.hh
+21
-19
21 additions, 19 deletions
dune/common/forloop.hh
with
21 additions
and
19 deletions
dune/common/forloop.hh
+
21
−
19
View file @
c993c5ac
...
...
@@ -11,7 +11,7 @@ namespace Dune
* @brief A static loop using TMP
*
* The ForLoop takes a
* \code template<int i> class Operation
* \code template<int i> class Operation
\endcode
* template argument with a static apply method
* which is called for i=first...last (first<=last are int template arguments).
* A specialization for class template class Operation for i=first
...
...
@@ -23,24 +23,26 @@ namespace Dune
* It is possible to pass a subclass to the ForLoop
* (since no specialization is needed).
* Example of usage:
* template <class Foo>
* struct A
* {
* template <int i>
* struct Operation
* {
* template <class T>
* static void apply(const double &x,const T &t, T &ret)
* {
* ret = "hallo" + t;
* }
* };
* void useForLoop()
* {
* std::string world;
* ForLoop<Operation,1,10>::apply(1.,"hallo",world);
* }
* };
* \code
template <class Foo>
struct A
{
template <int i>
struct Operation
{
template <class T>
static void apply(const double &x,const T &t, T &ret)
{
ret = "hallo" + t;
}
};
void useForLoop()
{
std::string world;
ForLoop<Operation,1,10>::apply(1.,"hallo",world);
}
};
* \endcode
*/
template
<
template
<
int
>
class
Operation
,
int
first
,
int
last
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment