cube: prefer value_initialization

* spot/twacube/cube.cc: Here.
This commit is contained in:
Etienne Renault 2020-06-09 16:29:51 +02:00
parent 9411dab738
commit 9b4d51e3db

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2018 Laboratoire de Recherche et Developpement de // Copyright (C) 2015, 2016, 2018, 2020 Laboratoire de Recherche et
// l'Epita (LRDE). // Developpement de l'Epita (LRDE).
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
// //
@ -36,10 +36,7 @@ namespace spot
cube cubeset::alloc() const cube cubeset::alloc() const
{ {
auto* res = new unsigned int[2*uint_size_]; return new unsigned int[2*uint_size_]();
for (unsigned int i = 0; i < 2*uint_size_; ++i)
res[i] = 0;
return res;
} }
void cubeset::set_true_var(cube c, unsigned int x) const void cubeset::set_true_var(cube c, unsigned int x) const