« first day (1682 days earlier)      last day (3270 days later) » 

10:00 AM
nice
 
Spirit X3 was a thing for a while, no?
 
@rightfold Okay, fine. Now show me an examples that parses differently (in both cases without an error) because a constexpr functions has different values in two different cases.
 
@BartekBanachewicz Unofficially
 
@BartekBanachewicz It's not quite true since constexpr is not arbitrary C++, but it's getting truer.
 
10:00 AM
-3
Q: Select random from e-commerce website in selenium

deepanI Want to select random product from a e-commerce website when the script run each time. Different product should be selected each time.

 
@BartekBanachewicz It was in official Boost repos for a while, but not officially.
Also welcome to having 3 versions of Spirit in official Boost releases.
 
Thank god I don't use boost anymore I guess.
 
Although there are people on a holy quest to get rid of Spirit Classic, lol.
But PropertyTree still depends on it, so... :D
 
when C++17 gets filesystem, optional and ranges, boost will become even less useful for modern C++
 
Yes. Just also give me ASIO in the standard library.
Also standard optional is borken.
 
10:02 AM
asio is already separate
 
It doesn't support references.
 
@BartekBanachewicz still plenty of good stuff inside
 
@Griwes ref_wrapper?
@buttifulbuttefly if it's available outside boost that's an outright advantage
cross-dependencies are a huge pain
 
And standard library variant will also be broken (aka it will most probably have an "empty" state lol).
 
@Griwes what
 
10:03 AM
not disagreeing but your wording "boost will become even less useful" implies boost isn't that useful already
 
(Because the committee doesn't have the balls for it to either require noexcept moves or be bigger than strictly necessary.)
 
@buttifulbuttefly It's certainly less useful than ~5 years ago, at least from my perspective
 
@BartekBanachewicz For the same reason boost variant does allocation in assignment.
 
who cares it's still massively useful
 
5 years ago I couldn't imagine a C++ codebase without boost
 
10:04 AM
Just... they selected the more braindead "solution" lol
 
now I can't really justify getting it in
 
Really??
We use it all over the place
 
@buttifulbuttefly I haven't used it in the last year
 
And most things we use won't get into the standard I believe
 
I didn't really feel the need to use it either
 
10:05 AM
flat containers, interprocess, string algo, ptree, log, endian, predef, etc
 
I personally don't use anything from that list
 
I'm mostly using Optional, Variant, Locale, Iostreams and the unofficial Process one.
 
@barakmanos wa3333333333 — Khaled Sb 6 mins ago
lol
 
Well, MPI for an uni project.
 
@BartekBanachewicz It's more and more difficult to justify bringing it in.
 
10:06 AM
@BartekBanachewicz your projects are too simple :D
 
Optional is available as a standalone lib so
 
@BartekBanachewicz ...still in Boost.
 
@buttifulbuttefly YMMV
 
@Griwes Always blame the authors. The SC doesn’t write the proposals.
 
@Griwes I can get optional without dragging in boost, is my point.
 
10:07 AM
@LucDanton The committee doesn't have the balls to do the right thing.
 
The SC doesn’t write proposals.
 
I think his point is that no one has proposed the right thing
 
also I have to admit I don't feel really motivated to do my job super extra nicely right now :/
 
My point is there wasn't a straight "NO WE WON'T DO THAT" from the committee.
Those guys think that that solution (an implicit "empty" state available in variant) is a good solution.
Which is really sad.
 
> EU dropped plans for safer pesticides because of TTIP and pressure from US
welp
 
10:09 AM
@BartekBanachewicz well just because you haven't needed it doesn't mean it's not usefull.
 
@buttifulbuttefly Link?
 
@Griwes 'Good enough' is how I would put it.
 
3 mins ago, by Bartek Banachewicz
@buttifulbuttefly YMMV
 
Final part of Using Monads in C++ to Solve Constraints: Refactoring functional code. http://bartoszmilewski.com/2015/05/25/using-monads-in-c-to-solve-constraints-4-refactoring/
 
10:10 AM
Personally I think it's good that not everything from boost be lumped into the core language. I don't see what's the harm in standardised optional stuff.
 
@LucDanton They don't think it's harmful is my point, and the fact is it just promotes bad coding (but it's the standard library so welp, we are probably destined to have that).
 
I'm sorry Bartosz but how do you expect to convince people that monads are great with that haircut
 
@thecoshman there's no harm and noone said that.
 
@buttifulbuttefly Hairshaming! SJWs onto you!
 
@Griwes The whole process is also larger than just the SC. Beyond the informal discussion on the groups (yes, I’m serious), the national bodies also act as channels etc. I can’t tell what will happen to the variant proposal in particular, but shooting the SC is shooting the mediator.
 
10:12 AM
@BartekBanachewicz is boost standardised though? It's not like others are providing alternate omplementations to the same problems.
 
what are you getting at again
 
@LucDanton I am shooting the people I've talked to at C++Now that support that proposal.
 
@thecoshman I'm sorry but I don't understand the question
 
That the whole SC? :D
 
4 mins ago, by thecoshman
@BartekBanachewicz well just because you haven't needed it doesn't mean it's not usefull.
Is @thecoshman playing me and @Bartek playing @rightfold / @Puppy? :D
 
10:14 AM
Is any1 familiar with qmake here?
 
quake make
 
literally nobody here has ever used qmake
 
@LucDanton No, obviously not, but I've also listened quite a lot to what Chandler thinks about the committee (and seen how Gabriel's thought process works) :P
 
My head hurts too much for this shit
 
@Griwes We all know that the Committee is full of nubcakes
 
10:15 AM
humm
 
@Puppy That was what I thought, but apparently @LucDanton has a different idea. :P
 
@Griwes I don't get it
 
    inline RefCounter::~RefCounter()
    {
        CLAW_ASSERT( _refCount != -1 );
        CLAW_ASSERT( _refCount == 0 );

    }
actual work code
 
oh dear.
 
IP LEAKAGE MUST REPORT IMMEDIATELY
 
10:18 AM
@thecoshman Go read the transcript, there's been a discussion between me and those two.
@BartekBanachewicz lol
 
@Griwes tempted to PR _refCount > -1 and _refCount < 1 :D
 
user1804599
I think it should be illegal to not use the result of expressions that aren't of type Unit.
 
@JerryCoffin There is a tiny, but non-negligible, chance I might have posted this before your did :)
Thanks anyways!
 
