#ifndef error...

krisjakobsenkrisjakobsen Kristoffer JakobsenOrganization: Engineering College of AarhusProject: An industrial machine with object oriented commMember
Hi,

Whats is wrong this Ice:
#ifndef DATETIME_ICE
#define DATETIME_ICE
module Logs
{
class Datetime
{
long year;
long month;
long date;
long hour;
long minute;
long second;
long milisecond;
};
};

#endif

When I compile it, it returns with this error message:
Error 1 error: Not in a #if (#ifdef) section Datetime.ice 17 1

Kind Regards
Kristoffer

Comments

  • dwaynedwayne St. John's, NewfoundlandDwayne BooneOrganization: ZeroC, Inc.Project: Internet Communications EngineMember
    What Ice version, slice compiler and OS is this with?
  • krisjakobsenkrisjakobsen Kristoffer JakobsenOrganization: Engineering College of AarhusProject: An industrial machine with object oriented commMember
    Win xp, Ice3.4, where do I find the version of the slice compiler? But i have not installed anything else than standard.
  • dwaynedwayne St. John's, NewfoundlandDwayne BooneOrganization: ZeroC, Inc.Project: Internet Communications EngineMember
    I meant which slice compiler, as in C++, Java, etc.
  • krisjakobsenkrisjakobsen Kristoffer JakobsenOrganization: Engineering College of AarhusProject: An industrial machine with object oriented commMember
    ohh, It is Slice2CS...
  • dwaynedwayne St. John's, NewfoundlandDwayne BooneOrganization: ZeroC, Inc.Project: Internet Communications EngineMember
    I do not see anything wrong with the slice nor can I reproduce the error. That error would occur if the #ifndef line were missing. Perhaps there are some extraneous characters in your slice file that are causing the problem?

    Maybe you could attach the actual file that is failing rather than just cutting and pasting the contents.
Sign In or Register to comment.