« first day (1801 days earlier)      last day (3145 days later) » 

9:01 AM
Is using custom literals common? Ive never come across it in code before
 
I use them.
 
'Common' seems like a stretch. They’re situational.
I don’t define them often but those I do define are very handy.
Plus the standard ones.
 
user1804599
@TonyTheLion full video powned.tv/nieuws/foto/2015/09/…
 
@elyse oh wow
 
9:07 AM
@ElimGarak hahaha I was just ready to highlight the same comment
 
Hahaha Volkswagen could be fined 18 billion dollars for that software thingy
Das Auto.
 
das Lol
 
18 billion dollars more than I have :(
 
lol -20% share price
 
hahah
@AnastasiyaAsadullayeva what was the issue again?
 
9:20 AM
> In the integer and floating-point digit sequences, optional separators ' are allowed between any two digits and are ignored
 
user1804599
@TonyTheLion fraud
 
neato
 
user1804599
@Prismatic so not 9.'8? D:
 
user1804599
wait
 
user1804599
9:20 AM
that is between two digits
 
user1804599
hmm
 
user1804599
so it should be allowed
 
1`000`000 // pretty
it says c++14 only
 
@AnastasiyaAsadullayeva shit
 
user1804599
@Prismatic why the fuck backticks
 
user1804599
9:21 AM
that's a syntax error
 
sorry I misread, it looks like apostrophe
 
user1804599
how can you mix up ' and `.
 
user1804599
luckily he has shitloads of money and hence won't go to jail
 
user1804599
Kim Dotcom is a hero.
 
9:27 AM
lol I got a stackoverflow with to_json @Rapptz
 
user1804599
nice
 
Nice comment in 3... 2... Ah, shit-
 
@fredoverflow all signs point to 'fancy'
 
@fredoverflow is this a teaching tool?
 
9:30 AM
probably production software
 
user1804599
protoduction
 
May 23 at 12:30, by fredoverflow
Someday it'll be a beginner IDE for C.
 
@fredoverflow nice
 
user1804599
@fredoverflow you should implement strxfrm.
 
@AnastasiyaAsadullayeva rename it to too_json
 
user1804599
9:32 AM
and this syntax:
 
user1804599
int pre_ansi_func(a, b)
int a, b;
{
    return a + b;
}
 
@elyse lol no
 
I'm actually not sure why it goes stackoverflowy
 
what sez debugger
 
user1804599
@fredoverflow do you plan on Java interop? :D
 
9:34 AM
Debugger shows the call stack just fine but I'm not sure what makes the compiler choose that path, is what I mean.
I'll try to use a few neurons before cri for help
 
Morning.
 
@fredoverflow it generates the graphics automatically based on the code?
probably a stupid question
 
@StackedCrooked yes
@StackedCrooked no
 
user1804599
@StackedCrooked based on the current state of the program during a breakpoint.
 
@Prismatic dot
 
9:36 AM
Does it only show data for the active scope?
 
No, it shows everything.
 
unwieldy, that
 
user1804599
then you should do automatic alpha renaming
 
By the way, alternating between x axis and y axis was easy as pie:
val axis = if (type.dimensions().and(1) == 1) BoxLayout.X_AXIS else BoxLayout.Y_AXIS
 
user1804599
with subscripts maybe
 
9:36 AM
Do the graphics disappear when variables go out of scope?
 
@sbi I based that on who I remember when I joined back in 2011/2012
 
Of course there's a ton of stuff I haven't implemented yet.
 
Finally I got OGRE, Bullet and CEGUI to work properly
Porting wasn't that bad after all
 
9:38 AM
@elyse the most baffling thing is, everybody duck really deep when they get inside the building. Why is that
 
user1804599
@sehe sign or ladder or other obstruction probably?
 
@TonyTheLion feels fucking fake
Why does the interface not highlight the message on the starboard I am replying to when I hover over my message
 
@Columbo I'm pretty sure the guy experiencing it will disagree with you
@Columbo :snackchat:
 
@TonyTheLion Why so sure
 
user1804599
@ʎǝɹɟɟɟǝſ dammit just missed it
 
user1804599
9:42 AM
was something with dead pigs
 
1 hour ago, by sbi
"David Cameron Allegedly Stuck His Naughty Bits In A Dead Pig's Mouth: http://www.huffingtonpost.co.uk/2015/09/20/david-cameron-dead-pigs-mouth_n_8167458.html <= A headline I didn't expect to wake up to.
 
user1804599
Funfact: pigs are more hygienic than most people who consider them filthy.
 
@elyse What exactly do you mean by that?
 
@elyse ^nope
 
@elyse What is strxfrm?
 
9:47 AM
@fredoverflow A function name you can type by randomly smashing your keyboard.
 
@fredoverflow String transform
Aka "what are vowels"
 
@fredoverflow nice
thanks
 
@StackedCrooked Someday I'll go reddit and ask for suggestions, but it needs much more polishing before I can make that step.
For example, if you increment a pointer with ++, you get a runtime type error :)
 
@fredoverflow Cool at the end of the program everything disappears except for the string literals. That's because they are actually static storage, not?
 
exactly
Although one could argue they should disappear as well...
Under the hood, they aren't really static, I just push them on the stack before I call main :)
 
9:52 AM
You sneaky bastard.
 
I'll probably need a second memory panel for dynamic memory...
 
Is this C or your own language?
Looks like it's C.
 
> runtime type error
 
@elyse they still wallow in mud
@Columbo oh hey, feels like I've not seen you around for a little while
 
@thecoshman That's because I got shit to do now
 
9:55 AM
Nice. It visualizes insertion sort for me!
 
@Columbo ... and/
 
@thecoshman I only visit the lounge if I'm bored.
 
@fredoverflow maybe use background colors to indicate memory regions
 
user1804599
> Transforms the null-terminated byte string pointed to by src into the implementation-defined form such that comparing two transformed strings with std::strcmp gives the same result as comparing the original strings with std::strcoll, in the current C locale.
 
I don't actually endorse in conversation unless I haven't got anything else to accomplish
 
user1804599
9:57 AM
@fredoverflow do you catch all UB?
 
user1804599
Maybe it's impossible to do that.
 
What happens if the Java runtime executes C++ UB code?
 
@fredoverflow is this thing up on github or something?
 
user1804599
@StackedCrooked UB
 
9:58 AM
Does Java have UB?
 
@StackedCrooked It's called Java
 
@StackedCrooked Java is UB
 
user1804599
@StackedCrooked Not sure if the language does, but the JDK certainly does.
 
Ell
well fucking shit man.
I water damaged my replacement phone >.<
7
now I need a replacement replacement phone
 
oh Ell! you failing so hard.
 
user1804599
9:59 AM
should've gotten a waterproof replacement phone
 
user1804599
 
Ell
also I can't find my wallet :S
 
@StackedCrooked Yes, I have thought about playing with different colors.
 
@Ell looool
@fredoverflow the layout in the drawing is purely representational, right?
 
@thecoshman It's on bitbucket :) Not sure if I'll ever release the source code. I released the source code for Karel The Robot, and pretty much nobody cared about that. (And why would they? Much more interesting compilers such as scala or clang are open source, too.)
 
10:03 AM
Ell isn't my sockpuppet
 
@elyse That's a good question. I don't know if it's possible on all cases. My plan is to catch as much UB as feasible.
 
@R.MartinhoFernandes I would be really surprised if Ell turned out to be your sockpuppet.
 
@thecoshman The internal memory is always flat.
 
@fredoverflow I meant more that code for the representation of memory. Is this a custom compiler you wrote for this?
@R.MartinhoFernandes I felt it a bit tedious to draw that analogy :P
 
@StackedCrooked It's a subset of C. I'll probably never get around to implementing all of C, but that's fine. I don't teach obscure stuff like unions or bitsets, anyway.
 
10:06 AM
That's cool.
 
@thecoshman What do you mean by "representation"? Internal model or UI? Yes, the compiler is hand-written recursive-descend.
 
@fredoverflow ah right. I take it you intend to keep the scope of what this supports fairly limited to what you need
 
@thecoshman Exactly, this is a personal project that I have been wanting to implement for years.
 
Ell
@R.MartinhoFernandes hehe
 
As a matter of fact, I have been using the tool this morning to demonstrate arrays of char pointers :)
 
Ell
10:08 AM
oh wait I just found my room key on the bathroom floor
which means my wallet ought to be in the flat somewhere
 
@Ell erm, why was it on the floor?
 
@thecoshman Of course I wouldn't mind if other people found the tool useful too and gave me thousands of dollars for it ;)
 
Ell
@StackedCrooked I think I thought I was gonna upchuck
 
@Ell ooooh, you just started uni didn't you
 
Ell
lol yes
 
10:11 AM
@fredoverflow ah right, well yeah, I was thinking it might be nice to have a poke around and maybe help with stuff
 
Ell
how did you know? :D
 
@Ell amature
 
oh right
It's september and IIRC Ell is around 17-19 years old. Story checks out.
 
Sounds like you had too much fun alcohol.
 
10:12 AM
@fredoverflow yay! metal!
@R.MartinhoFernandes or not enough
 
@thecoshman Are you sure you wanna help with code like this? :)
private fun initializer(type: Type): (Context, Int) -> Int {
    if (type is ArrayType) {
        val elementType = type.elementType
        expect(Token.OPEN_BRACE)
        val inits = arrayListOf(initializer(elementType))
        while (token == Token.COMMA) {
            eat()
            inits.add(initializer(elementType))
        }
        expect(Token.CLOSE_BRACE)
        if (inits.size() > type.length) lexer.error("too many initializers")
        if (inits.size() < type.length) lexer.error("not enough initializers")
 
Ell
@R.MartinhoFernandes I actually feel fine this morning
which is good
I probably did have a little too much though still
 
@fredoverflow well, maybe just mock :P
@fredoverflow oh, scala?
 
@thecoshman Kotlin
 
@fredoverflow o_0
 
10:14 AM
@elyse Wait, the for loop is a fold, isn't it?
 
lol, browser
 
Monday again... sighs
 
Almost done here
ahahahahahaha
 
Apr 26 at 15:42, by fredoverflow
user image
 
@fredoverflow you look a bit like who I presume to be the lead singer for Obituary. The one in middle.
 
10:16 AM
Except he's way more heavy than me.
 
@fredoverflow wait, what's going on with the two logos there?
 
Its also a nice approximation of the RAM for analyzing algorithms for a beginner
 
@thecoshman Double genitalia on the left.
 
@thecoshman One is obviously a cock
@JonClements thats exactly how I feel
 
@TonyTheLion lol, I see
 
10:19 AM
@TonyTheLion I bark at it... and after 24 hours or so it goes away... then it keeps coming back every single bloody week to taunt me.... must be doing something wrong
 
@elyse It is a fold!
// before
return { context, address ->
    var a = address
    for (init in inits) {
        a = init(context, a)
    }
    a
}
// after
return { context, address ->
    inits.fold(address, { a, init -> init(context, a) })
}
 
@fredoverflow he does have a sort of smug look in that image where he knows you are just mediocre
 
@JonClements yea same here
 
@thecoshman I'm pretty sure the one in the middle is the drummer. The lead singer is the 2nd from the left.
 
@fredoverflow If that were Haskell you could also foldl' (>>>) id (map ($ context) inits) a
 
10:25 AM
And that would be so much more readable!
public inline fun <T, R> Iterable<T>.fold(initial: R, operation: (R, T) -> R): R {
    var accumulator = initial
    for (element in this) accumulator = operation(accumulator, element)
    return accumulator
}
Note the inline. No abstraction penalty :)
 
what does the $ do in Haskell?
 
Ell
something about parenthesis
this (that the_other)
this $ that the_other
I think they are equivalent. but not 100%
 
@TonyTheLion No money, that's for sure in Haskell land.
 
@fredoverflow who you also look like... ok, you are white and have long blonde hair, generic metal look , check
oh, and not fat
 
@Ell They are with GHC due to special support, but otherwise it could have been a regular function. (i.e. f $ x = f x)
 
Ell
10:28 AM
Right
 
So $ is function application?
 
yeah
 
By the way, C has stupid initialization rules.
For example, you can write int x = {42};
 
The map ($ context) step is feeding the context to all the inits functions.
 
Who would want to write that?
 
10:32 AM
In C++, anyone willing to catch narrowing conversions.
 
Sure, but this predates uniform initialization. It's standard C89 syntax.
Also, you can leave out parenthesis in nested initializers.
Like int a[2][3] = {1, 2, 3, 4, 5, 6};
I find that way more confusing than useful.
 
fred: still? :')
 
Suppose you typedef real_type abstracted_type; and you document that the user can do abstracted_type x = { 23 };.
 
@chmod711telkitty Still what?
 
Then you can seamlessly go from an integral type to a struct type or vice versa as the real_type.
 
10:34 AM
Hm, I wonder if that's the reasoning behind it...
At least it would make some sense.
 
The argument boils down to 'the reason to make initialization uniform is that it gives more uniformity'.
 
I want to use user defined literals for measurement units (mm,in,cm,whatever)... but I think I have to allow for a raw floating point type too so I can pass things into my math library. :[
 
@Prismatic For things like scalar multiplication? You’d want a real unit system.
 
@fredoverflow well... a is a single contiguous block of memory under the hood any way, a[2][3] is no different to a[6], is it.
 
@fredoverflow Considering that it comes from C, I don't think it has really been thought through.
 
10:37 AM
@thecoshman sure, but his point is that it's more confusing than it is useful
 
@StackedCrooked I don't know...
 
@LucDanton Well I don't want the user to be able to specify a quantity without using a predefined measurement type. But I have to allow just 'floats' so I can pass things to my matrix lib
 
yesterday, by fredoverflow
22
Q: May I treat a 2D array as a contiguous 1D array?

fredoverflowConsider the following code: int a[25][80]; a[0][1234] = 56; int* p = &a[0][0]; p[1234] = 56; Does the second line invoke undefined behavior? How about the fourth line?

 
@Prismatic Those two things are contradictory. Make up your mind.
 
I'm just complaining is all, I don't think there's a decision to be made
 
10:41 AM
Face it. You should just give up and do something easier :P
 
I'll just have some docs that say: caveat emptor; always specify a measurement literal or bad things will happen
 
Sounds like you're missing something
 
@R.MartinhoFernandes elaborate pls
 
How can you be wanting units without wanting units?
 
unit to make up your mind
 
10:47 AM
I sometimes feel that organizing my documentation is harder than organizing my code.
 
@Prismatic Look at <chrono>. It doesn't have the problem you described.
 
user1804599
@fredoverflow all loops are folds
 
@elyse yup. that's why I'm baffled. Apparently the whole thing is just under construction or something
@elyse void folds
 
user1804599
@sehe yup!
 

« first day (1801 days earlier)      last day (3145 days later) »