|
by: Jeff Greenberg |
last post by:
Not an experienced c++ programmer here and I've gotten myself a bit
stuck. I'm trying to implement a class lib and I've run into a sticky
problem that I can't solve. I'd appreciate any help that I can get!
Consider 3 classes in the following heirarchy:
base
/ \
deriv1 deriv2
\
|
by: He Shiming |
last post by:
Hi,
I've got a question regarding class inheritance. The following code
reproduces the problem I'm dealing with:
class IBase
{
public:
virtual void Method(void)=0;
};
|
by: Student |
last post by:
Hi All,
I have an assignment for my Programming language project to create a
compiler that takes a C++ file as input and translate it into the C
file. Here I have to take care of inheritance and operator overloading
and virtual functions. I mean it should not hamper the C++ meaning. In
frank and simple terms i need to implement a small C++ compiler in C++,
and i want the intermediate representation to be C. Please help me in
this....
|
by: acheron05 |
last post by:
Hi there,
Hopefully I won't fit the stereotype of the typical student posting his
assignment to be written for him, but I am quite stuck. If anyone could
give me some help in how to create dynamic objects (which inherit from
a base class) and storing them in a vector, it would be absolutely
wonderful at this point. I think from there I might be able to sculpt
the rest of the program without (too much) trouble. I'll post what I've
been...
|
by: ramesh |
last post by:
Why do we have a virtual destructor and why cant we have a virtual
constructor?
|
|
by: Pravesh |
last post by:
Hello All,
I had some query regarding virtual functions/destructors. If a class is
having some/all of its methods that are virtual then is it recommended
that it should also have virtual destructor?
When I am defining such a class with default destructor then my
compiler is giving warning that class XXX has virtual functions but
non-virtual destructor.
|
by: wizwx |
last post by:
The followings are a few lines of code from the Template method in
"Thinking in C++" vol.2 pp.639
class ApplicationFramework {
protected:
virtual void customize1() = 0;
virtual void customize2() = 0;
public:
void templateMethod() {
customize1();
|
by: Anarki |
last post by:
##include <iostream>
using namespace std;
class A
{
};
class B:virtual public A
{
};
class C:virtual public A
|
by: Pranav |
last post by:
Hello All,
I have a simple question regarding the definition of abstract class,
IIRC , Abstract class is one which contains virtual function
declaration and other variables and no object of this class is created
directly.
If this is the case why don't we hide the constructor of abstract
class into protected region? So that only object which inherits it can
call the ctor of abstract class. In this way no one can create the
object of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
|
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|