General C++ Programming - June 2010 (Page 6)

by Ritsu
Changing from dead to alive
 
if ( (shipArray ->getBelongs() == 2) && (shipArray ->isAlive())) { cout<<"Hit!\n";...
[11 replies] Last: Thanks for the help!! =) (by Ritsu)
Aggregation and function template question
 
Hello Ive been using a mud source code which is written in c to learn how to code. I am tryi...
[2 replies] Last: Thanks Galik , i had experimented with stl lists before without luck b... (by judas97)
Problem with storing pointer
 
Hi all, I have a void pointer (args) and I want that pointer to point to a function pointer. I ha...
[17 replies] Last: Uh... No. void function_with_callback(void (*f)(void *),void *da... (by helios)
by briler
Cosructor without ()
 
In my code i have a call to a constructor and the call is without (). object * t = new object; ...
[2 replies] Last: thanks! (by briler)
C++ Interface(s) on Platforms (Windows, Linux, MacOS)..
 
You can suggest the interfaces (executor) could make easy you work on! Currently, I am using dev C+...
[2 replies] Last: The interface you're speaking of is an IDE (Integrated Development Env... (by Bo Pace)
by everid
header file question on linking error.
 
I include the same header file in 2 cpp files and get an link error for sure. The header file defin...
[7 replies] Last: oh, I see, i need to change a.cpp to namespace My{ int a=10; } ... (by everid)
by vivmen
problem with auto_ptr
 
Hello All .. i am getting strange errors when trying following code . any idea ? i am usin...
[4 replies] Last: Thanks To all. boost will solve my problem. (by vivmen)
by meocta
copy-constructor is preventing me from returning a temporary
 
Hi, I have a bit of a problem that looks as fallows: class cls { public: cls () {} // the ...
[3 replies] Last: C++ syntax and the resulting compiled code are 2 different things. ... (by Disch)
2 Easy Enum Questions
 
My first question is about how to create a private static member variable which is an array of enums...
[5 replies] Last: helios, thanks for that explanation. just to clarify: using an enu... (by Jonah11)
Programming Principles and Practice using C++ - Stroustrup
 
Hello Forum Plz, am new to this forum and a beginner of C++ selfstudy. I have came a cross a l...
[2 replies] Last: You can download lot of books from torrent. See this: http://cplusplu... (by R0mai)
_CLASSDEF
 
_CLASSDEF(classname) What is the use of this code. I came across this in many built in header ...
[3 replies] Last: sorry I couldn't reply for a while. I had posted some of these head... (by diffthinkr)
Finding Endianess
 
Hi I came across a code to find the endianess, wherein a union containing an integer and characte...
[9 replies] Last: [quote=helios]The only difference between char and int is that char is... (by helios)
Some doubts regarding NULL pointers
 
Guys, I have the following doubts regarding NULL pointers, 1. Can we have a pointer to a NULL poi...
[1 reply] : 1. yes 2. usually some kind of segmentation fault or access violation... (by Galik)
Operator Overload >>
 
I am trying to read data out of my txt file the text file got vector for example (-1,2,6) heres wh...
[9 replies] Last: ok guys thanks alot i got it working void read(){ fstream myfile... (by aymank1985)
Char split
 
Hey all, I have this textline in a char: 0x0BOF00x0S0x00x0EOF00x0S0x07101 or in pieces: 0x0B...
[8 replies] Last: @R0mai tnx it works, I will search it out further tomorrow (by closed account G26pX9L8)
Down Caste a class
 
Hello guys . I have my class vector as follow: template <class T> class vector { public: vec...
[5 replies] Last: Yah the use of this project is to replace the normal vector class , I ... (by aymank1985)
byte order in a union and endianness
 
So do I get it right, that on different platforms the outputed chars can swap depending on system ...
[4 replies] Last: Well, for those reading this, but not much interested in unions: the s... (by KarlisRepsons)
Time Conversion
 
Hello all, I want to convert a time string to a char. I tried many things and some works but that...
[8 replies] Last: Ok tnx all problem fixed (by closed account G26pX9L8)
How do you "force" screen size.
 
I'm using Visual Studio C++ and I want to control the size of the window when my code (console app) ...
[4 replies] Last: I got the console app window to fill the screen using: HAN... (by brian20)
by R0mai
Custom operator new/delete
 
I'm using a class from which a lot of single instances are allocated and deallocated at the same tim...
[no replies]
June 2010 Pages: 1... 45678... 18
  Archived months: [may2010] [jul2010]

This is an archived page. To post a new message, go to the current page.