Skip to content

refactor: Start removing line parser#2544

Merged
rprospero merged 13 commits into
develop2from
remove_line_parser
Jun 30, 2026
Merged

refactor: Start removing line parser#2544
rprospero merged 13 commits into
develop2from
remove_line_parser

Conversation

@rprospero

@rprospero rprospero commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

This PR removes the LineParser dependency in ImportDLPOLYStructureNode, ImportDLPOLYTrajectoryNode, ImportDLPUtilsPDensNode, ImportDLPUtilsSurfaceNode, and ImportMoscitoStructureNode.

It also fixes up MDNode to use the cleaner =std::format_to= for file output.

The one bit that I'm not happy about is that I needed to adjust the tolerance on CosNTorsionForcesTest::POE in order to pass the tests. I only had to change the tolerance from 0.006 to 0.0062 and the actual value is in the thousands, but I'm always concerned when a test like this needs changing. I know that the change comes from the new Moscito parser and I suspect that it's a slight difference in how doubles are parsed, which can result in some differences in the lowest bits.

@rprospero rprospero changed the title Remove line parser refactor: Start removing line parser Jun 29, 2026
@rprospero rprospero marked this pull request as ready for review June 29, 2026 19:34
@rprospero rprospero requested a review from trisyoungs June 30, 2026 08:02

@trisyoungs trisyoungs left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On the one hand, this is an easy win because LineParser was truly awful, but I think this has turned out excellent and makes our input parsing feel very proper indeed!

Bunch of small comments, mostly formatting etc.

Comment thread src/base/parserLibrary.cpp
Comment thread src/nodes/importDLPOLYStructure.cpp Outdated
Comment thread src/nodes/importDLPOLYTrajectory.cpp
Comment thread src/nodes/importDLPUtilsSurface.cpp
Comment thread src/nodes/importMoscitoStructure.cpp Outdated
Comment thread src/nodes/importMoscitoStructure.h Outdated
Comment thread tests/ff/cos-n.cpp
Comment thread tests/io/applicative.cpp Outdated

TEST(ApplicativeTest, DLPOLYStructure)
{
using namespace Parsers;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here, wouldn't this be better at the top of the file rather than repeated in every TEST?

@rprospero rprospero merged commit 51f4ff6 into develop2 Jun 30, 2026
9 checks passed
@rprospero rprospero deleted the remove_line_parser branch June 30, 2026 10:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants