Skip to content
This repository has been archived by the owner on Feb 3, 2020. It is now read-only.

Explicit Type Declarations #18

Closed
2 tasks done
sunjay opened this issue Jan 28, 2017 · 1 comment
Closed
2 tasks done

Explicit Type Declarations #18

sunjay opened this issue Jan 28, 2017 · 1 comment

Comments

@sunjay
Copy link
Owner

sunjay commented Jan 28, 2017

Types! 馃榾

Initially types were left out because there was only one type: raw byte arrays.

Before 1.0.0, in order to avoid immediately jumping to 2.0.0, we should support the following syntax:

let a: byte[] = "Hello, world";
let b: byte[3] = "abc";

// these two are the same
let c: byte = "c";
let d: byte[1] = "d";

// this syntax needs work
in q: byte[1];
// might just want to support:
//let q: byte[1] = read();
// where read is a special function?
// if we do this, we should also change out:
//out("a =", a, "\n");

Eventually, we'll support more types like int and maybe even user defined types! This syntax will help us do that in the future.

  • Implement this in the parser
  • Update all examples to use the new syntax
@sunjay
Copy link
Owner Author

sunjay commented Feb 17, 2017

See #24

@sunjay sunjay closed this as completed Feb 17, 2017
@sunjay sunjay moved this from Backlog to Done in MVP - 1.0.0 Feb 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Development

No branches or pull requests

1 participant