« first day (2062 days earlier)      last day (2903 days later) » 

3:00 PM
@R.MartinhoFernandes Haha, yeah.
 
my site scores 0
awesome
 
ITT Telkitty can't read.
There's no "score".
 
only crosses
I got all crosses
and telkitty.com is an html site too
 
very static
 
3:02 PM
@R.MartinhoFernandes Nice. Are you running your own or is it some hosting?
 
I had a dynamic site, but I had too many online enemies
they nearly trashed my site
 
@wilx My own.
 
@Telkitty Are you a superhero that you have enemies? :)
 
Well, I don't actually own the box itself, but I have full control over what runs on it.
 
villains don't have enemies? :p
 
3:04 PM
@Telkitty Oh! :D
 
Can someone explain the diff between:
Apartment apt(squares, length, width, price);
AND
Apartment apt2 = new Apartment(squares,length,width,price);
 
It still need to sort out Public-Key-Pins.
 
@Osh24 The latter most likely does not make any sense in C++.
 
with a pointer
*
 
3:06 PM
@Osh24 Well, value versus pointer then. Two different things.
 
Both are allocated on the heap?
 
I also have an A+ score on the SSL Labs analyser ssllabs.com/ssltest/analyze.html?d=rmf.io.
Not that users give any personal information when they visit my site, but it was not a lot of effort to make it extra secure.
 
@Osh24 the one with 'new' you would have to demolish it using delete, the other apartment automatically destructs itself once goes out of scope
 
Thanks.
The first one just calls the constructor and assigns in into apt?
 
3:11 PM
Thanks|!
 
user1804599
3:29 PM
@R.MartinhoFernandes lol 1 downvote
 
ffs when will http://llvm.org/apt go up again
 
@набиячлэвэлиь now I’m hungry
 
@набиячлэвэлиь When will llvm avr get merged :/
 
3:47 PM
@набиячлэвэлиь when you stop excessly loading it
(yes I know that's not how that's spelled in English)
 
@Griwes It's "ecsexly".
 
lol
 
4:03 PM
> I don’t think people would steal as many bikes if there weren’t as many hipsters. — 'S', Berlin bike thief
3
Hipsters ruin EVERYTHING
 
I know, right?
If you leave your bike out, what do you expect? That it stays there?
 
According to S, hipsters are the buyers.
 
Hip*
 
user1804599
4:21 PM
1.82 is parsed as Divide[182, 100].
 
user1804599
Having only integers makes things really easy.
 
user1804599
Integers and some irrational real constants.
 
4:56 PM
@R.MartinhoFernandes yes, this makes sense
on the other hand I, too, would lead a life of crime if my parents would have given me a single-letter name
 
nwp
the silver bullet syndrome talk nicely summarizes what is wrong with rightfold
TLDW: being a hipster
 
user1804599
Huh?
 
user1804599
Please give a description of what it is about.
 
5
Q: Non-trivial example of undefined behavior with const_cast

JRGThe following code is, as far as I understand it, undefined behavior according to the c++ standard (section 7.1.5.1.4 in particular). #include <iostream> struct F; F* g; struct F { F() : val(5) { g = this; } int val }; const F f; int main() { g->val = 8; std:...

This is so evil
 
user1804599
I am always very open minded.
 
nwp
5:03 PM
it is about people who keep switching programming languages, frameworks and general technology just for the sake of it and how that is bad
 
@Borgleader Nice one
 
@milleniumbug Also the snippet at the bottom is indeed spectacular
 
I recognise this
It's from here
 
why doesnt that work?
 
because you posted it here
CLEANUP AT AISLE ONE!
 
5:09 PM
Don't use C-arrays
std::array exists for a reason
 
@milleniumbug s/-arrays//
 
std::array is shit until ctor TArg deduction
 
-6
Q: How to do a sum function in C++

Ahmed SamaliguiInput Format: The first line contains 2 space-separated integers A and B, where A is the first number and B is the second number. Output Format: On the first and only line, output a single integer which is the sum of A and B . Subtasks: Subtask 1 [30 Points] — Small Numbers! -1,000,000 <= A, B <

