Opened 12 years ago

Closed 11 years ago

Last modified 9 years ago

#739 closed bug (worksforme)

command-line expressions with double-quoted strings misinterpret some special symbols

Reported by: pedromiguel.duarte@… Owned by:
Priority: normal Milestone:
Component: Compiler Version: 6.4.1
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


try for instance

ghc -e " reverse \"2<3\" " or ghc -e " reverse \"23\" "

The first gives a parsing error, while the second returns "32" instead of "32"

Change History (5)

comment:1 Changed 12 years ago by simonmar

Resolution: worksforme
Status: newclosed

Discussion on the mailing list indicates that you were trying to do this from Java, and the problem is a result of the Java exec interface not understanding quoting (perhaps).

The examples you give work fine from a /bin/sh command line on Linux or Windows.

If you can provide a more specific example that fails, please re-open the bug.

comment:2 Changed 11 years ago by simonpj

Resolution: worksforme
Status: closedreopened

I am running GHC on a windows XP platform. The bug i did report has nothing to do with java. Yes I found the problem while running a java program, but then i did try to execute

   ghc -e "reverse \"2<3\"" 

directly on a command line, and i get a message like "the system can't find the specified file".

If try

   ghc -e "reverse \"2^3\"" 

then i get "32"

If you think its's worth i can rewrite these examples as a new bug.


comment:3 Changed 11 years ago by simonmar

Resolution: worksforme
Status: reopenedclosed

I think the submitter of the bug is expecting shell quoting to work in a different way than it actually does, and/or is using a shell with quoting semantics different from those expected.

comment:4 Changed 9 years ago by simonmar

Architecture: UnknownUnknown/Multiple

comment:5 Changed 9 years ago by simonmar

Operating System: UnknownUnknown/Multiple
Note: See TracTickets for help on using tickets.