| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Requires updated man2html which puts out lower case.
* genman.txr: All matched and generated HTML is lower case.
* txr.1 (NP*): Use lower case h4 tag in M2SS macro.
|
|
|
|
|
|
| |
* txr.1: Improved wording, better explanation, explanation
that nested macro lists support all features, and
specified meaning of :whole inside nested lists.
|
|
|
|
| |
* txr.1: "unless they are the same object."
|
|
|
|
|
|
|
|
| |
txr.1: Lose the useless use of conditional evaluation.
Everything is doable with the meIP macro. Only one piece
of conditional evaluation is needed for different wording:
textual man page says "angle brackets" whereas formatted
page refers to italic font.
|
|
|
|
| |
* txr.1: Remove spurious z in example.
|
|
|
|
|
| |
* txr.1: Structures move under cobj types, which are indicated
with angle brackets to show they are not programmer-visible.
|
|
|
|
| |
* txr.1: more types are listed under typeof.
|
|
|
|
| |
* txr.1: Misuse of << in syntax block.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* eval.c (symbol_function): Only retrieve function binding,
and not macro or operator bindings, unless compatibility
<= 127 is in effect.
(symbol_macro): New function.
(fboundp): Only test for existence of function, not
macro or operator, unless <= 127 compatibility is in effect.
(fmakunbound): Do not remove macro binding, unless
compatibility <= 127 is in effect.
(eval_init): Register sys:top-mb variable for use in place.tl
library module. Register symbol-macro intrinsic function.
* share/txr/stdlib/place.tl (sys:get-mb): New function
(symbol-macro): New syntactic place.
* txr.1: Updated incorrect documentation about environments
from the perspective that macros and functions coexist.
Documented symbol-macro. Updated symbol-function, fboundp
and fmakunbound documentation. Added missing documentation
for mmakunbound. Reference to fboundp under define-place-macro
revised to mboundp. Added compatibility notes.
|
|
|
|
|
|
|
|
|
|
| |
* RELNOTES: Updated.
* configure, txr.1: Bumped version and date.
* share/txr/stdlib/ver.tl: Likewise.
* txr.vim, tl.vim: Regenerated.
|
|
|
|
|
|
|
|
| |
* share/txr/stdlib/ifa.tl (ifa): Accept dwim expressions
as the condition. Moreover, treat [f x] as a one-argument
call, even though it is the two-argument form (dwim f x).
* txr.1: Documented.
|
|
|
|
| |
* txr.1: Blank line before SYNOPSIS and DESCRIPTION.
|
|
|
|
|
|
|
|
| |
* txr.1: The ifa rules are organized as numbered clauses. The
definition of it-candidate is given up front. Rule 4 is
corrected: the it variable is bound to the argument
expression, not merely its value. Examples refer to rules and
new ones added.
|
|
|
|
|
| |
* txr.1: Remove text fragment, and clarify treatment of not,
null and false.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Already we have the situation that there is an if function and
an if macro, and same for and and or.
This change allows such situations to be programmer-defined.
* eval.c (op_defun): Don't remhash the name from the toplevel
macro bindings.
(op-defmacro): Don't remhash the name from the toplevel
function bindings.
* txr.1: Document the permissive behavior as dialect notes
under defmacro and defun.
|
|
|
|
|
|
|
|
|
| |
* eval.c (mboundp, mmakunbound): New static functions.
(eval_init): Registering mboundp and mmakunbound intrinsics.
* txr.1: Documenting new functions. Also clarifying that
fboundp checks for an operator macro binding (not a symbol
macro binding).
|
|
|
|
|
|
|
| |
* eval.c (eval_init): Register lookup_origin as macro-ancestor
intrinsic.
* txr.1: Documented.
|
|
|
|
|
| |
* txr.1: formatting fix in syntax section. Added explanation
that macro expansions inherit source loc info from expander.
|
|
|
|
|
| |
* txr.1: TXR pattern language condensed into fewer sections
with deeper nesting. Some sections renamed.
|
| |
|
|
|
|
|
| |
* txr.1: Under dwim operator, describe [...] notation
without asserting that it is preferred.
|
|
|
|
| |
* txr.1: Tense agreement, clarification. Italicize de facto.
|
| |
|
|
|
|
| |
* txr.1: replace colloquial word choice.
|
|
|
|
|
| |
* txr.1: Upgrade text under Callable Objects and Operator
dwim.
|
|
|
|
|
| |
* txr.1: There is no such function as range-regst.
This should be search-regst.
|
|
|
|
|
|
|
|
|
|
|
| |
* regex.c (range_regex): Return range.
(search_regst): Use appropriate accessors on
range returned by range_regex.
* lib.c (tok_where): Destructure range returned by
range_regex, using range_bind.
* txr.1: Documented changed behavior.
|
|
|
|
|
|
|
|
|
|
|
| |
* struct.c (static_slot_ensure): Restructured function so that
the subtypes of stype are processed even if stype already has
the static slot. This way static-slot-ensure can be used to
overwrite a static slot value, not only establish one.
And thus defmeth can redefine methods.
* txr.1: Revamped static-slot-ensure doc, and added notes
about redefining to defmeth.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This bug doesn't affect static slots that are defined in
defstruct, because those get initialized in the new type by
the static init function.
The bug is that the values of static slots added later with
static_slot_ensure are not inherited by subtypes that are
created later still.
(Since static_slot_ensure propagates a slot to subtypes which
already exist, those types get the slot value.)
* struct.c (make_struct_type): Copy the contents of the
static slot array of the supertype into the new type,
so that static slot values are inherited. We can just use
memcpy because the ordering of static slots is the same
in the new type, and the inherited ones precede the
new ones, due to the way the all_slots list is combined.
* txr.1: Clarify inheritance of static slots.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* eval.c (op_defun): Handle (meth type name) syntax
in place of name via sys:defmeth function, which
is dynamically resolved and autoloaded as necessary.
(builtin_reject_test): When defun is being checked,
recognize a (method ...) form and allow it.
* struct.h (meth_s): Declaration added.
* txr.1: Documented new defun capability.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* eval.c (func_get_name): Use try to use new method_name
function, if unable to get name from the lexical or
global environment for functions.
* struct.c (meth_s): New symbol variable.
(struct_init): Initialize meth_s variable.
(method_name): New function.
* struct.h (method_name): Declared.
* txr.1: Re-documented func-get-name.
|
|
|
|
|
|
|
|
|
|
| |
* RELNOTES: Updated.
* configure, txr.1: Bumped version and date.
* share/txr/stdlib/ver.tl: Likewise.
* txr.vim, tl.vim: Regenerated.
|
|
|
|
|
|
|
|
|
|
|
| |
* lisplib.c (place_set_entries): New entry to trigger
autoloading for define-accessor.
* share/txr/stdlib/place.tl (sys:register-simple-accessor):
New function.
(define-accessor): New macro.
* txr.1: Documented define-accessor.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* args.h (args_set_fill): New inline function.
* eval.c (eval_init): Register window-map and window-mappend
intrinics.
* lib.c (wrap_k, reflect_k): New keyword variables.
(calc_win_size): New static function.
(window_map_list, window_map_vec): New static functions.
(window_map, window_mappend): New functions.
(obj_init): Initialize wrap_k and reflect_k.
* lib.h (window_map, window_mappend): Declared.
* txr.1: Documented window-map and window-mappend
|
|
|
|
|
|
|
|
|
|
| |
* RELNOTES: Updated.
* configure, txr.1: Bumped version and date.
* share/txr/stdlib/ver.tl: Likewise.
* txr.vim, tl.vim: Regenerated.
|
|
|
|
|
|
| |
* lib.c (last): Handle non-list sequences via sub function.
* txr.1: Updated description of last.
|
|
|
|
|
|
|
|
|
| |
* txr.c (txr_main): Implement handling of TXR_COMPAT
environment variable. Also, before entering interactive
mode, if compatibility has been set via TXR_COMPAT,
emit an informative message about this.
* txr.1: Documented TXR_COMPAT.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the equal method is defined for structs, its return
value is used in their place for hashing and comparison.
* eval.h (eq_s, eql_s, equal_s): Declared.
* hash.c (equal_hash): If a COBJ defines an equalsub
function, we call it. If it returns non-nil, we
take the object in its place and recurse.
* lib.c (equal): Refactored to support equality substitution.
(less): Support equality substitution.
* lib.h (cobj_ops): New function pointer member, equalsub.
Only struct instances define this, currently.
(cobj_ops_init): Add null entry to initializer for equalsub.
(cobj_ops_init_ex): New initialiation macro for
situations when the equalsub member must be provided.
* struct.c (struct struct_type): new member eqmslot.
(make_struct_type): Initialize emslot to zero.
(static_slot_set, static_slot_ensure): If eqmslot is -1,
indicating positive knowledge that there is no equal method
static slot, we must invalidate that with a zero: it is no
longer known whether there is or isn't such a slot.
(get_equal_method, struct_inst_equalsub): New static functions.
(struct_inst_ops): Initialize the equalsub member using
new cobj_ops_init_ex macro.
* txr.1: Document equality substitution.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* share/txr/stdlib/struct.tl (lnew): New macro.
* struct.c (struct_type): Turn id into a bitfield one bit
smaller than cnum. New Boolean bitfield lazy.
(struct_init): Register make-lazy-struct intrinsic.
(make_struct): Initialize lazy bitfield to zero.
(lazy_struct_init, check_init_lazy_struct): New static
functions.
(make_lazy_struct): New function.
(copy_struct, clear_struct, replace_struct, reset_struct,
lookup_slot, struct_inst_equal, struct_inst_hash):
Call check_init_lazy_struct on all structures involved.
(lookup_slot): Call check_init_lazy_struct.
(struct_inst_mark): If the struct is lazy, it has one
instance slot which must be marked, holding the argfun
function passed into make_lazy_struct.
* struct.h (make_lazy_struct): Declared.
* txr.1: Documented lnew and make-lazy-struct.
|
|
|
|
|
|
|
|
|
|
|
| |
* match.c (v_next): Evaluate the source expression as TXR Lisp,
unless it is meta-expression or meta-variable, or
the compatibility option is set to 124 or lower.
In those cases treat it as an expression of the TXR Pattern
* txr.1: Updated documentation of @(next) and all
relevant examples of @(next) everywhere.
Added compatibility notes.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* filter.c (to_html_k, from_html_k, to_html_relaxed_k):
Variables removed.
(tohtml_k, tohtml_star_k, fromhtml_k): New keyword
symbol variables.
(to_html_table): Array renamed to tohtml_table.
(to_html_relaxed_table): Renamed to tohtml_star_table.
(from_html_table): Renamed to fromhtml_table.
(html_encode): Refers to tohtml_k.
(html_encode_star): Refers to tohtml_star_k.
(html_decode): Refers to fromhtml_k.
(filter_init): Initialize new symbol variables. Remove old
registrations. Register filters under old names too.
* txr.1: Document new names.
|
|
|
|
|
|
|
|
|
|
|
| |
* filter.c (to_html_relaxed_k): New keyword symbol variable.
(to_html_relaxed_table): New static array.
(html_encode_star): New static function.
(filter_init): Initialize new symbol variable.
Register new filter. Register html-encode* function.
* txr.1: Documented :to_html_relaxed filter and
html-encode* function.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* match.c (h_coll): Check for rep symbol, and handle similarly
to v_coll. Use symbol in error message.
(dir_tables_init): Bind rep symbol to h_coll.
* parser.y (elems): Don't generate rep_elem phrase structure
for the sake of catching "rep outside of output"; this
production now conflicts with the intent to allow this.
(elem): Add various REP productions which clones of COLL.
* txr.1: Documented new @(rep) usage.
|
|
|
|
|
|
|
|
|
|
| |
* eval.c (eval_init): Registered butlast intrinsic.
* lib.c (butlast): New function.
* lib.h (butlast): Declared.
* txr.1: Documented butlast.
|
|
|
|
|
|
|
| |
* lib.c (generic_funcall): If an object is used as a function,
get its lambda method and call that.
* txr.1: Document functors.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* struct.c (struct_init): Register uslot intrinsic function.
(uslot_fun): New static function.
(uslot): New function.
* struct.h (uslot): Declared.
* share/txr/stdlib/struct.tl (usl): New macro.
* lisplib.c (struct_set_entries): Add usl macro.
* txr.1: Documented uslot and usl.
|
|
|
|
|
|
|
|
|
|
| |
* RELNOTES: Updated.
* configure, txr.1: Bumped version and date.
* share/txr/stdlib/ver.tl: Likewise.
* txr.vim, tl.vim: Regenerated.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* debug.c (show_bindings): Use ~d for level, so as
not to be influenced by *print-base*.
(debug): Use ~d for line numbers.
* lib.c (gensym): Use ~d conversion specifier
for formatting gensym counter into symbol name.
* match.c (LOG_MISMATCH, LOG_MATCH): Use ~d for
line number references.
(h_skip, h_coll, h_fun, h_chr, match_line_completely, v_skip,
v_fuzz, v_gather, v_collect, v_output, v_filter, v_fun,
v_assert, v_load, v_line, h_assert, open_data_source): Use ~d
for line refs, number of iterations, errno values.
* parser.c (repl): Use ~d for prompt line numbers,
numbered variables and the expr-<n> string in error
messages.
* parser.l (yyerrorf, source_loc_str): Use ~d for line
numbers.
* stream.c (print_base_s): New symbol variable.
(formatv): Implement *print-base*.
(stdio_maybe_read_error, stdio_maybe_error, stdio_close,
pipe_close, open_directory, open_file, open_fileno, open_tail,
open_process, run, remove_path): Use ~d for errno values.
(stream_init): Initialize print_base_s and register
*print-base* special variable.
sysif.c (mkdir_wrap, ensure_dir, getcwd_wrap, mknod_wrap,
chmod_wrap, symlink_wrap, link_wrap, readlink_wrap,
excec_wrap, stat_impl, pipe_wrap, poll_wrap, getgroups_wrap,
setuid_wrap, seteuid_wrap, setgid_wrap): Use ~d for
errno values and system function results.
* txr.1: Documented *print-base* and ~d conversion specifier.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* configure (have_dbl_decimal_dig): New variable.
New configure test to test for DBL_DECIMAL_DIG
or __DBL_DECIMAL_DIG__, resulting in FLO_MAX_DIG
macro being deposited in config.h.
* arith.c (arith_init): Register flo-max-dig variable.
* stream.c (print_flo_precision_s): New symbol variable.
(formatv): Obtain default precision from *print-flo-precision*
special variable, rather than hard coded DBL_DIG.
(stream_init): Initialize print_flo_precision_s variable,
and register *print-flo-precision* special.
* txr.1: Document flo-max-dig, *print-flo-precision*,
and change of behavior in format.
|
|
|
|
| |
* txr.1: Missing @, added for comma.
|