We are looking for a presence of a particular character sequence in order. The overall objective is to evaluate the presence of the character sequence within...
... What kinds of "illegal values" stored at the offset would make a string compare operation crash? As long as the memory is really allocated to the string in...
... [deleted] ... 1) what the heck do you expect your list do DO? 2) why aren't you using std::string? ... Victor A. Wagner Jr. http://rudbek.com The five...
... Well, sort of. These are similar stuctures, not the same structure. It's not proper containment (in the sense of strictly greater) of the parent stucture...
Thanks for the information. I tested out a few examples and found that string operation functions would only crash if we pass a NULL char or const char pointer...
Check out this page: http://www.scit.wlv.ac.uk/cbook/chap1.strings.html You have to use the escape equivalents to test non-printable characters. Here are some...
... Which operations are you talking about? And how does that tie in with representing the string as an unsigned int? The only constraint that string...
... list of ... I think what he is looking for is a list template that lets him specify what to use instead of the copy constructor for the objects in the...
... Why not just use memmem: if ( memmem( message, length_of_message, char_sequence, length_of_char_sequence) == the_right_place) { . . . the sequence is...
... Actually, I have decided to use std::string for this project. What I am hoping to eventually accomplish is to write my own allocator class that will...
... I think you have misunderstood the purpose of the allocator. All of those classes (list, vector, etc.) have constructors that will do the appropriate deep...
... Read the STL manual on allocators. I found SGI's version http://www.sgi.com/tech/stl/Allocators.html Generally speaking, you write your own allocator if...
... Better to use the term 'null char' or 'null byte' rather than 'NULL char' which confuses the issue in that NULL is a null pointer constant macro and is not...
Is there any way to detect the name of function you are currently in? I want my small piece of software to write a log having details of each function called....
HI :), There is no such API's or system functions to display function names in which you are in as far i know !!!. I think this is not necessary to include in...
... Generally, __LINE__ and __FILE__ are sufficient, but C99 did introduce __func__ to be an implicit identifier which is the name of the enclosing function......
Just have the Program Function enter it's name into the log and remove it when it leaves. __________________________________ Discover Yahoo! Have fun online...
I know this topic has been discussed before, but i am running into some problems and cannot figure out what's going on. Below i have included the code i am...
... you've misunderstood the purpose of the allocator. I think you've also misunderstood the purpose of the containers in the library. the usual thing is to...
... some compilers have built-in macros that you can use for example: Microsoft VC++7.1 has: __FUNCTION__: Valid only within a function and returns the...
The function clrscr( ) should be used only after variable declarations. say use this piece as an example: { int a, b, c, d ; char a1, b1, c1; float a2; double...
... I just mentioned that the clrscr( ) should be used after var. decl. Its not like that.... For that reason you can just say... after any declaration... say...
It can be placed anywhere in Borland C++. I always did that way when I programmed using that IDE several years ago. In fact, clrscr( ) was traslated directly...
Jaime Stuardo
jstuardo@...
Jun 2, 2005 5:00 pm
44966
One difference between C and C++ is that, in C, all the local variables have to be declared at the beginning of a function block. In C++, they can be placed...
I was talking about placing clrscr() anywhere, not variables. Of course, in C, variables has to be declared only at the beginning of the block. Maybe I...
Jaime Stuardo
jstuardo@...
Jun 2, 2005 7:31 pm
44968
... I slightly reformatted your code and inserted some comments. void getnew(char** list) ... /* try argv = (char**)malloc(3 * sizeof(char*)); */ argv =...