LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 05-13-2004, 06:32 AM   #1
sheenak
LQ Newbie
 
Registered: Apr 2004
Posts: 23

Rep: Reputation: 15
STL Support in Linux


Hi all,

I have been working on a Porting project. I am moving my source code from VC6++ to KDE Linux.

I am facing some compilation errors:

These errors primarily due to the class _Ty and _Nodeptr term. After search i came across these terms in a file called list, which is a part of the STL Library.

Since this source code is working file on VC++ but is not working on KDE Linux. So, i checked the contents of the file list available in Linux.

It was found that the contents of the file differs from that on Windows platform.

So, how should i solve these compilation errors which are like:

>>>>>>>parse error before the ',' token in line :->

void shiftNode(_Nodeptr node, long const shift)

>>>>>>>>declaration of class _Ty

template <class _Ty> void check( CPersists *ptr) {

cout<< "Inside";
_Ty::constructor(ptr);
}


>>>>>>>>>shadows template parm 'class _Ty'


Am i targetting the problem right.

Can any one provide me a solution of this problem.

Plz give me a push back !
 
Old 05-13-2004, 12:48 PM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
What is your compiler version?
 
Old 05-13-2004, 10:50 PM   #3
sheenak
LQ Newbie
 
Registered: Apr 2004
Posts: 23

Original Poster
Rep: Reputation: 15
I got the solution:

Just compare the files from the Windows version and the Linux version. You will find the structure definition some whr which will be comparable to that in Windows file.

So, give the definition in your source code based on the parameters from the Linux file rather than that of Windows file.

It will solve the problem.
 
  


Reply



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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
about STL programming wangjinyi Programming 2 03-24-2005 05:45 PM
why are there many strange errors when I use STL in Linux icoming Programming 4 10-11-2004 04:05 PM
STL errors in Linux sheenak Programming 2 06-22-2004 04:54 AM
c++ and stl G67 Programming 4 12-17-2003 02:36 AM
Support your Favorite Distro, Support Linux. bkeating Linux - General 41 05-24-2002 05:03 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 12:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration