Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [photran] Re: myprog < input.file in photran??? (Luud Heck)

This would be a good question to put to the CDT information list as Photran inherits all of this functionality from CDT and the Eclipse platform.

Cheers,
Craig



On Aug 29, 2006, at 10:40 AM, Chris Malins wrote:

Hi,

I am certainly not an expert, or even very experienced user, but I have been working against this self same problem today and have been able to get photran to accept my input file using '< input.file' in the (x)arguments box.

One problem I created for myself was by trying to put the input file name in the Common -> Standard input and output -> File box. This had caused standard output of an abortive run to be written over my input file, and therefore prevented the program from running properly with the input filename in the arguments box. Could you have done this?

I see what Luud is trying to say, but I would persevere a little as I have made this work for me, leading me to believe that it is indeed possible!

Yours,

Chris


------------------------------
Message: 3
Date: Tue, 29 Aug 2006 09:47:09 +0200
From: "Luud Heck" <luud.heck@xxxxxxxxx>
Subject: Re: [photran] myprog < input.file in photran???
To: "Photran Information" <photran@xxxxxxxxxxx>
Message-ID:
	<84e3a0ac0608290047k7492b9a4y9ad953a0316005de@xxxxxxxxxxxxxx>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
On 8/28/06, Thomas Reichardt <thomas.reichardt@xxxxxxxxxxxxxxx> wrote:
Dear photran users

with a terminal I can execute a program with "myprog < input.file".

How does this work in Eclipse(Photran)?

I have tried it by inserting "< input.file" in run -> (x)arguments,
unfortunately without success.

Regards,
Thomas

Hi Thomas,
Indeed this does not work in Eclipse. Note that the < sign is
interpreted by the command shell and it will open the file for you and
pass it to stdin of your program. The arguments that you set in
Eclipse are just that, arguments which are not processes by a command
shell. So a way around this is to change your program to accept a
filename as argument and open it yourself and default to stdin if no
argument is given in order to keep the orinal functionality as well.
Good luck.
Luud
------------------------------
_______________________________________________
photran mailing list
photran@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/photran
End of photran Digest, Vol 12, Issue 8
**************************************
_______________________________________________
photran mailing list
photran@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/photran



Back to the top