« first day (1462 days earlier)      last day (3469 days later) » 

Ell
12:07 AM
h'okay clang is done!
at least I thought.
 
Are you trying to build it on Windows?
On Linux and OSX I never had any problems?
I've had more trouble building GCC.
 
Ell
I'm building it on linux
and I think it's just a test that's failed
/usr/local/src/llvm/tools/clang/tools/extra/clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp:250:26: error: no matching constructor for
      initialization of 'llvm::raw_fd_ostream'
    llvm::raw_fd_ostream FileStream(FileName, ErrorInfo, llvm::sys::fs::F_Text);
                         ^          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
hmm. maybe not a test
but an extra, so I shouldn't need it, right? :P
@StackedCrooked I've found GCC to be super easy
literally ./configure; make; sudo make install
 
Did you check out a release branch or trunk? (Trunk can be unstable.)
 
Ell
yeah it's trunk
probably why
although, isn't breaking the build a super bad thing in software places?
 
Ell
12:20 AM
I think it's just because I checked trunk out
but yay finally have gcc 4.9.1 and clang 3.6.0
it's just the compilation time that's the proble,
that means I can sleep
night!
 
Ell
12:34 AM
Ah I'm kidding myself
Instead I'll stay up for no reason
I love androids time selection widget
 
1:20 AM
How fast do you guys type?
 
Ell
100wpm approx
 
@Nooble my typing and brain bottleneck each other from time to time
depends on the situation
 
@Ell I feel like a peasant compared to that.
@Ell In bursts or reading and copying?
@AlexM. Yeah. I feel like typing on my own I can yield about a 90 to 100
Reading I get around a 60 to a 70
 
Ell
1:42 AM
@nooble that's reading and copying
 
I'm not sure how to implement the variable width/precision stuff for printf
there's no way to get a type of a tuple based on a runtime index
 
Ell
Isnt it all done at compile time?
 
impossible for this because you can feed it a run-time string
 
Ell
Do you know the type of the argument to print at compile time?
 
it's type agnostic
it's just a wrapper around iostream
 
Ell
1:47 AM
But let's say you want to print a tuple
You pass in a tuple don't you? Not a void* or boost::any
 
I store the arguments in a tuple.
 
Ell
What is the problem with that?
 
nothing
 
Ell
Oh
What are you not sure of how to implement? O.o
 
the variable width and precision stuff in printf
printf("%*.*f %*2$.*1$f", 3, 4);
 
Ell
1:51 AM
I've never used printf :P
I'll attempt to read
 
first string is %*.*f so the first * tells it 'get the next variable and that is the width' the second .* tells it 'get the next variable and that is the precision'
the second string is %*2$.*1$f which broken down is *2$ and .*1$
 
Ell
Oh right
 
which means the second index of the parameter list is the width, and the first is the precision
complicated
make sense?
 
Ell
Yeah
But I don't see what in particular about is hard to implement?
 
10 mins ago, by Rapptz
there's no way to get a type of a tuple based on a runtime index
 
Ell
1:54 AM
Well, I mean I don't see the road block
Why do you need to get the type of the tuple?
 
how else am I going to extract the width and precision from the tuple?
I think I could make an extractor visitor or whatever
lemme check
 
Ell
Meh, idk. I'm kinda lost as to what you mean
 
lol
given a tuple -- (10, 11, "hello", "test") how would you get 11 at runtime?
try it out
 
Ell
Copy it into a vector
 
what?
 
Ell
1:57 AM
Get the 2nd element from the vector :3
 
it's not homogeneous
the point of a tuple is that it's heterogeneous
 
Ell
right
store them in a boost::any :P
that's what I did
 
terrible idea
 
Ell
or void* :P
you have to use one of those, surely
if it's at runtime?
it's impossible to get the info a different way
there can't be any other way
oh wait a minute
@Rapptz I'm confused again now :(
when you say get 11 at runtime, you mean get the item at index 1 at runtime?
 
yes
 
Ell
2:02 AM
right okay
 
I think I figured it out
 
Ell
@Rapptz with a visitor?
can I see?
 
in a bit
 
Ell
because I'm just using boost::any atm
I'm p sure I need to anyway
 
