enum : char ???

K

Kelvin@!!!

In Visual Studio
we can limit the size of an enum by doing:
enum Weekday : char
{
MON, TUE, WED;
};

is that in the stardard C++ ?
or it's just an extension from microsoft?

thanks
 
I

Ivan Vecerina

Kelvin@!!! said:
In Visual Studio
we can limit the size of an enum by doing:
enum Weekday : char
{
MON, TUE, WED;
};

is that in the stardard C++ ?
or it's just an extension from microsoft?

It is a platform-specific extenstions (although it has
been proposed for inclusion in the next C++ standard).
 
I

Ioannis Vranos

Kelvin@!!! said:
In Visual Studio
we can limit the size of an enum by doing:
enum Weekday : char
{
MON, TUE, WED;
};

is that in the stardard C++ ?
or it's just an extension from microsoft?

Extension.


--
Ioannis Vranos

http://www23.brinkster.com/noicys

[I am using 90 characters word-wrapping - (800/640) *72= 90 or better described as:
(800/640) *80 - 10 for quotation= 90. If someone finds it inconvenient, please let me know].
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,156
Messages
2,570,878
Members
47,408
Latest member
AlenaRay88

Latest Threads

Top