Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: user-defined number type #2

Open
data-man opened this issue May 31, 2020 · 3 comments
Open

Feature request: user-defined number type #2

data-man opened this issue May 31, 2020 · 3 comments
Labels
enhancement New feature or request

Comments

@data-man
Copy link
Contributor

data-man commented May 31, 2020

E.g.:

pub fn Vm(comptime intType: type, comptime floatType: type) {
 ...
}

var vm = bog.Vm(u128, f128).init(allocator, .{ .import_files = true });

or

pub fn Vm(comptime intBits: u8, comptime floatBits: u8) {
 ...
}
@Vexu
Copy link
Owner

Vexu commented Jun 1, 2020

I don't think this is useful enough to justify making Vm generic, but it could be provided as a build option.

@data-man
Copy link
Contributor Author

data-man commented Jun 1, 2020

it could be provided as a build option.

👍

Are you interested in extending the standard library?
E.g. std.* or std.math.*.

Or should I open a separate issue for that?

@Vexu
Copy link
Owner

Vexu commented Jun 2, 2020

Are you interested in extending the standard library?

Sure, I haven't got around to do much with the std since other parts like the gc are still quite broken.

should I open a separate issue for that?

Not necessary, but feel free to do so.

@Vexu Vexu added the enhancement New feature or request label Jun 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants