« first day (1104 days earlier)      last day (669 days later) » 

00:00
I have autocorrect disabled on my phone, yes
Also, I was typing with only my non-dominant hand, and my fingers were cold, dry, and shaking
00:15
Right hand side must be int
I need bigint on the right hand side
00:37
@lyxal Does BigInt(1) << bitsToAdd.toInt work?
That might lose precision
How's that?
bitsToAdd is bigint
Well ints go up pretty high
2^31 is nothing to sneeze at
Are we likely to have numbers bigger than 2^(2^32)?
You never know
00:42
@lyxal Sorry about that before, I meant an extension method called ** on Int or BigDecimal ought to help
Isn't this just for encoding/decoding though?
It's for raising 2 to the power of numbers
But this is only for the range coder thing, right?
Yes
It requires arbitrary size numbers
idk how it works but is it actually possible for it to go up to 2^(2^32)?
Wouldn't that require having those many characters?
Or am I just not understanding how it works?
Wait let me look at it before I say more
2 days ago, by AndrovT
The encode and decode functions require BigInts to work so it's not straight forward to port it to JS
s/js/scala
Some internal values go up to int limits during the encoding
00:45
@AndrovT Does bits_to_add here go up to 2^31?
Great work on the encoder/decoder btw
It really is good
I've been wanting something to compete with nibbles on a fracbyte level for a while
Sorry I meant this one, was looking at the original repo
Wait no that's Lyxal/
I thought there was a Vyxal/ fork
There's a scala version in the org
Oh
Androv's is the original, mine has a better corpus and the org one is a scala port
It's only going to scala because I need to access the encoder online without having to make server requests
And scala.js exists
00:54
@lyxal I just tried (bitsToAdd >> 1.toInt) and it works for me
Although it's supposed to be the other way around so nvm
This is in absence of a 2**bigint method
imma commit BigInt(1) << bitsToAdd.toInt for now so it at least works
I'll leave a todo comment so we can chang eit later
So either bitshift with bigint on the right or pow operator
Maybe spire is needed
Looking at the code right now, what's top?
Good question
01:03
If it doesn't exceed 2^31 or whatever, then we can just do bitsToAdd.toInt and call it a day
Probably an upper limit
@user I think it might
:(
But as I said, a pow operator would also work
Bit shifting is better
Is there any reason for binList accepting Ints rather than BigInts?
Because if it's okay to do binList(top.toInt, ...), then top doesn't exceed the max int, and bitsToAdd probably doesn't either
I'll just wait for Androv to respond
01:20
@user oh dang that's probably a mistyped thing
Yeah we better wait
Made a commit with some minor changes
 
5 hours later…
06:07
Okay so good news it's no longer making programs twice as long
Bad news is that it's still adding a bit to some programs and nowhere near the efficiency of the python
As in a literal bit
 
2 hours later…
07:52
@user it's always <= minBits
 
1 hour later…
09:07
@AndrovT is minBits always less than 2^31?
09:25
@lyxal The default is 16 and it seems to work well enough
It is theoretically better with higher values but it get diminishing returns
but definitely below 2^31
The only values that need to be BigInts in the original python code are top, bottom and ranges (and acc in the decode funtion)
 
1 hour later…
10:36
Oh
Good
 
2 hours later…
12:53
!!/status
@Ginger I am doing whatever I feel like. You could try that sometime, instead of being a mindless sheeple.
13:20
!!/amilyxal
@Ginger You are not lyxal.
but
!!/amilyxal
@lyxal You are lyxal.
good
 
1 hour later…
14:22
GingerIndustries created branch GingerIndustries-patch-1 in Vyxal/VyxalBot2
!!/pull
@Ginger Restarting...
Ah'll be bahk.
Well, here we are again.
cool
15:14
@lyxal Vyxal supports some infinite arrays. But is it possible to use it in input, as in 05AB1E in this answer?
https://codegolf.stackexchange.com/a/260466/114511
15:41
@lesobrod the 05ab1e answer doesn't have it in the input section, it has it in the header section
So I'm pretty sure you can do the same in Vyxal
 
3 hours later…
18:31
@lesobrod just fyi, your solution would fail on e.g. 14 14 14 14 14 (more than four <15)
 
4 hours later…
22:51
@lesobrod input can be placed on the stack before program execution

« first day (1104 days earlier)      last day (669 days later) »