diff --git a/ast/arrays.py b/ast/arrays.py
index e7fd2c707debeda3be8928b038dd0c403120627a..308bd12bf7bfedbec1f42d6a3ef7ae1cdb96ee00 100644
--- a/ast/arrays.py
+++ b/ast/arrays.py
@@ -115,7 +115,6 @@ class ArrayAccess(ASTTerm):
         self.array = array
         self.indexes = [as_lit_ast(sim, index)]
         self.index = None
-        self.mutable = True
         self.generated = False
         self.check_and_set_index()
 
@@ -161,9 +160,6 @@ class ArrayAccess(ASTTerm):
         return self.array.type()
         # return self.array.type() if self.index is None else Type_Array
 
-    def is_mutable(self):
-        return self.mutable
-
     def scope(self):
         if self.index is None:
             scope = None
diff --git a/ast/ast_node.py b/ast/ast_node.py
index b0641f45c16a64efe7eb70ef1279b67f19691da3..7e426762ba235fba865137a30c45c939eeb88638 100644
--- a/ast/ast_node.py
+++ b/ast/ast_node.py
@@ -11,9 +11,6 @@ class ASTNode:
     def type(self):
         return Type_Invalid
 
-    def is_mutable(self):
-        return False
-
     def scope(self):
         return self.sim.global_scope
 
diff --git a/ast/bin_op.py b/ast/bin_op.py
index 4cc8dd56a03177e322d882ccc037445ebc43bf5f..840ca43fa81fd8bcf28acc90f7d43fc1dfd01c7d 100644
--- a/ast/bin_op.py
+++ b/ast/bin_op.py
@@ -46,7 +46,6 @@ class BinOp(ASTNode):
         self.rhs = as_lit_ast(sim, rhs)
         self.op = op
         self.mem = mem
-        self.mutable = self.lhs.is_mutable() or self.rhs.is_mutable() # Value can change accross references
         self.inlined = False
         self.generated = False
         self.bin_op_type = BinOp.infer_type(self.lhs, self.rhs, self.op)
@@ -167,9 +166,6 @@ class BinOp(ASTNode):
     def kind(self):
         return BinOp.Kind_Vector if self.type() == Type_Vector else BinOp.Kind_Scalar
 
-    def is_mutable(self):
-        return self.mutable
-
     def scope(self):
         if self.bin_op_scope is None:
             lhs_scp = self.lhs.scope()
diff --git a/ast/block.py b/ast/block.py
index 45fbf74a8e11a4cc44c190e8d4f5be3c568f356a..b7f287e1b055dc1d49160858c49e631c550856ce 100644
--- a/ast/block.py
+++ b/ast/block.py
@@ -71,17 +71,3 @@ class Block(ASTNode):
             result_block = Block.merge_blocks(result_block, block)
 
         return result_block
-
-    def set_block_levels(ast):
-        Block.level = 0
-
-        def enter(ast):
-            if isinstance(ast, Block):
-                ast.set_level(Block.level)
-                Block.level += 1
-
-        def leave(ast):
-            if isinstance(ast, Block):
-                Block.level -= 1
-
-        Visitor(ast, enter, leave).visit()
diff --git a/ast/cast.py b/ast/cast.py
index 5bf1ba93212eaa50c8ca0450c426dd2fed6c9f61..0a30700b05311ed3bdc6e3d116bb0c89a9764391 100644
--- a/ast/cast.py
+++ b/ast/cast.py
@@ -20,9 +20,6 @@ class Cast(ASTNode):
     def type(self):
         return self.cast_type
 
-    def is_mutable(self):
-        return self.expr.is_mutable()
-
     def scope(self):
         return self.expr.scope()
 
diff --git a/ast/math.py b/ast/math.py
index c872b5b1810183db3e6156a207d6538bdbb4aecc..90977b8af5d53e8716245ad867b8787bab8dec66 100644
--- a/ast/math.py
+++ b/ast/math.py
@@ -13,9 +13,6 @@ class Sqrt(ASTNode):
     def type(self):
         return self.expr.type()
 
-    def is_mutable(self):
-        return self.expr.is_mutable()
-
     def scope(self):
         return self.expr.scope()
 
diff --git a/ast/properties.py b/ast/properties.py
index 44f141cca71eb234fe0c40ffb189faa45925d9e0..fee01512563cf3f16f738b4bd41348d4b16dfb6d 100644
--- a/ast/properties.py
+++ b/ast/properties.py
@@ -47,7 +47,6 @@ class Property(ASTNode):
         self.prop_layout = layout
         self.default_value = default
         self.volatile = volatile
-        self.mutable = True
 
     def __str__(self):
         return f"Property<{self.prop_name}>"
@@ -64,9 +63,6 @@ class Property(ASTNode):
     def default(self):
         return self.default_value
 
-    def is_mutable(self):
-        return self.mutable
-
     def scope(self):
         return self.sim.global_scope
 
diff --git a/ast/variables.py b/ast/variables.py
index 34f9a9d9e818619f2c157a0d65d82ce9a3a73ec8..aed082141039cff05272564a9fd6112b3dad396c 100644
--- a/ast/variables.py
+++ b/ast/variables.py
@@ -60,9 +60,6 @@ class Var(ASTTerm):
     def bonded_arrays(self):
         return self.var_bonded_arrays
 
-    def is_mutable(self):
-        return self.mutable
-
 
 class VarDecl(ASTNode):
     def __init__(self, sim, var):
diff --git a/sim/particle_simulation.py b/sim/particle_simulation.py
index 52c9e0fabe8658b1ba6669b3a60695757f2ce5a4..12104a3acdecbe431db74f844f56e7be7e9c1dd6 100644
--- a/sim/particle_simulation.py
+++ b/sim/particle_simulation.py
@@ -193,7 +193,6 @@ class ParticleSimulation:
 
         program = Block.merge_blocks(decls, body)
         self.global_scope = program
-        Block.set_block_levels(program)
         Transform.apply(program, Transform.flatten)
         Transform.apply(program, Transform.simplify)
         #Transform.apply(program, Transform.reuse_index_expressions)