Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8429405
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T05:19:41+00:00 2026-06-10T05:19:41+00:00

I created a Matrix class, using static_assert(std::is_arithmetic<T>::value,); to check if the template type is

  • 0

I created a Matrix class, using

static_assert(std::is_arithmetic<T>::value,"");

to check if the template type is an arithmetic type. So I tried with

Matrix<char> matrix1(3,3); // ctor takes number of rows and columns

and it works. The static_assert function is not called with char type. It is normal? char is seen like an arithmetic type?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T05:19:43+00:00Added an answer on June 10, 2026 at 5:19 am

    From the reference:

    If T is an arithmetic type (that is, an integral type or a floating-point type), provides the member constant value equal true. For any other type, value is false.

    char is an integral type, so the answer is true. The fact that the small integers that fit in a char are often interpreted as codepoints in a particular character encoding space is secondary.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created the following type using implicit type construction: open System type Matrix(sourceMatrix:double[,])
I have a template class defined as: #include <stdio.h> #include <queue> using namespace std;
I recently created a generic Matrix<T> class that acts as a wrapper around a
I created a 2-D matrix using double pointer like that: int** pt; pt =
I've created a templated class, and it works fine: ( I'm using openCV library,
I am trying to create a Matrix class using c++. So far, I have
I am working on an exercise in operator overloading. I've created a matrix class
I'm looking to transform an image using a Matrix on the onDraw method of
i have created a coverflow using the code given by http://android.jmsliu.com/138/android-infinite-loop-gallery.html . And it
I'm doing a project for a class which focuses on storing a huge matrix

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.