www.digitalmars.com         C & C++   DMDScript  

D - Help!!!! (Off Topic!)

reply "Andrew" <crxace13 comcast.net> writes:
I've been working on this silly little program in C++ and am
having some problems getting it to run.  Error codes refer to
something wrong in the money.h file, however I am not capable of
fixing the problem.

Normally, I wouldn't think of asking this question here, but I
running out of time so I thought I might give it a shot.

Thanks in advance.
Andrew

(P.S. The header file was created by the writers of a book I'm
using called "Problem Solving, Abstraction, and Design Using
C++," which is loaded with problems of its own.)
Jun 11 2002
next sibling parent reply "Andrew" <crxace13 comcast.net> writes:
Pavel Minayev wrote:
|
| If you look at the comment, you will see that you probably need
to
| link money.cpp (whatever it is) to your program as well...
|

I have the file...but am unsure of how to link another source
file to my own. The only linking I'm capable of right now is that
which is automatically performed after compilation.
Jun 11 2002
parent reply "Sean L. Palmer" <seanpalmer earthlink.net> writes:
Maybe I'm crazy but it seems that DMD could automatically figure out what
OBJ and LIBs are necessary (to a point!) by analyzing import statements in
the main file.

It should be able to get all the ones in the main app because they are all
interconnected.  Stuff like OpenGL, WinGDI, etc would have to be specified
but with some small addition to the language we could specify this
information inside the D import "header"

For instance in WinGDI.d:

// WinGDI.d
// import functions within WinGDI32.DLL

import wingdi32.lib;

struct RECT
{
  int left,top,right,bottom;
}

...

Then we would not have to pass much at all to the LINK command line.  Just
paths so it can find all the libraries it decides it needs.

Sean

"Andrew" <crxace13 comcast.net> wrote in message
news:ae4v0d$2gvq$1 digitaldaemon.com...
 Pavel Minayev wrote:
 |
 | If you look at the comment, you will see that you probably need
 to
 | link money.cpp (whatever it is) to your program as well...
 |

 I have the file...but am unsure of how to link another source
 file to my own. The only linking I'm capable of right now is that
 which is automatically performed after compilation.

Jun 11 2002
parent reply "Pavel Minayev" <evilone omen.ru> writes:
"Sean L. Palmer" <seanpalmer earthlink.net> wrote in message
news:ae5h63$2oq$1 digitaldaemon.com...

 Maybe I'm crazy but it seems that DMD could automatically figure out what
 OBJ and LIBs are necessary (to a point!) by analyzing import statements in
 the main file.

Indeed. Delphi does it since version 1.0. =)
Jun 12 2002
parent reply "Walter" <walter digitalmars.com> writes:
"Pavel Minayev" <evilone omen.ru> wrote in message
news:ae70td$1k13$1 digitaldaemon.com...
 "Sean L. Palmer" <seanpalmer earthlink.net> wrote in message
 news:ae5h63$2oq$1 digitaldaemon.com...

 Maybe I'm crazy but it seems that DMD could automatically figure out


 OBJ and LIBs are necessary (to a point!) by analyzing import statements


 the main file.

Indeed. Delphi does it since version 1.0. =)

It is entirely possible to do that with D. It is not, strictly speaking, a feature of the language but of the compiler. It's also possible with a D build system to eliminate make.
Jun 12 2002
parent reply "Robert W. Cunningham" <rcunning acm.org> writes:
Walter wrote:

 It's also possible with a D build system to eliminate make.

Getting rid of the preprocessor was good. But you're going to take away Make as well? Next thing you know, you'll replace my bash and wish (TCL) shells with a D interpreter. Then the only language I'll need to know will be D. Wait: You're not planning on making powerful regexps part of the D language, are you? No? Then it looks like I'll be able to keep Perl after all... -BobC
Jun 12 2002
next sibling parent "Matthew Wilson" <dm synesis-group.com> writes:
That's not a bad idea though. That would be rather nice.

Any thoughts on making this a serious library ... ?

"Robert W. Cunningham" <rcunning acm.org> wrote in message
news:3D07D46B.E7BCC32B acm.org...
 Walter wrote:

 It's also possible with a D build system to eliminate make.

Getting rid of the preprocessor was good. But you're going to take away Make as well? Next thing you know, you'll replace my bash and wish (TCL) shells with a D interpreter. Then the only language I'll need to know will be D. Wait: You're not planning on making powerful regexps part of the D

 are you?

 No?  Then it looks like I'll be able to keep Perl after all...


 -BobC

Jun 12 2002
prev sibling parent reply "Walter" <walter digitalmars.com> writes:
Phobos has a nice regexp package in it. -Walter

"Robert W. Cunningham" <rcunning acm.org> wrote in message
news:3D07D46B.E7BCC32B acm.org...
 Walter wrote:

 It's also possible with a D build system to eliminate make.

