SIGSEGV: Illegal storage access
Hello!
I'm using godot 3.0.6-stable and using godot-nim-stub as a base project. I wrote very simple script using MeshDataTool:
```
import godot
import engine, mesh_instance, mesh_data_tool, array_mesh
import strutils

gdobj NoisedMesh of MeshInstance:

  method ready*() =
    print("Noised mesh is ready")

  proc makeSomeNoise*(iterations: int) {.gdExport.} =
    var tool = MeshDataTool.new()
    if tool == nil:
      print("Tool is nil")
      return
    var mesh = self.mesh as ArrayMesh
    if mesh == nil:
      print("Mesh is nil")
      return
    print("Blend shapes:", mesh.getBlendShapeCount())
    print("Surface count:", mesh.getSurfaceCount())
    var err = tool.createFromSurface(mesh, 0)
    print("Error:", err)
    for i in 1..iterations:
        print("Iteration ", i)
    var new_mesh = ArrayMesh.new()
    err = tool.commitToSurface(new_mesh)
    print("Error: ", err)
    self.mesh = new_mesh
```

When I call function make_some_noise(100)  from gdscript the application is failed with this log:
```
OpenGL ES 3.0 Renderer: NVIDIA GeForce GT 1030 OpenGL Engine
Noised mesh is ready
Blend shapes:0
Surface count:1
Traceback (most recent call last)
godotmacros.nim(569)     methFunc
noisedmesh.nim(26)       makeSomeNoise
mesh_data_tool.nim(76)   createFromSurface
godotinternal.nim(19)    ptrCall
SIGSEGV: Illegal storage access. (Attempt to read from nil?)
```

I rebuilded nim godotapi for version 3.0.6 but it doesn't help. It seems to be the same as godotapi in current godot-nim-stub.
What can I do to fix that problem?