jmeaster30 / ocean

A C-like programming language (get it like sea-like like an ocean lol)
GNU General Public License v3.0
0 stars 0 forks source link

Generic types in hydro #96

Closed jmeaster30 closed 6 months ago

jmeaster30 commented 8 months ago

I want to write some generic array algorithms. I tried using the 'any' type but it fails when allocating because the any type has no specific value.

I don't know if I want full generics in hydro. I want to research what java does a little more or I just try to make an array that has an any type to fully resolve it's type when data gets put into it the first time

jmeaster30 commented 6 months ago

My plan for generics in Ocean was to generate a new function for each version of the generic that is needed so hydro wouldn't actually need generics