mirror of
https://github.com/Z3Prover/z3
synced 2026-02-18 22:54:21 +00:00
Add safety comment and improve test documentation
- Add comment about safety of &levels[0] after n > 0 check - Improve test documentation about SimpleSolver limitations - Clarify that Units/NonUnits are more reliable for general use Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
parent
b799238fe8
commit
87812a99c0
2 changed files with 10 additions and 5 deletions
|
|
@ -242,6 +242,7 @@ func (s *Solver) TrailLevels() []uint {
|
|||
levels := make([]C.uint, n)
|
||||
|
||||
// Get the levels using the trail vector directly
|
||||
// Safe to pass &levels[0] because we checked n > 0 above
|
||||
C.Z3_solver_get_levels(s.ctx.ptr, s.ptr, trailVec, C.uint(n), &levels[0])
|
||||
|
||||
// Convert to Go slice
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue