ModularM
Modular3y ago
3 replies
ndbecker(@ndbecker)

trouble with mandelbrot example

Newb here. I've copied code from the mandelbrot example, placing it into the file mandel.mojo, which I've copied here:
https://gist.github.com/nbecker/820a6f740e4bad43bb09a52103d5b19b

When I run
mojo mandel.mojo
I get lots of errors:
mojo: /lib64/libtinfo.so.6: no version information available (required by mojo)
/home/nbecker/mojo/mandel.mojo:59:1: error: TODO: expressions are not yet supported at the file scope level
show_plot(compute_mandelbrot())
^
/home/nbecker/mojo/mandel.mojo:36:23: error: use of unknown declaration 'Tensor'
def show_plot(tensor: Tensor[float_type]):
                      ^~~~~~
/home/nbecker/mojo/mandel.mojo:11:26: error: use of unknown declaration 'ComplexFloat64'
def mandelbrot_kernel(c: ComplexFloat64) -> Int:
... more errors
mojo: error: failed to parse the provided Mojo

This is running on fedora 38 linux, using an ubuntu container.
Any ideas?
Gist
mandel test. GitHub Gist: instantly share code, notes, and snippets.
mandel test
Was this page helpful?