diff --git a/pystencils/typing/leaf_typing.py b/pystencils/typing/leaf_typing.py
index c62824892930a2d90d630794543006107663955d..b4648835a662027b124a6c5b0192f67b76da5980 100644
--- a/pystencils/typing/leaf_typing.py
+++ b/pystencils/typing/leaf_typing.py
@@ -178,7 +178,13 @@ class TypeAdder:
             new_args = [a if t.dtype_eq(bool_type) else BooleanCastFunc(a, bool_type) for a, t in args_types]
             return expr.func(*new_args), bool_type
         elif type(expr, ) in pystencils.integer_functions.__dict__.values():
-            raise NotImplementedError('integer_functions')
+            args_types = [self.figure_out_type(a) for a in expr.args]
+            collated_type = collate_types([t for _, t in args_types])
+            # TODO: should we downcast to integer? If yes then which integer type?
+            if not collated_type.is_int():
+                raise ValueError(f"Integer functions need to be used with integer types but {collated_type} was given")
+
+            return expr, collated_type
         elif isinstance(expr, flag_cond):
             #   do not process the arguments to the bit shift - they must remain integers
             args_types = [self.figure_out_type(a) for a in (expr.args[i] for i in range(2, len(expr.args)))]