Getting rid of the preprocessor was good. But you're going to take away Make as well? Next thing you know, you'll replace my bash and wish (TCL) shells with a D interpreter. Then the only language I'll need to know will be D. Wait: You're not planning on making powerful regexps part of the D

 are you?

 No?  Then it looks like I'll be able to keep Perl after all...


 -BobC

Jun 12 2002
parent reply "Matthew Wilson" <matthew thedjournal.com> writes:
See, I told you I didn't know anything. :)

"Walter" <walter digitalmars.com> wrote in message
news:ae99bg$280t$1 digitaldaemon.com...
 Phobos has a nice regexp package in it. -Walter

 "Robert W. Cunningham" <rcunning acm.org> wrote in message
 news:3D07D46B.E7BCC32B acm.org...
 Walter wrote:

 It's also possible with a D build system to eliminate make.

Getting rid of the preprocessor was good. But you're going to take away Make as well? Next thing you know, you'll replace my bash and wish (TCL) shells with a


 interpreter.

 Then the only language I'll need to know will be D.

 Wait:  You're not planning on making powerful regexps part of the D

 are you?

 No?  Then it looks like I'll be able to keep Perl after all...


 -BobC


Jun 12 2002
parent reply "Andrew Edwards" <crxace13 comcast.net> writes:
Point taken!!!

"Matthew Wilson" <matthew thedjournal.com> wrote in message
news:ae99ki$288e$1 digitaldaemon.com...
| See, I told you I didn't know anything. :)
|
| "Walter" <walter digitalmars.com> wrote in message
| news:ae99bg$280t$1 digitaldaemon.com...
| > Phobos has a nice regexp package in it. -Walter
| >
| > "Robert W. Cunningham" <rcunning acm.org> wrote in message
| > news:3D07D46B.E7BCC32B acm.org...
| > > Walter wrote:
| > >
| > > > It's also possible with a D build system to eliminate make.
| > >
| > > Getting rid of the preprocessor was good.
| > >
| > > But you're going to take away Make as well?
| > >
| > > Next thing you know, you'll replace my bash and wish (TCL) shells
with a
| D
| > > interpreter.
| > >
| > > Then the only language I'll need to know will be D.
| > >
| > > Wait:  You're not planning on making powerful regexps part of the D
| > language,
| > > are you?
| > >
| > > No?  Then it looks like I'll be able to keep Perl after all...
| > >
| > >
| > > -BobC
| > >
| > >
| >
| >
|
|
Jun 12 2002
parent reply "Matthew Wilson" <matthew thedjournal.com> writes:
Don't worry Andrew, I'm not having a dig - just a sarcastic English git,
surrounded by even more sarcastic Australian gits. (ooh, maybe I shouldn't
mention that, as that will help the stalkers track me down!)

"Andrew Edwards" <crxace13 comcast.net> wrote in message
news:ae99pp$289n$1 digitaldaemon.com...
 Point taken!!!

 "Matthew Wilson" <matthew thedjournal.com> wrote in message
 news:ae99ki$288e$1 digitaldaemon.com...
 | See, I told you I didn't know anything. :)
 |
 | "Walter" <walter digitalmars.com> wrote in message
 | news:ae99bg$280t$1 digitaldaemon.com...
 | > Phobos has a nice regexp package in it. -Walter
 | >
 | > "Robert W. Cunningham" <rcunning acm.org> wrote in message
 | > news:3D07D46B.E7BCC32B acm.org...
 | > > Walter wrote:
 | > >
 | > > > It's also possible with a D build system to eliminate make.
 | > >
 | > > Getting rid of the preprocessor was good.
 | > >
 | > > But you're going to take away Make as well?
 | > >
 | > > Next thing you know, you'll replace my bash and wish (TCL) shells
 with a
 | D
 | > > interpreter.
 | > >
 | > > Then the only language I'll need to know will be D.
 | > >
 | > > Wait:  You're not planning on making powerful regexps part of the D
 | > language,
 | > > are you?
 | > >
 | > > No?  Then it looks like I'll be able to keep Perl after all...
 | > >
 | > >
 | > > -BobC
 | > >
 | > >
 | >
 | >
 |
 |

Jun 12 2002
parent "Carlos" <carlos8294 msn.com> writes:
"Matthew Wilson" <matthew thedjournal.com> escribió en el mensaje
news:ae9a82$28ph$1 digitaldaemon.com...
 Don't worry Andrew, I'm not having a dig - just a sarcastic English git,
 surrounded by even more sarcastic Australian gits. (ooh, maybe I shouldn't
 mention that, as that will help the stalkers track me down!)

Jun 13 2002
prev sibling parent "Andrew" <crxace13 comcast.net> writes:
I got it!
Thanks allot Pavel.
Jun 11 2002