mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: add FixedList templated get<unsigned>() methods
- provides fast compile-time indexing for FixedList (invalid indices trigger a compiler error). This enables noexcept access, which can propagate into various other uses (eg, triFace, triPoints, ...) ENH: add triangle edge vectors
This commit is contained in:
committed by
Andrew Heather
parent
c7e6ae30bf
commit
d3e285b48b
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2020 OpenCFD Ltd.
|
||||
Copyright (C) 2020-2022 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
@ -43,7 +43,7 @@ void print(const boolVector& v)
|
||||
<< " any:" << Switch::name(v.any())
|
||||
<< " all:" << Switch::name(v.all())
|
||||
<< " none:" << Switch::name(v.none())
|
||||
<< " count:" << v.count() << nl;
|
||||
<< " on:" << v.count() << " off:" << v.count(false) << nl;
|
||||
}
|
||||
|
||||
|
||||
@ -68,7 +68,7 @@ int main(int argc, char *argv[])
|
||||
Info<< nl;
|
||||
|
||||
{
|
||||
boolVector vec{1, 0, 1};
|
||||
boolVector vec(1, 0, 1);
|
||||
print(vec);
|
||||
|
||||
vec.flip();
|
||||
|
||||
Reference in New Issue
Block a user