From 93066f1868a1451534663cf2f9d981f51b6d06b8 Mon Sep 17 00:00:00 2001 From: kusumotonorio <47816570+kusumotonorio@users.noreply.github.com> Date: Mon, 20 Jan 2020 20:47:16 +0900 Subject: [PATCH] boxing.factor: Swap first and second positions --- basis/compiler/cfg/builder/alien/boxing/boxing.factor | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/basis/compiler/cfg/builder/alien/boxing/boxing.factor b/basis/compiler/cfg/builder/alien/boxing/boxing.factor index 05406653a1..dd50feb4a7 100644 --- a/basis/compiler/cfg/builder/alien/boxing/boxing.factor +++ b/basis/compiler/cfg/builder/alien/boxing/boxing.factor @@ -14,14 +14,14 @@ SYMBOLS: int-reg-reps float-reg-reps ; : record-reg-reps ( reps -- reps ) dup ! reps: { { reg-rep on-stack? odd-register? } ... } - [ [ [ second not ] [ first int-rep? ] bi and ] count int-reg-reps +@ ] - [ [ [ second not ] [ first int-rep? not ] bi and ] count float-reg-reps +@ ] + [ [ [ first int-rep? ] [ second not ] bi and ] count int-reg-reps +@ ] + [ [ [ first int-rep? not ] [ second not ] bi and ] count float-reg-reps +@ ] bi ; : unrecord-reg-reps ( reps -- reps ) dup - [ [ [ second not ] [ first int-rep? ] bi and ] count -1 * int-reg-reps +@ ] - [ [ [ second not ] [ first int-rep? not ] bi and ] count -1 * float-reg-reps +@ ] + [ [ [ first int-rep? ] [ second not ] bi and ] count -1 * int-reg-reps +@ ] + [ [ [ first int-rep? not ] [ second not ] bi and ] count -1 * float-reg-reps +@ ] bi ; GENERIC: flatten-c-type ( c-type -- pairs )