aboutsummaryrefslogtreecommitdiff
path: root/lang/seed7
Commit message (Collapse)AuthorAgeFilesLines
* - Update to 05_20140420Pietro Cerutti2014-04-222-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The chapter in the manual about the foreign function interface has been improved. * A paragraph about regular expressions and lexical scanner functions has been added to the FAQ. * The handling of the actions CHR_CLIT and INT_STRI in the compiler has been improved. The string buffers for chrCLitToBuffer and intStrToBuffer use the correct alignment now. * In big_rtl.c the functions bigParseBasedPow2 and bigParseBased2To36 have been added and bigParseBased has been changed to call them. This improves the conversion of a string to a bigInteger, when the base is a power of two. Valgrind measurements of the function bigParseBased in chkbig.sd7 show a speed improvement with a factor of 239. * The macros memcpy_to_strelem and memset_to_strelem (defined in striutl.h) have been turned into functions (defined in striutl.c). * The unrolling in memcpy_to_strelem and memset_to_strelem has been changed from 8 times to 32 times. This improves the performance for big data amounts by 16% (Measured with valgrind and gcc). * Usages of the macros memcpy_to_strelem and memset_to_strelem in bst_rtl.c, fil_rtl.c, soc_rtl.c and str_rtl.c have been turned into usages of the corresponding functions. * Calls of cstri_expand, ustri_expand, cstri_expand2 and ustri_expand2 in analyze.c, chr_rtl.c, flt_rtl.c, infile.c, str_rtl.c and striutl.c have been turned into calls of memcpy_to_strelem. * The functions (macros) cstri_expand, ustri_expand, cstri_expand2 and ustri_expand2 have been removed from striutl.c and striutl.h. * The functions doCompileAndLink, compileAndLinkWithOptionsOk, compileAndLinkOk, appendToFile and detemineDatabaseDefines have been added to chkccomp.c. The function compilationOkay has been replaced by compileAndLinkOk. Notes: svn path=/head/; revision=351847
* - Update to 05_20140406Pietro Cerutti2014-04-153-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * The chapters in the manual about primitive actions and the foreign function interface have been improved. * The names of the C types used in interpreter and runtime library have been refactored to use camel case. * The elements in the unions valueUnion (in data.h) and rtlValueUnion (in data_rtl.h and s7c.sd7) have been refactored to use names with camel case. * The library bigint.s7i has been changed to define the operators radix and RADIX with the actions BIG_radix and BIG_RADIX. This results in a significant performance improvement when large numbers are converted. * Interpreter and compiler have been improved to support the actions BIG_radix and BIG_RADIX. * Testcases for the operators radix and RADIX have been added to chkbig.sd7. * The compiler has been improved to do an optimization for the action INT_MDIV when the divisor is known at compile time. When the dividend is known to be positive or zero it is casted to an unsigned integer and the quotient is casted back to a signed integer. Dividing an unsigned integer by a constant is known to be faster than dividing a signed integer. * The functions bigRadix, bigRadixPow2, bigRadix2To36 and uBigDivideByDigit have been added to big_rtl.c * The function bigRadix has been added to big_gmp.c. * The functions stri_to_cstri8_buf and cstri8_buf_to_stri have been added to striutl.c. * In traceutl.c the function mapTraceFlags has been improved to work correctly when the parameter trace_level defines several options. * The function printTraceOptions has been added to traceutl.c. * In arr_rtl.c the definition of getArgv has been improved to use less #ifdef directives in the function body. Notes: svn path=/head/; revision=351307
* - Update to 05_20140316Pietro Cerutti2014-03-172-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The documentation file doc/install.txt has been improved to describe the command 'make install'. * The chapter about the foreign function interface in the manual has been improved. * In striutl.h the macros os_stri_alloc and os_stri_free have been improved to use a stack like allocation. Allocations done with os_stri_alloc must be freed with os_stri_free in the reverse order of their creation. The new macros reduce the runtime of stri_to_os_stri and cp_to_os_path to 66% of the old time. This reduces the time used by operating system calls. E.g.: The CPU time used by the program sydir7 is reduced to 83% of the old time. * The targets 'install' and 'uninstall' have been added to makefile, mk_linux.mak, mk_osx.mak, mk_clang.mak, mk_cygw.mak, mk_mingw.mak, mk_msys.mak, mk_nmake.mak, mk_msvc.mak, mk_bcc32.mak and mk_bccv5.mak. * The program setwpath.c has been added. This program sets the search path (PATH variable) under Windows. * The obsolete target 'hi' has been removed from the makefiles. * The functions initEmulatedCwd, cmdSetenv (both in cmd_rtl.c), setEmulatedCwd (in striutl.c) and freeArgVector (in cmd_unx.c) have been adjusted to work with the stack like allocation of os_stri_alloc and os_stri_free. * The functions heapAllocOsStri and heapFreeOsStri have been added to striutl.c. * Usages of MAX_SYMLINK_PATH_LENGTH in cmd_rtl.c have been replaced with MAX_OS_STRI_LEN. Notes: svn path=/head/; revision=348466
* - Update to 05_20140302Pietro Cerutti2014-03-132-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The function setSockOpt and the constant SO_REUSEADDR have been added to sockbase.s7i. Many thanks go to Domingo Alvarez Duarte for pointing out that this functionality was missing. * The function openInetListener in listener.s7i has been improved to succeed when the socket is reused (it calls setSockOpt with SO_REUSEADDR now). * The functions opendir and wopendir in dir_win.c and the function opendir in dir_dos.c have been improved to check for the maximum path length supported by Windows and DOS. * The functions act_string and act_okay have been removed from actutl.c. * The function exec_action in exec.c has been improved to use get_primact instead of act_okay. This results in a significant performance improvement in the case when WITH_ACTION_CHECK is defined and the option -tc is used. * The function str1Split has been removed from strlib.c. * Documentation comments have been added to arr_rtl.c, arrutl.c, cmd_unx.c, cmd_win.c, dir_dos.c, dir_rtl.c, dir_win.c, kbd_inf.c, kbd_poll.c, scanner.c and ut8_rtl.c. * Interpreter and compiler have been improved to support the action SOC_SET_OPT_BOOL. Notes: svn path=/head/; revision=348060
* - Update to 05_20140216Pietro Cerutti2014-02-172-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * A new numeric escape sequence for string literals has been introduced. A backslash followed by an integer literal and a semicolon is interpreted as character with the specified ordinal number. E.g.: "abc\128;def". With the old numeric escape sequence this would be "abc\128\def". Terminating the escape sequence with ; instead of \ improves the readability, especially when escape sequences follow each other. Instead of "\8\\12\\7\8\9\\\" it is now possible to write "\8;\12;\7;8\9;\\" The old escape sequence is still supported, but it is deprecated and should not be used. Future versions will warn about the deprecated escape sequence. * The conversion functions 'bytes' and 'bytes2Int' in bytedata.s7c have been improved to support all combinations of signedness and endianess. * The functions bStriBe and bStriLe have been removed from bstring.s7i. The function 'bytes' in bytedata.s7c can be used as replacement. * Checks for lowestSetBit and UNSIGNED conversions with the functions 'bytes' and 'bytes2Int' have been added to chkint.sd7. * Checks for UNSIGNED conversions with the functions 'bytes' and 'bytes2BigInt' have been added to chkbig.sd7. * Checks for the function rand have been added to chkset.sd7. * The parser has been improved to write error messages when the source file contains unexpected UTF-8 continuation bytes, solitary UTF-8 start bytes, extended control codes from the C1 set or an UTF-16 byte order mark. * In tar.s7i the functions getoct, putspc and putoct have been improved. The computation of the size of padding data has also been improved. * The compiler has been improved to optimize string initialisations with the function strZero. StrZero creates a string of arbitrary length with '\0;' (zero) bytes. * The compiler has been improved to optimize integer exponentiation (action INT_POW). Now the multiplication pattern is determined at compile time and the number of multiplications is reduced. * The performance of the function setCard in set_rtl.c has been improved by a factor of 2.5. * The performance of the function setRand in set_rtl.c has been improved by a factor of 2.3. * Loop unrolling inspired by Duff's device has been introduced in striutl.h. The unrolling is used for tight loops which copy byte data to Seed7 strings in fil_rtl.c, soc_rtl.c and bst_rtl.c. The performance improvement has been verified with gcc and valgrind. * The example program err.sd7, which checks compile time error messages, has been improved. * The old way to store the data of constant bigIntegers has been removed from compiler and runtime library. * The buffers used in intRadix and intRadixPow2 (file int_rtl.c) have been enlarged to fit for the most negative number with a base of 2. * In itflib.c the functions itf_cpy and itf_cpy2 have been fixed to work correctly, when the destination is converted from a struct to an interface. * In traceutl.c the tracing of characters has been improved in the functions prot_char, prot_os_stri, prot_stri_unquoted and prot_bstri. * In ut8_rtl.c the function ut8Getc has been improved to use smarter checks for ranges of characters. * The deprecated variant of the function str, which has a second parameter to specify a numeric base, has been removed. The operators radix and RADIX can be used instead. * Interpreter and compiler have been improved to support the new actions INT_BYTES_BE, INT_BYTES_LE, INT_BYTES_BE_2_INT and INT_BYTES_LE_2_INT. The functions intBytesBe, int_bytesBe, intBytesLe, int_bytesLe, intBytesBe2Int, int_bytesBe2Int, intBytesLe2Int and int_bytesLe2Int have been added. * Support for the actions BIG_CLIT, INT_TO_BSTRI_BE, INT_TO_BSTRI_LE, INT_BYTES_BE_2_UINT and INT_BYTES_LE_2_UINT has been removed from interpreter and compiler. The functions bigImport, bigCLit, big_clit, intToBStriBe, int_toBStriBe, intToBStriLe, int_toBStriLe, intBytesBe2UInt, int_bytes_be_2_uint, intBytesLe2UInt and int_bytes_le_2_uint have been removed. Notes: svn path=/head/; revision=344725
* - Update to 05_20140202Pietro Cerutti2014-02-032-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The manual chapter describing the foreign function interface has been improved. * The handling of Unicode in the console has been improved. Cursor positioning and writing Unicode strings to the desired position works now also under Linux. * A strict checking of all strings, that are passed to C functions, has been introduced. Zero bytes and non Unicode characters in the original string raise the exception RANGE_ERROR now. * The performance of several loops in the runtime library has been improved. Now the loops use indices instead of pointer increments and they work downward towards an index of zero. This allows C compilers to do more optimizations (verified with gcc and valgrind). * The enumeration types signedness and endianess have been added to bytedata.s7c. * The conversion functions bytes, bytes2Int and bytes2BigInt have been added to bytedata.s7c. The new function allow conversions to and from signed and unsigned byte strings with big- and little-endian byte order. This functions replace the less flexible functions bytesLe2Int, bytesBe2Int, bytesLe and bytesBe. * The functions bStriBe, bStriLe, bStriBe2BigInt and bStriLe2BigInt have been moved from bytedata.s7c to bstring.s7i. * The performance of the functions int16AsTwoBytesLe, int32AsFourBytesLe, int64AsEightBytesLe int16AsTwoBytesBe, int32AsFourBytesBe and int64AsEightBytesBe has been improved. * Documentation comments have been added or improved in cc_conf.s7i, bytedata.s7i, environment.s7i, sockbase.s7i, actutl.c, big_rtl.c, big_gmp.c, biglib.c cmd_rtl.c, con_inf.c, con_win.c, con_wat.c, int_rtl.c, intlib.c, soc_rtl.c, striutl.c and syvarutl.c. * The program chk_all.sd7 has been improved to check several compiler options and to allow that the output of interpreted and compiled compiler differs. The difference of the generated C code is okay, when the execution of the compiled programs results in the same output. * The compiler (s7c) has been improved to do more optimizations for the action BIG_REM (operator rem). * The compiler has been improved to count inserted and suppressed range checks. * Interpreter, compiler and runtime library have been improved to allow bstrings with slices. This is used by the compiler to reduce the memory used for constant bstrings. * The compiler has been improved to store the data of constant bigIntegers in bstrings. * Checks for div, rem, mdiv and mod have been added to chkbig.sd7. * Checks for float division by zero have been added to chkexc.sd7. * Checks for float parse have been added to chkflt.sd7. * In con_inf.c, con_win.c and con_wat.c the function conText has been replaced by conWrite. ConWrite takes an UTF-32 string and writes it to the console. If stdout is redirected an UTF-8 string is written to the destination file. * The function gen_act_ptr_table has been added to actutl.c. This function creates act_ptr_table and removes double entries from it. * The functions intBytesBe2UInt and intBytesLe2UInt have been added to int_rtl.c. * Interpreter and compiler have been improved to support the new actions INT_BYTES_BE_2_UINT and INT_BYTES_LE_2_UINT. * Checks for the function sigaction() and for integer division and remainder have been added to chkccomp.c. * The configuration values ALLOW_BSTRITYPE_SLICES, CHECK_INT_REM_BY_ZERO and CHECK_INT_REM_ZERO_BY_ZERO have been added to cc_conf.s7i, chkccomp.c, cmd_rtl.c and s7c.sd7. * Several versions of timAwait in tim_unx.c have been improved to restart calls of poll(), ppoll() and select(). * A check for the character '=' in the environment variable name has been added to the function cmdSetenv (in cmd_rtl.c). * In striutl.c the functions stri_compress, stri_export_utf8 and cp_to_cstri8 have been improved and renamed to conv_to_cstri conv_to_cstri8 and stri_to_cstri8 respectively. Interpreter and runtime library have been improved to use the new function names. * The function stri_to_cstri and the macro free_cstri8 have been added to striutl.c. * The functions conv_to_cstri, conv_to_cstri8, stri_to_cstri8 and stri_to_bstri have been improved to use an err_info parameter. Notes: svn path=/head/; revision=342454
* - Update to 20140119Pietro Cerutti2014-01-203-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The library tdes.s7i with TDES (Triple DES respectively 3DES) cipher support has been added. * The library tls.s7i has been improved to allow encoding with TDES (3DES) and to accept the handshake message CertificateRequest. * The function drwGetImage has been added to drw_dos.c (thanks to "Rugxulo" for pointing out, that it was missing). * Checks for mdiv and mod have been added to chkbig.sd7. * The compiler (s7c) has been improved to do more optimizations for the action BIG_MOD (operator mod). Now the functions bigLowerBits and bigLowerBitsTemp are used when the divisor is a power of two. * The compiler has been improved to optimize if-statements, when the condition is constant. * The compiler has been improved to optimize the action BIG_MDIV (operator mdiv) correctly, when the divisor is a negated power of two (e.g. n div -8). The generated code now corresponds to the Seed7 expression -dividend >> log(-divisor). * New functions to open files have been introduced in various libraries. The new functions are openUtf8, openUtf16, openEcho, openLine, openTee, openMore, openUpper, openLower, openReverse, openWindow and openField. The new functions have been added as replacement for the functions open_utf8, open_utf16, open_echo, open_line, open_tee, open_more, open_upper, open_lower, open_reverse, open_window and open_field. The old functions are still supported, but they are deprecated and should not be used. Deprecated functions will be removed in a future version. * The example programs have been changed to use the new functions to open files. * Documentation comments have been added or improved in cipher.s7i, clib_file.s7i, external_file.s7i, shell.s7i, utf8.s7i, utf16.s7i, unicode.s7i, bytedata.s7i, big_gmp.c, biglib.c, big_rtl.c, cmdlib.c, cmd_rtl.c, fillib.c, fil_rtl.c, intlib.c, int_rtl.c, strlib.c, str_rtl.c and entutl.c. * The functions bigLowerBits and bigLowerBitsTemp have been added to big_rtl.c and big_gmp.c. * The free list management in big_rtl.c and big_gmp.c has been improved to allow the configuration of a maximum free list length. * The function bigMultAssign1 has been added to big_rtl.c. This function is used by bigMultAssign when the factor is just one bigdigit. * The function bigLog2BaseLShift has been renamed to bigLog2BaseIPow in big_rtl.c, big_gmp.c and s7c.sd7. * The function getValue for boolean values has been added to progs.s7i. Interpreter, compiler and runtime library have been improved to support it. * the management of types in the runtime library has been improved. Now they are attached to the corresponding program. This way they can be freed by prgDestr(). Notes: svn path=/head/; revision=340382
* - Update to 05_20140105Pietro Cerutti2014-01-083-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The library des.s7i with DES (Data Encryption Standard) cipher support has been added. * The library tls.s7i has been improved to support block ciphers and encoding with DES. * The functions blockSize and decode have been added to cipher.s7i and arc4.s7i. * The the functions str, rotLeft and rotRight and the operators radix, RADIX, ~ and ><:= have been added to bin32.s7i. * Support to write bin32 values has been added to bin32.s7i. * The new library unicode.s7i, with functions to convert between Unicode encodings, has been added. * The functions utf16beToStri, utf16leToStri, utf7ToStri and replaceUtf16SurrogatePairs have been improved and moved from charsets.s7i to unicode.s7i. The functions striToUtf8 and utf8ToStri have been moved from string.s7i to unicode.s7i. The functions striToUtf16be and striToUtf16le have been added to unicode.s7i. * The actions FLT_MINUS, INT_MINUS and BIG_MINUS have been renamed to FLT_NEGATE, INT_NEGATE and BIG_NEGATE respectively. * The library gethttps.s7i has been improved to accept links to HTTP. * The operator symbols ~ and ><:= have been added to syntax.s7i. * Checks for -, mdiv, << and >> have been added to chkbig.sd7. * The compiler (s7c) has been improved to do more optimizations for the actions BIG_DIV, BIG_LSHIFT, BIG_RSHIFT, BIG_MDIV, BIG_MULT, BIG_NEGATE and CHR_CLIT. * The function charLiteral has been added to the compiler. * The compiler has been improved to avoid the generation of long lines for bigInteger literals. * The function bigMinus has been renamed bigNegate and the function bigNegateTemp has been added to big_gmp.c and big_rtl.c. * A check for the keyword 'restrict' has been added to chkccomp.c. * The function chrCLitToBuffer has been added to chr_rtl.c. * Interpreter, compiler and runtime library have been improved to support the action INT_XOR_ASSIGN. * The functions utf8_char (literal.c), utf8_to_stri (striutl.c), utf8_bytes_missing (striutl.c), strUtf8ToStri (str_rtl.c) and ut8Getc (in ut8_rtl.c) have been improved to check for ranges of characters instead of bit patterns. This improves the performance of UTF-8 conversions by up to 6%. * The functions freeArgVector and genArgVector have been added to cmd_unx.c. Notes: svn path=/head/; revision=339157
* - Update to 05_20131124Pietro Cerutti2013-11-253-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The new library pic_util.s7i has been added. It contains utility functions for pictures. A picture is a simple way to describe graphic images as readable text. A picture is an array of strings, where every character describes the color of a pixel. * The programs castle.sd7, mahjong.sd7, pairs.sd7, panic.sd7, shisen.sd7, sokoban.sd7 and sudoku7.sd7 have been adjusted to use pic_util.s7i. * The pictures in pic16.s7i and pic32.s7i have been adjusted to be useable by pic_util.s7i. * The pictures cancel_pic, folder_pic and reset_pic have been added to pic16.s7i and pic32.s7i. * A function to convert a pixmap image to BMP format has been added to draw.s7i. * The function getPixelColor has been added to draw.s7i. * In the example programs all usages of the function clear without parameters have been replaced with clear(black). The function clear without parameters is deprecated. * Interpreter and compiler have been improved to support the actions DRW_GETIMAGE and DRW_GETIMAGEPIXEL. * The performance of the function strCLit in str_rtl.c has been improved by a factor of 10. * The function init_bstri_constants in s7c.sd7 has been improved to use the function c_literal instead of cCharLiteral. This way it cannot happen that a sequence like ??( is interpreted as trigraph sequence. As a side effect the performance has been improved also. * The function init_win_constants in s7c.sd7 has been improved to call getImage instead of getPixel. This improves the performance dramatically. * The functions prc_return and prc_return2 in prclib.c have been improved to avoid using block_body when it is NULL. * Spelling errors in chlog.txt, faq.htm, faq.txt, install.txt, manual.htm, manual.txt, problems.txt read_me.txt, src/read_me.txt, flistutl.c, flistutl.h, heaputl.c, heaputl.h and striutl.c have been fixed. * The function drwGetImage has been added to drw_x11.c and drw_win.c. * The function drwGetImagePixel has been added to drw_rtl.c. * The program chkccomp.c has been improved to write defines for NO_EMPTY_STRUCTS, HAS_SYMLINKS and HAS_FIFO_FILES to version.h. Notes: svn path=/head/; revision=334846
* - Update to 05_20131110Pietro Cerutti2013-11-113-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Compiler and runtime library have been improved to work on Sparc 64-bit machines under OpenBSD. Thanks go to Brian Callahan, for his support and for providing access to his Sparc 64-bit machine. * The FAQ explanation concerning portability has been improved. * The new library cc_conf.s7i has been added. This library manages configuration values for C compiler and runtime. * The compiler has been improved to use the library cc_conf.s7i. * The chapter about the defines used in version.h has been improved in src/read_me.txt. * The type rtlGenerictype has been renamed to generictype in the files of the runtime library. Now compiler and runtime library both use the name generictype. * The function checkForLimitedStringLiteralLength, a check for trigraph sequences and checks for the presence of getrlimit() and siglongjmp() have been added to chkccomp.c. * The function setupStack has been added to cmd_rtl.c. This function tries to raise the stack limit to STACK_SIZE. * Usages of USE_SIGSETJMP have been renamed to HAS_SIGSETJMP. * The table key_code has been improved in kbd_inf.c and kbd_poll.c. Now the erase char of the terminal interface (VERASE) is always returned as backspace (KEY_BS respectively '\8\'). This improves the behavior under Cygwin. * The function utf8_init has been changed in kbd_inf.c and kbd_poll.c to assume UTF-8 mode when no locale environment variable is set. * The function msgDigest in msgdigest.s7i has been changed to use in-parameters. * The function configValue has been moved from osfiles.s7i to cc_conf.s7i. * The macro REALLOC_STRI_SIZE_SMALLER has been added to heaputl.h. Several usages of REALLOC_STRI_SIZE_OK in the runtime library have been changed to usages of REALLOC_STRI_SIZE_SMALLER. * The compiler has been improved to initialize boolean and enumeration elements of structs with the values value.boolvalue respectively value.enumvalue. This is necessary to work correctly on big-endian systems. * Interpreter and compiler have been improved to support the actions ACT_EQ and ACT_NE. Notes: svn path=/head/; revision=333482
* - Update to 05_20131027Pietro Cerutti2013-10-282-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Compiler and runtime library have been improved to support big-endian systems. Thanks go to Brian Callahan, for his support and for providing access to his PowerPC Macintosh under OpenBSD. * The list of source files and the chapter about the defines used in version.h have been improved in src/read_me.txt. * The library tls.s7i has been improved to avoid raising an exception, when the remote side closes the socket. * The program chkccomp.c has been improved to write defines for CHECK_INT_DIV_BY_ZERO, INT_DIV_BY_ZERO_SIGNALS and DO_SIGFPE_WITH_DIV_BY_ZERO to version.h. * Documentation comments have been added or improved in fillib.c, int_rtl.c, soclib.c, tim_dos.c, tim_unx.c, tim_win.c, ut8lib.c, ut8_rtl.c, tls.s7i and bytedata.s7i. * The generic compare functions bigCmpGeneric, bstCmpGeneric, chrCmpGeneric, intCmpGeneric, rflCmpGeneric, setCmpGeneric, strCmpGeneric and typCmpGeneric have been improved to work endianness neutral. Now they work correct on little- and big-endian systems. * The generic create functions bigCreateGeneric, bstCreateGeneric, drwCreateGeneric, rflCreateGeneric, setCreateGeneric, strCreateGeneric and itfCreateGeneric have been improved to work endianness neutral. Now they work correct on little- and big-endian systems. * The new generic copy functions bigCpyGeneric, bstCpyGeneric, drwCpyGeneric, fltCpyGeneric, rflCpyGeneric, setCpyGeneric and strCpyGeneric have been added. This functions work endianness neutral. * The new generic destroy functions bigDestrGeneric, drwDestrGeneric, rflDestrGeneric, setDestrGeneric and strDestrGeneric have been added. This functions work endianness neutral. * The functions uintCmpGeneric, intCreateGeneric and intDestrGeneric have been renamed to genericCmp, genericCreate respectively genericDestr. * The functions genericCpy, ptrCmp, ptrCmpGeneric, ptrCpyGeneric and ptrCreateGeneric have been added to int_rtl.c. * The function cmdConfigValue in cmd_rtl.c has been improved to support the config value DO_SIGFPE_WITH_DIV_BY_ZERO. * The handling of the option -l in processOptions (file s7.c) has been improved to work endianness neutral. * Several functions have been optimized: In infile.c: get_file_name and get_file_name_ustri In prg_comp.c: prgSyobject In rfllib.c: rfl_elemcpy and rfl_idx In rfl_data.c: rflElemcpy, rflIdx and rflTail * The function get_ident and the macro IDENT_TABLE have been changed to have an additional progtype argument. * The function typNum in typ_data.c has been improved to use a hashtable. * In typlib.c the functions typ_num and typ_str have been improved to call typNum respectively typStr. * Support for the actions ACT_ICONV and ACT_ORD has been added to interpreter, compiler and runtime library. * The function id_string2 has been added to datautl.c, and used in ref_data.c and typ_data.c. Notes: svn path=/head/; revision=331850
* - Update to 05_20131013Pietro Cerutti2013-10-173-17/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: 20131013: - Libraries for TLS (Transport Layer Security), SSL (Secure Sockets Layer) and HTTPS (HyperText Transfer Protocol Secure) support have been added. The new libraries are: arc4.s7i, asn1.s7i, cipher.s7i, gethttps.s7i, hmac.s7i, pkcs1.s7i, tls.s7i and x509cert.s7i. - Comparison operators for < (proper subset) and > (proper superset) have been added to hashsetof.s7i. - The type digestAlgorithm and the functions msgDigest, blockSize and digestSize have been added to msgdigest.s7i. - The function hex has been added to bytedata.s7i. - The example program castle.sd7 has been improved to avoid, that an item can be dropped on an illegal place. - The library make.s7i has been improved to accept the option -p for the cp command. - Documentation comments have been added to sockbase.s7i, socket.s7i, atom.c, entutl.c, soclib.c, soc_rtl.c and striutl.c. - The padding in the message digest functions of msgdigest.s7i has been corrected. Now the functions pad nothing instead of 64 bytes, when the message length is 55 (mod 64). - The function getHttp in gethttp.s7i has been improved to use a case-insensitive comparison for HTTP header field names. - In exec.c the functions eval_arg_list and dump_arg_list have been improved to avoid reading from freed memory. This occured in very rare cases. - The functions find_action (in actutl.c), fltParse (in flt_rtl.c), cmdConfigValue (in cmd_rtl.c) and find_sysvar (in syvarutl.c) have been improved to use the macros MAX_STRI_EXPORT_LEN and max_utf8_size. - Interpreter and runtime library have been improved to ignore the signal SIGPIPE. Writing to a broken pipe or socket raises the exception FILE_ERROR instead. - The functions bln_and and bln_or in blnlib.c have been improved to return either SYS_TRUE_OBJECT or SYS_FALSE_OBJECT. - The program chkccomp.c has been improved to determine the alignment used by malloc and whether an access to unaligned memory succeeds. - Usages of ALLOC_CHUNK in flistutl.h have been improved to allocate aligned memory the same way as malloc returns aligned memory. - The program chkccomp.c has been improved to define the macro 'inline', when the C compiler does not support the keyword inline. - Occurances of 'INLINE' have been replaced with 'inline' in the files analyze.c, atom.c, big_gmp.c, big_rtl.c, chr_rtl.c, exec.c, findid.c, infile.c, int_rtl.c, numlit.c, parser.c, rfl_data.c, scanner.c, striutl.c, strlib.c, str_rtl.c, syntax.c and ut8_rtl.c. 20130929: - The functions bStriLe, bytesLe, bStriBe and bytesBe have been added to bytedata.s7i. This functions convert an integer to a sequence of bytes. - The compiler has been improved to generate inline code for the action STR_PUSH. This action is used when a character is appended to a string (with the operator &:= ). - The function sendGet has been added to gethttp.s7i. - The functions str_yy_mm_dd and str_hh_mm_ss have been added to time.s7i. - Checks for +:= and -:= have been added to chkbig.sd7. - Checks for bytesBe and bytesLe have been added to chkint.sd7. - Checks for & and &:= have been added to chkstr.sd7. - The function doLocalDeclsOfStatement has been added to the compiler. This function is used to simplify the processing of various statements. - The functions that process the statement actions BIG_GROW, BIG_LSHIFT_ASSIGN, BIG_MULT_ASSIGN, BIG_RSHIFT_ASSIGN, BIG_SHRINK, BLN_CPY, CHR_CPY, CHR_GROW, CHR_SHRINK, ENU_CPY, FIL_CPY, FLT_CPY, FLT_DIV_ASSIGN, FLT_GROW, FLT_MULT_ASSIGN, FLT_SHRINK, INT_AND_ASSIGN, INT_CPY, INT_GROW, INT_LSHIFT_ASSIGN, INT_MULT_ASSIGN, INT_OR_ASSIGN, INT_RSHIFT_ASSIGN, INT_SHRINK, INT_URSHIFT_ASSIGN, REF_CPY, RFL_INCL, SET_EXCL, SET_INCL, SOC_CPY, STR_PUSH and TYP_CPY in the compiler have been simplified. - The functions int_toBStriBe and int_toBStriLe have been added to intlib.c. - The functions intToBStriBe and intToBStriLe have been added to int_rtl.c - In big_rtl.c and big_gmp.c the functions bigFromBytesBe and bigFromBytesLe have been renamed to bigFromByteBufferBe respectively bigFromByteBufferLe. - The performance of the functions bst_cmp (in bstlib.c), bstCmp (in bst_rtl.c) and strMult (in str_rtl.c) has been improved. - The macro 'unlikely' has been added to functions in bst_rtl.c. Notes: svn path=/head/; revision=330617
* Add NO_STAGE all over the place in preparation for the staging support (cat: ↵Baptiste Daroussin2013-09-201-0/+1
| | | | | | | lang) Notes: svn path=/head/; revision=327741
* - Update to 05_20130908Pietro Cerutti2013-09-093-261/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The compiler has been improved to use charvalue instead of intvalue, when characters are initialized. Thanks go to Brian Callahan, for reporting the bug. Btw.: Brian Callahan created an openBSD port for Seed7. * The makefile mk_freebsd.mk has been added to support compilation under freeBSD. Thanks go to Pietro Cerutti, for providing it. * The makefiles mk_clang.mak and mk_freebsd.mk have been improved to use the options -ffunction-sections, -fdata-sections and *Wl,--strip-debug. * The functions bStriLe2BigInt, bytesLe2BigInt, bStriBe2BigInt, bytesBe2BigInt, bStriLe, bytesLe, bStriBe and bytesBe have been added to bytedata.s7i. This functions convert between sequences of bytes and bigInteger numbers. * In bytedata.s7i the functions bytesLeAsInt and bytesBeAsInt have been renamed to bytesLe2Int respectively bytesBe2Int. * Parameter names have been added to seed7_05.s7i, graph_file.s7i, graph.s7i, reference.s7i, pac.sd7, tetg.sd7, tet.sd7 and wiz.sd7. * Checks for the Karatsuba multiplication and the functions bytesBe, bytesLe, bytesBe2BigInt and bytesLe2BigInt have been added to chkbig.sd7. * Checks for set membership in character sets have been added to chkset.sd7. * The readability of the bitset initialisation in the compiler (s7c) has been improved. * Interpreter and compiler have been improved to support the new actions BIG_FROM_BSTRI_BE, BIG_FROM_BSTRI_LE, BIG_TO_BSTRI_BE and BIG_TO_BSTRI_LE. * The functions bigFromBytesBe, bigFromBytesLe, bigFromBStriBe, bigFromBStriLe, bigToBStriBe and bigToBStriLe have been added to both, big_gmp.c and big_rtl.c. * In big_gmp.c and big_rtl.c the function bigImport has been rewritten to use bigFromBytesBe. * The readability of the function uint2_mult in int_rtl.c has been improved. * The program chkccomp.c has been improved to check for a ones complement inttype and if casting can be used to get the element of a union. * Several makefiles have been adjusted to use 'cp -p' instead of 'cp -a'. The cp command openBSD does not support -a. * The function bigRand in big_rtl.c has been improved to avoid that a random number is outside the required range. Notes: svn path=/head/; revision=326786
* - Update to 05_20130820Pietro Cerutti2013-08-276-73/+268
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - Add a custom Makefile for FreeBSD, and remove the custom patches to the distributed Makefile. Changes: * The library sha1.s7i has been renamed to msgdigest.s7i. * The message digest and secure hash functions md4, md5, sha224 and sha256 have been added to msgdigest.s7i. * The new library propertyfile.s7i, which defines functions to read a property file into a hash table, has been added. * The performance of the random number generator has been improved. The function uint2_mult in int_rtl.c is now defined as inline function. The macro 'unlikely' has been added to describe that the initialisation of the random number generator is unlikely. * The function uint_mult has been added to int_rtl.c and used in big_rtl.c. * The macro 'unlikely' has been added to functions in flt_rtl.c. * The function bytesLeAsInt has been added to the library bytedata.s7i. * In bytedata.s7i the function int64AsBytesBytesLe has been renamed to int64AsEightBytesLe. * A variant of the function skipWhiteSpace has been added to the library scanfile.s7i. Notes: svn path=/head/; revision=325440
* - Update to 05_20130805aPietro Cerutti2013-08-085-13/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 20130805: * The functions hashCode in complex.s7i, duration.s7i, rational.s7i and time.s7i have been improved to avoid an integer overflow. Thanks to Pietro Cerutti, for reporting this problem. * The description of the Seed7 installation in doc/install.txt has been improved. * The new library sha1.s7i, which defines a message digest with the SHA-1 secure hash algorithm, has been added. * Definitions of the operators &:= and |:= have been added to bin32.s7i. * The functions int64AsBytesBytesLe, int64AsEightBytesBe and bytesBeAsInt have been added to bytedata.s7i. * Interpreter and compiler have been improved to support the actions INT_AND_ASSIGN and INT_OR_ASSIGN. * A bug in the function conText (file con_win.c) has been fixed. * Debug code has been added to kbd_inf.c and kbd_poll.c. * The makefile mk_cygw.mak has been improved to avoid problems with the console keyboard. 20130722: * Spelling errors in chlog.txt, faq.htm and faq.txt have been fixed. * The function conText (in con_win.c) has been improved to work correctly for long strings. The underlying function WriteConsoleW fails for string lengths above some limit between 26000 to 32000. * The functions find_window, remove_window, gkbGetc, gkbKeyPressed, gkbButtonPressed, gkbRawGetc, gkbWindow, gkbButtonXpos and gkbButtonYpos have been moved from drw_win.c to the new file gkb_win.c. * In the functions drwPCircle, drwPFCircle, drwPFEllipse and drwFPolyLine (file drw_win.c) wrong usages of inIntRange have been replaced with better code. * In con_win.c the table map_key has been improved such that kbdGetc recognizes the key F12. * In gkb_x11.c the functions find_window, enter_window and remove_window have been improved. * The makefiles mk_bcc32.mak, mk_bccv5.mak, mk_mingc.mak, mk_mingw.mak, mk_msvc.mak, mk_msys.mak and mk_nmake.mak have been changed to use the new file gkb_win.c. * The program chk_all.sd7 has been improved to call chkhsh.sd7. * The program chkhsh.sd7 has been improved. * The compiler has been improved to generate compare functions with the correct prototype. * The functions bitSize and process_generic_cmp_declaration have been added to s7c.sd7. * In flt_rtl.c the function fltCpy has been renamed to fltCpyGeneric. * The functions dump_hash and dump_helem have been added to hsh_rtl.c. * The function new_type in typeutl.c has been changed to add the new type to the parameter owningProg instead of the global prog. Notes: svn path=/head/; revision=324394
* - Update to 05_20130704Pietro Cerutti2013-07-092-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * A wordfile for Ultraedit and a syntax definition file for Textpad has been added. Many thanks to Renato Lenzi for providing it. This files can be found also on his great italian page about Seed7. * A compilation problem with DJGPP in fil_rtl.c has been fixed (thanks to "Rugxulo" for pointing it out). * The keyboard read function getc(KEYBOARD) has been improved to accept all Unicode characters also under Linux/Unix/BSD. Up do now the function did only accept Latin-1 characters. * The keyboard read function getc(KEYBOARD) has been improved to accept usages of the mouse wheel also under Windows. * Checks for correct UTF-8 encoding of the program source have been added. Overlong UTF-8 encodings, UTF-16 surrogate characters and missing UTF-8 continuation bytes result in a compile time error. * The example program err.sd7, which checks compile time error messages, has been improved. * The FAQ explanations concerning Unicode and automatic casts have been improved. * Documentation comments have been added to gzip.s7i and make.s7i. * The example programs gkbd.sd7 and kbd.sd7 have been improved to write the character, if it is printable. * The example programs pairs.sd7, panic.sd7, tetg.sd7, sokoban.sd7, sudoku7.sd7, mandelbr.sd7 and wator.sd7 have been changed to use proportional Seed7 pixmap fonts. * Tests for the functions lower and upper with cyrillic letters have been added to chkstr.sd7. * The libraries console.s7i, pixmap_file.s7i, graph_file.s7i, file.s7i, editline.s7i, echo.s7i, null_file.s7i, external_file.s7i, strifile.s7i, stritext.s7i, tee.s7i, window.s7i, reverse.s7i, lower.s7i and upper.s7i, have been improved to work with proportional fonts. Proportional font support uses the functions moveLeft, erase, backSpace, cursorOn and cursorOff. * The vector font cronos16 has been improved to look more similar to the font cronos27. * The bitmap fonts stdFont10, stdFont12, stdFont14, stdFont16, stdFont18, stdFont20 and stdFont24 have been improved. * The vector fonts vecFont10 and vecFont18 have been adjusted to look like the corresponding bitmap fonts. * The fonts stdFont8, stdFont9 and cronos27 have been improved to use less spacing between the characters. * In graph_file.s7i the logic of a writeln after a setPosXY has been changed. Now the writeln moves one line downward relative to the position given with setPosXY. * A description of the subrange operator, which gets an array slice from a position with maximum length, has been added to the manual. * A table to map keysym values to Unicode and the function mapKeysymToUnicode, which does a binary search in this table, have been added to gkb_x11.c. * The function gkbGetc in gkb_x11.c has been improved to work without recursion, to use mapKeysymToUnicode and to recognize cursor keys in combination with ALT, NUMLOCK and SHIFT. Notes: svn path=/head/; revision=322548
* - Update to 05_20130616Pietro Cerutti2013-06-172-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Documentation comments have been added or improved in bigfile.s7i, char.s7i, clib_file.s7i, complex.s7i, external_file.s7i, file.s7i, float.s7i, hash.s7i, integer.s7i, shell.s7i, string.s7i, utf16.s7i, osfiles.s7i, rational.s7i, arrlib.c, blnlib.c, bstlib.c, arr_rtl.c, big_gmp.c, big_rtl.c, bst_rtl.c, chrlib.c, chr_rtl.c, cmdlib.c, cmd_rtl.c, fillib.c, fil_rtl.c, fltlib.c, flt_rtl.c, hshlib.c, hsh_rtl.c, int_rtl.c, pol_sel.c, pol_unx.c, setlib.c, set_rtl.c, strlib.c, str_rtl.c. * The functions lower and upper in string.s7i and char.s7i have been improved to use the default Unicode case mapping. In other words: conversions to lower respectively upper case works for all Unicode characters, which have a case mapping. Characters without case mapping are left unchanged. The mapping is independend from the locale. Individual character case mappings cannot be reversed, because some characters have multiple characters that map to them. * In the library deflate.s7i the performance of the deflate compression has been improved by a factor between 5 and 10. * The performance of the functions str_cmp, str_range and str_substr in strlib.c has been improved. * The performance of the functions strCompare, strRangeSlice, strRange, strSubstrSlice and strSubstr in str_rtl.c has been improved. * Tests for the string functions compare, lower and upper and for the index operations head, tail, range and substring have been added to chkstr.sd7. * The definition of the macro arrayMaxPos in common.h has been improved and usages of the macro have been added to arrlib.c and arr_rtl.c. * The compiler has been improved to support the actions HSH_IDX2 and HSH_UPDATE. * The compiler has been improved to inline code for the actions STR_HASHCODE, STR_RANGE and STR_SUBSTR. * The function intStrToBuffer has been added to int_rtl.c. This function allows conversions from integer to string, without memory allocation. * The compiler has been improved to take advantage of the function intStrToBuffer. * The functions getGenericValue, getGenericValueToResultExpr, getTempVariable, beginCastGeneric, endCastGeneric, beginCastGenericToResultExpr and endCastGenericToResultExpr have been added to the compiler. * The functions hsh_idx2 and hsh_update have been added to hshlib.c. * The functions hshIdxAddr2 and hshUpdate have been added to hsh_rtl.c * The macro hashCode has been defined in str_rtl.h and used in str_rtl.c (function strHashCode) and strlib.c (function str_hashcode). * The program chkccomp.c was improved to write a definition of the macro INLINE to version.h * The deprecated function 'read_dir' has been removed from the library "osfiles.s7i". The replacement of 'read_dir' is 'readDir'. * The functions arrHeadTemp, arrRangeTemp and arrSubarrTemp in arr_rtl.c have been improved. Notes: svn path=/head/; revision=321113
* - Update to 05_20130602Pietro Cerutti2013-06-033-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The implementation of the type integer has been changed to use a 64-bit value. * Documentation comments have been added to bigint.s7i, integer.s7i, string.s7i, arr_rtl.c, big_gmp.c, biglib.c, big_rtl.c, flt_rtl.c, intlib.c, int_rtl.c, set_rtl.c and str_rtl.c. * The new library bin32.s7i, which defines bit operations for 32-bit values, has been added. * The new library crc32.s7i, which supports the CRC-32 cyclic redundancy check, has been added. * The new library deflate.s7i, which supports the deflate compression algorithm, has been added. * The library binary.s7i has been renamed to bytedata.s7i. The functions get_asciiz, get_uint16_le, get_uint32_le, get_uint16_be and get_uint32_be have been renamed to getAsciiz, getUInt16Le, getUInt32Le, getUInt16Be and getUInt32Be respectively. Definitions of the functions int16AsTwoBytesLe, int32AsFourBytesLe, int16AsTwoBytesBe and int32AsFourBytesBe have been added. * The functions getBitLe, getBitsLe, getNonCompressedBlock, getLiteralOrLength, getDistance, decodeLength, decodeDistance, decodeFixedHuffmanCodes, getHuffmanValue, computeConversionTable, decodeDynamicHuffmanCodes, processCompressedBlock and inflate have been moved from gzip.s7i to the new library inflate.s7i. * The functions gzip, openGzipFile, close and write have been added to the library gzip.s7i. * The functions 'name' and 'path' have been added to the library progs.s7i. * The function openStrifile has been added to strifile.s7i. * The library tar.s7i and the example program tar7.sd7 have been improved to allow the creation of compressed archives. * The compiler has been improved to support the actions BIG_CONV, BIN_AND, BIN_OR, BIN_XOR, INT_AND, INT_OR, INT_XOR, INT_URSHIFT, INT_URSHIFT_ASSIGN, PRG_OWN_NAME and PRG_OWN_PATH. * Optional checks for integer shift operations have been added to the compiler. * The function bigFromInt64 and bigToInt64 in big_gmp.c have been improved. * Several functions in big_gmp.c have been improved to free temporary values with mpz_clear(). * The function big_conv() has been added to biglib.c. * The functions drw_image and drwRtlImage have been improved. * The functions drwImage in drw_win.c and drw_x11.c have been improved. * The meaning of the actions PRG_NAME and PRG_PATH has changed. The new actions PRG_OWN_NAME and PRG_OWN_PATH are used as replacement. * The functions strRPos2, strRIPos2 and strRepl2 have been added to str_rtl.c. This functions use a modified Boyer–Moore string search algorithm. * Usages of the macro arraySize have been added to drwlib.c, drw_rtl.c, libpath.c and prg_comp.c. * The macro arrayMaxPos has been defined in common.h and used in arrlib.c and arr_rtl.c. Notes: svn path=/head/; revision=319778
* - Update to 05_20130505Pietro Cerutti2013-05-102-12/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Functions to compare arrays (compare, <, >, <=, >=) have been added to the library array.s7i. * In seed7_05.s7i the functions hashCode and compare have been defined for enum types. * In the library bigrat.s7i the operator parse has been improved. Now the parse operator accepts decimal numbers with repeating decimals. * The function integer has been added to the library integer.s7i. This function converts a numeric string, with a specified radix, to an integer. * The function bigInteger has been added to the library bigint.s7i. This function converts a numeric string, with a specified radix, to a bigInteger. * The files encoding.s7i, gethttp.s7i, scanfile.s7i, scanstri.s7i, xml_ent.s7i and bas7.sd7 have been changed to use the new function integer instead of toInt (toInt was an undocumented internal function). * Checks for the function integer have been added to chkint.sd7. * Checks for the function bigInteger have been added to chkbig.sd7. * The operator sci has been added to to the library complex.s7i. This operater converts a complex to a string in scientific notation. * The compiler (s7c) has been improved to support the actions BIG_PARSE_BASED, TYP_CMP, ENU_CPY, ENU_CREATE and GEN_DESTR. * The memory management in the interpreter has been improved. Now it is possible that a destructor is called and the object memory is not freed. This is used to free the memory of struct objects only, when the usage_count reaches zero. * The UNUSED flag was defined in data.h and used to monitor if the object memory can be freed. * The compiler has been improved to call the destructor for local interface objects (In process_local_declaration process_destr_call is called for INTERFACEOBJECT objects). * The compiler has been improved to initialize set constants, that are part of a data structure (In walk_const_list SETOBJECT objects are added to set_const_table). * The runtime library has been improved to use the action GEN_DESTR instead of PRC_NOOP as destructor for integer and other simple data types. Notes: svn path=/head/; revision=317793
* - Update to 05_20130421Pietro Cerutti2013-04-223-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The FAQ explanation concerning garbage collection has been improved. * The manual chapters describing the introduction, EBNF, literals (for integer, bigInteger, float, char and string), set operations and file I/O have been improved. * Operations, to get an array slice with a specified length, have been added to the libraries array.s7i and idxarray.s7i. * Array aggregates for arrays with a given start index have been added to idxarray.s7i. * Functions for binomial coefficient and modular exponentiation have been added to the library bigint.s7i. * A definition of an empty set with the name {} has been added to bitset.s7i. * Functions to compute the minimum and maximum have been added to the libraries integer.s7i and float.s7i. * Documentations comments in keybd.s7i have been improved. * In pixmap_file.s7i the logic of a writeln after a setPosXY has been changed. Now the writeln moves one line downward relative to the position given with setPosXY. * A pound symbol has been added to several bitmap fonts. * A standard bitmap font, with capital height of 9, has been defined in the new library stdfont9.s7i. * Checks for the factorial function and the binomial coefficient have been added to chkbig.sd7. * The comanche webserver has been improved to accept cookies. * The compiler has been improved to generate better code for the allocation of array memory. * The function arrMalloc in arr_rtl.c has been improved to avoid an overflow, when the size of the memory is computed. * The functions arrSubarr and arrSubarrTemp have been added to arr_rtl.c. * Support for the action ARR_SUBARR has been added to the compiler. * The macros arraySize and arraySize2 have been defined in common.h and used in arrlib.c, arr_rtl.c, arrutl.c, cmdlib.c, cmd_unx.c and cmd_win.c. * Definitions of INT64TYPE_MIN, INTTYPE_MIN and MIN_MEM_INDEX have been added to common.h. Notes: svn path=/head/; revision=316237
* - Update to 05_20130401Pietro Cerutti2013-04-173-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: - The FAQ explanations concerning, 'in' parameters and different behavior of val and ref parameters, have been improved. - The keyboard read function getc(KEYBOARD) has been improved to support more function keys and to accept Unicode characters also under Windows. - The program calc.sd7 has been improved to accept and display Unicode characters. - The automatic memory management has been improved to work also for the files managed by pollData. - The function openEditLineLatin1 has been added to editline.s7i. Only Latin-1 characters are accepted and written to ''outFile''. Unicode characters beyond ISO Latin-1 (ISO-8859-1) are ignored. - In file.s7i the function writeln(file, string) has been defined as DYNAMIC (virtual) function. This allows that the implementation function writeln(socket, string) sends string and '\n' together. - The definition of keys in keybd.s7i have been changed such that function keys are outside the range of Unicode characters. - The new library keydescr.s7i, which defines a hash table with descriptive text for function keys, has been added. - The implementation function writeln(null_file, string) has been added to null_file.s7i. This function is used by many derived types. - An implementation function of writeln(socket, string) has been added to socket.s7i. This function sends string and '\n' together. - Definitions of writeln (without string parameter) have been removed from external_file.s7i, socket.s7i and utf8.s7i. - The example programs bas7.sd7, gkbd.sd7 and kbd.sd7 have been changed to use the hash keyDescription (defined in keydescr.s7i). - Tests for string assignment and string append (operator &:= ) have been added to chkstr.sd7. - The function bigStr in big_rtl.c has been improved to realloc the string to the correct size. - The function determineEnvironDefines in chkccomp.c has been improved. - The function itf_destr in itflib.c has been improved to cooperate with the function close_stack (defined in name.c). - The function kbdKeyPressed in kbd_inf.c has been improved to never wait for input (calls of tcsetattr() were fixed, see below). - In pol_unx.c and pol_sel.c the functions addCheck, removeCheck, polCpy, polCreate, polDestr and polClear have been improved to use the function pointers incrUsageCount and decrUsageCount from fileObjectOps. - The function initPollOperations has been added to pol_unx.c, pol_sel.c and pol_dos.c. - In str_rtl.c the functions strAppend and strCopy have been changed to use SLICE_OVERLAPPING instead of GET_SLICE_ORIGIN. - In str_rtl.c the functions strHeadSlice, strRangeSlice, strSubstrSlice and strTailSlice have been improved to avoid (mis)using the string capacity. Now the capacity of a slice is set to zero. Before the origin of a slice was stored in the capacity. - The function print_real_value in traceutl.c has been improved to print interface values with more detail. - Support for additional function keys has been added to kbd_inf.c, kbd_poll.c, cap_def.h, trm_cap.c and trm_inf.c. - The files kbd_inf.c and kbd_poll.c have been improved to use read() instead of fread(). - The files kbd_inf.c and kbd_poll.c have been improved to take a weakness of tcsetattr() into account. The function tcsetattr() may return success, although not all changes could be carried out. Now the calls of tcsetattr() are done via the new functions term_descr_equal, tcset_term_descr and tcset_vmin_vtime. - The compiler has been improved to create and use cpy_... functions for the interface assignment (action ITF_CPY). - The free list management for strings has been improved to allow different maximum list lengths for strings with different capacity. - Definitions of databasetype and sqlstmttype have been added to common.h. This are the first steps towards database support. Feature safe: yes Notes: svn path=/head/; revision=315947
* - Update to 05_20130317Pietro Cerutti2013-03-202-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The FAQ explanations concerning, what kind of programs can be written in Seed7 and the automatic memory management of Seed7, have been improved. * The compiler (s7c) has been improved to use the function strConcatN, when three or more strings are concatenated. * The compiler has been improved to define and use dynamic (virtual) destructors for interface types. The function itfCreate is used as constructor. * In the compiler the function init_string_constants_with_slices has been improved, to store the characters of string constants with more density. * The compiler functions prepare_typed_result, process_itf_cpy, process_itf_to_interface and process_ref_trace have been improved. * In str_rtl.c the functions strIPos2 and strPos2 have been added. This functions use a modified Boyer–Moore string search algorithm. * The performance of the function replace2 (library string.s7i) has been improved. * The example programs tetg.sd7 and tet.sd7 have been changed to abstain from using an outdated language feature. Now this programs can be compiled. * Parameter names have been added to seed7_05.s7i, pixmap_file.s7i, bitset.s7i, dialog.s7i, hash.s7i, console.s7i and string.s7i. * In sctlib.c and itflib.c the functions sct_cpy, sct_create, sct_destr, itf_cpy, itf_cpy2, itf_create, itf_create2, itf_destr and itf_to_interface have been improved to use reference counting (usage_count) for all objects of the category STRUCTOBJECT. * The support for the actions ITF_TO_HEAP and REF_BUILD has been removed from the interpreter. * Support for the action REF_GETREF has been added to interpreter and compiler. * The functions itf_to_heap (in itflib.c) and ref_build (in reflib.c) have been removed. * The function refItftosct (in ref_data.c) has been renamed to refItfToSct. The function ref_itftosct (in reflib.c) and the compiler have been changed to use the new function name. * The types smallpriortype and prior_type have been replaced by prioritytype in common.h, data.h, expr.c, expr.h, findid.h, syntax.c, token.c and token.h. * In itf_rtl.c the function itfCreate has been added and the function itfDestr has been removed. * Usages of the function stri_charpos in analyze.c and prclib.c have been replaced by calls of strChPos. * In executl.c the function crea_struct has been introduced and the function any_var_initialisation has been replaced by the functions sct_elem_initialisation and arr_elem_initialisation. * The function prot_block has been added to traceutl.c. Notes: svn path=/head/; revision=314745
* - Update to 05_20130303Pietro Cerutti2013-03-073-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The library editline.s7i has been added. This library defines a file type for linewise editing with history. * The manual chapter describing types, especially the type program, has been improved. * The calc.sd7 example has been improved to allow linewise editing. * The handling of the internal program representation in interpreter and compiler has been improved to free most unused memory. * The handling of the functions prgGlobalObjects, refArrToList, refHshDataToList, refHshKeyToList, refLocalVars and refSctToList in compiler and run-time library has been improved to free unused memory. * The stack trace has been improved to display infix operators better and to write parameter names. * The compiler has been improved to support the action TYP_FUNC. * The functions copy_expression and free_expression in listutl.c have been optimized. * The function substitute_params has been added to match.c . * The functions free_params and free_name_list have been added to name.c . * The function dump_list has been added to objutl.c . * The function copy_params has been added to entutl.c . * The functions prot_float and prot_params have been added to traceutl.c . * The functions free_type and close_type have been added to typeutl.c . * The free list management has been improved to be configurable in config.h. * The memory management in heaputl.h has been improved to work with and without DO_HEAPSIZE_COMPUTATION. * The function free_file and remove_prog_files have been added to infile.c. * The functions itf_cpy and itf_cpy2 in itflib.c have been improved to support assigning forward declared objects to an interface. * The function emptylist and the macro to_empty_list have been renamed to free_list and free_list2. * In prg_comp.c the function prgDeclObjects has been renamed to prgGlobalObjects. * In ref_data.c the functions refArrmaxidx, refArrminidx, refArrtolist, refScttolist and refHshKeyToList have been renamed to refArrMaxIdx, refArrMinIdx, refArrToList, refSctToList and refHshKeysToList. * In ref_data.c the functions refResult, refResini and refSetParams have been improved to raise RANGE_ERROR when the argument is NULL or when it is not a BLOCKOBJECT. * In progs.s7i the functions sys_var, error_count, declared_objects, params, setParams, func_result, func_res_init, local_consts, local_vars, array_to_list, array_min_index, array_max_index, struct_to_list, hash_data_to_list, hash_key_to_list, interface_to_struct, obj_number, type_number and match_obj have been renamed to sysVar errorCount, globalObjects, formalParams, setFormalParams, resultVar, resultInitValue, localConsts, localVars, arrayToList, arrayMinIdx, arrayMaxIdx, structToList, hashDataToList, hashKeysToList, interfaceToStruct, objNumber, typeNumber and typeObject. * In seed7_05.s7i the functions is_func, is_varfunc, result_type and is_derived have been renamed to isFunc, isVarfunc, resultType and isDerived. Notes: svn path=/head/; revision=313572
* - Update to 05_20130217Pietro Cerutti2013-02-202-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The description of exceptions in the manual has been improved. * The handling of program data in interpreter and compiler has been improved to free more unused memory. * The handling of the actions PRG_FIL_PARSE and PRG_STR_PARSE in the Seed7 compiler (s7c) has been improved to support releasing unused programs. * The function prgDestr (in prg_comp.c) has been improved to free (most of) the data used by a program. Several functions, which need to free program data, have been improved to call prgDestr. * The functions prgCpy (in prg_comp.c) and prg_cpy (in prglib.c) have been improve to free a program when the usage_count reaches zero. * The functions getPixmap in draw.s7i have been improved. * The functions decl_any (in analyze.c), dcl_const and dcl_var (both in dcllib.c) have been improved to free unused expressions. * The actions ARR_BASELIT, ARR_BASELIT2, ARR_TIMES, ARR_GEN, ARR_PUSH and ARR_EXTEND in the interpreter (file arrlit.c) have been improved to work correctly for arrays with interface elements. * In blockutl.c the functions free_locobj, free_body, free_block and free_local_consts have been added or improved. * In entutl.c the function free_entity has been improved to free also syobject and name_list. * The function close_entity has been added to entutl.c. This function frees the list of inactive entities. * In executl.c the function destroy_local_init_value has been added and the function destroy_object_list has been removed. * The parameter dest_type has been added to the function any_var_initialisation (file executl.c). * The functions heap_statistic (in flistutl.c) and rtlHeapStatistic (in heaputl.c) have been improved to write information about pollData elements. * The functions free_ident and close_idents in identutl.c have been improved. * The function free_expression has been added to listutl.c. * The function pop_object in name.c has been improved to add inactive entities to a list of inactive entities * The function close_stack in name.c has been improved to reverse the list of local objects and to dump and free the local objects. * The function dump_temp_value, which releases a value without releasing the object, has been added to objutl.c. * The function free_args has been added to prg_comp.c. Notes: svn path=/head/; revision=312621
* - Update to 20130203Pietro Cerutti2013-02-053-98/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Files to generate man pages for Seed7 interpreter and compiler have been added to the documentation (files doc/s7.1 and doc/s7c.1). * The makefiles have been improved to support the targets distclean and test. * The operators radix and RADIX have been added to the libraries integer.s7i and bigint.s7i. This operators convert an integer respectively bigInteger to a string. The conversion uses the numeral system with the given base. * The variants of the function str, which have a second parameter to specify a numeric base, are deprecated now and will be removed in a future release. The operators radix and RADIX should be used instead. * Interpreter and compiler have been improved to support the operators radix and RADIX. * In chkint.sd7 checks for the function str with base have been replaced with checks for the operators radix and RADIX. * Usages of the function str with base have been changed to usages of the operators radix or RADIX in the files gethttp.s7i, bas7.sd7, encoding.s7i and s7c.sd7. * Errors in bas7.sd7, concerning the function VARPTR and the statement OPEN, have been fixed. * The function getLineWithMacrosApplied in makedata.s7i has been improved to ignore space and tab characters after an escaped newline. * Result variables have been renamed in various libraries and example programs. * The currency sign character has been added to stdfont10.s7i, stdfont12.s7i, stdfont14.s7i, stdfont16.s7i, stdfont18.s7i, stdfont20.s7i, stdfont24.s7i, vecfont10.s7i and vecfont18.s7i. * The file chkccomp.c has been improved to define a macro that describes what happens, when a cast of a float to int overflows. - This release features the inclusion of the man pages for the seed7 interpreter s7(1) and compiler s7c(1) - Remove patch included upstream Notes: svn path=/head/; revision=311669
* - Update to 05_20130120Pietro Cerutti2013-01-214-13/+137
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * Interpreter and compiler have been improved to support the option *l. This option allows adding a directory to the include library search path (e.g.: -l ../lib). * The compiler (s7c) has been improved to support the option -b. With -b the directory of the Seed7 runtime libraries can be specified (e.g.: -b ../bin). * The target s7c in the makefiles has been changed to take advantage of the options -l and -b. Now packages can compile the Seed7 compiler without a post install step. * Additional function variants of parseFile, parseStri and execute have been added to the library progs.s7i. The new functions allow a detailed specification of parse and execution options. * The library gzip.s7c has been improved to decode also blocks with fixed Huffman codes. This type of block is almost never used since dynamic Huffman codes compress better. * The parsing of bigInteger literals has been improved to support literals with bases other than 10 (e.g.: 16#FEDCBA98765434210_). * The integer and bigInteger functions str (conversion to string) have been changed to use lower case characters for digits larger than 9. Now str(48879, 16) returns "beef" instead of "BEEF". * The program make7.sd7 and the library make.s7i have been improved to support multiple targets and the option -C. * The Seed7 compiler has been improved to generate special inline code for the case that the C floating point division by zero does not result in Infinity, -Infinity or NaN (not a number). * The functions chkLiteral and chkBitLength as well as checks for shifts with negative shift count have been added to the program chkbig.sd7. * The function check_division as well as has checks for the operator /:= (in check_nan) have been added to the program chkflt.sd7. * The function check_str in chkint.sd7 has been improved to check the new behaviour of the function str with a give base. * The makefile mk_clang.mak has been added to support compilation with the clang C compiler. * The explanations of possible compilation errors in src/read_me.txt have been improved. * The functions interpreterPath and callOwnProgram have been removed from the libraries environment.s7i respectively shell.s7i. This functions were not used in any example program. * The support for the interpreter option -m (use less memory during the analyzing phase) has been removed. On many systems it was a noop anyway. * Result variables have been renamed in various libraries and example programs. * The functions find_include_file, print_lib_path, append_to_lib_path and init_lib_path have been moved from infile.c to the new file libpath.c. * The function gen_rtl_array has been defined in the new file arrutl.c. The function is used in the files cmdlib.c (functions cmd_pipe2, cmd_pty, cmd_start_process) and prglib.c (functions prg_exec, prg_fil_parse, prg_str_parse). * The interpreter/compiler improvements (option -l) and the new function variants in progs.s7i have been realized with changes in prg_comp.c, analyze.c, data.h, infile.c, infile.h, info.c, option.h and s7.c. * The functions prgExec, prgFilParse and prgStrParse in prg_comp.c have been improved to support additional parse and execution options. * The function interpr has been renamed to interpret and moved from exec.c to prg_comp.c. * The function copy_args has been moved from prclib.c to prg_comp.c. * In traceutl.c the function set_trace has been changed and the function set_trace2 has been removed. The functions mapTraceFlags, mapTraceFlags2 and set_protfile_name have been added. * The functions uBigMultiplyAndAdd and bigParseBased have been added to big_rtl.c: * In big_gmp.c the functions bigBitLength, bigLShift, bigRShift, bigLShiftAssign, bigRShiftAssign, bigParse, and bigToInt32 have been improved and bigParseBased has been added. * To support bigInteger literals with base the file numlit.c has been Notes: svn path=/head/; revision=310774
* - Update to 05_20130105Pietro Cerutti2013-01-094-20/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The Seed7 interpreter was renamed. The new name of the Seed7 interpreter is s7. * Manual, FAQ, read_me files and several example programs were updated to use the new name of the Seed7 interpreter (s7). * The build process of a package can compile interpreter and compiler with (xx and yy must be replaced with a path): $ make S7_LIB_DIR=xx SEED7_LIBRARY=yy depend s7 s7c * The function drwOpen in drw_win.c was improved to hide the console window, when the program was not started from a console. * Descriptions of the operators 'sci' and 'exp' were added to the manual. * Documentation comments were added to clib_file.s7i. * In pixmap_file.s7i the functions for pixmapFontFiles were improved. * Interpreter and compiler were improved to allow using winmain as main function. * In cmd_win.c the function prepareCommandLine was improved and in the function cmdStartProcess the flag wShowWindow was changed to 1. * The file hi.c was renamed to s7.c. * In striutl.c the function escape_command was changed to quote commands with special characters under windows. * In striutl.c the function cp_to_command was improved to do a quoting under windows, even when there are no parameters. * Parameter names were added to null_file.s7i, osfiles.s7i, time.s7i, pixmapfont.s7i, progs.s7i, reference.s7i, seed7_05.s7i, shell.s7i, stritext.s7i, text.s7i, rever.sd7 and snake.sd7. Notes: svn path=/head/; revision=310158
* - Respect user's CFLAGSPietro Cerutti2012-12-201-1/+1
| | | | Notes: svn path=/head/; revision=309313
* - Use double-precision floating point numbersPietro Cerutti2012-12-181-0/+1
| | | | Notes: svn path=/head/; revision=309190
* - Update to 05_20121212Pietro Cerutti2012-12-183-259/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The Seed7 compiler was renamed. The new name of the Seed7 compiler is s7c. * Manual, FAQ, read_me files and several example programs were updated to use the new name of the Seed7 compiler (s7c). * A description of ltrim and rtrim and some links were added to the manual. * The library make.s7i and the example program make7.sd7 were improved to execute make commands with predefined macros. * The library makedata.s7i was improved to support dependencies which contain a space. * The library make.s7i was improved to support the command cp -a. * A variant of the function popen, with the parameters 'command' and 'parameters', was added to shell.s7i. * An explanation, why & and <& are defined for string concatenation, was added to the FAQ. * The program tar7.sd7 was improved to accept also DOS paths for all file arguments. * Documentation comments were added to progs.s7i and reference.s7i. * The files drw_win.c, drw_x11.c and gkb_x11.c were improved to exit a program when the close button (X) is pressed. * The functions refFile, refLine, refParams and refSetParams in ref_data.c were improved to raise RANGE_ERROR, when they are called with NULL. * The function ref_params in reflib.c was improved to call refParams. * The makefiles were improved such that 'make s7c' generates an executable of the Seed7 compiler. * The makefile mk_mingc.mak, which supports the compilation of the self extracting version of Seed7, was improved. * The support for the unused action REF_NAME was removed. - Reorganize installed files structure as per author's request (see http://seed7.sourceforge.net/faq.htm#seed7_package) - Remove article from COMMENT Notes: svn path=/head/; revision=309159
* - Update to 05_20121125Pietro Cerutti2012-11-284-24/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 20121125: - The makefiles and the file setpaths.c were improved to accept the macros S7_LIB_DIR (Directory with static Seed7 object libraries) and SEED7_LIBRARY (Directory with the Seed7 include libraries). Now the build process of a package can call make e.g. with: make S7_LIB_DIR=/abc/seed7/bin SEED7_LIBRARY=/abc/seed7/lib depend This way the two paths are defined in version.h. This defines them as default paths in the interpreter executable and in the compiler. - An explanation, what a binary Seed7 package should install, was added to the FAQ. This can be used as guideline for Seed7 packages. - The description of the times-operator in the manual and in array.s7i was improved. - A description of the function name(PROGRAM), file(PROGRAM) and 'environment' was added to the manual. - The new library environment.s7i was added. Most of the contents of this library was extracted from "seed7_05.sd7". The new library is included from "seed7_05.s7i", so no change in existing programs is necessary. - A documentation comment for getSearchPath was added to shell.s7i. - The functions ltrim and rtrim were added to the library string.s7i. - Testcases for ltrim and rtrim were added to chkstr.sd7. - The function getProgramName in arr_rtl.c was improved to do the comparison with EXECUTABLE_FILE_EXTENSION correctly. - The program tar7.sd7 was improved to accept also DOS paths for the file specified with -f. - The function homeDir was improved to work with DJGPP (either $HOME or C:\ is used). - The function prc_cpy in prclib.c was improved. - The files executl.c, hshlib.c, ref_data.c, reflib.c and sctlib.c were improved to copy the descriptor union with memcpy and to copy the posinfo flag with SET_ANY_FLAG, when necessary. 20121104: - The new function homeDir was added to the library osfiles.s7i. Interpreter and compiler were improved to support homeDir. - The libraries makedata.s7i and make.s7i were improved to support replacement macros. - A check for division by zero with /:= was added to chkflt.sd7. - The compiler (comp.sd7) was improved to use definitions of NOT_A_NUMBER, POSITIVE_INFINITY and NEGATIVE_INFINITY. - The program chkccomp.c was improved. Now it manages the macros likely, unlikely, UNISTD_H_PRESENT, POPEN_MISSING, os_utime_orig, os_utime, USE_ALTERNATE_UTIME, INCLUDE_SYS_UTIME, USE_LOCALTIME_R, USE_LOCALTIME_S, FLOAT_ZERO_DIV_ERROR, CHECK_FLOAT_DIV_BY_ZERO, ISNAN_WITH_UNDERLINE and HOME_DIR_ENV_VAR. Additionally chkccomp.c does not depend on the definitions of long_long_EXISTS, long_long_SUFFIX_LL, __int64_EXISTS, __int64_SUFFIX_LL and USE_BUILTIN_EXPECT in chkccomp.h. - The functions flt_div and flt_div_assign in fltlib.c were improved to work correctly when CHECK_FLOAT_DIV_BY_ZERO is defined. - Several #defines were ommitted from the makefiles. - Explanations of several version.h #defines were added to read_me.txt Feature safe: yes Notes: svn path=/head/; revision=307906
* - Update to 05_20121021Pietro Cerutti2012-10-293-8/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: - The library vecfont10.s7i, which defines the standard vector font with capital height 10, was added. Now mahjong.sd7 and shisen.sd7 use vecfont10.s7i. - The programs mahjong.sd7, pairs.sd7, shisen.sd7 and sokoban.sd7 were improved to fit into a screen with a resolution of 1024 x 768. - The library make.s7i was improved: The parsing of command parameters (used by the Unix version of the echo command), was improved. The processing of pattern rules was improved (The rule with the shortest stem value is used, when several rules match). - Functions to read a makefile were moved from make.s7i to the new library makedata.s7i. - The reading of makefiles was improved: The processing of the gmake directives 'ifeq' and 'ifneq' was improved to allow else clauses. The processing of the nmake directive 'if' was added. Merging of dependencies for rules with the same target was improved. - The parse function for time values (library time.s7i) was improved to allow fractions of a second. - The functions getSubNodes and getContent and a for-loop for xmlNode values were defined in the library xmldom.s7i. - The compiler was improved to initialize bstring literals correctly, when pointers are 64-bit and integers are 32-bit. - The font libraries cronos16.s7i, cronos27.s7i, modern27.s7i and vecfont18.s7i were improved to include vectorfont.s7i. - The font libraries stdfont10.s7i, stdfont12.s7i, stdfont14.s7i, stdfont16.s7i, stdfont18.s7i, stdfont20.s7i and stdfont24.s7i were improved to include bitmapfont.s7i. - The program dnafight.sd7 was improved to limit the speed of the animation. - The program make7.sd7 was improved to recognize the options correctly. Additionally make7 inherits also all improvements of makedata.s7i and make.s7i. - The program ftp7.sd7 was improved to accept the option -?. - The graphic libraries drw_x11.c and drw_win.c were improved to draw the background of maximized windows with the color of the last clear command. Feature safe: yes Notes: svn path=/head/; revision=306597
* - Update to 05_20121007Pietro Cerutti2012-10-183-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: 20121007: - An error message, that could occur when the Seed7 interpreter is compiled, is explained in the FAQ and to 'src/read_me.txt'. - A description of the for-step-statement was added to the manual. - The library make.s7i was improved. Now makefile dependencies can contain colons (:) and equal signs (=). The parameters of the echo command are parsed better now. Calls of the function callOwnProgram are also avoided now. This way the library works correctly, when it is used by programs other than make7.sd7. - The library tar.s7i was improved to set the file mode, when an archive is extracted. - Testcases for a variant of the @:= operator, which copies a string to another, were added to the program chkstr.sd7. - Interpreter and compiler were improved to support the situation, when source and destination of the @:= operator (action STR_POSCPY) are identical. - The compiler was improved to support the action ITF_DESTR. - The compiler was improved, to call C compiler and linker with specific options, such that unneeded functions are ommited (when the linker and executable file format support this feature). - The compiler was improved to remove debug symbols, unless called with -g (some makefiles now define LINKER_OPT_NO_DEBUG_INFO). - The function name(PROGRAM) was improved, to return the program name without following symbolic links. - The function path(PROGRAM) was improved, to follow symbolic links (see function followLink in cmd_rtl.c). Consequently dir(PROGRAM) also follows symbolic links. - The function CommandLineToArgvW in cmd_win.c was improved. - The files itf_rtl.c and itf_rtl.h, which contain interface functions, were added. - The makefile mk_mingc.mak was added to support compilation of the self extracting version of Seed7. 20120923: - Experimental support for automatic memory management with reference counting was added to the interpreter. - The libraries external_file.s7i, field.s7i, stritext.s7i, gzip.s7i, listener.s7i, pixmap_file.s7i, shell.s7i, socket.s7i, strifile.s7i, dir.s7i, utf16.s7i, utf8.s7i and xmldom.s7i were improved to use the function toInterface. - The function name(PROGRAM) was improved, to return the name of the program without extension and without path. - The interpreter was improved to support the action ITF_DESTR. Feature safe: yes Notes: svn path=/head/; revision=306068
* - update to 05_20120909Pietro Cerutti2012-09-242-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: 20120909: - The chapters about predefined statements and the foreign function interface in the manual, were improved. - An explanation, why the div operator is used for integer divisions, was added to the FAQ. - The FAQ about garbage collection was improved. - Links to EBNF syntax descriptions and exceptions were added to the HTML version of the manual. - EBNF syntax descriptions in the manual were improved. - Interpreter and compiler were improved to support the actions CMD_ENVIRONMENT and CMD_GET_SEARCH_PATH. - The library shell.s7i was improved to define the functions getSearchPath and environment. - The function path(PROGRAM) was improved to return the accurate value under all circumstances. - Several preprocessor defines were moved from "common.h to the new include file "config.h". - In cmdlib.c the function toArraytype() was introduced and used in cmd_environment() and cmd_getSearchPath(). - In cmd_rtl.c the functions add_stri_to_array() and complete_stri_array() were introduced and used in read_dir(), getSearchPath() and cmdEnvironment(). - Parameter names in drw_win.c, drw_x11.c and drw_dos.c were changed to fit to the names used in graph.s7i. - Parameter names in clib_file.s7i, keybd.s7i, sockbase.s7i, socket.s7i, utf8.s7i, fil_rtl.c, gkb_rtl.c, kbd_rtl.c, soc_dos.c, soc_rtl.c and ut8_rtl.c were changed to fit to each other. - The function conv_from_os_stri() was added to striutl.c . - The function concat_path in str_rtl.c was improved to work correctly, when the relative path contains "..". - In several makefiles defines for SEARCH_PATH_DELIMITER and os_environ were added and defines for MAP_ABSOLUTE_PATH_TO_DRIVE_LETTERS were replaced with defines for OS_PATH_HAS_DRIVE_LETTERS. - A description of several C preprocessor macros used in "version.h" and "config.h" was added to the file "src/read_me.txt". - Parameter names were added to function definitions in various libraries. - Documentation comments were added or improved in the files "clib_file.s7i", "external_file.s7i", "socket.s7i", "fil_rtl.c" and "striutl.c". - The function determineEnvironDefines was added to "chkccomp.c". 20120826: - A chapter, which explains the foreign function interface, was added to the manual. - Syntax descriptions, code examples and tables in the HTML version of the manual were improved. - Documentation comments were added to the file "striutl.c". - A description of several C preprocessor macros used in "version.h" was added to the file "src/read_me.txt". Notes: svn path=/head/; revision=304777
* - Update to 05_20120806Pietro Cerutti2012-08-163-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The new library image.s7i was added. The contents of this library was extracted from the program "carddemo.sd7". * The new library make.s7i was added. The contents of this library was extracted from the program "make7.sd7". * The function 'str' and the 'parse' operator were added to the library bstring.s7i. * The function readDir was added to the library tar.s7i. * A documentation comment was improved in the library bigint.s7i. * The generation of bstring constants in the compiler (comp.sd7) was improved. * The function intStrHex was renamed to intStrPow2Base in the files "int_rtl.c", "int_rtl.h" and in the compiler. The new function is used to convert an integer to a string, when the number base is a power of two. * The function stri_export was renamed to stri_export_utf8 in the C source files. * The function cp_to_cstri was renamed to cp_to_cstri8 in the C source files. * Documentation comments were added and improved in the file "striutl.c". * The makefile mk_msvc.mak was changed to write a definition of LIMITED_CSTRI_LITERAL_LEN to "version.h". * Documentation comments were improved in the libraries idxarray.s7i, array.s7i, dir.s7i, external_file.s7i, osfiles.s7i, duration.s7i and time.s7i. * Parameter names were added to function definitions in the libraries array.s7i, bigfile.s7i, hash.s7i and idxarray.s7i. * The compiler was improved to generate better inline code for set membership (operator: in). * The functions 'cmdFileType' and 'cmdFileTypeSL' in "cmd_rtl.c" were improved to return FILE_ABSENT, when the file name is too long (stat() respectively lstat() return an error and errno has the value ENAMETOOLONG) or when the file name is an empty string. * The new libraries subrange.s7i, ref_list.s7i and reference.s7i were added. The contents of this libraries were extracted from the seed7_05.s7i library. Notes: svn path=/head/; revision=302631
* - Update to 05_20120703Pietro Cerutti2012-07-093-3/+8
| | | | Notes: svn path=/head/; revision=300668
* - Update to 05_20120603Pietro Cerutti2012-06-143-3/+17
| | | | | | | | Since I've missed a few releases the list of changes is quite bit. Please see the chlog.txt file in DOCSDIR. Notes: svn path=/head/; revision=299250
* - Update to 05_20120304Pietro Cerutti2012-03-062-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: * The "ftpserv.sd7" example program was improved to support the commands RNFR and RNTO and to work correctly, when the listener cannot open a passive data port. * The font support was improved, such that caching of character pixmaps works. * Some characters in the standard bitmap fonts were added or improved. * The functions 'socSend' and 'socSendto' in "soc_rtl.c" were improved to work correctly under 64-bit systems. * The function 'fltSci' in "flt_rtl.c", was improved to avoid a C compiler warning about the change of a constant value. * The function 'redraw' in "drw_x11.c" was changed, such that it does not use a parameter of type 'XExposeEvent'. * The functions 'drwHeight', 'drwWidth', 'drwXPos' and 'drwYPos' in "drw_x11.c" were improved to raise RANGE_ERROR when the window does not exist. * The function 'handleExpose' was introduced in "gkb_x11.c", to handle the job of calling 'redraw'. * The type 'unsigned int' was replaced by 'sysizetype' in 'findid.c', 'findid.h', 'identutl.c', 'identutl.h', 'literal.c', 'numlit.c', 'scanner.c' and 'symbol.h'. * Some improvements were done in 'prg_comp.c', 'reflib.c', 'analyze.c', 'exec.c', 'infile.c', 'info.c' and 'typlib.c' to reduce the number of warnings. * Support for the unused action "ENU_SIZE" was removed. - Add LICENSE Notes: svn path=/head/; revision=292824
* - Update to 05_20120219Pietro Cerutti2012-02-283-14/+3
| | | | | | | - Fixes to the console library have been pushed upstreams Notes: svn path=/head/; revision=292360
* - Update to 05_20120205Pietro Cerutti2012-02-062-3/+3
| | | | Notes: svn path=/head/; revision=290473
* - Update to 05_20120115Pietro Cerutti2012-02-034-5/+18
| | | | | | | - Install console library as well Notes: svn path=/head/; revision=290339
* - Update to 05_20120101Pietro Cerutti2012-01-033-3/+6
| | | | Notes: svn path=/head/; revision=288460
* - second attempt to respect CC and CFLAGSPietro Cerutti2011-11-242-2/+2
| | | | | | | Feature safe: yes Notes: svn path=/head/; revision=286359
* - Update to 05_20111111Pietro Cerutti2011-11-233-8/+17
| | | | | | | | | | | - Respect CC and CFLAGS [1] PR: 162542 [1] Submitted by: Jan Beich <jbeich@tormail.net> Feature safe: yes Notes: svn path=/head/; revision=286297
* - Update to 05_20110904Pietro Cerutti2011-09-074-13/+37
| | | | Notes: svn path=/head/; revision=281355
* - Update to 05_20110403Pietro Cerutti2011-04-052-3/+3
| | | | Notes: svn path=/head/; revision=272235
* - Update to 05_20110306Pietro Cerutti2011-03-152-3/+3
| | | | Notes: svn path=/head/; revision=270968
* - Update to 05_20110203Pietro Cerutti2011-02-044-9/+10
| | | | | | | | | Many changes since the last update, see doc/chlog.txt for the details. Feature safe: yes Notes: svn path=/head/; revision=268606
* - Update to 05_20101219Pietro Cerutti2010-12-244-14/+24
| | | | Notes: svn path=/head/; revision=266835