Re: Expand macro's

Discussion in 'C++' started by Victor Bazarov, Jul 22, 2003.

  1. "Darius Blaszijk" <> wrote...
    > I was wondering if there is something like a tool that does expand all
    > macro's from a project?? User defined and preferrably system macro's. Ok,

    I
    > know that the preprocessor does the same, but is there such a tool without
    > having to use the bulky preprocessor. Or if this is not possible, how can

    I
    > use the preprocessor to expand a project for me?? Please spell it out for
    > me, as I'm only a beginner in C. I use DJGPP as a compiler.


    (a) If you're a beginner in C, why are you posting to a C++ newsgroup?
    Those are two different languages.

    (b) Compilers usually have command-line options that allow the user to
    control the output. I can't be sure of DJGPP, take a look at its
    help and find the option that allows you to get "preprocessor output"
    in a separate file. As an example, G++ has the option -E, which tells
    it to preprocess the input file only, no compilation. Combined
    with -o it can give you the desired result. Again, I don't know DJGPP
    that well.

    Victor
    Victor Bazarov, Jul 22, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. MiniDisc_2k2

    Re: Expand macro's

    MiniDisc_2k2, Jul 22, 2003, in forum: C++
    Replies:
    4
    Views:
    505
    Stewart Gordon
    Jul 22, 2003
  2. Guy Harrison

    Re: Expand macro's

    Guy Harrison, Jul 22, 2003, in forum: C++
    Replies:
    0
    Views:
    364
    Guy Harrison
    Jul 22, 2003
  3. sathyashrayan

    pls expand this macro

    sathyashrayan, Oct 30, 2005, in forum: C Programming
    Replies:
    8
    Views:
    409
    Simon Biber
    Oct 31, 2005
  4. Fabrice
    Replies:
    12
    Views:
    532
    Keith Thompson
    Nov 1, 2007
  5. Doug .

    C macro to expand struct types?

    Doug ., Jul 1, 2011, in forum: C Programming
    Replies:
    1
    Views:
    1,191
    Shao Miller
    Jul 3, 2011
Loading...

Share This Page