From bug-request at octave dot org Tue Jan 11 14:50:12 2005 Subject: isascii(1) returns error From: "Vadim Gutnik" To: Cc: "Vadim Gutnik" Date: Tue, 11 Jan 2005 11:55:09 -0600 Bug report for Octave 2.1.64 configured for sparc-sun-solaris2.8 Description: ----------- I'm trying to build Octave on a Sun blade running solaris 2.8. I built and installed (from source) gcc, readline, bison, and dejagnu. Octave builds and installs, and make check passes with no errors. I can start octave, and some simple things work, but isascii does not. octave:6> sin (pi/4) ans = 0.70711 octave:7> isascii('a') ans = 1 So far, so good. octave:8> isascii(1) error: isascii: unable to handle real arguments Not so good. Repeat-By: --------- isascii(1) I did notice another thing; not sure how it relates: octave:19> isascii('a') ans = 1 octave:20> isascii(1) error: isascii: unable to handle real arguments octave:20> isascii(200) error: isascii: unable to handle real arguments octave:20> isascii(['a',1,200]) warning: implicit conversion from scalar to char matrix warning: implicit conversion from scalar to char matrix warning: implicit conversion from scalar to char matrix warning: implicit conversion from char matrix to string ans = 1 1 0 That gives the correct response -- 'a' and 1 are ascii, 200 is not. Fix: --- No clue. I tried rebuilding octave a couple times messing with LD_LIBRARY_PATH, and even tried deleting lex.cc and parse.cc to see if rebuilding them would solve the problem but it did not. Same result. Unfortunately I couldn't figure out what was happening in gdb well enough to get more of a clue. Configuration (please do not edit this section): ----------------------------------------------- uname output: SunOS snoopy 5.8 Generic_117350-02 sun4u sparc SUNW,Sun-Blade-100 configure opts: '--prefix=/home/gutnik/local' 'MAKE=gmake' Fortran compiler: g77 FFLAGS: -O F2C: F2CFLAGS: FLIBS: -L/usr/ccs/lib -L/usr/lib -L/home/gutnik/local/lib/gcc/sparc-sun-solaris2.8/3.4.3 -L/usr/ccs/bin -L/home/gutnik/local/lib/gcc/sparc-sun-solaris2.8/3.4.3/../../.. -lfrtbegin -lg2c -lm -lgcc_s CPPFLAGS: INCFLAGS: -I. -I. -I./liboctave -I./src -I./libcruft/misc -I./glob -I./glob C compiler: gcc, version 3.4.3 CFLAGS: -g -O2 CPICFLAG: -fPIC C++ compiler: g++, version 3.4.3 CXXFLAGS: -g -O2 CXXPICFLAG: -fPIC LD_CXX: g++ LDFLAGS: LIBFLAGS: -L. RLD_FLAG: -R /home/gutnik/local/lib/octave-2.1.64 BLAS_LIBS: FFTW_LIBS: LIBS: -lreadline -lncurses -lm LEXLIB: LIBPLPLOT: LIBDLFCN: LIBGLOB: ./glob/glob.o ./glob/fnmatch.o SED: /opt/sfw/bin/gsed DEFS: -DPACKAGE_NAME="" -DPACKAGE_TARNAME="" -DPACKAGE_VERSION="" -DPACKAGE_STRING="" -DPACKAGE_BUGREPORT="" -DOCTAVE_SOURCE=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_UNISTD_H=1 -DSEPCHAR=1 -DSEPCHAR_STR=":" -D__NO_MATH_INLINES=1 -DCXX_NEW_FRIEND_TEMPLATE_DECL=1 -DCXX_ISO_COMPLIANT_LIBRARY=1 -DCXX_ABI=gnu_v3 -DHAVE_LIBM=1 -DHAVE_IEEE754_DATA_FORMAT=1 -DF77_FUNC(name,NAME)=name ## _ -DF77_FUNC_(name,NAME)=name ## __ -DHAVE_GETHOSTNAME=1 -DHAVE_GETPWNAM=1 -DHAVE_DEV_T=1 -DHAVE_INO_T=1 -DHAVE_NLINK_T=1 -DHAVE_NLINK_T=1 -DHAVE_LONG_LONG_INT=1 -DHAVE_UNSIGNED_LONG_LONG_INT=1 -DHAVE_SIGSET_T=1 -DHAVE_SIG_ATOMIC_T=1 -DSIZEOF_SHORT=2 -DSIZEOF_INT=4 -DSIZEOF_LONG=4 -DSIZEOF_LONG_LONG=8 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DNPOS=std::string::npos -DHAVE_PLACEMENT_DELETE=1 -DHAVE_DYNAMIC_AUTO_ARRAYS=1 -DSTDC_HEADERS=1 -DHAVE_DIRENT_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_SYS_WAIT_H=1 -DHAVE_ASSERT_H=1 -DHAVE_CURSES_H ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------