goalc: support static arrays of types (#2140)

draft because using the array is a little weird still, don't feel like
dealing with window's slow debugging builds today.

I get the following weird error:
```clj
(define test-array (new 'static 'boxed-array :type type vector))
gr> (-> test-array 0)
1538004        #x1777d4              0.0000        vector
gr> (type? (-> test-array 0) type)
1342757        #x147d25              0.0000        #t
gr> (new 'static (-> test-array 0))
-- Compilation Error! --
Got 3 arguments, but expected 2
Form:
(-> test-array 0)
Location:
Program string:1
(new 'static (-> test-array 0))
^
Code:
(new 'static (-> test-array 0))
```

Maybe this is expected though and the `new` method wants a symbol, not a
type?

Fixes #2060

Co-authored-by: water <awaterford111445@gmail.com>
This commit is contained in:
Tyler Wilding
2023-01-21 21:40:39 -05:00
committed by GitHub
parent abf61a94fb
commit 98393c6f4c
6 changed files with 267 additions and 6 deletions
@@ -664,7 +664,7 @@ TEST_F(FormRegressionTestJak1, DmaSyncCrash) {
test_with_expr(func, type, expected);
}
TEST_F(FormRegressionTestJak1, DmaSendDraft) {
TEST_F(FormRegressionTestJak1, DmaSend) {
std::string func =
"sll r0, r0, 0\n"
" daddiu sp, sp, -64\n"