The Bot Bikeshed
-
@error_bot eval 'alert("pwnd")'
-
Error: lex failed; remaining: "pwnd"); match: null
-
@dcon said in The Bot Bikeshed:
Haven't needed it yet, just have it bookmarked.
Same. Looks pretty nice. I seem to remember @cvi having had good experience with it.
@error is certainly using JS/TS for it, though. Maybe there's a suitable PEG library in the leftpad world.
-
@topspin said in The Bot Bikeshed:
Same. Looks pretty nice. I seem to remember @cvi having had good experience with it.
Hmm, yeah, if you're in the C++ world, PEGTL is awesome. It's now pretty much my go to solution for any parsing.
-
@Jaloopa said in The Bot Bikeshed:
@error_bot eval 'alert("pwnd")'
Sorry, the language doesn't have a string data type at all.
-
Next patch should add variable declarations and unary
-
.(Why variables? I wanted to roll a die and get both sin and cos of the same value. Why? Listen here you little shit...)
-
@error said in The Bot Bikeshed:
variable declarations
a late-resolved variable is pretty much a function...
but even regular variables can be a billion laughs. although, you did say you excluded string already.
Woohoo! I successfully transferred the trying to approximate pi with dice compulsion!
-
@Gribnit said in The Bot Bikeshed:
@error said in The Bot Bikeshed:
variable declarations
a late-resolved variable is pretty much a function...
but even regular variables can be a billion laughs. although, you did say you excluded string already.
They won't be late resolved, but I think I could get UDFs into this architecture too. Very simple ones, at least.
-
@Gribnit said in The Bot Bikeshed:
@error said in The Bot Bikeshed:
variable declarations
a late-resolved variable is pretty much a function...
but even regular variables can be a billion laughs. although, you did say you excluded string already.
Woohoo! I successfully transferred the trying to approximate pi with dice compulsion!
@error_bot eval 1d1 * pi
-
3.142
-
@error said in The Bot Bikeshed:
@Gribnit said in The Bot Bikeshed:
@error said in The Bot Bikeshed:
variable declarations
a late-resolved variable is pretty much a function...
but even regular variables can be a billion laughs. although, you did say you excluded string already.
Woohoo! I successfully transferred the trying to approximate pi with dice compulsion!
@error_bot eval 1d1 * pi
I hate your stupid face.
-
Alright, I'm gonna fuck this right up.
So we have 1d12 and 1d12, yes? or perhaps more conveniently 1d20 and 1d20, two matching dice.
So, for 1d12, a result of 1-6 may be plotted on an axis so as to address negative numbers, 7-12 positive. With the matched dice, we can address integers on a finite Cartesian plane. The square root of the sum of the squares of the (translated) dice will give whether a roll is within or without a circle plotted around the origin of this plane. Fair?
@error Are there any comparison functions, or min/max? I need something like an if or a signum. Also need a
FISRfractional exponent.signum(((1d20-10)2+(1d20-10)2)1/2-10) is probably the most compact way to state a unit of the approximation.
could use a repetition operator
-
-
-
2 1.414
-
@error said in The Bot Bikeshed:
@Gribnit said in The Bot Bikeshed:
fractional exponent.
@error_bot eval 4^(1/2) pow(4, 1/4)
hmph. Doesn't it understand sup tags?
-
@Gribnit said in The Bot Bikeshed:
@error said in The Bot Bikeshed:
@Gribnit said in The Bot Bikeshed:
fractional exponent.
@error_bot eval 4^(1/2) pow(4, 1/4)
hmph. Doesn't it understand sup tags?
HTML is mostly cleaned out by this point but I could work on Unicode superscript support.
-
@error said in The Bot Bikeshed:
Unicode superscript support.
Sounds creepy. I like it. Can we get
reversed associativitylate vs early evaluation inRTL
regions?
-
@error_bot eval max(min( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
1
Ā
Ā
-
@error_bot eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
-1
-
@error_bot eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
-1
-
@error_bot eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
-1
-
@error_bot
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
eval min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
-1
-
-1
-
1
Ā
Ā
-
1
Ā
Ā
-
-0.513
-
-1
-
1
Ā
Ā
-
1
Ā
Ā
-
-1
-
@error_bot eval 40 + ( min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + ( min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) )
-
Error: too many tokens
-
@error_bot eval 10 + ( min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
Error: too many tokens
-
@error_bot eval 5 + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1) + min(max( pow( pow( 1d20-10, 2 ) + pow( 1d20-10, 2 ), 1/2 ) - 10, 0 - 1 ), 1)
-
Error: too many tokens
-
@error_bot said in The Bot Bikeshed:
Error: too many tokens
I was paranoid about DoS attacks but I think I can raise the max by at least an order of magnitude.
-
@error_bot eval pow(0.00001,0.00001)
-
1
Ā
Ā
-
@error_bot said in The Bot Bikeshed:
1
Ā
ĀFormatter is rounding to nearest thousandth. Internal representation is double precision float.
-
@error_bot uh, maybe.
-
@error_bot eval pow(0.1,0.1)
-
0.794
-
@error_bot eval pow(0.01,0.01)