oh lord that was crazy. Some how set the IDE to some squiggly font language I've never seen before :\
 
user1804599
@BartekBanachewicz lol
 
10:22 AM
6 mins ago, by thecoshman
My head hurts too much for this shit
 
Hmmm @Rapptz, is it desirable that you can silently use operator[] (non-const) on an empty JSON value? aka json::value v; v["foo"] = "bar"; // discards bar
 
user1804599
What is an empty JSON value?
 
@BartekBanachewicz I would add a CLAW_ASSERT(_refCount != 1) too
cos symmetry
 
but then you'd have to add imaginary numbers too
cos symmetry
 
user1804599
Maybe it's UB to compare _refCount to 0 before comparing it to -1.
 
user1804599
10:24 AM
You never know how operator== is implemented!
 
you think this json null value talk is crazy
 
user1804599
@buttifulbuttefly 1 is a complex number.
 
I've been struggling at work to get a agreement on what exactly a 'nilable' string means, specifically regarding a string of length zero
 
@rightfold good for him
 
@thecoshman that's an empty string
 
user1804599
10:25 AM
@thecoshman pick a definition, done.
 
user1804599
If you can't, then don't use the term, done.
 
user1804599
It's important to distinguish between an empty value and a lack of a value.
 
epilogue: I had to use a raw pointer for this variable
apparently someone steals my variable and destroys it
literally making it impossible to use it by value
 
you should do the same to their lunch
 
Should I make a self-answered Q/A about assert in constant expressions?
 
user1804599
10:26 AM
Don't destroy food.
 
@rightfold or to have clear agreement that you don't care and can treat them the same... not that you should.
 
@Columbo Sure
 
