Commit c350a127 authored by Mark Olesen's avatar Mark Olesen
Browse files

STYLE: add compile-time deprecated message for face/triangle normal()

- in 1812 propagated through the distinction between areaNormal and
  unitNormal (issue #885).

  In older versions, the normal() always meant the area-normal for
  certain of these primitive.

  However, the .org version changed this to now return the unit-normal
  instead, but with the same method name. Thus add the deprecated
  message to avoid future inadvertent uses of normal() without being
  certain which one is being meant.
parent 20670140
......@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017-2018 OpenCFD Ltd.
\\/ M anipulation | Copyright (C) 2017-2019 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
......@@ -201,6 +201,7 @@ public:
//- Legacy name for areaNormal()
// \deprecated(2018-06) Deprecated for new use
inline vector normal(const UList<point>& p) const
FOAM_DEPRECATED_FOR(2018-12, "areaNormal() or unitNormal()")
{
return areaNormal(p); // Legacy definition
}
......
......@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017-2018 OpenCFD Ltd.
\\/ M anipulation | Copyright (C) 2017-2019 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
......@@ -132,6 +132,7 @@ public:
//- Legacy name for areaNormal()
// \deprecated(2018-06) Deprecated for new use
inline vector normal(const UList<point>& points) const
FOAM_DEPRECATED_FOR(2018-12, "areaNormal() or unitNormal()")
{
return areaNormal(points); // Legacy definition
}
......
......@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2018 OpenCFD Ltd.
\\/ M anipulation | Copyright (C) 2018-2019 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
......@@ -215,6 +215,7 @@ public:
//- Legacy name for areaNormal().
// \deprecated(2018-06) Deprecated for new use
inline vector normal() const
FOAM_DEPRECATED_FOR(2018-12, "areaNormal() or unitNormal()")
{
return areaNormal();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment