* Remove Dict::getData() for a strict abstraction boundary
Replace direct access to Dict's internal std::vector<Pair> with
encapsulated methods: size(), empty(), const iteration via
begin()/end(), appendPair(), markNonPOD(), and getRawVal().
This enables future changes to Dict's internal representation
without breaking callers.
Ref: rdkit/rdkit#9112
* Harden Dict::appendPair to take a populated Pair by move
appendPair(Pair&&) now auto-detects non-POD status via
RDValue::needsCleanup(), eliminating markNonPOD() and the
risk of dangling references or uninitialized entries.
needsCleanup() is placed next to destroy() on RDValue to
keep the POD/non-POD distinction in one place.
* Remove vestigial dictHasNonPOD param from streamReadProp
Both callers ignored the output. Non-POD detection is now handled
by Dict::appendPair via RDValue::needsCleanup().
* unbork java build
* Address PR review: bulk append, rename getRawVal, add custom data test
- Add Dict::append(vector<Pair>&&) for bulk insertion with reserve
- Use bulk append in streamReadProps to restore pre-allocation
- Rename getRawVal -> getRDValue per reviewer preference
- Add test verifying custom AnyTag data is destroyed through Dict lifecycle
* heed self-review
* don't manually implement vec.insert
* Add test: ExplicitBitVect round-trip through Dict serialization
Exercises the full streamWriteProps/streamReadProps path with an
ExplicitBitVect in an RDProps Dict, confirming the custom handler
is invoked and no memory is leaked (verified under valgrind).
* in anyTag test, assert destructors ran a specific number of times.
---------
Co-authored-by: bddap (Coding Agent) <andrew+bot@dirksen.com>
* Add RealValueVect.
* Add UniformRealValueGrid3D
* Add Molecular Interaction Fields (MIFs)
* line endings
* cherry-pick f1bc94a4c8
* format
* Adapt tests for python3.
* Adapt RealValueVector pickling for python3.
* Speed-up of MIF calculations.
* Bugfix in MIFDescriptors.cpp.
* all tests pass
* clean up some memory leaks
* update copyrights
* rename
* rename the library
* complete the rename
* lost file
* another forgotten file
* cleanup
* clang-tidy
* clang-tidy
* windows DLL builds work
* python wrapper and tests cleanup
* convert to catch2 testing
* switch RealValueVect to use std::vector
* remove obsolete friend
* - Replace explicit loops with stdlib implicit equivalents
- Replace explicit types with auto where possible
- Avoid unnecessary copy operations where possible
- Replace raw pointers with exception-safe unique_ptr
- Replace C-style #define with constexpr
- Replace C-style casts with C++ casts
- Replace C-style arrays with std::vector
- Avoid code duplication with templated operators
- Replace VdWaals class taking multiple atom type definitions and force-field name as string parameter with force-field-specific classes deriving from an abstract VdWaals class
- Replace x,y,z doubles with Point3D class where possible
- Removed unused (and untested) DistanceToClosestAtom class
- Renamed some variables and functions for better clarity
- Converted tabs to spaces
- Made the mol parameter in cube read/write functions optional for convenience
- Made the Python wrappers more pythonic (e.g., avoid C++-style passing objects as parameters which are modified in place)
- Implemented alternative Python class constructors using boost::python::make_constructor rather than with external non-class functions
- The Python wrappers taking a sequence of Point3D now take a sequence of sequences, such that the output of Conformer.GetPositions() can be passed
- Made the Python wrapper sequence parsing more robust
- Removed duplicated code from Python wrappers
* - avoid an unnecessary copy
* progress
* works
* more cleanup
* all tests pass
* changes in response to review
---------
Co-authored-by: dfhahn <dfhahn@users.noreply.github.com>
Co-authored-by: ptosco <paolo.tosco@novartis.com>
* Fixes#7533
Fixes problem with SparseIntVect and SparseBitVect where the intention is to
be able to store all possible values of the index type: in these cases
you could not store (or access) the final element.
* increase the verbosity of the DataStructs tests
so that we can see what's going on
* clean up in testDatastructs
* avoid jump on unassigned mem in rxns
* set valgrind error exit code
* update suppressions
* clean up RDValue in testDict
* don't leak mol if parsing Maestro file fails
* don't leak mol if parsing PDB block fails
* cleanup leftover rxns in testReaction
* cleanup mol if CX extensions cannot be parsed
* cleanup leftover mols in smiTest1
* cleanup leftover mols in moldraw2DTest1
* cleanup leftover mols in testSubstructMatch
* make testEnumeration go easier on valgrind
* reduce R counts
* Deprecation: planned removal of .message() and .getMessage() methods
* Deprecation: planned removal of old MolHash code
* document deprecations
* output the diffs when the psql tests fail
* remove .message() from SWIG wrappers
note that the KeyError doesn't work properly. We should clean up the the exceptions here anyway
* typo
* run clang-tidy with readability-braces-around-statements
clang-format the results
clean up all the parts that clang-tidy-8 broke
* fix problem on windows
* unused vars in bison parser cleanup
* initialization order in TopologicalTorsionGenerator
* unused params in SLN bison
* sln flex unused params
* throwing destructor in TDTWriter
* signed comparison in substructmethods
* unused input param in smiles/smarts bison
* unused ms param in sln bison
* signed comparison in FingerprintGenerator
* store return of fscanf in StructCheckerOptions
* unreferenced var in catch
* uninitialized value in FileParserUtils
* avoid override overload warning in MolDraw2DSVG
* non-final overrides in Validate.h
* unused static var in Avalon
* unused vars in catch blocks
* make AvalonTools avalonSimilarityBits & avalonSSSBits const int
* assert fscanf result in StructCheckerOptions
* add an additional equality test to testDatastructs
(can never have too many tests!)
* automatically run assignStereochemistry() for chiral fingerprints
This currently runs for the three FP types that support chirality: MFP, AP, and TT