nomssi / abap_scheme Goto Github PK
View Code? Open in Web Editor NEWABAP Scheme
License: MIT License
ABAP Scheme
License: MIT License
from R6RS
(apply
proc
arg1 . . . rest-args)
Rest-args must be a list. Proc
should accept n arguments, where n is number of args plus the length of rest-args. The apply procedure calls proc
with the elements of the list
(append (list arg1 . . . ) rest-args )
as the actual arguments.
Implementation and unit test created. Tests fails.
in R7RS, a body is made of 0 or more declarations followed by expressions, so
define
s must be placed before any expressiondefine
for the same variable are not allowed.So the following programs should be wrong:
(define (foo)
(display 1) ; not allowed before define
(define bar 1)
bar)
(define (foo)
(define bar 1)
(define bar 2) ; redefinition not allowe
bar)
Top-level definitions do not have this restriction.
ports, input, output
Create classes implementing different input/output port:
Enable selection/switch between console implementations - to be extended to accept opt. parameter
(display obj)
(display obj port)
(write obj)
(write obj port)
(newline)
(newline port)
(input-port? obj)
(output-port? obj)
(textal-port? obj)
(binary-port? obj)
(port? obj)
(input-port-open? obj)
(output-port-open? obj)
(current-input-port)
(current-output-port)
(current-error-port)
(close-port port)
(close-input-port port)
(close-output-port port)
(open-input-string string)
(open-output-string)
(get-output-string port)
;; deferred to new issue
(parameterize
((current-output-port
(open-output-string)))
(display "piece")
(display " by piece ")
(display "by piece.")
(newline)
(get-output-string (current-output-port)))
=โ "piece by piece by piece.\n"
(read)
(read port)
(read-char)
(read-char port)
(peek-char)
(peek-char port)
(char-ready?)
(char-rea
Iterations are already possible with named let,
TO DO: do special form
(do (( <variable1> <init1> <step1>)
. . . )
(<testi> <expressioni> . . . )
<commandi> . . . )
The Code was verified under Netweaver 7.4 SP9
while debugging it would help to see the S-Expression tree.
The S-Expression viewer logic should be re-implemented as a debugger script
||
|HelloWorld| are valid identifier that are not recognized by the parser yet
(let ''name'' (''bindings'') ''body'')
e.g.
(let sum ((lst (list 1 2 3))
(s 0))
(if (null? lst)
s
(sum (cdr lst) (+ s (car lst)))))
TO DO:
The developer should be able to define a maximal execution time for any ABAP Scheme Evaluation. If the time needed is larger, a TIME_OUT should occurs within the Workbench without ABAP Short Dump
ABAP Unit can also Limit the execution time of an ABAP Unit test. This is the functionality to replicate
Class CL_AUNIT_CLASSTEST_SESSIONFE
Method __CANCEL_RFC
check Racket syntax
https://docs.racket-lang.org/sql/index.html
Hi,
Can you help adding a license to let users know how/if they can use the code?
See
https://help.github.com/articles/adding-a-license-to-a-repository/
https://choosealicense.com/
Tail Cail Optimization is not supported yet
Currently it possible to create a pair with cons
(cons a b) => ( a . b )
but
'( a . b )
will not work.
(parameterize
((current-output-port
(open-output-string)))
(display "piece")
(display " by piece ")
(display "by piece.")
(newline)
(get-output-string (current-output-port)))
=โ "piece by piece by piece.\n"
If abapGit fails with a Shared Memory issue,
start transaction SHMA, enter Area Name ZCL_LISP_AREA and press the "Generate area class" icon (Ctrl+F3). You can then repeat the installation.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.