Skip to content
This repository has been archived by the owner on Sep 15, 2022. It is now read-only.

[ASC] Optional parameters should be undefined over null #15

Open
AuHau opened this issue Jul 16, 2022 · 0 comments
Open

[ASC] Optional parameters should be undefined over null #15

AuHau opened this issue Jul 16, 2022 · 0 comments

Comments

@AuHau
Copy link

AuHau commented Jul 16, 2022

Currently, if generate for example this WIDL:

interface{
  storeChunk(data: bytes, stamp: string?): string
}

The generated code for the call has stamp: string | null, which makes it a practically required parameter in AssemblyScript. It would make sense with AssemblyScript/TypeScript semantic instead of null use undefined so the parameter could be truly optional.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant