mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-18 21:29:18 +02:00
Explicit inlines
This commit is contained in:
parent
10569ddcfd
commit
75b9e7bf8a
13 changed files with 110 additions and 0 deletions
|
@ -207,6 +207,22 @@
|
|||
; letrec-syntax
|
||||
;;;;
|
||||
)
|
||||
(inline
|
||||
square
|
||||
quotient
|
||||
numerator
|
||||
denominator
|
||||
truncate
|
||||
negative?
|
||||
positive?
|
||||
zero?
|
||||
not
|
||||
string>=?
|
||||
string>?
|
||||
string<=?
|
||||
string<?
|
||||
string=?
|
||||
)
|
||||
(begin
|
||||
;; Features implemented by this Scheme
|
||||
(define (features)
|
||||
|
|
|
@ -15,6 +15,9 @@
|
|||
make-rectangular
|
||||
real-part
|
||||
)
|
||||
(inline
|
||||
real-part
|
||||
imag-part)
|
||||
(import (scheme base))
|
||||
(begin
|
||||
(define (real-part x) x)
|
||||
|
|
|
@ -28,6 +28,13 @@
|
|||
emit-newline
|
||||
string-join
|
||||
)
|
||||
(inline
|
||||
global-not-lambda?
|
||||
global-lambda?
|
||||
c:num-args
|
||||
c:allocs
|
||||
st:->var
|
||||
)
|
||||
(begin
|
||||
|
||||
(define (emit line)
|
||||
|
|
|
@ -61,6 +61,10 @@
|
|||
lib:idb:entry->library-name
|
||||
lib:idb:entry->library-id
|
||||
)
|
||||
(inline
|
||||
lib:idb:entry->library-name
|
||||
lib:import-set->import-set
|
||||
)
|
||||
(begin
|
||||
|
||||
(define (library? ast)
|
||||
|
|
|
@ -22,6 +22,8 @@
|
|||
macro:get-env
|
||||
macro:get-defined-macros
|
||||
)
|
||||
(inline
|
||||
macro:macro?)
|
||||
(begin
|
||||
;; top-level macro environment
|
||||
(define *macro:env* '())
|
||||
|
|
|
@ -106,6 +106,27 @@
|
|||
closure-convert
|
||||
prim-convert
|
||||
)
|
||||
(inline
|
||||
cell-get->cell
|
||||
cell->value
|
||||
set-cell!->value
|
||||
set-cell!->cell
|
||||
env-get->env
|
||||
env-get->field
|
||||
env-get->id
|
||||
env-make->id
|
||||
closure->fv
|
||||
closure->env
|
||||
closure->lam
|
||||
begin->exps
|
||||
app->args
|
||||
app->fun
|
||||
letrec->exp
|
||||
letrec->bindings
|
||||
let->exp
|
||||
let->bindings
|
||||
void
|
||||
)
|
||||
(begin
|
||||
|
||||
;; Container for built-in macros
|
||||
|
|
|
@ -83,6 +83,23 @@
|
|||
string-replace-all
|
||||
take
|
||||
filter)
|
||||
(inline
|
||||
env:frame-values
|
||||
env:frame-variables
|
||||
env:first-frame
|
||||
env:enclosing-environment
|
||||
lambda->exp
|
||||
lambda->formals
|
||||
define->exp
|
||||
set!->exp
|
||||
set!->var
|
||||
ref?
|
||||
app?
|
||||
if->else
|
||||
if->then
|
||||
if->condition
|
||||
tagged-list?
|
||||
)
|
||||
(begin
|
||||
|
||||
(define (tagged-list? tag exp)
|
||||
|
|
|
@ -25,6 +25,24 @@
|
|||
%import
|
||||
imported?
|
||||
)
|
||||
(inline
|
||||
primitive-implementation
|
||||
procedure-environment
|
||||
procedure-body
|
||||
procedure-parameters
|
||||
operands
|
||||
operator
|
||||
application?
|
||||
if-alternative
|
||||
if-consequent
|
||||
if-predicate
|
||||
lambda-body
|
||||
lambda-parameters
|
||||
definition-variable
|
||||
assignment-value
|
||||
assignment-variable
|
||||
variable?
|
||||
)
|
||||
(begin
|
||||
|
||||
;; From r7rs:
|
||||
|
|
|
@ -42,6 +42,15 @@
|
|||
lset-union lset-intersection lset-difference lset-xor lset-diff+intersection
|
||||
lset-union! lset-intersection! lset-difference! lset-xor! lset-diff+intersection!
|
||||
)
|
||||
(inline
|
||||
tenth
|
||||
ninth
|
||||
eighth
|
||||
seventh
|
||||
sixth
|
||||
fifth
|
||||
not-pair?
|
||||
)
|
||||
(include "1.scm")
|
||||
(begin)
|
||||
)
|
||||
|
|
|
@ -36,6 +36,8 @@
|
|||
*msg-peek* *msg-oob* *msg-waitall*
|
||||
*shut-rd* *shut-wr* *shut-rdwr*
|
||||
)
|
||||
(inline
|
||||
socket->fd)
|
||||
(begin
|
||||
(define *socket-object-type* '%socket-object-type%)
|
||||
(define (socket->fd obj) (cdr obj))
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
(import (scheme base))
|
||||
(import (scheme case-lambda))
|
||||
(import (scheme char) (scheme complex) (scheme inexact))
|
||||
(inline
|
||||
boolean<?)
|
||||
(export comparator? comparator-ordered? comparator-hashable?)
|
||||
(export make-comparator
|
||||
make-pair-comparator make-list-comparator make-vector-comparator
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
(define-library (srfi 133) ;vectors)
|
||||
(import (scheme base))
|
||||
(import (scheme cxr))
|
||||
(inline
|
||||
unspecified-value
|
||||
between?
|
||||
nonneg-int?
|
||||
)
|
||||
;; Constructors
|
||||
(export vector-unfold vector-unfold-right vector-reverse-copy
|
||||
vector-concatenate vector-append-subvectors)
|
||||
|
|
|
@ -49,6 +49,10 @@
|
|||
->heap
|
||||
Cyc-minor-gc
|
||||
)
|
||||
(inline
|
||||
thread-specific
|
||||
thread-name
|
||||
)
|
||||
(begin
|
||||
;; Threading
|
||||
(define (thread? obj)
|
||||
|
|
Loading…
Add table
Reference in a new issue