GCC Code Coverage Report
Directory: . Exec Total Coverage
File: src/util/floatingpoint_size.cpp Lines: 10 10 100.0 %
Date: 2021-05-22 Branches: 8 64 12.5 %

Line Exec Source
1
/******************************************************************************
2
 * Top contributors (to current version):
3
 *   Aina Niemetz, Martin Brain
4
 *
5
 * This file is part of the cvc5 project.
6
 *
7
 * Copyright (c) 2009-2021 by the authors listed in the file AUTHORS
8
 * in the top-level source directory and their institutional affiliations.
9
 * All rights reserved.  See the file COPYING in the top-level source
10
 * directory for licensing information.
11
 * ****************************************************************************
12
 *
13
 * The class representing a floating-point format.
14
 */
15
#include "util/floatingpoint_size.h"
16
17
#include "base/check.h"
18
19
namespace cvc5 {
20
21
7768
FloatingPointSize::FloatingPointSize(uint32_t exp_size, uint32_t sig_size)
22
7768
    : d_exp_size(exp_size), d_sig_size(sig_size)
23
{
24
7768
  Assert(validExponentSize(exp_size));
25
7768
  Assert(validSignificandSize(sig_size));
26
7768
}
27
28
34272
FloatingPointSize::FloatingPointSize(const FloatingPointSize& old)
29
34272
    : d_exp_size(old.d_exp_size), d_sig_size(old.d_sig_size)
30
{
31
34272
  Assert(validExponentSize(d_exp_size));
32
34272
  Assert(validSignificandSize(d_sig_size));
33
34272
}
34
35
}  // namespace cvc5