18
18
/* Test MACRO with
19
19
20
20
(defmacro foo (aa bb) `(defmacro ,aa () `(princ ,,bb)))
21
- (foo ' bar "baz")
21
+ (foo bar "baz")
22
22
23
23
*/
24
24
@@ -3047,7 +3047,7 @@ object *fn_intern (object *args, object *env) {
3047
3047
checkargs (INTERN, args);
3048
3048
if (!stringp (car (args))) error (INTERN, notastring, car (args));
3049
3049
char b[BUFFERSIZE];
3050
- char *cs = cstring (car (args), b, BUFFERSIZE);
3050
+ char *cs = cstring (INTERN, car (args), b, BUFFERSIZE);
3051
3051
return internlong (cs);
3052
3052
}
3053
3053
@@ -5819,11 +5819,11 @@ const char doc_defmacro[] PROGMEM = "(defmacro (params*) body*)\n"
5819
5819
" defines a macro" ;
5820
5820
const char doc_quasiquote[] PROGMEM = " (quasiquote *args)\n "
5821
5821
" Lisp quasiquotes" ;
5822
- const char doc_unqoute [] PROGMEM = " (unqoute arg)\n "
5822
+ const char doc_unquote [] PROGMEM = " (unqouote arg)\n "
5823
5823
" Lisp unquotes. Cannot be used outside of (quasiquote)." ;
5824
5824
const char doc_unquotesplicing[] PROGMEM = " (unquote-splicing *args)\n "
5825
5825
" Lisp unquotes. Cannot be used outside of (quasiquote)." ;
5826
- const char doc_unquotesplicing [] PROGMEM = " (expand macro params body)\n "
5826
+ const char doc_expand [] PROGMEM = " (expand macro params body)\n "
5827
5827
" Expand a macro." ;
5828
5828
5829
5829
const char doc40[] PROGMEM = " (progn form*)\n "
@@ -6252,9 +6252,9 @@ const char doc220[] PROGMEM = "(invert-display boolean)\n"
6252
6252
6253
6253
const char doc_batteryvoltage[] PROGMEM = " (battery:voltage)\n "
6254
6254
" Returns the current voltage of the LiPo battery powering the board." ;
6255
- const char doc_baterypercentage [] PROGMEM = " (battery:percentage)\n "
6255
+ const char doc_batterypercentage [] PROGMEM = " (battery:percentage)\n "
6256
6256
" Returns the current percentage charge of the LiPo battery powering the board, from 0-100%." ;
6257
- const char doc_baterypercentage [] PROGMEM = " (battery:change-rate)\n "
6257
+ const char doc_batterychangerate [] PROGMEM = " (battery:change-rate)\n "
6258
6258
" Returns the change rate of the LiPo battery powering the board, that is, how fast it is charging or discharging." ;
6259
6259
6260
6260
// Insert your own function documentation here
@@ -6304,6 +6304,12 @@ const tbl_entry_t lookup_table[] PROGMEM = {
6304
6304
{ string_unwindprotect, sp_unwindprotect, 0x1F , doc_unwindprotect },
6305
6305
{ string_ignoreerrors, sp_ignoreerrors, 0x11 , doc_ignoreerrors },
6306
6306
// { string_error, sp_error, 0x2F, doc_error },
6307
+ { string_MACRO_SENTINEL, NULL , 0x00 , NULL },
6308
+ { string_defmacro, sp_defmacro, 0x2F , doc_defmacro },
6309
+ { string_quasiquote, sp_quasiquote, 0x11 , doc_quasiquote },
6310
+ { string_unquote, sp_unquote, 0x11 , doc_unquote },
6311
+ { string_unquotesplicing, sp_unquote_splicing, 0x11 , doc_unquotesplicing },
6312
+ { string_expand, sp_expand, 0x23 , doc_expand },
6307
6313
6308
6314
{ string39, NULL , 0x00 , NULL },
6309
6315
{ string40, tf_progn, 0x0F , doc40 },
@@ -6503,7 +6509,7 @@ const tbl_entry_t lookup_table[] PROGMEM = {
6503
6509
{ string229, NULL , 0x00 , NULL },
6504
6510
6505
6511
// Insert your own table entries here
6506
- { string_batteryvoltage, fn_batteryvoltage, 0x00 , doc_batteryvolatage },
6512
+ { string_batteryvoltage, fn_batteryvoltage, 0x00 , doc_batteryvoltage },
6507
6513
{ string_batterypercentage, fn_batterypercentage, 0x00 , doc_batterypercentage },
6508
6514
{ string_batterychangerate, fn_batterychangerate, 0x00 , doc_batterychangerate },
6509
6515
@@ -6569,7 +6575,6 @@ void testescape () {
6569
6575
eval - the main Lisp evaluator
6570
6576
*/
6571
6577
object *eval (object *form, object *env) {
6572
- static unsigned long start = 0 ;
6573
6578
int TC=0 ;
6574
6579
EVAL:
6575
6580
yield (); // Needed on ESP8266 to avoid Soft WDT Reset or ESP32 for multithreading
@@ -7376,7 +7381,7 @@ void repl (object *env) {
7376
7381
loop - the Arduino IDE main execution loop
7377
7382
*/
7378
7383
void loop () {
7379
- if (! setjmp ( exception )) {
7384
+ if (ulisp_setup_error_handling ( )) {
7380
7385
; // noop
7381
7386
}
7382
7387
// Come here after error
@@ -7386,4 +7391,4 @@ void loop () {
7386
7391
SDpfile.close (); SDgfile.close ();
7387
7392
client.stop ();
7388
7393
repl (NULL );
7389
- }
7394
+ }
0 commit comments