and fuck off anyone who says you shouldn't think about 'what ifs'
 
user1804599
@thecoshman then don't make it nullable or don't allow it to be empty.
 
but it's so counterintuitive to say that a value is null
pointers can be null
 
user1804599
10:28 AM
intuition is moot.
 
or references like in C#
 
user1804599
consistency > POLA
 
@rightfold what's the difference?
 
user1804599
lack of special cases > POLA
 
@rightfold vOv I know, it's not a hard thing to solve, you just need people to fucking state clearly what they mean
@AndyProwl real question?
@rightfold what is this POLA?
 
10:28 AM
principle of least astonishment
 
user1804599
@AndyProwl String s = null; indicates a lack of value. String s = ""; indicates a presence of value, which happens to be empty.
 
user1804599
POLA is heavily overrated.
 
user1804599
It's way too subjective.
 
@rightfold Oh, I see what you mean
 
user1804599
You need to pick an audience and if that audience happens to be "total morons" you will dumb down your API to being incomprehensible because POLA.
 
10:30 AM
@AndyProwl that's a real thing?
 
@sehe Ah, I hadn't noticed it, but I guess that's not really a huge surprise.
 
@thecoshman depends what you mean by "real" thing but yes, it's a known thing
 
I wonder if I can use boost.spirit to come up with some way for my ai to recognize input patterns and turn them into "executable code" or some intermediary language only it uses
 
user1804599
.NET has this horrible method called String.IsNullOrEmpty.
 
user1804599
If you need it, it indicates you're working with bad APIs.
 
10:32 AM
@FilipRoséen-refp Ah, btw. concerning addressof, check out LWG 2296
 
user1804599
Also lol it being monomorphic.
 
user1804599
Imagine implementing that.
 
@BartekBanachewicz try using Germain++
 
10:38 AM
what
 
"Count Saint-Germain" redirects here. Also see St. Germain (Theosophy). For other uses of St. Germain see Saint-Germain (disambiguation). The Comte de Saint Germain (born 1712?; died 27 February 1784) was a European courtier, with an interest in science and the arts. He achieved prominence in European high society of the mid-1700s. Prince Charles of Hesse-Kassel considered him to be "one of the greatest philosophers who ever lived". St. Germain used a variety of names and titles, an accepted practice amongst royals and nobles at the time. These include the Marquis de Montferrat, Comte Bellamarre...
 
uh whatever
can you answer my question?
 
> Saint-Germain: The Immortal Count
He was an alchemist who, it is believed, discovered the secret of eternal life
 
user1804599
 
I have a const-ref
it should prolong the life of Noisy
 
10:39 AM
dayum bortak
you learned something new today
take it easy
 
@AndyProwl oh, I guess as a general guideline it makes sense "toString" should return a string based representation, with not side effects. That sort of thing?
 
user1804599
@BartekBanachewicz here:
 
user1804599
Whenever a reference is bound to a temporary or to a base subobject of a temporary, the lifetime of the temporary is extended to match the lifetime of the reference, with the following exceptions:
- a temporary bound to a return value of a function in a return statement is not extended: it is destroyed immediately at the end of the return expression. Such function always returns a dangling reference.
- a temporary bound to a reference member in a constructor initializer list persists only until the constructor exits, not as long as the object exists.
 
> - a temporary bound to a reference member in a constructor initializer list persists only until the constructor exits, not as long as the object exists.
(until C++17)
 
@AlexM. @sehe can tell you :P
 
10:41 AM
this is relevant
oh for fucks sake C++
and now it is to change in C++17
 
@thecoshman I guess that can be taken as an instance of the principle, yes
 
user1804599
I sometimes use toString side-effects in Clojure.
 
basically, minimize the WTFs
anyway rightfold does have a point about POLA being subjective, on the other hand it's not a completely valid reason to dismiss it IMO
 
user1804599
The REPL calls toString, so I can restart my program by just typing r instead of (r) in the REPL by overriding toString. :)
 
@AndyProwl it seems like one of the more fluffy guidelines. Something like "immutable classes are good" is easy to either 'pass or fail', but 'doing what is expected' is non-trivial. It relies too much on interpretation.
 
