carl  24.04
Computer ARithmetic Library
Conversion.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <carl-common/config.h>
4 #include "../poly/Conversion.h"
5 
6 namespace carl {
7 
8 template<typename ToPoly, typename FromPoly, typename = std::enable_if_t<needs_context_type<ToPoly>::value>>
9 inline BasicConstraint<ToPoly> convert(const typename ToPoly::ContextType& context, const BasicConstraint<FromPoly>& c) {
10  return BasicConstraint<ToPoly>(convert<ToPoly>(context, c.lhs()), c.relation());
11 }
12 template<typename ToPoly, typename FromPoly, typename = std::enable_if_t<!needs_context_type<ToPoly>::value>>
14  return BasicConstraint<ToPoly>(convert<ToPoly>(c.lhs()), c.relation());
15 }
16 
17 }
carl is the main namespace for the library.
BasicConstraint< ToPoly > convert(const typename ToPoly::ContextType &context, const BasicConstraint< FromPoly > &c)
Definition: Conversion.h:9
Represent a polynomial (in)equality against zero.
const Pol & lhs() const
Relation relation() const