1. Bug in Euphoria for Linux?
- Posted by JJProg at CYBERBURY.NET Dec 27, 1999
- 353 views
- Last edited Dec 28, 1999
In Euphoria for Linux, the ~ character apparently doesn't work. I created a program in my home directory called test.exu: integer f f = open("~/test.exu","r") if f = -1 then puts(1,"f = -1\n") abort(0) end if close(f) When I run it, it displays f = -1. Jeffrey Fielding JJProg at cyberbury.net http://members.tripod.com/~JJProg/
2. Re: Bug in Euphoria for Linux?
- Posted by Robert Craig <rds at ATTCANADA.NET> Dec 27, 1999
- 318 views
- Last edited Dec 28, 1999
Jeffrey Fielding writes: > In Euphoria for Linux, the ~ character apparently doesn't work. > I created a program in my home directory called test.exu: > integer f > f = open("~/test.exu","r") > if f = -1 then > puts(1,"f = -1\n") > abort(0) > end if > close(f) > When I run it, it displays f = -1. I believe the '~' character is a special feature of the Linux shell that you are using. It's not a part of the underlying file system, so it doesn't mean anything to the open() command. ~ seems to be equivalent to $HOME so you could do: tilde = getenv("HOME") f = open(tilde & "/test.exu", "r") Regards, Rob Craig Rapid Deployment Software http://www.RapidEuphoria.com