General C++ Programming - August 2009 (Page 7)

by Yuan
Making custom-sized ints?
 
Hello all. How do I make custom-sized ints/doubles/etc., such as 42-bit ints, instead of the standard 32-bit ones? Thanks! ~Yuan
[3 replies] Last: isnt the following similiar? struct { long bla : 6 cha... (by Incubbus)
Passing auto_ptr<T> by non-const reference.
 
Hi Everyone Could someone please let me know what the C++ standard says about passing auto_ptr's by non-const reference. Does it or does it not transfer own...
[6 replies] Last: In the foo() function of the code (above) compiled using gcc 3.4.6, it... (by Robertlzw)
How to find the g++ library version
 
Hi Everyone I have a libstdc++.so.6 g++ library file. How can i find out which version of gcc was used to build this library? Regards Rajat
[1 reply] : Not sure you can. Why would you want to anyway? (by jsmith)
by rituk
sudoku in wxDEV-C++
 
hey everyone, can anyone of you please send any codes on sudoku solver and generator coded in wxDev-C++......that's my assignment and i am unable to crack it u...
[6 replies] Last: rituk, I don't know what sort of level you are at so this may be w... (by closed account z05DSL3A)
spin lock issues with stlport4
 
Hi All, does anyone knows why string operations in stlport4 makes the threads to spin on the mutex locks?? Plez refre the below stack trace for more info.. ...
[no replies]
question on exception specification
 
As the example class Base{ public: void virtual abc() throw(int,double,long){} }; class Derived:Base{ public: //void abc(){}//1 //void abc() thro...
[1 reply] : Exception specifications were originally added to the language to allo... (by jsmith)
by helios
Parameter!=argument?
 
Before call: //(Another function call that internally makes a library call.) this->pointer->pointer->pointer->function(); //this->pointer->pointer->pointer...
[no replies]
Chat Server Methodics
 
Hey... now that i did a lot of stuff with Winsock etc i´d like to create a little chat server; but i am unsure about the implementation: I cant get my he...
[no replies]
SDL issue
 
It compiles fine with no errors or warnings, but then crashes when I open it. Any ideas? (trying to get it to display the png, which IS in the right place). All...
[10 replies] Last: I have same problem too but I solved with this way: Measure look.png ... (by a20365354)
by nny
tcp addressing problem
 
hello all... i want my application to exchange data between two users online, and i`m facing a problem. i`m using TTcpServer and TTcpClient. here is simp...
[7 replies] Last: I understand that your comms works on your LAN, but not outside it. ... (by kbw)
by skiing
random number generator
 
I am really confused on how the use of a random number generator works when using cutoff and being unbiased. Here is the code that I was given to incorporate i...
[4 replies] Last: Well, first you have to post syntactically correct code, otherwise I c... (by jsmith)
numeric_limits::max() vs windows.h
 
hey... im writing on a project which includes <windows.h> and <limits> for numeric_limits... but when i want to do: cin.ignore(numeric_limits::max()); it...
[7 replies] Last: "Kanji" is Japanese for "Chinese Character(s)". It is for Shift-JIS su... (by Duthomhas)
more test questions
 
one more question I am confused Q1: string str; if("hello" == str) cout << "here" << endl; In the sample code above, how does a C++ compiler interp...
[5 replies] Last: thanks for the help. (by chrisben)
Casting iterators?
 
Hi! I am working on a neural network where I have a superclass Neuron that has been extended to InputNeuron, HiddenNeuron and OutputNeuron. In the NeuralNetw...
[4 replies] Last: Or make it a template function. (by jsmith)
by sedrel
How can I force a derived class to override a base class member variable?
 
Hello All, I'm new to C++ (been an Ada guy for over 20 years), and I've search but can't find an answer to my question on the Web (big place!), so I'm hoping...
[3 replies] Last: Here's a thought. Not sure if it helps.... template< typename... (by jsmith)
Code::Blocks problem
 
I got a serious problem with my IDE Code::Blocks. Perhaps some users can help me out. I do not know why but for some reason I cannot compile things properly...
[1 reply] : There may be some problem with the compiler, try to see if the setting... (by Bazzy)
by rcr
Memory problem?
 
hi, what will happen if u allocate memory using new or malloc but u forget to delete?
[4 replies] Last: Ah. Got it. Thanks helios. (by kevinchkin)
next days dates and times
 
Hello everyone! Please excuse me for my bad English but I'm not a native speaker. Anyway, let's get to my problem: I have a program that writes some data on a ....
[19 replies] Last: Ah...! Thanks man, you're a life saver! (by Drake Aran)
by bayuaj
forward declaration and template function error
 
I am a new member of cplusplus forum and this is my first post here. Currently I have a frustrating problem with forward declaration and template function. Bel...
[7 replies] Last: Hi kbw.. thank u a lot for your suggestion.. that really works! (by bayuaj)
by wans
Tic Tac Toe program need a fix for the Drawing of the game.
 
Hi there my program is a Tic Tac Toe game which is a Human Vs Human Game. But my program is having problem when the game comes to a draw. It doesn't stop the ga...
[7 replies] Last: Thanks for the help. Really appreciate it. (by wans)
August 2009 Pages: 1... 56789... 12
  Archived months: [jul2009] [sep2009]

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