Skip to content

Commit 94ca530

Browse files
authored
Fix bug affecting async IO + single precision particles (#1583)
The proposed changes: - [x] fix a bug or incorrect behavior in AMReX - [ ] add new capabilities to AMReX - [ ] changes answers in the test suite to more than roundoff level - [ ] are likely to significantly affect the results of downstream AMReX users - [ ] are described in the proposed changes to the AMReX documentation, if appropriate
1 parent d9af9ab commit 94ca530

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Src/Particle/AMReX_WriteBinaryParticleData.H

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -497,7 +497,7 @@ void WriteBinaryParticleDataAsync (PC const& pc,
497497

498498
auto RD = pc.ParticleRealDescriptor;
499499

500-
AsyncOut::Submit([=] ()
500+
AsyncOut::Submit([=] ()
501501
#if defined(__GNUC__) && (__GNUC__ == 8) && (__GNUC_MINOR__ == 1)
502502
mutable // workaround for bug in gcc 8.1
503503
#endif
@@ -516,7 +516,7 @@ void WriteBinaryParticleDataAsync (PC const& pc,
516516

517517
if ( ! HdrFile.good()) amrex::FileOpenFailed(HdrFileName);
518518

519-
if (sizeof(typename PC::ParticleType) == 4)
519+
if (sizeof(typename PC::ParticleType::RealType) == 4)
520520
{
521521
HdrFile << PC::ParticleType::Version() << "_single" << '\n';
522522
}

0 commit comments

Comments
 (0)