yeah I got it working
int main() {
    std::string str = "Hello World!";
    fprint(std::cout, "[%*s]", 15, str);
}
does indeed print [ Hello World!]
 
user1646075
2:12 AM
@Nooble with or without counting all the backspaces?
 
Ell
How did you do tuple thing then?
 
the tuple is (15, str) :v
 
Ell
I mean getting an item at index n at runtime
 
I had a way to do visitation based on runtime index on a tuple.
 
Ell
Without copying it into an array or vector or homogeneous container
 
2:13 AM
so I used that technique on a different visitor
 
Ell
Can I see that code?
 
I think the printf code has too much in it
I can make a shorter version for ya
cause this printf stuff is 280 lines and counting
 
Ell
I just want to see the runtime indexing of a tuple
 
some caveats
the function has to be generic and work for every type in the list (just like a boost visitor for variant)
so you have to use SFINAE to nullify the garbage overloads
 
Ell
Cool
 
2:25 AM
yup
 
Ell
I'll use it on saturday probs
Template stuff is cool
I wish I was good at it
:P
 
it's pretty easy
I learned like a year ago or so.
 
Ell
Its not too bad
I'm just learning now
But you have to think functional
I'm not so used to that
Pure functional anyway
 
Also requires thinking abstractly
 
Ell
I'll modify my open multi method Saturday to use tuples instead of std vectors
 
2:29 AM
Think that confuses some people
 
Ell
If its possible. I'm not sure it is
 
I don't know what your problem domain is.
 
Ell
Actually I don't think I can do it
 
What are you trying to do with your open multi methods?
 
Ell
I have to store functions of variable number of arguments
 
2:34 AM
yeah you're fubar there
I'm not storing callables in the tuple
 
Ell
And as you stated earlier containers are homogeneous
 
actually
 
Ell
So there is no way but to make them accept a std::vector<boost::any>
Which is what I do currently
And it works :3
But I haven't implemented the most important feature yet
Which is choosing an overload based on the derivedness of pointer/reference arguments
@rapptz actually?
 
2:52 AM
oh sorry forgot
but it wasn't helpful dw
 
3:11 AM
what do you expect printf("[%*1$s]", 15, "hello world") to print?
assuming %s is a 'generic' verb (well, all of them are)
this doesn't work in regular printf btw
 
3:49 AM
why is mac saving changes without user's explicit permission?
Now I have lost the content of a text file and I don't remember what was on it ...
 
4:05 AM
 
4:35 AM
@Ell That’s what you should focus on, i.e. the essence of the problem. Restrict yourself to a fixed number of arguments if you have to.
E.g. single dispatch has a fixed number of arguments.
 
4:54 AM
@Rapptz 1$ selects the argument by position. But if you wanted to print hello world then it should have been 2$, right? I am not sure what the asterisk does.
Aha!
I had to consult the man page.
It would probably print first 15 characters of the string?
 
it prints 15 right aligned with 13 spaces
 
Of course.
 
*1$ says 'width is based on first parameter' and then the %s says get the first index and print it
not sure it it's good or anything
 
But your format is s, that does not fit the int...
Weird.
 
2 hours ago, by Rapptz
assuming %s is a 'generic' verb (well, all of them are)
:p
 
5:07 AM
Eh.
 
I think if Boost.Format supported the precision and width specifiers in printf it'd probably print the same thing
but atm all it prints is [15] and silently ignores everything else
> Width or precision set to asterisk (*) are used by printf to read this field from an argument. e.g. printf("%1$d:%2$.*3$d:%4$.*3$d\n", hour, min, precision, sec);
This class does not support this mechanism for now. so such precision or width fields are quietly ignored by the parsing.
so is it a bug or a feature? :p
 
 
1 hour later…
6:19 AM
@Rapptz wut. Does that syntrap work with anything existing?
Good morning
 
