473,386 Members | 1,758 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

C++ empty class question

What does an empty Class contains?
Aug 12 '07 #1
2 2000
JosAH
11,448 Expert 8TB
What does an empty Class contains?
You posted you question in the C/C++ Articles section. That section is for
(informative?) articles only. I'll move your question over to the C/C++ Forum
section where questions like yours belong.

kind regards,

Jos
Aug 12 '07 #2
weaknessforcats
9,208 Expert Mod 8TB
An empty class contains nothing. Usually these are used as dummies (placeholders) while you get other stuff to compile.
Aug 12 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

10
by: Brian Roberts | last post by:
I'm using using generators and iterators more and more intead of passing lists around, and prefer them. However, I'm not clear on the best way to detect an empty generator (one that will return no...
23
by: Mikko Ohtamaa | last post by:
From XML specification: The representation of an empty element is either a start-tag immediately followed by an end-tag, or an empty-element tag. (This means that <foo></foo> is equal to...
2
by: Robert A. van Ginkel | last post by:
Hello Fellow Developer, This looks like a long mail, but at the end of this post is my socket wrapper attached. I want to make a timeout procedure that starts counting down after the...
3
by: Emmanuel Thomé | last post by:
This is a comment aside the empty class behavior FAQ. I understand there are a fair number of reasons which make empty classes have non-zero size (except as base classes). If ``class foo'' were...
4
by: web1110 | last post by:
I have an array of of 5 string elements. I put values in 3 of them. Yet when I loop over them, I do not catch the empty string. The code output below does not include "Empty" stringx=new...
9
by: Søren M. Olesen | last post by:
Hi Can someone tell me how to implement something similar to String.Empty ?? Given a class called myValue Public class myValue private id as integer private value as string end class
4
by: avranju | last post by:
Hi, We have a few exception marker classes in a project that are used only to throw exceptions. I mean stuff like this (this may not be such a hot idea for doing exception handling - a simple...
2
by: Harish | last post by:
This was an interview question: The size of an empty class is 1 byte. Why? Should it not be 4 bytes? Because an invisible pointer "this" is part of every class?
7
by: Ajay | last post by:
Hi all, Please tell me why empty class has one Byte Size. thanks in Advance.. Ajay
9
by: Morgan Cheng | last post by:
Hi, I once worked for java in embedded system. Since the memory is limited in embedded system, there are some guidelines for programming. One of them is "Don't create too many classes, because...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.