/cc @Mysticial straight outta homeworkton
 
2 messages moved to bin
cleaned up
 
Poor Jacob.
 
5:16 PM
@Puppy You're a top bloke
 
@StackedCrooked Who's jacob?
 
The one who was kicked by pup.
 
@nwp rightfold doesn't do this in production, silly
 
5:35 PM
@Borgleader ahaha fail
 
6:22 PM
@rightfold You never speak in absolutisms
 
6:40 PM
@R.MartinhoFernandes Fucking hipsters
 
...and this is why we close vote questions on SO
 
user1804599
> (fun[X] X)[1]
(fun[X] X)[1]
 
user1804599
Time to implement beta reduction!
 
@sehe Never!
 
6:53 PM
@LucDanton strangely the opposite happened to me when I saw the tweet
@QPaysTaxes not all fucking is a reward
@fredoverflow WOW
 
user1804599
that was easy :)
 
> fun1()
{
static int loaclvar
}
Troll confirmed
 
@sehe Never attribute to trolling what is reasonably explained by stupidity.
 
This however cannot be reasonably be explained by stupidity
 
Do not underestimate the stupids.
 
6:56 PM
Is malloc(0) UB or something?
 
I think it's IB and therefore cannot be relied to result in defined behaviour (AFAIR)
 
@fredoverflow No, it just it's unspecified whether it returns null or a non-null value
 
Google Test src
 
@fredoverflow So you can safely call free() on the returned value, but not much else
Which is fine really
 
Ah so free(NULL) is fine?
 
6:59 PM
yep
 
user1804599
> (fun[X, Y] Add[X, Y])[x, 0]
x
 
user1804599
yay it works
 
@sehe oh ffs putting spaces between # and include
another pet peeve of mine is not putting space between include and <a_header>
 
@sehe ಠ_ಠ
 
@milleniumbug Right, they should have put a tab between the # and the include!
 
user1804599
7:02 PM
 
user1804599
Thanks, Wolfram Language.
 
@milleniumbug I'll take that anyday. The rest, though, is inexcusable
 
hi everyone, i have a problem with a homework assignment; i'm not well versed in c++ and now i'm stuck. the assignment was to write a maze solver - one of my solvers does breadth first search, finds the correct way on the biggest maze, but then crashes. i'm storing the path in a recursive structure (
(a point class with a shared_ptr to the parent)
now it crashes when the solution is found
 
@stefs Sorry to hear that. You probably need to fire up the debugger and figure out what's happening.
 
7:04 PM
We've got lots of problems with homework assignments, today
 
because, it seems, there's a stack overflow when releasing the memory
the path is ~950 segments
 
Mainly, the fact that people keep swooping in and dumping them here
 
big, steamy dump
 
sorry, if this is not the right place, i'll go elsewhere
 
Pirate being drunk on twitter
 
7:07 PM
@stefs When you post on Stack Overflow, include a minimal, complete, verifiable example--i.e., enough code that a read can copy and paste it, see the same result, etc. Trying to diagnose from a description of what the code is intended to do, along with a statement that it doesn't work is rarely a fruitful way to do things.
 
well, i don't want a solution
 
use a debugger or debug a user
 
@stefs Okay--but it's unlikely anybody can give any more than the very most general advise without actually seeing the code.
 
i just wanted confirmation that a stack overflow when freeing a recursive data structure with ~1000 shared_ptr parents is probable
 
@stefs No, it's not (unless you have a cycle, or something on that order). Calls 1000 deep shouldn't normally cause a problem though (unless you have much larger stack frames than most functions should).
 
7:12 PM
thanks for confirmit it. the stack overflow happens in _Ref_count_base::_decref. the data structure contains two ints and a shared_ptr to parent
i do resolve the path by looping, the exception happens only when freeing. the stack trace is ... long.
haven't counted the lines :)
works fine on samller mazes though
*smaller
well, thanks for your help, i'll try a different approach.
 
@ScarletAmaranth ancestral warchief
 
@orlp my damage seems to have been reduced since the latest minipatch (from the aoe nerf)
 
