dev-cpp-users Mailing List for Dev-C++ (Page 512)
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
You can subscribe to this list here.
| 2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(15) |
Oct
(115) |
Nov
(154) |
Dec
(258) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2001 |
Jan
(377) |
Feb
(260) |
Mar
(249) |
Apr
(188) |
May
(152) |
Jun
(150) |
Jul
(195) |
Aug
(202) |
Sep
(200) |
Oct
(286) |
Nov
(242) |
Dec
(165) |
| 2002 |
Jan
(245) |
Feb
(241) |
Mar
(239) |
Apr
(346) |
May
(406) |
Jun
(369) |
Jul
(418) |
Aug
(357) |
Sep
(362) |
Oct
(597) |
Nov
(455) |
Dec
(344) |
| 2003 |
Jan
(446) |
Feb
(397) |
Mar
(515) |
Apr
(524) |
May
(377) |
Jun
(387) |
Jul
(532) |
Aug
(364) |
Sep
(294) |
Oct
(352) |
Nov
(295) |
Dec
(327) |
| 2004 |
Jan
(416) |
Feb
(318) |
Mar
(324) |
Apr
(249) |
May
(259) |
Jun
(218) |
Jul
(212) |
Aug
(259) |
Sep
(158) |
Oct
(162) |
Nov
(214) |
Dec
(169) |
| 2005 |
Jan
(111) |
Feb
(165) |
Mar
(199) |
Apr
(147) |
May
(131) |
Jun
(163) |
Jul
(235) |
Aug
(136) |
Sep
(84) |
Oct
(88) |
Nov
(113) |
Dec
(100) |
| 2006 |
Jan
(85) |
Feb
(119) |
Mar
(33) |
Apr
(31) |
May
(56) |
Jun
(68) |
Jul
(18) |
Aug
(62) |
Sep
(33) |
Oct
(55) |
Nov
(19) |
Dec
(40) |
| 2007 |
Jan
(22) |
Feb
(49) |
Mar
(34) |
Apr
(51) |
May
(66) |
Jun
(43) |
Jul
(116) |
Aug
(57) |
Sep
(70) |
Oct
(69) |
Nov
(97) |
Dec
(86) |
| 2008 |
Jan
(32) |
Feb
(47) |
Mar
(106) |
Apr
(67) |
May
(28) |
Jun
(39) |
Jul
(31) |
Aug
(25) |
Sep
(18) |
Oct
(25) |
Nov
(5) |
Dec
(21) |
| 2009 |
Jan
(33) |
Feb
(27) |
Mar
(27) |
Apr
(22) |
May
(22) |
Jun
(10) |
Jul
(17) |
Aug
(9) |
Sep
(21) |
Oct
(13) |
Nov
(4) |
Dec
(11) |
| 2010 |
Jan
(10) |
Feb
(8) |
Mar
(4) |
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(8) |
Oct
(26) |
Nov
(9) |
Dec
(1) |
| 2011 |
Jan
(21) |
Feb
(16) |
Mar
(4) |
Apr
(19) |
May
(26) |
Jun
(9) |
Jul
(6) |
Aug
|
Sep
(4) |
Oct
(3) |
Nov
(2) |
Dec
(1) |
| 2012 |
Jan
(4) |
Feb
(7) |
Mar
(4) |
Apr
|
May
(1) |
Jun
(10) |
Jul
(1) |
Aug
(1) |
Sep
(18) |
Oct
(3) |
Nov
(1) |
Dec
(1) |
| 2013 |
Jan
(4) |
Feb
(2) |
Mar
(15) |
Apr
(6) |
May
(1) |
Jun
(3) |
Jul
(1) |
Aug
(2) |
Sep
(4) |
Oct
|
Nov
(9) |
Dec
|
| 2014 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
(4) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(4) |
| 2015 |
Jan
(2) |
Feb
(3) |
Mar
(1) |
Apr
(2) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
(9) |
Nov
(35) |
Dec
(6) |
| 2016 |
Jan
(7) |
Feb
(10) |
Mar
(10) |
Apr
(9) |
May
(13) |
Jun
(9) |
Jul
(1) |
Aug
(3) |
Sep
(3) |
Oct
(1) |
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2019 |
Jan
(1) |
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Bill W. <bil...@at...> - 2002-10-10 02:15:29
|
As a new user porting my source code from Borland 5.02 and Unix, I have = run into a debugging issue. I jhave created a library, and a calling program called MainProg. I cannot seem to get the debugger to step into any of the source coce = modules for the library. =20 The debugger seems to behave like it is entering the module, but nothing = happens on the screen when you do 'Next Step'. =20 If you do a 'Step Over', you return properly to the next line in the = calling source file. Even if I add a given .cpp file from the library to the MainProg = project, I cannot debug into it. The debugger only seems to work when = stepping into functions that are in the MainProg .cpp file itself. Both the library and the Main program have been linked with debugging = turned on. Does anyone have a clue as to what I may not have set properly, or is = this a problem with the GDB degbugger in connectionm with the IDE? Thanks in advance, Bill |
|
From: Vern-N <ve...@cs...> - 2002-10-10 01:03:37
|
trying to compile the default DLL application using the MinGW 3.1 compiler, libs, and includes... also have msys bin folder in my path after mingw. this is the 2.0 snapshot of MinGW. The generated makefile works fine from a cygwin window, but trying to compile w/ dev-c++ gives the following log: Executing make... make.exe -f "C:\newdll\Makefile.win" all g++.exe -c dllmain.cpp -o dllmain.o -I"C:/Program Files/MinGW/include" -I"C:/Program Files/MinGW/include" - I"C:/Program Files/MinGW/include/g++-v3" -DBUILDING_DLL=3D1 -s dllwrap.exe --output-def libnewdll.def --driver-name c++ -- implib libnewdll.a dllmain.o -L"C:/Program Files/MinGW/lib" - -no-export-all-symbols --add-stdcall-alias -o newdll.dll c++: =A0=86: No such file or directory c:\Program Files\MinGW\bin\dllwrap.exe: no export definition file provided. Creating one, but that may not be what you want c:\Program Files\MinGW\bin\dllwrap.exe: c++ exited with status 1 make.exe: *** [newdll.dll] Error 1 Execution terminated All I can figure is something is going wrong w/ the commandline for the dllwrap command... Would really like the convenience of not having to compile from the cygwin shell. I've searched the lists for this problem for some time, and have not come up w/ any similar problems... Any help would be appreciated. Please carbon-copy any responses to me, as I may not be monitoring the list directly. Thanks, -Vern |
|
From: Gregory H. <gr...@fr...> - 2002-10-09 23:27:24
|
I'm having trouble using apstring in Dev-C++. My code is:
#include "iostream.h"
#include "apstring.cpp"
int main ()
{
apstring testString = "test";
if (testString == "test"){
cout << apstring
}
}
I get 6 C:\Dev-Cpp\projects\irs\test.cpp `apstring' undeclared (first use
this function).
When I put apsting.cpp into the function, the first error is the ::.
Any suggestions?
-Greg
|
|
From: Ioannis V. <no...@ho...> - 2002-10-09 23:08:19
|
> -----Original Message----- > From: dev...@li...=20 > [mailto:dev...@li...] On Behalf=20 > Of Andrew Vidler > Sent: Wednesday, October 09, 2002 6:36 PM > To: 'C++ Dev' > Subject: RE: [Dev-C++] Why doesn't this compile? >=20 >=20 > Absolutely. Sorry, I'm probably not being very clear :) > MY_TYPE *p =3D *c > Does work, problem is, what I'm looking for is some operator=20 > that does: > MY_TYPE *p =3D c; >=20 > I don't think this is possible...but you never know! Ok you have confused things. Forget the whole thing completely. Just do: // Example #define MY_TYPE int CBase *c =3D new CDerived; If you want to point to it using some pointer of entirely foreign type, this means you must know what you are doing and use a cast (in your case the ugliest of all, reinterpret_cast). MY_TYPE *f =3D reinterpret_cast<MY_TYPE *>(c); Forget those operators you were using. Ioannis * Ioannis Vranos * Programming pages: http://www.noicys.freeurl.com * Alternative URL: http://run.to/noicys |
|
From: Ioannis V. <no...@ho...> - 2002-10-09 22:55:48
|
> -----Original Message----- > From: dev...@li...=20 > [mailto:dev...@li...] On Behalf=20 > Of Andrew Vidler > Sent: Wednesday, October 09, 2002 6:05 PM > To: 'C++ Dev' > Subject: RE: [Dev-C++] Why doesn't this compile? >=20 >=20 > Ummm...MY_TYPE can be any type, change it to "float" if you like, > doesn't make any difference like I said. > I know the constructors etc... aren't strictly needed, they don't stop > it compiling or working though. > Also, the constructors etc... *are* required for the actual > implementation - this is just a stripped down and renamed version for > test perposes. >=20 > Oh, and I disagree with the "better to 'return 0'" comment :) > 0 is an integer, I know NULL is just #defined as 0, but using NULL > implies a pointer type. > You wouldn't type the following: >=20 > UINT I =3D 27 + NULL; >=20 > Would you?, so why write: >=20 > UINT *p =3D 0; >=20 > ? "The C++ Programming Language" 3rd Edition or Special Edition (you must have this book): On page 88, 5.1.1. On page 835 the first paragraph. Ioannis * Ioannis Vranos * Programming pages: http://www.noicys.freeurl.com * Alternative URL: http://run.to/noicys |
|
From: Matthias <mm...@ma...> - 2002-10-09 20:50:00
|
>>I haven't learned about it yet, but the solution is in >dirent.h, do a
> search ...
>
> Ok, i searched. But all examples that i found didn't compile.
Read up un 'stat', 'lstat' for information about files and directories
make sure that you link with libc.
Then read the paragraph about 'scandir' if you use Unix or
'FindFirstFile'/'FindNextFile' on Windows
----
int fl_filename_isdir(const char* n) {
struct stat s;
#ifdef WIN32
char fn[1024];
int length;
// This workaround brought to you by the fine folks at Microsoft!
// (read lots of sarcasm in that...)
length = strlen(n);
if (length < (int)(sizeof(fn) - 1)) {
if (length < 4 && isalpha(n[0]) && n[1] == ':' &&
(isdirsep(n[2]) || !n[2])) {
// Always use D:/ for drive letters
fn[0] = n[0];
strcpy(fn + 1, ":/");
n = fn;
} else if (length > 0 && isdirsep(n[length - 1])) {
// Strip trailing slash from name...
length --;
memcpy(fn, n, length);
fn[length] = '\0';
n = fn;
}
}
#endif
return !stat(n, &s) && (s.st_mode&0170000)==0040000;
}
|
|
From: Santiago <sa...@ho...> - 2002-10-09 20:41:20
|
Why would programming Windows98 be a good start? ----- Original Message ----- From: "metalseb" <met...@fr...> To: <Dev...@li...> Sent: Wednesday, October 09, 2002 5:23 AM Subject: Re: [Dev-C++] Best book > You could try to find a copy of "Programming Windows98 by Charles Petzold". It's a good book > for anyone a bit newbie about Win programming. > > It's out of print since a while now, but you can still find some at http://www.bookshop.co.uk. > > Kind regards > > -- > Seb |
|
From: <we...@ha...> - 2002-10-09 20:30:11
|
Hi Guys,
Thkz a lot Carlos.
>I haven't learned about it yet, but the solution is in >dirent.h, do a
search ...
Ok, i searched. But all examples that i found didn't compile.
See the example:
#include <stdio.h>
#include <dirent.h>
int main (){
DIR *dirh;
struct dirent *dirp;
static char mydir[20] = "/etc";
if ((dirh = opendir(mydir)) == NULL){
perror("opendir");
return(0);
}
for (dirp = readdir(dirh); dirp != NULL; dirp = readdir(dirh)){
printf("Got dir entry: %s\n",dirp->d_name);
}
closedir(dirh);
}
When i compile i received this error:
[Linker error] undefined reference to `opendir'
[Linker error] undefined reference to `readdir'
[Linker error] undefined reference to `closedir'
What is wrong ?? How to solve it ??
Ahhh, the lib dirent.h appear that haven't a funciont to check if a
directory exist. Someone knwo other way to check ??
Thkz a lot.
Best Regards.
[ ]'s
> Hi Guys,
>
> I have two doubts. If someone can help me... or give-me a example in C. :)
>
> 1) I want to check for example if the directory c:\windows exist. How to
do
> it ?
>
> 2) I want list all files that exist in directory c:\windows. How to do it
??
>
> Thkz a lot.
>
> Best Regards.
>
> [ ]'s
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Dev-cpp-users mailing list
Dev...@li...
TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
|
|
From: Matthias <mm...@ma...> - 2002-10-09 19:42:18
|
The Package Maker is a rewrite of the original code that is checked into the Dev-C++ CVS at Sourceforge. I published the source code to, so you guys can change/add to it. Remeber though, it is - like the original - under GPL license. That means that you have to publish all the changes you do. It would be great if someone could add Makefiles for Linux and Dev-C++ and post them back to me. BTW: it should also compile on Mac OS... . Matthias http://www.matthiasm.com/DevCpp.html Carlos García del Monte wrote: > In the message c++ and dev, it's a link to a site where the mailer has a > program called package maker, it might be wath you want (I didn't prove it, > since I'm not interested in making packages, yet), and it is downloadable as > exe, so you don't need additional downloads (for compiling it you'll need > fltk, if want compile the source, well see at the page) > > http://www.matthiasm.com/DevCpp.html > > Martin Marconcini escribió: > > |
|
From: Colin L. <col...@wa...> - 2002-10-09 18:53:23
|
Hello, We wrote a small package maker, which i was going to release soon. As it was asked on the mailing list, you can download this utility at http://bloodshed.no-ip.org/dev/PackMaker.tar.gz It should be a matter of minutes to create a .DevPak using it. Greetings, Colin Laplace |
|
From: Rodolfo d'E. <rod...@la...> - 2002-10-09 17:54:14
|
Hi, I had a similar problem, in my case I changed the environmental = variables TMP and TEMP, so their values would be a short name directory. = If you have W2k, check both the user variables and the system variables = thorugh the Control Panel.=20 Good luck. Rodolfo d'Ettorre |
|
From: Samuel K. <big...@ya...> - 2002-10-09 17:35:07
|
okay,
I got another one for you. I thought windows would
create a file named LPT1 and put it in the directory
where I ran the .exe file. It didn't. I changed the
file name to USB1 and looked again. There was a file
named USB1 in the same directory as my .exe file.
When I write LPT1 though and run the .exe file, I have
to stop the program by going through ctrl alt del.
Nothing is ever printed, no file made, or if it is I
don't know where it is going. I'm confused. Here is my
source if it will help.
#include <conio.c>
char PrintBuf[5000]; // make it large enough!
int printer(const char *Format,...) //user defined
function
{
char *Ptr = PrintBuf+lstrlen(PrintBuf);
va_list arglist;
va_start(arglist,Format);
vsprintf(Ptr,Format,arglist);
va_end(arglist);
return printf(Ptr);
}
int main()
{
FILE* sfile;
PrintBuf[0] = 0;
// your program runs here......
// just use printer() instead of printf.
// It will print text to screen and into the buffer
// example:
printer("\t\t\tS K DATABASE SOLUTIONS\n\n");
printer("\t\t\t=-=-=-=-=-=-=-=-=-=-=-\n\n");
printer("Employee ID: %d\n",1001);
printer("Employee Name:%s\n","Shashi");
printer("Employee Pay:%f\n",1000.75);
printer("-===-=-=-=-=-=-=-=-=-=-=-=-");
// Now print the buffer to the printer
sfile = fopen("LPT1","wt");
if(sfile)
{
fwrite(PrintBuf,1,lstrlen(PrintBuf),sfile);
fputc('\f',sfile); // add a formfeed for pageprinters
fclose(sfile);
}
return 0;
}
__________________________________________________
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos & More
http://faith.yahoo.com
|
|
From: Carlos d. M. <cg...@wo...> - 2002-10-09 17:29:36
|
I haven't learned about it yet, but the solution is in dirent.h, do a sea= rch about it, there is a couple of pages I have not read yet which seems have= a good information about its use. we...@ha... escribi=F3: > Hi Guys, > > I have two doubts. If someone can help me... or give-me a example in C.= :) > > 1) I want to check for example if the directory c:\windows exist. How t= o do > it ? > > 2) I want list all files that exist in directory c:\windows. How to do = it ?? > > Thkz a lot. > > Best Regards. > > [ ]'s > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > Dev-cpp-users mailing list > Dev...@li... > TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users |
|
From: Carlos d. M. <cg...@wo...> - 2002-10-09 17:16:17
|
In the message c++ and dev, it's a link to a site where the mailer has a program called package maker, it might be wath you want (I didn't prove i= t, since I'm not interested in making packages, yet), and it is downloadable= as exe, so you don't need additional downloads (for compiling it you'll need fltk, if want compile the source, well see at the page) http://www.matthiasm.com/DevCpp.html Martin Marconcini escribi=F3: > Frank: I am looking for the same info... let me know if you find anythi= ng. > > Regards, > > Martin > ----- Original Message ----- > From: "Frank Wagner" <F.W...@wi...> > To: <dev...@li...> > Sent: Wednesday, October 09, 2002 12:38 PM > Subject: Antw: [Dev-C++] DevCpp, Cygwin and DevPacks of GUI Toolkits > > > Hello another time, > > > > I can't believe that there is noone who can tell me how to create a > > DevPac. > > > > Greetings > > > > Frank > > > > > > >>> "Frank Wagner" <F.W...@wi...> 10/07 2:02 >>> > > Hello, > > > > last weekend I installed the lftk GUI Toolkit with its DevPack but > > like > > WxWindows some essential files (libs) can't be find. > > Am I right when I think that the available DevPacks are only for use > > with the MinGW Compiler System? > > In this case I can compile the toolkits under Cygwin but I don't now > > how to create a DevPack, maybe someone can give me a expaination how > > to > > do this? > > > > Greetings > > > > Frank > > > > > > ------------------------------------------------------- > > This sf.net email is sponsored by:ThinkGeek > > Welcome to geek heaven. > > http://thinkgeek.com/sf > > _______________________________________________ > > Dev-cpp-users mailing list > > Dev...@li... > > TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > > > ------------------------------------------------------- > > This sf.net email is sponsored by:ThinkGeek > > Welcome to geek heaven. > > http://thinkgeek.com/sf > > _______________________________________________ > > Dev-cpp-users mailing list > > Dev...@li... > > TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm > > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users > > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > Dev-cpp-users mailing list > Dev...@li... > TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users |
|
From: Samuel K. <big...@ya...> - 2002-10-09 17:02:40
|
Thanks Carlos, You was right, declarations have to be at the front or .c files. I'm used to writing in c++ and forgot about that. Trouble is this only works for Linux because it treats printers as files while windows (I think) treats them differently. So I still can't print. Samuel Keding __________________________________________________ Do you Yahoo!? Faith Hill - Exclusive Performances, Videos & More http://faith.yahoo.com |
|
From: <Ech...@ne...> - 2002-10-09 16:54:05
|
A DevPak file is a *.tar.bz2 file with it's extension renamed to .DevPak I don't believe there is any documentation on the format of the package, but it is fairly easy to "reverse engineer". I have made a DevPak (http://echempel.freezope.org/projects-fall2002/SigCpp-DevPak/libsigcpp-1.1.DevPak) in this manner. I would suggest downloading a few existing DevPaks, renaming them to ____.tar.bz2, un-packing them, and then replacing the contents with your desired contents. After this all that is needed is to repackage and rename the ___.tar.bz2 file to ___.DevPak. Hope this is helpful, if you need any more help feel free to contact me. Evan > Message: 13 > Date: Wed, 09 Oct 2002 12:38:53 +0200 > From: "Frank Wagner" <F.W...@wi...> > To: <dev...@li...> > Subject: Antw: [Dev-C++] DevCpp, Cygwin and DevPacks of GUI Toolkits > > Hello another time, > > I can't believe that there is noone who can tell me how to create a > DevPac. > > Greetings > > Frank > > > >>> "Frank Wagner" <F.W...@wi...> 10/07 2:02 >>> > Hello, > > last weekend I installed the lftk GUI Toolkit with its DevPack but > like > WxWindows some essential files (libs) can't be find. > Am I right when I think that the available DevPacks are only for use > with the MinGW Compiler System? > In this case I can compile the toolkits under Cygwin but I don't now > how to create a DevPack, maybe someone can give me a expaination how > to > do this? > > Greetings > > Frank > __________________________________________________________________ The NEW Netscape 7.0 browser is now available. Upgrade now! http://channels.netscape.com/ns/browsers/download.jsp Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/ |
|
From: <we...@ha...> - 2002-10-09 16:11:11
|
Hi Guys, I have two doubts. If someone can help me... or give-me a example in C. :) 1) I want to check for example if the directory c:\windows exist. How to do it ? 2) I want list all files that exist in directory c:\windows. How to do it ?? Thkz a lot. Best Regards. [ ]'s |
|
From: Daniel G. <sp...@ho...> - 2002-10-09 15:42:55
|
Oh yes of course, that was a schoolboy error there lol. Been doing non-programming projects at work, and I need the C++ practice! >From: "Abhijit Shylanath" <mu...@gm...> >To: "Daniel Glenfield" ><sp...@ho...>,<big...@ya...>,<dev...@li...> >Subject: Re: [Dev-C++] printer >Date: Wed, 9 Oct 2002 20:55:36 +0530 > > > Have you forgotten to include a header file? Does conio.h have the FILE > > declaration in it? > >Nope, <stdio.h> does. > > > Also, your if statement ( if (fp) ), won't that return true is the >pointer > > is anything but null? Shouldn't it be *fp ? Or something? > >No, actually, if(fp) is right. This is basically > >if(fp != NULL), which is what we're checking for. We're checking the >pointer, not the value of the structure (which could be anything, it's >totally unrelated to the pointer). > >___________________________________________________________ > >Abhijit Shylanath > >E-mail: mu...@gm... || ibr...@bi... >Web-site: http://mudeth.tripod.com/ _________________________________________________________________ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com |
|
From: Andrew V. <av...@in...> - 2002-10-09 15:36:18
|
Absolutely. Sorry, I'm probably not being very clear :)
MY_TYPE *p = *c
Does work, problem is, what I'm looking for is some operator that does:
MY_TYPE *p = c;
I don't think this is possible...but you never know!
-----Original Message-----
From: Per Westermark [mailto:pw...@ia...]
Sent: 09 October 2002 16:28
To: Andrew Vidler
Cc: 'C++ Dev'
Subject: RE: [Dev-C++] Why doesn't this compile?
Style issues aside.
Correct me if I'm wrong but, your
operator CDerived::MY_TYPE*();
converts from a CDerived object to a MY_TYPE*.
However, you try to use it to convert from a CDerived*.
This would work:
MY_TYPE *p = *c;
/Per W
On Wed, 9 Oct 2002, Andrew Vidler wrote:
> Ummm...MY_TYPE can be any type, change it to "float" if you like,
> doesn't make any difference like I said. I know the constructors
> etc... aren't strictly needed, they don't stop it compiling or working
> though. Also, the constructors etc... *are* required for the actual
> implementation - this is just a stripped down and renamed version for
> test perposes.
>
> Oh, and I disagree with the "better to 'return 0'" comment :) 0 is an
> integer, I know NULL is just #defined as 0, but using NULL implies a
> pointer type. You wouldn't type the following:
>
> UINT I = 27 + NULL;
>
> Would you?, so why write:
>
> UINT *p = 0;
>
> ?
>
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf Of
> Ioannis Vranos
> Sent: 09 October 2002 15:54
> To: 'C++ Dev'
> Subject: RE: [Dev-C++] Why doesn't this compile?
>
>
> > -----Original Message-----
> > From: dev...@li...
> > [mailto:dev...@li...] On Behalf Of
> > Andrew Vidler
> > Sent: Tuesday, October 08, 2002 10:53 PM
> > To: C++ Dev
> > Subject: [Dev-C++] Why doesn't this compile?
> >
> >
> > And more importantly, how can I make it compile?!
> >
> >
> >
> > #define MY_TYPE IDirect3DBaseTexture8
> >
> > class CBase
> > {
> > public:
> > CBase() {}
>
>
> Not needed.
>
>
> > virtual ~CBase() {}
>
>
> Or better: virtual ~CBase();
>
>
>
> >
> > virtual operator MY_TYPE * () = 0;
>
>
> Where is IDirect3DBaseTexture8 defined?
>
>
>
> > };
> >
> > class CDerived : public CBase
> > {
> > public:
> > CDerived() {}
> > ~CDerived() {}
>
>
> You can ommit the above two.
>
>
> >
> > operator MY_TYPE * () { return NULL; }
>
> Better: return 0;
>
>
> IDirect3DBaseTexture8 not defined anywhere.
>
>
>
> > };
> >
> > void test()
> > {
> > CBase *c = new CDerived();
> > MY_TYPE *f = c;
> > }
> >
> >
> >
> >
> > The #define is there purely so I could see if the code compiled with
> > different types - it doesn't.
>
>
> Ioannis
>
> * Ioannis Vranos
> * Programming pages: http://www.noicys.freeurl.com
> * Alternative URL: http://run.to/noicys
>
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
>
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Dev-cpp-users mailing list Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
|
|
From: Per W. <pw...@ia...> - 2002-10-09 15:28:37
|
Style issues aside.
Correct me if I'm wrong but, your
operator CDerived::MY_TYPE*();
converts from a CDerived object to a MY_TYPE*.
However, you try to use it to convert from a CDerived*.
This would work:
MY_TYPE *p = *c;
/Per W
On Wed, 9 Oct 2002, Andrew Vidler wrote:
> Ummm...MY_TYPE can be any type, change it to "float" if you like,
> doesn't make any difference like I said.
> I know the constructors etc... aren't strictly needed, they don't stop
> it compiling or working though.
> Also, the constructors etc... *are* required for the actual
> implementation - this is just a stripped down and renamed version for
> test perposes.
>
> Oh, and I disagree with the "better to 'return 0'" comment :)
> 0 is an integer, I know NULL is just #defined as 0, but using NULL
> implies a pointer type.
> You wouldn't type the following:
>
> UINT I = 27 + NULL;
>
> Would you?, so why write:
>
> UINT *p = 0;
>
> ?
>
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf Of Ioannis
> Vranos
> Sent: 09 October 2002 15:54
> To: 'C++ Dev'
> Subject: RE: [Dev-C++] Why doesn't this compile?
>
>
> > -----Original Message-----
> > From: dev...@li...
> > [mailto:dev...@li...] On Behalf
> > Of Andrew Vidler
> > Sent: Tuesday, October 08, 2002 10:53 PM
> > To: C++ Dev
> > Subject: [Dev-C++] Why doesn't this compile?
> >
> >
> > And more importantly, how can I make it compile?!
> >
> >
> >
> > #define MY_TYPE IDirect3DBaseTexture8
> >
> > class CBase
> > {
> > public:
> > CBase() {}
>
>
> Not needed.
>
>
> > virtual ~CBase() {}
>
>
> Or better: virtual ~CBase();
>
>
>
> >
> > virtual operator MY_TYPE * () = 0;
>
>
> Where is IDirect3DBaseTexture8 defined?
>
>
>
> > };
> >
> > class CDerived : public CBase
> > {
> > public:
> > CDerived() {}
> > ~CDerived() {}
>
>
> You can ommit the above two.
>
>
> >
> > operator MY_TYPE * () { return NULL; }
>
> Better: return 0;
>
>
> IDirect3DBaseTexture8 not defined anywhere.
>
>
>
> > };
> >
> > void test()
> > {
> > CBase *c = new CDerived();
> > MY_TYPE *f = c;
> > }
> >
> >
> >
> >
> > The #define is there purely so I could see if the code compiled with
> > different types - it doesn't.
>
>
> Ioannis
>
> * Ioannis Vranos
> * Programming pages: http://www.noicys.freeurl.com
> * Alternative URL: http://run.to/noicys
>
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
>
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
|
|
From: Abhijit S. <mu...@gm...> - 2002-10-09 15:26:00
|
> Have you forgotten to include a header file? Does conio.h have the FILE > declaration in it? Nope, <stdio.h> does. > Also, your if statement ( if (fp) ), won't that return true is the pointer > is anything but null? Shouldn't it be *fp ? Or something? No, actually, if(fp) is right. This is basically if(fp != NULL), which is what we're checking for. We're checking the pointer, not the value of the structure (which could be anything, it's totally unrelated to the pointer). ___________________________________________________________ Abhijit Shylanath E-mail: mu...@gm... || ibr...@bi... Web-site: http://mudeth.tripod.com/ |
|
From: Andrew V. <av...@in...> - 2002-10-09 15:05:30
|
Ummm...MY_TYPE can be any type, change it to "float" if you like,
doesn't make any difference like I said.
I know the constructors etc... aren't strictly needed, they don't stop
it compiling or working though.
Also, the constructors etc... *are* required for the actual
implementation - this is just a stripped down and renamed version for
test perposes.
Oh, and I disagree with the "better to 'return 0'" comment :)
0 is an integer, I know NULL is just #defined as 0, but using NULL
implies a pointer type.
You wouldn't type the following:
UINT I = 27 + NULL;
Would you?, so why write:
UINT *p = 0;
?
-----Original Message-----
From: dev...@li...
[mailto:dev...@li...] On Behalf Of Ioannis
Vranos
Sent: 09 October 2002 15:54
To: 'C++ Dev'
Subject: RE: [Dev-C++] Why doesn't this compile?
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf
> Of Andrew Vidler
> Sent: Tuesday, October 08, 2002 10:53 PM
> To: C++ Dev
> Subject: [Dev-C++] Why doesn't this compile?
>
>
> And more importantly, how can I make it compile?!
>
>
>
> #define MY_TYPE IDirect3DBaseTexture8
>
> class CBase
> {
> public:
> CBase() {}
Not needed.
> virtual ~CBase() {}
Or better: virtual ~CBase();
>
> virtual operator MY_TYPE * () = 0;
Where is IDirect3DBaseTexture8 defined?
> };
>
> class CDerived : public CBase
> {
> public:
> CDerived() {}
> ~CDerived() {}
You can ommit the above two.
>
> operator MY_TYPE * () { return NULL; }
Better: return 0;
IDirect3DBaseTexture8 not defined anywhere.
> };
>
> void test()
> {
> CBase *c = new CDerived();
> MY_TYPE *f = c;
> }
>
>
>
>
> The #define is there purely so I could see if the code compiled with
> different types - it doesn't.
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.freeurl.com
* Alternative URL: http://run.to/noicys
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf _______________________________________________
Dev-cpp-users mailing list
Dev...@li...
TO UNSUBSCRIBE: http://www.noicys.cjb.net/devcpp/ub.htm
https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
|
|
From: Ioannis V. <no...@ho...> - 2002-10-09 14:54:20
|
> -----Original Message-----
> From: dev...@li...=20
> [mailto:dev...@li...] On Behalf=20
> Of Andrew Vidler
> Sent: Tuesday, October 08, 2002 10:53 PM
> To: C++ Dev
> Subject: [Dev-C++] Why doesn't this compile?
>=20
>=20
> And more importantly, how can I make it compile?!
>=20
>=20
>=20
> #define MY_TYPE IDirect3DBaseTexture8
>=20
> class CBase
> {
> public:
> CBase() {}
Not needed.
> virtual ~CBase() {}
Or better: virtual ~CBase();
>=20
> virtual operator MY_TYPE * () =3D 0;
Where is IDirect3DBaseTexture8 defined?
> };
>=20
> class CDerived : public CBase
> {
> public:
> CDerived() {}
> ~CDerived() {}
You can ommit the above two.
>=20
> operator MY_TYPE * () { return NULL; }
Better: return 0;
IDirect3DBaseTexture8 not defined anywhere.
> };
>=20
> void test()
> {
> CBase *c =3D new CDerived();
> MY_TYPE *f =3D c;
> }
>=20
>=20
>=20
>=20
> The #define is there purely so I could see if the code compiled with
> different types - it doesn't.
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.freeurl.com
* Alternative URL: http://run.to/noicys
|
|
From: Elizabeth B. <sog...@ya...> - 2002-10-09 12:43:50
|
"Frank Wagner" <F.W...@wi...> writes: > I can't believe that there is noone who can tell me how to create a > DevPac. Hi, A DevPac is a bzipped2 tar file with the addition of a "Manifest" file in the root (of the archive) directory entitiled "PackageName.DevPackage". This file is very important and is an .ini file. [Setup] Version=1 AppName=LibXML AppVersion=2.4.22 AppVerName=LibXML 2.4.22 MenuName=LibXML Description=An XML parsing library. Url=http://www.libxml.org/ Readme=Readme.txt License=License.txt Dependencies=i18n [Icons] Website=http://www.libxml.org/ Introduction=http://www.xmlsoft.org/intro.html Documentation=http://www.xmlsoft.org/docs.html FAQ=http://www.xmlsoft.org/FAQ.html [Files] include=<app>\include\ lib=<app>\lib\ Note that during the install, the include and lib files are copied over and, for the above DevPack, the first directory layer looks like this: libxml-dev-2.4.22/: LibXML.DevPackage License.txt Readme.txt include/ lib/ So, after you make the directory structure, you can tar it up and then run it through bzip2. Call it something with a DevPak extension. tar cf - libxml-dev-2.4.22/ | bzip2 -c > libxml-dev-2.4.22.DevPak Elizabeth |
|
From: Christophe C. <chr...@fr...> - 2002-10-09 12:00:50
|
Hi, you should use dev-cpp package maker to create new devpacks. I don't know of any exe distribution of this tool, but you can get it's source from dev-cpp cvs. If my memory is OK, borland offers a free personal delphi version to download. I didn't find it anymore, but at least you can freely download kylix. But I think a C++ rewrite wouldn't be a so bad idea, since I'm not very used to pascal... It would be great to compile dev-c++ with "itself" (not really cause it isn't the compiler, but...) Krap |