Good morning.
I feel bad for downloading Synergy without paying... :(
 
@StackedCrooked "I am a ghost!" Nice
@MarkGarcia That's a start
@Ell hm. So, you can select more time if you run out?
 
@sehe No.
I only put the string there to fool people.
 
@Ell wow. How do you ever put up with mobile o.O
@Rapptz Was that sarcasm? I don't know what happened here
 
No?
printf("[%*1$s]", 15) prints the same thing.
 
6:26 AM
@Rapptz Ah, you were bikeshedding? Ok, now I see, I think
@Rapptz with only 1 vararg?
 
yeah
I don't know what to make of it though
it makes sense to me lol
but that doesn't make it a good thing
 
Well. That's something :)
 
is %t taken
yup :(
 
@Rapptz Oh wait, is this about C11?
test.cpp|5 col 25| warning: ISO C++11 does not support %n$ operand number formats [-Wformat=]
 
nah it's my own printf :)
the conversion specifiers don't actually do anything outside of setting some iostream flags (a la Boost.Format)
 
6:30 AM
11 mins ago, by sehe
@Rapptz wut. Does that syntrap work with anything existing?
So, the answer was yes (but it doesn't use the string)
@Rapptz I'm starting to get it now
 
Well it doesn't work with Boost.Format because it silently ignores all variable width/precision specifiers.
 
Still an interesting warning from gcc 4.9 there ^
 
So that 'syntrap' only works with me.
 
xD That's exactly what I asked :)
 
I thought by 'existing' you mean 'existing standard printf implementations' :p
 
6:32 AM
It's clear now. You might have a printf fetish (like I have a Boost Spirit fetish)
@Rapptz Does yours not exist? Now I'm confused again
 
Let’s not be harsh here.
 
I have a thing with format strings.
 
@LucDanton Good morning
 
I think I'll make this syntax my own printf variant that would be documented
 
sup
 
6:33 AM
I don't really care about printf compatibility too much.
 
> error: cannot convert 'std::basic_ostream<char>' to 'bool' in return
 
static_cast?
 
@NikkiChumakov I cannot (at the moment). And I probably won't find the motivation. There is something in Boost Phoenix, though, that tells whether a Phoenix expression template is "stateless" (maybe I half-remember this being the case if the type of the expression is default-constructible?). If that's the case, then there is no issue storing it. Otherwise, all bets are off. There is a post by Eric Niebler himself detailing this, IIRC. — sehe 7 secs ago
@LucDanton ^ Oh hey, look what the cat dragged in
 
Gives me pause to think on explicit returns.
 
why?
 
6:37 AM
> In short: we'll be stuck in this "halfway" land where we can have nice things, but with some pretty constrained restrictions.
That’s why I’m reinventing everything!
 
Good! Good! Don't let me interrupt you :)
 
is the printf("[%*1$s]", 15); thing that bad?
 
Don’t think there is anything wrong on your end. I don’t like *+varargs period.
 
This might be the post I remembered: Static functions from boost.lambda or boost.phoenix. The goal there was slightly different, so you'll have to see through that to see how it all applies here. — sehe 46 secs ago
 
I use tuples!
 
6:40 AM
== English == === Phrase === forget, when up to one's neck in alligators, that the mission is to drain the swamp (idiomatic) To lose sight of one's initial objective, becoming caught up in subtasks or in tasks only tangentially/orthogonally related to the initial objective. ==== See also ==== yak shaving bikeshedding...
 
@Rapptz I dislike convoluted syntaces. It's maintenance intensive and not very clear. I do like .NET's format strings, e.g. Complete with extendability
 
@Rapptz *+variadic then.
 
@TonyTheLion I can how you got there
 
Oo, that’s a fun one. Can you build requires(X x) { x = {}; } from smaller concepts/traits?
 
@sehe You a word
 
6:55 AM
Wow Synergy this is AWESOME!
I'm really gonna pay you big time someday!
 
7:12 AM
I am markiing your words
 
Please do. Seriously.
 
@Rapptz So you what? Implemented printf on top of iostream which is implemented on top of printf?
 
I don't think iostream is implemented on top of printf.
it's too different for that
 
Boost::format is on iostream, which can ignore stuff if it wants
iostream takes hints instead of commands
 
user1804599
Dammit.
 
user1804599
7:20 AM
Why is operator@ not a polymorphic functor. :'(
 
@Rapptz I think I have once debugged streams and some of the facets AFAIK do use sprintf() for some number formats. At least in some version of MSVC.
 
I don't think libstdc++ does
 
@VáclavZeman Can (almost) confirm.
 
yeah it doesn't seem like libstdc++ does
 
		int _Count = _CSTD sprintf_s(_Buf, sizeof (_Buf), "%.0Lf",
			_Val);	// convert to chars
 
7:29 AM
so lazy :p
 
In C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\crt\src\xlocmon
 
I don't have VS anymore.
what does that function do?
or well source file
 
user1804599
It printfs to a string instead of a file.
 
That's monetary facet do_put(). It prints your pay check!
 
I know what sprintf does bud.
 
user1804599
7:31 AM
Me too.
 
xlocnum has similar instances. This one was just the first one in my search.
 
libstdc++ does something else it seems
 
user1804599
 
Hm....
 
I see no sprintf!
and digging around _S_format_float is not what I thought it was
  // The following code uses vsnprintf (or vsprintf(), when
  // _GLIBCXX_USE_C99 is not defined) to convert floating point values
  // for insertion into a stream.  An optimization would be to replace
  // them with code that works directly on a wide buffer and then use
  // __pad to do the padding.  It would be good to replace them anyway
  // to gain back the efficiency that C++ provides by knowing up front
  // the type of the values to insert.  Also, sprintf is dangerous
  // since may lead to accidental buffer overruns.  This
I did find this comment though.
 
7:43 AM
@Rapptz It is obscured. I have tracked this done: _S_format_float() and its use. I cannot find __convert_from_v() right now.
TBH, I do not see why they would not use existing formatting functions if they could.
 
@Rapptz Do you have things like SignedIntegral? Where do you put those?
I have a concepts/category for the primary categories and I think I want to leave it at that.
 
Nope.
I have stuff like make_signed
which isn't really relevant lol
 
404
 
7:52 AM
That’s a builtin though ;)
 
 
works now
had NoScript
 
So it’s a printf on top of iostreams on top of the builtin that implements everything anyway? :Þ
 
1 hour ago, by Luc Danton
Let’s not be harsh here.
 
I’m actually curious if those builtins actually do something or are hooks to the system.
 
7:54 AM
@LucDanton No. The built-ins are magical but for the more complex non-constant formats they forward to the C library functions.
 
That makes sense.
 
Did anyone spot the issue with that fine Cabernet Sauvignon yet? Something tells me that's not a very classy bottle
 
Is it the lack of date?
 
@Mikhail I was wondering as well, I wanted to ask @sehe but got distracted...
@sehe "Lore ipsum dolor..."
 
@VáclavZeman Yay. You get the bottle! /cc @Mikhail
 
8:05 AM
I’m planning to get rid of all the placeholder types I can soon. For decltype(auto) that’s fairly easy to look for, but how do I go about it for auto (with no late return type)?
 
@VáclavZeman lol
 
Its worth like 4.99 at Aldi right?
 
@sehe Yay! Looks like somebody used TeX to typeset it? :)
 
To be completely honest, I don't think it's authentic. The Lorem text appears much straighter than the curved label?
 
8:07 AM
Also the wine from Aldi is cheaper then grape juice...
 
@sehe It seems so.
 
@Puppy I suppose this video might change your perspective on racing a tiny bit.
 
I read that as "racism".
(not implying anything)
 
Wooo
> Get started with Myo scripting using Lua!
> Now that over half of Myo Developer Kits have shipped, let's dig into the code! In addition to the base libraries for Windows, Mac, iOS, and Android, we've also implemented a very simple scripting interface directly into Myo Connect on Mac and PC. Written in Lua, these scripts allow you to easily capture Myo data and push it to existing applications in the form of key presses or mouse commands.
cool cool cool
 
I just want people to be aware of the limits and pitfalls involved when doing higher-order combination of TMP-heavy libraries in general, and using auto with expression templates in particular. — sehe 50 secs ago
/cc @LucDanton
 
8:13 AM
TMP is a bit of a red herring.
 
@BartekBanachewicz 1:38 bit, fire fighters of the Czech Republic. TBH, I do not see what should change in my perspective? It is a PR brainwashing clip with "feel good" pictures from India and Africa.
 
> Define small unnamed function objects at the actual call site, and more.
Boost.Phoenix tagline in the list of libraries.
IOW, if it persists for longer than just the call sites, you’re in trouble.
 
@LucDanton true, added it
 
@BartekBanachewicz This is what Youtube offered me after watching your linked video. I find that much more interesting. :) I love the way she looks, the suspenders and all. :)
 
