stamourv / picobit

A Compact Scheme System for Microcontrollers
GNU General Public License v3.0
180 stars 35 forks source link

Compiler won't run under current Racket release #9

Open 0xacf opened 4 years ago

0xacf commented 4 years ago

It appears that some unstable libraries have been removed. Changing to the racket standard library versions is not difficult.

diff --git a/compiler/ast.rkt b/compiler/ast.rkt
index 577d28f..88060d2 100644
--- a/compiler/ast.rkt
+++ b/compiler/ast.rkt
@@ -1,7 +1,7 @@
 #lang racket

 (provide (all-defined-out))
-(require syntax/parse unstable/match racket/syntax)
+(require syntax/parse racket/match racket/syntax)
 (require "utilities.rkt" "env.rkt")

 ;; Syntax-tree node representation.
diff --git a/compiler/primitives.rkt b/compiler/primitives.rkt
index 57b0915..33ef228 100644
--- a/compiler/primitives.rkt
+++ b/compiler/primitives.rkt
@@ -1,11 +1,14 @@
 #lang racket

-(require racket/mpair unstable/sequence racket/syntax)
+(require racket/mpair racket/sequence racket/syntax)
 (require srfi/4)
 (require "env.rkt" "ast.rkt") ; to build the eta-expansions

 ;;-----------------------------------------------------------------------------

+(define (in-pairs seq)
+(in-parallel (sequence-map car seq) (sequence-map cdr seq)))
+
 (provide primitive-encodings)
 (define primitive-encodings '())

Thanks, Alan

kristianlm commented 3 years ago

I was able to fix my build problems using this patch, thank you for fixing this Alan.

I know it's 6 years since this tree has been touched, but is there any way this patch could be applied upstream so others won't have to browse to fix build errors? Thank you.