Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
openfoam
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor 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
Development
openfoam
Commits
2c31e665
Commit
2c31e665
authored
8 years ago
by
Henry Weller
Browse files
Options
Downloads
Patches
Plain Diff
autoPtr: Added assignment to pointer
parent
9d2ba297
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/OpenFOAM/memory/autoPtr/autoPtr.H
+4
-1
4 additions, 1 deletion
src/OpenFOAM/memory/autoPtr/autoPtr.H
src/OpenFOAM/memory/autoPtr/autoPtrI.H
+8
-1
8 additions, 1 deletion
src/OpenFOAM/memory/autoPtr/autoPtrI.H
with
12 additions
and
2 deletions
src/OpenFOAM/memory/autoPtr/autoPtr.H
+
4
−
1
View file @
2c31e665
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
========= |
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / O peration |
\\ / A nd | Copyright (C) 2011-201
6
OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-201
7
OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
License
License
...
@@ -125,6 +125,9 @@ public:
...
@@ -125,6 +125,9 @@ public:
//- Return const object pointer
//- Return const object pointer
inline
const
T
*
operator
->
()
const
;
inline
const
T
*
operator
->
()
const
;
//- Take over the object pointer from parameter
inline
void
operator
=
(
T
*
);
//- Take over the object pointer from parameter
//- Take over the object pointer from parameter
inline
void
operator
=
(
const
autoPtr
<
T
>&
);
inline
void
operator
=
(
const
autoPtr
<
T
>&
);
};
};
...
...
This diff is collapsed.
Click to expand it.
src/OpenFOAM/memory/autoPtr/autoPtrI.H
+
8
−
1
View file @
2c31e665
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
========= |
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / O peration |
\\ / A nd | Copyright (C) 2011-201
6
OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-201
7
OpenFOAM Foundation
\\/ M anipulation |
\\/ M anipulation |
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
License
License
...
@@ -190,6 +190,13 @@ inline const T* Foam::autoPtr<T>::operator->() const
...
@@ -190,6 +190,13 @@ inline const T* Foam::autoPtr<T>::operator->() const
}
}
template
<
class
T
>
inline
void
Foam
::
autoPtr
<
T
>::
operator
=
(
T
*
p
)
{
reset
(
p
);
}
template
<
class
T
>
template
<
class
T
>
inline
void
Foam
::
autoPtr
<
T
>::
operator
=
(
const
autoPtr
<
T
>&
ap
)
inline
void
Foam
::
autoPtr
<
T
>::
operator
=
(
const
autoPtr
<
T
>&
ap
)
{
{
...
...
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