@sehe I completely relate to the disbelief the OP. You do have to read between the lines to figure out that Phoenix (as well as the Proto defaults) are designed std::for_each(a, b, /* cute expression */) and assume it as the default. Which is crazy when you have things like lambda and let, which just beg to partially evaluate.
 
8:19 AM
@LucDanton Yes. I'm also quite sad about this
 
And I don’t think I can find the explanation the OP is asking for. There is a good soft argument though: prior to C++11, you have to go out of your way to create dangling nodes (well… if we ignore Boost.Function :s). So in C++03-land it was assumed to be a relatively harmless ‘optimization’.
 
Another thing is that this is quickly becoming a dominant problem encountered in
 
Well, who wants to bother with C++03? :)
 
10 hours ago, by sehe
Wow. The number of cases where people push into UB with Proto/Phoenix/Range/Spirit due to expression templates having dangling references is really growing by the day.
 
Did you know I reinvented a lazy-eval EDSL to dodge this at some point? :Þ
The silly compile times made me ditch it.
 
8:26 AM
@LucDanton Not as such. I have come to assume that whatever TMP magic library you have done a better version of it at some time :/
 
sbi
8:38 AM
@MarkGarcia He definitely is someone else. (I follow him on twitter and he has a completely different personality.)
 
@sbi Reminiscing huh? ;)
 