@ScarletAmaranth correct
max charge distance is now 60 instead of 50
so if you charge less than 60 you deal less dmg
 
I don't like this, it feels a lot slower
 
what links do you use
and what gear
and what level
 
7:20 PM
I use facebreaker (730% or so), with 5L charge -> melee phys. dmg -> added fire dmg -> fire pen -> faster attacks
 
fire pen
wtf dude
 
not that good ^^?
I have herald of ash on; can't afford more auras atm, run into a lot of mana issues otherwise - perhaps with enlighten
 
charge -> melee phys -> faster attacks -> inc aoe -> fortify
run herald of ash and hatred
run a mana potion and get 0.3+ phys mana leech on gear
what other gear?
facebreakers isn't enough
 
nothing of greatness
 
you need flat phys dmg on rings, amulet, shield and belt (meginord's)
 
user1804599
7:24 PM
My simplifier simplifies 2+2 to 2^2 :[
 
soo foritfy is better than added fire dmg?
 
it's safer
@rightfold simplified
(maybe priority for + < - < * < / < ^)
 
uu cool, imma try it out! thanks :P
 
user1804599
Because it sees 2+2, it turns it into 2*2 because there are two 2s being added, which it subsequently turns into 2^2 because there are two 2s being multiplied.
 
user1804599
This will fix itself once constant folding for Raise is implemented.
 
7:25 PM
wait, what is the scope/goal of your simplifier?
like, an optimizer?
in that case 2+2 should be 4 :P
 
user1804599
@orlp Symbolic computation.
 
Xeo
(continues here, since the other view doesn't show the rest)
 
@rightfold btw I think 2*x should be an exception
 
user1804599
Why?
 
7:28 PM
to simplify to x + x
 
user1804599
No.
 
oh wait symbolic computation
I don't really know what that is, I thought for CPU optimization
 
user1804599
It allows you to do computation with variables that don't have values.
 
user1804599
It can do differentiation for example: Differentiate[3x^2 + 5, x] is simplified to 6x.
 
@JerryCoffin: just for reference: #pragma comment(linker, "/STACK:2000000") solved the problem
 
user1804599
7:33 PM
And units: (1 Meter / Second) * 10 Second turns into 10 Meter.
 
"solved"
 
@milleniumbug well ... i interpret this as a problem in the stack frame size of the shared_ptr?
 
No. Go back to square one.
 
okay
 
@R.MartinhoFernandes it worked… on the second click
> the <begin> and <end> iterators
what’s with the goofy typesetting
 
nwp
> When the next standard is approved, the semantics opted-in with the /std:c++latest will be covered by /std:c++17 (assuming that the next standard is C++17, but the standards committee working group never ceases to surprise)
 
should really be /std:c++upcoming then
how2names
 
nwp
std:c++whatever_is_implemented
 
@nwp terrible
make the sane semantics default
a.k.a. if you see OpenSSL doing a thing, do the same thing, but in an opposite way
 
nwp
7:52 PM
@milleniumbug what is that "sane semantics" you speak of?
 
opting-in to a specific version with a commandline argument, and having the latest version by default
 
nwp
pretty sure they will do that
 
@milleniumbug the default appears to be C++14
I may be reading too much into it
> if you specify a language version that isn’t any of those, the compiler will ignore the switch (with a warning) and default to C++14.
 
nwp
@LucDanton thus the complaint about not making the sane semantics default
 
oh, I’m still in 'C++14 is the latest' mode in my head lol
 
7:58 PM
@LucDanton whoop - nice
That's not nearly the biggest problem with most unauthenticating/non-signed package managers of course
 
@LucDanton As far as official standards go, it is.
 
@sehe does signing really help here?
 
The packages could be authenticated in repo, and then tampered with in transit
 
ah I get it
 
@DieterLücking that doesn't make a difference in the problem that I'm dealing with though I guess it would make it run faster — I_love_coding_93 3 mins ago
in response to "don't use using namespace std"
 
8:01 PM
Groan. Kindly refer to my avatar — sehe 10 secs ago
 
nwp
"not constructive"
 
yo
 
@nwp It's not meant to be constructive. Also, be sure to flag that guy's "magical thinking" comment as not constructive too :)
 
@sehe Second meaning: somebody being chased by a polar bear probably really would run faster.
 
nwp
that one doesn't look like the chasy type
 
8:06 PM
@JerryCoffin Brilliant
And since running code reaches completion sooner than non-running code, it follows that removing using namespace std indeed makes the code run faster. Q.E.D. — sehe 19 secs ago
 
Wow. And here I had my money on Pixies. Pixies can run the hamster wheel in the CPU at a higher clockrate than the usual goblins. — user4581301 1 min ago
This one's pretty good too
 
hey guys, should I really learn C++, like, now? Came from java and android, and really wondering how all those lower layer stuff work atm. Is C++ a good place to start?
 
nwp
@DeanK no
 
Okay, going to learn Java bytecode and Assembly now.
Kidding aside, what do you guys use C++ for in your daily job?
 
user1804599
@DeanK C++ is higher level than Java.
 
user1804599
8:18 PM
It provides higher abstraction capabilities out of the box.
 
user1804599
It does more for you.
 
You have to allocate memory and manage pointer stuff, no?
 
user1804599
lolno
 
nwp
@DeanK no
 
@DeanK no
 
8:20 PM
@DeanK I use them as a crutch, for when my magnetized needle gets dull, and starts to affect more than one bit at a time as I write programs to the hard drive. Also handy for programming on SSDs, where the magnetic needle doesn't work so well.
 
user1804599
That has been automatic since 1989.
 
@rightfold But Java has reflection :o
And garbage collection.
 
I stand corrected
 
@JerryCoffin for SSDs the trick is to work in the basement
 
@DeanK no
 
8:21 PM
@LucDanton My office is on the second floor...
 
But don't use C++
If you want to go low level, use Rust by default
 
yeah that leads to high level programming
 
user1804599
Rust master race.
 
you never post any rust
 
user1804599
fn remove_dead_blocks(sub: &mut Subroutine) {
    let dead_blocks = Vec::from_iter(sub.blocks().filter(|&b| is_dead_block(sub, b)));
    for &block in dead_blocks.iter() {
        sub.remove_block(block);
    }
    if !dead_blocks.is_empty() {
        remove_dead_blocks(sub);
    }
}
 
8:22 PM
@LucDanton Only mid-level at best. When I was in Colorado, I did much higher level programming, even in the basement, but now I'm pretty much right at sea level.
 
Your instinct is correct in that C++ is almost never a good idea
 
okay.........
 
user1804599
Note how the Vec (vector) has to be created because Rust does not allow you to modify something that is being iterated over.
 
user1804599
Like it won't even compile if you try to do that.
 
nwp
@DeanK don't believe him, a lot of people hanging out here hate C++ for some reason
 
user1804599
It's a bug that never happens in a Rust program.
 
nwp
it is still a fun language when you got it down
 
I can imagine so
 
Fun? Of all the adjectives about C++ I'd say "fun" is the furthest away from the truth
 
nwp
I'd say the most important rule is to never use new
 
8:24 PM
I like working with C++ iterators but that's probably a Stockholm syndrom.
 
What?
 
user1804599
@Shoe Fun as in hilarious.
 
that
 
It's just sad
 
@Shoe You stand corrected. I often have fun writing C++ :o
 
8:25 PM
Also many GUI toolkits are just terrible and laggy
 
user1804599
resolve (Lam ps x) (Γ γ) =
  let γ' = foldl (\g p -> Map.insert p (Var p) g) γ ps
   in Lam ps <$> resolve x (Γ γ')
 
user1804599
High-level abstractions are the best.
 
Also, there are many worse languages, like PHP
 
Eh
 
nwp
@rightfold y u foldl and no foldr?
 
8:27 PM
With the latest iteration of PHP I'm honestly not sure what's worse?
 
user1804599
PHP 7 is great and far more fun to work with than C++.
 
Oh, wait, I forgot PHP is dynamically typed
 
@milleniumbug I'm not sure agree. Given PHP's lack of coherence, it may not qualify as a language.
 
user1804599
Especially the type checker for PHP which is called Hack and works super nicely.
 
But yeah if you consider Hack + PHP then C++ is way worse
 
user1804599
8:28 PM
PHP is my favourite dynamically typed language because unlike all the others it has interfaces and it doesn't have monkey patching.
 
All this hate on the champ
Put some respec on PHP's legacy
Are we done or are we finished?
 
user1804599
Wolfram Language is the best programming language ever.
 
PHP's legacy? Like implementing hash functions with strlen?
 
@rightfold do you like the lambdas?
 
Am I right or am I white?
 
8:29 PM
c# wins the lambda war imo
4
 
user1804599
@JohanLarsson Yeah they're fine.
 
user1804599
@JohanLarsson No; Haskell with the LambdaCase language extension does.
 
I used lambdas for the first time and it felt like I entered another dimension.
 
@JohanLarsson Indeed, the only (very minor) complaint is that they aren't proper expressions, only after assigning to Func or Action
 
8:30 PM
@rightfold what does it look like? a regex?
 
user1804599
f $ \case
      Just n  -> n
      Nothing -> 0
 
@milleniumbug they can be expressions
 
user1804599
@Shoe I think you mean xor you silly racist.
 
wat
 
AFAIK their type has to be deduced from the type of function arguments, for example
but I wouldn't blame the language, if it was a different design, it would probably be more problematic
so I consider it a very minor problem
 
8:32 PM
@KretabChabawenizc Chroma 5
 
I think I want to try and write some language
 
user1804599
> When it comes to accepting the official 9/11 Commission Report version of what happened on that terrible day of September 11, 2001, are you a true Belieber—or do you beliebe that it was perpetrated by our own government? Grab your “Boyfriend” and take this quiz!
 
user1804599
@Shoe write Rust
 
user1804599
> If Trump promises to deport Justin Bieber, I think he would actually win.
 
@milleniumbug maybe this is what you mean
 
8:35 PM
...I have no idea what is this, but looks awesome
Did you just store the lambda as a syntax tree, translated from a language it was written in?
 
@rightfold What tools have you used to try and write your own language?
 
user1804599
I have no idea what you mean.
 
Which ones would you recommend?
 
user1804599
You mean writing a language implementation?
 
yes
 
8:36 PM
@milleniumbug I'm not sure, depends on what it means
 
user1804599
I have used Haskell, PureScript, C#, Erlang, Elixir, C++, Racket, JavaScript, LiveScript, a bunch more probably
 
@milleniumbug yes
 
user1804599
as well as various parser generators and code generators
 
In Rust, when code is marked unsafe it can mean one of two things: 1) that the code is unsafe to call from safe code; or 2) that the code is safe to call from unsafe code.
That's my trivia for today.
 
user1804599
8:38 PM
It can also mean that the code is unsafe from the inside and safe from the outside.
 
Also, safe code is generally unsafe to call from unsafe code.
 
wonderful
 
@rightfold What language and respective tools did you enjoy the most?
 
user1804599
PureScript w/ PEG.js.
 
user1804599
 
user1804599
8:43 PM
Haskell with Happy and Alex for parsing is also very neat. example with type checker
 
@DeanK Programming
 
I decided just take my bet on C++. Its no coincidence that this room is far more crowded than Java & Android room.
@sehe Hm?
 
Pfft yesterday it almost dropped off the first page of chat rooms by activity
And it hasn't been on the first page anywhere in the last 5 weeks when I looked
 
@DeanK It's dangerous to go alone, take this
 
nwp
@milleniumbug awesome start for an adventure
I want to play an adventure game
 
8:46 PM
@milleniumbug Thanks, have my eyes on effective c++ already. Gonna buy that from Amazon tmr
 
What is tmr?
 
nwp
@DeanK make sure you get effective modern c++, don't want to learn outdated crap
@sehe tomorrow?
 
I didn't know Amazon closes at night
 
@nwp sehe wants to know right now
4
 
@rightfold Thks
 
8:47 PM
LOL I don't wanna open Amazon right now.
Procrastinating hard.
 
@LucDanton haha
that is a star
 

« first day (2062 days earlier)      last day (2903 days later) »