user1804599
10:44 AM
user=> (def r (proxy [Object] []
                (toString []
                  (println "restarting application...")
                  "")))
#'user/r
user=> r
restarting application...
 
user1804599
:D
 
@BartekBanachewicz what kind of exotic stuff are you doing that you've encountered that
 
@thecoshman Yeah, a bit like SRP. There's always a grain of subjectivity, but there's also a lot of common sense and valid insight
 
user1804599
The problem is when POLA starts introducing special cases because some people consider them intuitive.
 
user1804599
And suddenly your API becomes hard to use because of it.
 
10:46 AM
@AlexM. trying to get our work code to work
 
@BartekBanachewicz Wait. There's an "until C++17", but no "since C++17". Are they going to make those referenced temporaries magically live for an unknown amount of time?
 
user1804599
@BartekBanachewicz Initializer list, not constructor arguments.
 
@rightfold Yes, that's the part I agree with. Picking the correct audience is the subjective part.
I hate when a colleague of mine writes C++ code in such a way to make it resemble C# as much as possible because he finds C# more intuitive
 
@Rapptz have you seen this? nexusmods.com/witcher3/mods/12
 
user1804599
@AndyProwl lol
 
user1804599
10:49 AM
Why doesn't he become a C# programmer?
 
@rightfold He was eventually "asked" to
 
it can tweak a lot of stuff in W3
 
user1804599
Tell him to learn C++.
 
uh what
alsso
 
@rightfold Special cases should be handled to clearly look like special cases.
 
10:50 AM
class X
{
public: void foo()
{
// ...
}

public: void bar()
{
// ...
}

private: // ...
};
 
@BartekBanachewicz Actually, it isn't
 
People should feel bad that they have to handle it in a special way
 
user1804599
@thecoshman They should be not introduced unless they are part of the problem.
 
fuck markdown
anyway, just an instance
 
inside the constructor it is not a temporary, it's an lvalue.
 
10:51 AM
@rightfold hahaha as if no attempts were made
 
it seems the game has a GC running, interesting
 
you are just calling some function with a temporary.
 
user1804599
@AndyProwl Write a tool that checks for that and install it as a pre-receive hook on all Git repositories he pushes to.
 
this shit can really config everything
 
@rightfold I take it as a given these days that no matter how smart a solution you come up with, someone will point out the exception you don't handle :(
but that's just the domain I work in
 
10:51 AM
Someone wrote this
RichString( const WideString& text, const Text::Format& format ) {
    m_string.emplace_back( text, format );
}
 
@rightfold Also his proposal on how to make our code more maintainable was literally "abandon all modern C++ wankeries like exceptions, lambdas, etc. except smart pointers - use smart pointers everywhere"
 
@Griwes no freaking idea
 
user1804599
C# also has exceptions and lambdas.
 
user1804599
Better use them.
 
@AlexM. omg what would blow say
 
10:52 AM
yeah but that's C#
 
@BartekBanachewicz that emplace_back obviously won't move since text is an lvalue.
 
not to talk about spaghetti code and global state everywhere
 
@Puppy yeah. It's a retarded microopt from what I see
 
because "in the end everything's connected so this way it is simpler"
 
user1804599
Fire him, problem solved.
 
10:53 AM
@BartekBanachewicz In the presence of move semantics, if you need to end up with a value of WideString and a value of Text::Format, best just take them by value and then move them into wherever you need them.
 
I'm not a manager
 
@AndyProwl Having everything be connected is the antithesis of simpler ;p
 
Go tell him
 
I would if he were available
 
I've tried for ages
The sad part is that my managers aren't much different
 
10:55 AM
and both push_back and emplace_back move if you have an rvalue
 
not that bad but not even much different
 
@rightfold linky?
 
It surprises me how managers fail to understand the problem with crappy short sited code.
8
 
user1804599
@AndyProwl Tell the manager to fire him.
 
@Griwes ouch
 

« first day (1682 days earlier)      last day (3270 days later) »