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

Support octal and binary literals #38

Open
NeeEoo opened this issue Mar 8, 2021 · 5 comments
Open

Support octal and binary literals #38

NeeEoo opened this issue Mar 8, 2021 · 5 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@NeeEoo
Copy link
Contributor

NeeEoo commented Mar 8, 2021

Octal literals are defined as 0[0-7]+
Binary literals are defined as 0b[01]+

@elikaski elikaski added enhancement New feature or request good first issue Good for newcomers labels Mar 9, 2021
@elikaski
Copy link
Owner

elikaski commented Mar 9, 2021

Good idea!
Need to add it to lexical analyzer and get_NUM_token_value function

@elikaski
Copy link
Owner

Let's make octal like Python: 0o[0-7]+

@abhra2020-smart
Copy link
Contributor

lol no need to do anything it already does support octals and stuff

@NeeEoo
Copy link
Contributor Author

NeeEoo commented Apr 6, 2021

This is talking about integers.

int octal = 0b635;
int binary = 0b1101010;

@abhra2020-smart
Copy link
Contributor

abhra2020-smart commented Apr 6, 2021

Oh, sorry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants