| Commit message (Expand) | Author | Age | Files | Lines |
* | print: Support R7RS |...| symbol notation....* libguile/print.c (scm_print_opts): Add 'r7rs-symbols' print option.
(symbol_has_extended_read_syntax): If the 'r7rs-symbols' option is
enabled, then disallow '|' and '\' from bare symbols.
(print_extended_symbol): Use 'scm_lfwrite' and 'scm_putc' instead of
'display_string' and 'display_character' when printing ASCII literals.
(print_r7rs_extended_symbol): New static function.
(scm_i_print_symbol_name): If the 'r7rs-symbols' option is enabled,
use 'print_r7rs_extended_symbol' instead of 'print_extended_symbol'.
* libguile/private-options.h (SCM_PRINT_R7RS_SYMBOLS_P): New macro.
(SCM_N_PRINT_OPTIONS): Increment.
* doc/ref/api-evaluation.texi (Scheme Write): Mention 'r7rs-symbols'
print option.
* test-suite/tests/print.test ("write"): Add tests.
| Mark H Weaver | 2014-01-14 | 1 | -1/+2 |
* | read: Support R7RS |...| symbol notation....* libguile/private-options.h (SCM_R7RS_SYMBOLS_P): New macro.
(SCM_N_READ_OPTIONS): Increment.
* libguile/read.c (scm_read_opts): Add entry for 'r7rs-symbols'.
(t_read_opts): Add field for 'r7rs_symbols_p'.
(scm_read_string_like_syntax): New function based on earlier
'scm_read_string' that handles either string literals or R7RS quoted
symbols (delimited by vertical bars), depending on the value of 'chr'.
(scm_read_string): Reimplement based on 'scm_read_string_like_syntax'.
(scm_read_r7rs_symbol): New static function.
* doc/ref/api-data.texi (Symbol Read Syntax): Briefly describe the R7RS
symbol syntax, mention the 'r7rs-symbols' read option, and give some
examples.
* doc/ref/api-evaluation.texi (Scheme Read): Mention the 'r7rs-symbols'
read option.
* test-suite/tests/reader.test ("reading"): Add test.
| Mark H Weaver | 2014-01-14 | 1 | -2/+3 |
* | Increment SCM_N_READ_OPTIONS for 'curly-infix' option....* libguile/private-options.h (SCM_N_READ_OPTIONS): Increment to 8.
This should have been done when the 'curly-infix' was added.
| Mark H Weaver | 2014-01-08 | 1 | -1/+1 |
* | Implement SRFI-105 curly infix expressions....* libguile/private-options.h: Add SCM_CURLY_INFIX_P macro, and increment
SCM_N_READ_OPTIONS.
* libguile/read.c (sym_nfx, sym_bracket_list, sym_bracket_apply): New
variables.
(scm_read_opts): Add curly-infix reader option. Reformat to comply
with GNU coding standards.
(scm_t_read_opts): Add curly_infix_p and neoteric_p fields.
(init_read_options): Initialize new fields.
(CHAR_IS_DELIMITER): Add '{', '}', '[', and ']' as delimiters if
curly_infix_p is set.
(set_port_square_brackets_p, set_port_curly_infix_p): New functions.
(read_inner_expression): New function which contains the code that was
previously in 'scm_read_expression'. Handle curly braces when
curly_infix_p is set. If curly_infix_p is set and square_brackets_p
is unset, follow the Kawa convention: [...] => ($bracket-list$ ...)
(scm_read_expression): New function body to handle neoteric
expressions where appropriate.
(scm_read_shebang): Handle the new reader directives: '#!curly-infix'
and the non-standard '#!curly-infix-and-bracket-lists'.
(scm_read_sexp): Handle curly infix lists.
* module/ice-9/boot-9.scm (%cond-expand-features): Add srfi-105 feature
identifier.
* doc/ref/srfi-modules.texi (SRFI-105): Add stub doc for SRFI-105.
* doc/ref/api-evaluation.texi (Scheme Read): Add documentation for the
'curly-infix' read option, and the '#!curly-infix' and
'#!curly-infix-and-bracket-lists' reader directives.
* doc/ref/api-options.texi (Runtime Options): Add 'curly-infix' to the
list of read options.
* test-suite/Makefile.am: Add tests/srfi-105.test.
* test-suite/tests/srfi-105.test: New file.
| Mark H Weaver | 2012-10-26 | 1 | -1/+2 |
* | new print option escape-newlines, defaults to #t...* libguile/private-options.h (SCM_PRINT_ESCAPE_NEWLINES_P):
* libguile/print.c: Add new escape-newlines print option, defaulting to
on.
(write_character): For newlines, if SCM_PRINT_ESCAPE_NEWLINES_P, then
print them as \n.
(scm_init_print): Refactor print options initialization.
| Andy Wingo | 2011-12-04 | 1 | -1/+4 |
* | implement r6rs hungry escaped EOL...* libguile/private-options.h (SCM_HUNGRY_EOL_ESCAPES_P): New private
option.
* libguile/read.c: Define SCM_HUNGRY_EOL_ESCAPES_P, defaulting to #f.
(skip_intraline_whitespace): New helper.
(scm_read_string): If SCM_HUNGRY_EOL_ESCAPES_P,
skip_intraline_whitespace after an escaped EOL.
* test-suite/tests/reader.test ("read-options"): Add test.
| Andy Wingo | 2011-01-21 | 1 | -1/+2 |
* | scm_debug_opts to debug.c, backtrace on by default, scm_*_opts internal linkage...* libguile/eval.c:
* libguile/debug.c (scm_debug_opts): Move here, from eval.c. Change
SCM_BACKTRACE_P to 1, initially.
* libguile/private-options.h: Make all options vars private.
| Andy Wingo | 2010-10-01 | 1 | -3/+3 |
* | remove elisp-strings and elisp-vectors read options...* libguile/private-options.h (SCM_ELISP_VECTORS_P, SCM_ESCAPED_PARENS_P):
* libguile/read.c (scm_read_opts): Remove unused elisp-vectors option,
and the elisp-strings option (which allowed \( and \) escapes in
strings).
(scm_read_string): Remove the elisp-strings case.
* doc/ref/api-options.texi (Reader options): Update, and update wording
of the case-insensitive bit.
| Andy Wingo | 2010-10-01 | 1 | -5/+3 |
* | remove unused print-options...* libguile/private-options.h (SCM_PRINT_CLOSURE, SCM_PRINT_SOURCE_P):
* libguile/print.c (scm_print_opts):
* doc/ref/api-options.texi (Printing options): Remove source and
closure-hook print options.
| Andy Wingo | 2010-10-01 | 1 | -7/+5 |
* | remove a number of debug options...* libguile/private-options.h (SCM_BREAKPOINTS_P, SCM_TRACE_P)
(SCM_REC_PROCNAMES_P, SCM_BACKTRACE_INDENT, SCM_N_FRAMES)
(SCM_BACKTRACE_MAXDEPTH, SCM_DEVAL_P): Remove these internal names.
* libguile/eval.c (scm_debug_opts): Remove the corresponding debug
options -- breakpoints, trace, procnames, indent, frames, maxdepth,
and debug.
* libguile/debug.c (scm_debug_options): Remove SCM_N_FRAMES check.
* test-suite/lib.scm (with-debugging-evaluator*):
* module/scripts/summarize-guile-TODO.scm:
* module/statprof.scm (statprof-reset):
* module/ice-9/boot-9.scm (turn-on-debugging): Remove useless
debug-enable 'debug calls.
* module/ice-9/deprecated.scm (debug-enable): As it seems that 'debug is
a particulatly common option that we just removed, add a deprecation
shim.
* doc/ref/api-options.texi (Debugger options): Update the set of debug
options.
| Andy Wingo | 2010-09-24 | 1 | -15/+8 |
* | remove evaluator-traps-interface...* libguile/debug.h:
* libguile/debug.c (scm_with_traps):
* libguile/eval.c (scm_evaluator_traps, scm_evaluator_trap_table):
Remove these procedures. Note that scm_evaluator_traps was known in
Scheme as `evaluator-traps-interface'.
* libguile/private-options.h (SCM_TRAPS_P, SCM_ENTER_FRAME_P)
(SCM_APPLY_FRAME_P, SCM_EXIT_FRAME_P, SCM_ENTER_FRAME_HDLR)
(SCM_APPLY_FRAME_HDLR, SCM_EXIT_FRAME_HDLR, SCM_MEMOIZE_P)
(SCM_MEMOIZE_HDLR): Remove these private interfaces.
* module/ice-9/boot-9.scm (traps, trap-enable, trap-disable, trap-set!):
Remove.
* module/ice-9/scm-style-repl.scm (error-catching-loop): Remove
with-traps wrap.
* doc/ref/api-options.texi (Low level options interfaces):
(User level options interfaces, Evaluator trap options)
* doc/ref/api-evaluation.texi (Evaluator Behavior): Remove references to
the evaluator traps interface.
| Andy Wingo | 2010-09-24 | 1 | -15/+0 |
* | remove eval-options...* libguile/eval.c:
* libguile/private-options.h (scm_eval_opts, scm_eval_options_interface)
(SCM_EVAL_STACK): Remove these private interfaces.
* module/ice-9/boot-9.scm (eval-options, eval-enable, eval-disable)
(eval-set!): Remove these procedures.
* doc/ref/api-evaluation.texi:
* doc/ref/api-options.texi: Remove references to eval options.
| Andy Wingo | 2010-09-24 | 1 | -6/+0 |
* | lisp nil always enabled...* configure.ac: Remove --disable-elisp option. Lisp nil is always
enabled.
* libguile/boolean.h:
* libguile/gen-scmconfig.c:
* libguile/gen-scmconfig.h.in:
* libguile/init.c:
* libguile/lang.c:
* libguile/lang.h:
* libguile/pairs.h:
* libguile/private-options.h:
* libguile/read.c: Remove conditionals for disabling elisp.
| Andy Wingo | 2010-04-09 | 1 | -9/+0 |
* | reader options macros incorrect when SCM_ENABLE_ELISP undefined...When compiled with SCM_ENABLE_ELISP undefined, the reader options
macros SCM_R6RS_ESCAPES_P and SCM_SQUARE_BRACKETS_P point past
the end of the scm_read_opts struct.
*libguile/private-options.h (SCM_R6RS_ESCAPES_P) [!SCM_ENABLE_ELISP]: modified
(SCM_SQUARE_BRACKETS_P) [!SCM_ENABLE_ELISP]: modified
(SCM_N_READ_OPTIONS): modified
| Michael Gran | 2010-01-17 | 1 | -3/+6 |
* | add reader option for parsing [] as ()....* libguile/private-options.h:
* libguile/read.c (scm_read_opts, SCM_SQUARE_BRACKETS_P): Add an option
for treating [ and ] as parentheses, on by default. Note that this
makes them delimiters also, so [ and ] cannot appear in a symbol name,
with this read option on.
(scm_read_sexp): If we start with [, we end with ].
(scm_read_expression): Add case for [.
| Andy Wingo | 2010-01-15 | 1 | -1/+2 |
* | Reader option for R6RS hex escapes...This adds a reader option 'r6rs-hex-escapes that modifies the
behavior of numeric escapes in characters and strings. When enabled,
variable-length character hex escapes (#\xNNN) are allowed and become
the default output format for numerically-escaped characters. Also,
string hex escapes switch to a semicolon terminated hex escape (\xNNNN;).
* libguile/print.c (PRINT_CHAR_ESCAPE): new macro
(iprin1): use new macro PRINT_CHAR_ESCAPE
* libguile/private-options.h (SCM_R6RS_ESCAPES_P): new #define
* libguile/read.c (scm_read_opts): add new option r6rs-hex-escapes
(SCM_READ_HEX_ESCAPE): modify to take a terminator parameter
(scm_read_string): parse R6RS hex string escapes
(scm_read_character): parse R6RS hex character escapes
* test-suite/tests/chars.test (with-read-options): new procedure
(R6RS hex escapes): new tests
* test-suite/tests/strings.test (with-read-options): new procedure
(R6RS hex escapes): new tests
| Michael Gran | 2010-01-12 | 1 | -2/+6 |
* | remove unused scm_eval_stack var...* libguile/private-options.h:
* libguile/eval.c (scm_eval_stack): Remove declaration and definition of
unused scm_eval_stack variable.
| Andy Wingo | 2009-12-01 | 1 | -3/+1 |
* | Change Guile license to LGPLv3+...(Not quite finished, the following will be done tomorrow.
module/srfi/*.scm
module/rnrs/*.scm
module/scripts/*.scm
testsuite/*.scm
guile-readline/*
)
| Neil Jerram | 2009-06-17 | 1 | -6/+7 |
* | * private-options.h: idem....* eval.i.c: copyright nitpicking.
* eval.c: distangle. move duplicate code to eval.i.c and include
twice.
* eval.i.c: new file.
* backtrace.c, debug.c, debug.h, deprecation.c, eq.c, eval.c
eval.h, gsubr.c, init.c, macros.c, print.c, print.h, read.c,
read.h, stacks.c, symbols.c, throw.c: use private-options.h
* private-options.h: new file: contain hardcoded option
definitions.
| Han-Wen Nienhuys | 2007-01-22 | 1 | -1/+1 |
* | * backtrace.c, debug.c, debug.h, deprecation.c, eq.c, eval.c...eval.h, gsubr.c, init.c, macros.c, print.c, print.h, read.c,
read.h, stacks.c, symbols.c, throw.c: use private-options.h
* private-options.h: new file: contain hardcoded option
definitions.
| Han-Wen Nienhuys | 2007-01-22 | 1 | -0/+103 |