Move utility module to generic template bindings - #464
Merged
Merged
Conversation
- JsonContainer<double/Rational> becomes the JsonContainer[ValueType] template family; the Python-side dunder extensions are applied to all registered instantiations. - Remove vestigial suffix parameter from the Kwek-Mehlhorn bindings.
There was a problem hiding this comment.
🟢 Approval recommended
No unresolved review comments are reported, and all reviewed files are covered by the submitted changes.
Pull request overview
Moves utility bindings to the generic template system while preserving simulator behavior.
Changes:
- Migrates JSON containers to generic template bindings.
- Simplifies Kwek–Mehlhorn binding signatures.
- Updates Python exposure and simulator tests.
File summaries
| File | Reviewed change |
|---|---|
tests/simulator/test_simulator.py |
Updates tests for generic JSON container types. |
src/utility/kwekMehlhorn.h |
Updates the Kwek–Mehlhorn declaration. |
src/utility/kwekMehlhorn.cpp |
Simplifies the binding definition. |
src/utility/json.h |
Updates the JSON binding declaration. |
src/utility/json.cpp |
Registers generic JSON container specializations. |
src/mod_utility.cpp |
Uses the updated binding APIs. |
lib/stormpy/utility/__init__.py |
Exposes JsonContainer as a generic family. |
Review details
- Files reviewed: 7/7 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Move utility to the new generic system (#449).