Error "type specifier omitted for parameter" in preprocessor directives??

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • eminemence@gmail.com

    #1

    Error "type specifier omitted for parameter" in preprocessor directives??

    Hi,
    I have been trying to get STLPort work for Symbian.
    I am using CodeWarrior compiler and it spews this errors namely
    *************** *************** *************** *************** *************
    Error : type specifier omitted for parameter
    string.h line 30
    *************** *************** *************** *************** ************
    The following is the line where I get this error:
    Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
    Line 31 : # include <stl/_epilog.h>
    Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
    Line 33 : # endif

    Can somebody please help me in getting this fixed.
    --eminemence.

  • mlimber

    #2
    Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??

    eminemence@gmai l.com wrote:[color=blue]
    > Hi,
    > I have been trying to get STLPort work for Symbian.
    > I am using CodeWarrior compiler and it spews this errors namely
    > *************** *************** *************** *************** *************
    > Error : type specifier omitted for parameter
    > string.h line 30
    > *************** *************** *************** *************** ************
    > The following is the line where I get this error:
    > Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
    > Line 31 : # include <stl/_epilog.h>
    > Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
    > Line 33 : # endif
    >
    > Can somebody please help me in getting this fixed.
    > --eminemence.[/color]

    What is _STLP_OUTERMOST _HEADER_ID defined as?

    Cheers! --M

    Comment

    • eminemence

      #3
      Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??

      Its a simple #define noting else!!

      Comment

      • Victor Bazarov

        #4
        Re: Error &quot;type specifier omitted for parameter&quot; in preprocessordir ectives??

        eminemence@gmai l.com wrote:[color=blue]
        > I have been trying to get STLPort work for Symbian.
        > I am using CodeWarrior compiler and it spews this errors namely
        > *************** *************** *************** *************** *************
        > Error : type specifier omitted for parameter
        > string.h line 30
        > *************** *************** *************** *************** ************
        > The following is the line where I get this error:
        > Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
        > Line 31 : # include <stl/_epilog.h>
        > Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
        > Line 33 : # endif
        >
        > Can somebody please help me in getting this fixed.[/color]

        Please go to



        STLport has its own forum, they can help you.

        As to the code you posted, there is nothing in it to warrant that error
        message.

        V

        Comment

        • Howard

          #5
          Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??


          <eminemence@gma il.com> wrote in message
          news:1138097001 .268027.86860@g 14g2000cwa.goog legroups.com...[color=blue]
          > Hi,
          > I have been trying to get STLPort work for Symbian.
          > I am using CodeWarrior compiler and it spews this errors namely
          > *************** *************** *************** *************** *************
          > Error : type specifier omitted for parameter
          > string.h line 30
          > *************** *************** *************** *************** ************
          > The following is the line where I get this error:
          > Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
          > Line 31 : # include <stl/_epilog.h>
          > Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
          > Line 33 : # endif
          >
          > Can somebody please help me in getting this fixed.
          > --eminemence.
          >[/color]

          If that's the actual code, then the problem is probably the spaces after the
          # symbol. For example, instead of "# if", it should be #if". I'm not sure
          if that's in the standard anywhere, but my compilers sure won't accept those
          with spaces after the # symbol. If you want to indent, indent the # as
          well, and you'll be fine. Try this:

          #if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
          #include <stl/_epilog.h>
          #undef _STLP_OUTERMOST _HEADER_ID
          #endif

          -Howard

          -Howard



          Comment

          • Marcus Kwok

            #6
            Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??

            Howard <alicebt@hotmai l.com> wrote:[color=blue]
            >
            > <eminemence@gma il.com> wrote in message[color=green]
            >> Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
            >> Line 31 : # include <stl/_epilog.h>
            >> Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
            >> Line 33 : # endif[/color]
            >
            > If that's the actual code, then the problem is probably the spaces after the
            > # symbol. For example, instead of "# if", it should be #if". I'm not sure
            > if that's in the standard anywhere, but my compilers sure won't accept those
            > with spaces after the # symbol. If you want to indent, indent the # as
            > well, and you'll be fine. Try this:
            >
            > #if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
            > #include <stl/_epilog.h>
            > #undef _STLP_OUTERMOST _HEADER_ID
            > #endif[/color]

            I thought the '#' had to be in the first column?

            --
            Marcus Kwok

            Comment

            • JustBoo

              #7
              Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??

              On Tue, 24 Jan 2006 18:43:15 +0000 (UTC), ricecake@gehenn om.net
              (Marcus Kwok) wrote:
              [color=blue][color=green]
              >> #if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
              >> #include <stl/_epilog.h>
              >> #undef _STLP_OUTERMOST _HEADER_ID
              >> #endif[/color]
              >
              >I thought the '#' had to be in the first column?[/color]

              That's interesting. In my compiler I can do this:

              # define BOO
              # define BOO 69

              Those are spaces where the white space is and it complies both
              without errors or warnings. That surprised me. Is there a rule for
              this?

              Comment

              • Victor Bazarov

                #8
                Re: Error &quot;type specifier omitted for parameter&quot; in preprocessordir ectives??

                Marcus Kwok wrote:[color=blue]
                > Howard <alicebt@hotmai l.com> wrote:
                >[color=green]
                >><eminemence@g mail.com> wrote in message
                >>[color=darkred]
                >>>Line 30 : # if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
                >>>Line 31 : # include <stl/_epilog.h>
                >>>Line 32 : # undef _STLP_OUTERMOST _HEADER_ID
                >>>Line 33 : # endif[/color]
                >>
                >>If that's the actual code, then the problem is probably the spaces after the
                >># symbol. For example, instead of "# if", it should be #if". I'm not sure
                >>if that's in the standard anywhere, but my compilers sure won't accept those
                >>with spaces after the # symbol. If you want to indent, indent the # as
                >>well, and you'll be fine. Try this:
                >>
                >>#if (_STLP_OUTERMOS T_HEADER_ID == 0x269)
                >> #include <stl/_epilog.h>
                >> #undef _STLP_OUTERMOST _HEADER_ID
                >>#endif[/color]
                >
                >
                > I thought the '#' had to be in the first column?[/color]

                Are you asking? We don't know what you thought. The '#' has to be the
                first non-whitespace character on the line.

                V

                Comment

                • eminemence

                  #9
                  Re: Error &quot;type specifier omitted for parameter&quot; in preprocessor directives??

                  I have done all the things like a space before '#' and after '#' but it
                  doesn't matter the compiler doesn't care.
                  Anyway the errors gone after the proper files had been included.
                  --eminemence.

                  Comment

                  Working...