sbi
@MarkGarcia I just ran into this when I browsed the transcript. There was a time I wondered about this, too, but then I saw the differences. If that is the same person as LRiO, then this world truly is in deep shit.
 
user1804599
dammit
 
@sbi "I follow him on twitter" But ! I wonder what made you follow him.
Oh Germany.
 
sbi
@MarkGarcia His tweets, of course.
 
8:45 AM
oh
 
sbi
oh
 
I know the difference between that tomalak and LRiO
tomalak twits and LRiO twats
 
@sbi Where does the belief that they're the same person come from? I've wondered about it a couple of times, mostly because they seem different, but I feel like people keep implying they're the same, and then I get confused :D
 
@Abyx I should have guessed that that's bound to come.
 
@Rapptz Here we go, concepts!
 
8:47 AM
yeah, someone had to say that joke
 
sbi
@jalf In this case, it came from a posting by @Mark here. In general, it's probably because they have the same name?
 
they do?
 
sbi
Stop pulling my leg.
 
I'm not. "Lightning Races in Orbit" is not the same name as "Tomalak". If they have other aliases, I haven't paid enough attention to either of them to realize it
 
there are two Tomalaks
 
8:49 AM
aha
 
sbi
@jalf Stop it!
 
@LucDanton Neat.
 
@sbi yeah, like I said, I got the impression they were the same, but I was never sure why
or, well, if LRiO used to use the name Tomalak as well, that explains a lot
 
@Rapptz There are range concepts as well somewhere else, but I’m a bit disappointed with D-style ranges these days so let’s not bother.
 
sbi
@jalf Just click on his name besides, e.g., this message.
 
8:53 AM
@sbi Ah, TIL :)
 
@LucDanton :<
Why?
Are you a fan of Niebler ranges?
 
Random-access ranges don’t make too much sense. It’s been bothering me for a long time (without really knowing why), and with Mr. Niebler’s work it’s starting to coalesce into something.
 
Niebler has RA ranges too
 
@Rapptz I don’t like the premise of ‘let’s reuse iterators, whatever that means’, but the result has some compelling qualities.
@Rapptz Not D-style. Iterator-style.
 
Ah
 
sbi
8:56 AM
Ah
 
well, it's good to know that the Tomalak I see being helpful and sane on SO isn't the same as LRIO. I can stop being puzzled about that now :)
 
I tended not to worry about the awkwardness of D ranges because I was looking at it from the perspective of a range writer or (end-)user, but not an algorithm writer (because that’s hard). I’ve written lower_bound & friends though and the awkwardness really hit me then.
 
Didn't know you guys are so emotionally attached to tomalak, seriously, if you miss him that much you should just go & beg him to come back
you people are sad
 
@Rapptz lower_bound and others, if you want to take a peek.
 
8:59 AM
@chmod711telkitty yeah, you're much better than him
 

« first day (1462 days earlier)      last day (3469 days later) »