Skip to content

Conversation

Vipul-Cariappa
Copy link
Contributor

Example:

lp
>>> x: u32 = u32(1)
>>> x
1
>>> x << u32(31)
2147483648
>>> x = u32(0)
>>> i: i32
>>> for i in range(1, 32):
...   x += u32(1) << u32(i)
... 
>>> x
4294967294

@Vipul-Cariappa Vipul-Cariappa marked this pull request as ready for review May 28, 2024 12:37
@Vipul-Cariappa
Copy link
Contributor Author

cc @Shaikh-Ubaid

Copy link
Collaborator

@ubaidsk ubaidsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks for this! Great work!

@ubaidsk ubaidsk merged commit 56d5723 into lcompilers:main May 28, 2024
@Vipul-Cariappa Vipul-Cariappa deleted the unsigned branch June 1, 2024 03:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants