]> git.eshelyaron.com Git - emacs.git/commitdiff
add emit_INTEGERP
authorAndrea Corallo <andrea_corallo@yahoo.it>
Sat, 15 Jun 2019 16:38:20 +0000 (18:38 +0200)
committerAndrea Corallo <akrl@sdf.org>
Wed, 1 Jan 2020 10:33:42 +0000 (11:33 +0100)
src/comp.c

index a18ed07391be2aeab6e6782096a6f33b47075cb2..1b1401caff9d032834af3d94dfb14d6241e93d72 100644 (file)
@@ -572,6 +572,7 @@ declare_PSEUDOVECTORP (void)
 static gcc_jit_rvalue *
 emit_BIGNUMP (gcc_jit_rvalue *obj)
 {
+  /* PSEUDOVECTORP (x, PVEC_BIGNUM); */
   gcc_jit_rvalue *args[2] = {
     obj,
     gcc_jit_context_new_rvalue_from_int (comp.ctxt,
@@ -643,6 +644,17 @@ emit_XFIXNUM (gcc_jit_rvalue *obj)
                                        comp.inttypebits);
 }
 
+static gcc_jit_rvalue *
+emit_INTEGERP (gcc_jit_rvalue *obj)
+{
+  return gcc_jit_context_new_binary_op (comp.ctxt,
+                                       NULL,
+                                       GCC_JIT_BINARY_OP_LOGICAL_OR,
+                                       comp.bool_type,
+                                       emit_FIXNUMP (obj),
+                                       emit_BIGNUMP (obj));
+}
+
 static gcc_jit_rvalue *
 emit_make_fixnum (gcc_jit_block *block, gcc_jit_rvalue *obj)
 {