Go Back   ZeroC Forums > Help Center

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
  #1 (permalink)  
Old 09-28-2004
MKoleoso MKoleoso is offline
Registered User
 
 
Join Date: Feb 2004
Location: Aachen, Germany
Posts: 9
slice2cpp syntax error using string simple types

Hi all,
im currently having problems with slice2cpp creating sources for the following
TestInterface.ice file:

module TestModule{
interface TestInterface{
string userName;
bool IsConnected();
};
};
which give me a syntax error for the line containing string userName;
>> stUserData.ice:3: syntax error

I'm using the command
/opt/ICE-1.2.0/bin/slice2cpp TestInterface.ice
to get c++ source files from this. slice2java reports the same problem.
However, it compiles fine if I remove the string from the interface.

My system is SUSE Linux 9.1, ICE v1.2.0, and I compiled & installed ICE without problems.

Have I missed something I need to setup for Linux so that 'string' is a basic type the slice2cpp code generator will accept?

Greetings.
Reply With Quote
  #2 (permalink)  
Old 09-28-2004
marc's Avatar
marc marc is offline
ZeroC Staff
 
Name: Marc Laukien
Organization: ZeroC, Inc.
Project: The Internet Communications Engine
 
Join Date: Feb 2003
Location: Florida
Posts: 1,781
It's a syntax error because interfaces cannot have data members.
Reply With Quote
  #3 (permalink)  
Old 09-28-2004
MKoleoso MKoleoso is offline
Registered User
 
 
Join Date: Feb 2004
Location: Aachen, Germany
Posts: 9
Smile Ah! Yes!

Hi again,
that's absolutely right. I'm mixing up my interface definition and the implementation...

Thanks!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
slice2cpp --dll-export error xdm Bug Reports 1 11-06-2006 09:37 AM
slice2cpp error JimSec Bug Reports 1 08-16-2006 02:05 PM
encoding error when Ice java client get string from Ice c++ server casper Help Center 1 09-16-2005 04:01 AM
An error occurs when c# client send chinese string to c++ server ChaosXu Help Center 4 10-29-2004 08:12 AM
Compile error, slice2cpp, VC7 Kaos Help Center 2 05-06-2004 12:22 PM


All times are GMT -4. The time now is 09:29 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0
(c) 2008 ZeroC, Inc.