Age | Commit message (Collapse) | Author | Files | Lines |
|
Reported by Dmitry Bogatov <KAction@gnu.org>.
* doc/ref/api-compound.texi (Vector Syntax, Vector Creation): Mention
that vectors are self-quoting. Remove examples with quote signs.
|
|
* module/language/lua/compile-tree-il.scm (while-loop->tree-il):
Generate `letrec' instead of `let'.
Generate valid `lambda' expression.
|
|
* module/language/lua/compile-tree-il.scm (make-sequence): New procedure.
|
|
* module/language/lua/compile-tree-il.scm: Rename.
|
|
* module/language/lua/compile-tree-il.scm (compile): Add clause for
ast-variable-arguments.
* module/language/lua/parser.scm (define-ast, make-parser): Add
vararg-gensym field to functions, gensym field to variable-arguments.
Propagate *vararg-gensym* from functions to variable-arguments.
* test-suite/tests/lua-eval-2.test ("lua-eval"): Check for #nil
|
|
* test-suite/tests/lua-lexer.test ("lua-lexer"): #:vararg -> #:varargs
|
|
values resulting from a function call as the last argument.
doc/ref/api-languages.texi: Add a small blurb about Lua.
module/language/lua/compile-tree-il.scm: Function calls now properly
handle multiple values resulting from a function call as the last
argument.
|
|
|
|
* module/language/lua/compile-tree-il.scm: Fix and/or double evaluation.
* module/language/lua/notes.org: Add file describing known issues.
* module/language/lua/parser.scm: (token-type): Recognize and/or.
* module/language/lua/standard/math.scm: Add modf, fmod implementations.
* test-suite/tests/lua-eval-3.test: Add another test file for basic
language features.
|
|
* module/language/lua/compile-tree-il.scm (compile): Get more lua code
returning via the normal path.
|
|
* module/language/lua/runtime.scm: Various indentation and idiom
tweaks.
|
|
* module/language/lua/lexer.scm: Some tweaks and reindentations. Remove
the define/init lexer interface; I don't like separating declaration
and initialization.
* module/language/lua/parser.scm:
* test-suite/tests/lua-lexer.test: Adapt to lexer interface change.
|
|
* module/language/lua/compile-tree-il.scm: Reflow a bit, and a number of
small rewrites. Added some FIXMEs.
|
|
* module/language/lua/runtime.scm (true?, false?): Remove, now that #nil
is false.
* module/language/lua/compile-tree-il.scm: Don't emit calls to true? or
false?.
|
|
* module/language/lua/parser.scm (define-record, define-ast): Simplify
these macros.
(make-parser): A number of small idiomatic changes.
|
|
* module/language/lua/common.scm: Remove `or-eqv?'. Make a bit more
idiomatic.
* module/language/lua/compile-tree-il.scm:
* module/language/lua/lexer.scm:
* module/language/lua/parser.scm:
* module/language/lua/runtime.scm: Replace or-eqv? instances with memq
or memv.
|
|
* module/language/lua/common.scm (syntax-error): Throw to
'syntax-error.
|
|
What is missing:
+ Functions: module, getfenv, setfenv, math.modf, table.sort
+ Parser: needs to be more flexible
+ Compiler: needs more extensive work to properly handle all possible
cases of variable arguments, multiple returns, and loops
+ Language: Variable arguments and unpacking of multiple returns. (For
example we need to be able to handle something as complex as
print(unpack({...})), which is easy with Lua's explicit stack but will
require lots of tree-il gymnastics, or perhaps modifications to better
allow different calling conventions. (For instance -- how would we
support Python or Ruby, where keyword arguments are gathered into a
hashtable and passed as a single argument?)
What is there:
A fair shot at supporting Lua 5.1, not quite a drop-in replacement, but
not far from that goal either.
|
|
* libguile/numbers.c (char_decimal_value): A wee micro-optimization.
|
|
* libguile/strings.c (scm_from_port_stringn): Always inline to
scm_from_utf8_string if the byte sequence is valid utf-8.
|
|
* libguile/ports.c (scm_ungetc_unlocked): Inline the conversion from
codepoint to bytes for UTF-8 and latin-1 ports. Speeds up a
numbers-reading test case by 100% (!).
|
|
* module/Makefile.am:
* module/language/cps/contification.scm: New pass.
* module/language/cps/compile-rtl.scm (optimize): Wire it into the
compiler.
|
|
* module/Makefile.am:
* module/language/cps/compile-rtl.scm:
* module/language/cps/dfg.scm:
* module/language/cps/slot-allocation.scm: New modules.
* module/language/cps/spec.scm: Register the compiler.
* test-suite/Makefile.am:
* test-suite/tests/rtl-compilation.test: Add tests.
|
|
* module/Makefile.am:
* module/language/cps/reify-primitives.scm: New pass.
|
|
* module/Makefile.am:
* module/language/cps/arities.scm: New module. Adapts call and return
arities, especially for primcalls.
|
|
* module/Makefile.am:
* module/language/cps/primitives.scm: New file.
|
|
* module/Makefile.am
* module/language/rtl.scm:
* module/language/rtl/spec.scm: Add a stub RTL language.
|
|
* module/Makefile.am
* module/language/cps/closure-conversion.scm: New module, implementing a
closure conversion pass.
|
|
* module/language/tree-il/compile-cps.scm: New module implementing CPS
conversion of Tree-IL.
* module/Makefile.am:
* module/language/tree-il/spec.scm:
* module/language/cps/spec.scm: Integrate CPS in the build and language
system.
|
|
* module/Makefile.am:
* module/language/cps.scm:
* module/language/cps/verify.scm: Add CPS language.
* .dir-locals.el: Add indentation rules for some CPS forms.
|
|
* module/scripts/disassemble.scm (disassemble):
* module/system/vm/disassembler.scm (disassemble-file): Factor
disassemble-file out.
* module/system/repl/command.scm (disassemble-file): Map ,xx to
disassemble RTL images.
|
|
* module/scripts/disassemble.scm (disassemble): Update to work with
RTl (and only RTL, as that's the future).
* module/system/vm/debug.scm (for-each-elf-symbol): New public
interface.
(debug-context-from-image): New helper.
(find-debug-context): Use the helper.
* module/system/vm/disassembler.scm (disassemble-image): New public
interface.
|
|
* module/system/vm/assembler.scm (define-assembler):
(define-macro-assembler): Export the assemblers.
|
|
* libguile/vm-engine.c (box-set!): Remove the OP_DST flag.
|
|
* module/system/vm/disassembler.scm: Modify call disassembler to assume
RA == MVRA.
|
|
* module/system/vm/assembler.scm (link-data): Give stringbufs the
"shared" flag already, so we don't attempt to set it at runtime. Give
.data sections the SHF_WRITE flag.
|
|
* module/system/base/compile.scm (compile-file): Pass #:to-disk? as an
option to indicate that the result will be being loaded from disk.
Perhaps a linker might want to page-align in that case.
* module/language/elisp/compile-tree-il.scm (process-options!): Accept
and ignore the #:to-file compiler option.
|
|
* libguile/vm-engine.c (return-values): Remove NVALUES operand.
Don't reset the frame.
* test-suite/tests/rtl.test ("cached-toplevel-set!"): Adapt to the fact
that 'return-values' has no operand now, and that 'reset-frame' must
be done first.
|
|
* libguile/vm-engine.c (apply, tail-apply): apply -> tail-apply.
(RETURN_VALUE_LIST): goto op_apply -> goto op_tail_apply.
* libguile/vm.c (rtl_apply_code): scm_rtl_op_apply ->
scm_rtl_op_tail_apply.
|
|
* libguile/vm-engine.c (halt): Fix off-by-one error in retrieving
multiple values from the frame.
|
|
* module/language/tree-il/primitives.scm (maybe-simplify-to-eq): Wrap
within another lambda, binding the primitive name. If there are less
than two arguments, expand to constant #t. If there are more than two
arguments, convert into a conjunction of binary applications.
(expand-chained-comparisons): New procedure.
(*primitive-expand-table*): Add entries for (< <= = >= > eq?).
|
|
|
|
* module/ice-9/curried-definitions.scm (cdefine, cdefine*): Simplify,
and improve error reporting by making the patterns more strict.
(define-public): Fix bug in generated 'export' form.
|
|
* module/ice-9/boot-9.scm (module-add!): Check that the symbol argument
is actually a symbol.
(define-public): Expand into 'define' in such a way that curried
definitions will immediately fail.
|
|
* doc/ref/api-io.texi (R6RS Textual Input): Remove `count' argument.
|
|
* module/web/http.scm (write-request-line): Always write "/" when path
is empty, regardless of query.
* test-suite/tests/web-http.test ("write-request-line"): Add test.
|
|
Fixes <http://bugs.gnu.org/15100>.
Reported by Göran Weinholt <goran@weinholt.se>.
* libguile/bytevectors.c (INTEGERS_TO_LIST): Enforce the R6RS
requirement that SIZE divides the bytevector length.
* test-suite/tests/bytevectors.test: Add test. Remove tests that
assumes that this "divides" check is not enforced.
|
|
|
|
Partially fixes <http://bugs.gnu.org/15100>.
Reported by Göran Weinholt <goran@weinholt.se>.
* libguile/bytevectors.c (INTEGERS_TO_LIST): Make sure SIZE isn't 0.
Allow SIZE to be greater than the bytevector length, for consistency
with allowing extra bytes at the end when the bytevector length is
non-zero. Use scm_from_size_t instead of scm_from_uint.
* test-suite/tests/bytevectors.test: Add tests. Remove a test that
checks for an exception when SIZE is greater than the bytevector
length.
|
|
|