Skip to content

Commit

Permalink
[MISC] Update core_language
Browse files Browse the repository at this point in the history
  • Loading branch information
eseiler committed Mar 25, 2022
1 parent d80da2f commit 1058327
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions include/seqan3/utility/concept/exposition_only/core_language.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,28 +80,32 @@ namespace seqan3
{
/*!\interface seqan3::implicitly_convertible_to <>
* \ingroup utility_concept
* \brief Resolves to `std::ranges::implicitly_convertible_to<type1, type2>()`.
* \brief Checks whether `from` can be implicityly converted to `to`.
*
* \details
*
* The STL concept `convertible_to` checks for implicit and explicit convertability.
*
* \noapi
*/
//!\cond
template <typename t, typename u>
concept implicitly_convertible_to = std::is_convertible_v<t, u>;
template <typename from, typename to>
concept implicitly_convertible_to = std::is_convertible_v<from, to>;
//!\endcond

/*!\interface seqan3::explicitly_convertible_to <>
* \ingroup utility_concept
* \brief Resolves to `std::ranges::explicitly_convertible_to<type1, type2>()`.
* \brief Checks whether `from` can be explicitly converted to `to`.
*
* \details
*
* The STL concept `convertible_to` checks for implicit and explicit convertability.
*
* \noapi
*/
//!\cond
template <typename t, typename u>
concept explicitly_convertible_to = requires (t vt) { { static_cast<u>(vt)}; };
template <typename from, typename to>
concept explicitly_convertible_to = requires (from v) { { static_cast<to>(v)}; };
//!\endcond

/*!\interface seqan3::arithmetic <>
Expand All @@ -121,18 +125,17 @@ concept arithmetic = std::is_arithmetic_v<t>;

/*!\interface seqan3::floating_point <>
* \ingroup utility_concept
* \extends seqan3::arithmetic
* \brief An arithmetic type that also satisfies std::is_floating_point_v<t>.
* \brief An alias for `std::floating_point<t>`.
*
* \details
*
* \sa https://en.cppreference.com/w/cpp/types/is_floating_point
* \sa https://en.cppreference.com/w/cpp/concepts/floating_point
*
* \noapi
*/
//!\cond
template <typename t>
concept floating_point = arithmetic<t> && std::is_floating_point_v<t>;
concept floating_point = std::floating_point<t>;
//!\endcond

/*!\interface seqan3::builtin_character <>
Expand Down

0 comments on commit 1058327

Please sign in to comment.