« first day (1492 days earlier)      last day (3459 days later) » 

8:02 PM
that shirt is sold out
 
user1646075
but it's supposed to be home-made?
 
Those two things are not mutually exclusive
 
user1646075
bwa-hahaha "Those who feel offended by that shirt should be told to iron it."
 
the site is pretty tiny
 
user1646075
8:04 PM
@CatPlusPlus I know I'd be ramping up production
 
and.. weird looking lol.
 
Not enough Comic Sans
 
user1646075
@Rapptz Damn, I have a stoopit beach-themed office xmas party to attend in a week. That would have been perfect and topical.
 
lol
stupid javascript room and their flags
 
8:08 PM
ignore them
Hi
 
user1804599
HELLO sehe I LOVE YOU SO MUCH HI
 
the Coliru example is still O(N), not O(log N), or am I missing something? (I got to a similar solution that you showed, but it is a pity that Boost.ICL won't support a logarithmic solution). — TemplateRex 6 hours ago
@TemplateRex which one? the first or the last?
@rightføld It's completely mutant. I mean, mutable
 
user1804599
The Coliru example is O(1). No matter how often you run it, no matter the inputs, it will always take equally long.
 
Brillant. You should reply that :)
 
@sehe Hey, why do I get a blue popup on the upper left-hand corner of my profile picture to the left of the chatbox?
Can I review flags inside chatrooms now?
 
8:12 PM
Apparently. Don't ask me. It's your own fault
 
@Columbo One of the "privileges" of 10K+ rep.
 
Yeah, just what I thought
 
You'll soon ask for downvotes to make it go away (or at least feel as negatively about flags as the rest of us).
 
user1804599
Maaaan.
 
user1804599
I wish JavaScript had computed gotos.
 
user1804599
8:14 PM
Oh wait, that's called switch.
 
everything is computed in an interpreted language
 
@rightføld Then the bound can be tightened to Theta(1).
 
user1804599
Nice.
 
user1804599
I have solved the coroutine problem with higher performance.
 
user1804599
Instead of generating bytecode and writing a bytecode interpreter that manipulates a custom stack, I just generate JavaScript code that manipulates that stack instead.
 
user1804599
8:15 PM
Removes one layer of indirection!
 
user1804599
It just has to be a gigantic switch statement.
 
AC Unity is a mess.
 
lol
 
And has a late embargo
Also - Rust input is messy :(.
 
@exitc0de huh?
 
user1804599
8:17 PM
@TemplateRex It appears to be O(1). No matter what stdin/command line arguments/environment I pass to the program, it takes equal amount of time for each input. Am I doing it wrong? — rightføld 5 mins ago
 
hi all
@rightføld are you trolling me? ;-)
 
@TemplateRex lla ih
 
user1804599
Actually O(1) ⊆ O(N), so you're still right.
 
user1804599
But I'm more right!
 
@rightføld You're righter
 
8:18 PM
@sehe 2nd example is O(N), right?
the 1st doesn't show the requested output
so it's either efficient but incorrect, or correct but ineffecient, frustrating library, that Boost.ICL
 
sup biatches :)
 
@TemplateRex Yes, second sample however not very relevant to the answer
 
user1804599
HELLO Tony The Lion I LOVE YOU SO MUCH HI
 
@TemplateRex I wouldn't call it incorrect (did you read the answer?). It's just stubbornly ignoring the incidental requirements :)
 
Why can't I review my own, flagged posts?
Weird
 
8:19 PM
@rightføld Hi
 
@caps ?
 
:O)
 
@sehe ha
 
@exitc0de Assassin's Creed Unity is a "mess" and has a "late embargo"?
 
I'm bored
 
8:20 PM
The embargo was noon day of release.
 
ok, so writing your own combiner would give the OP's exact requirements?
 
It should be the day before release or earlier.
 
review embargo.
 
@TemplateRex I do that sometimes. Chances are that the OP did indeed just want to simply do something with the result
 
And it is riddled with bugs
 
8:21 PM
I need some sort of variant_ptr
 
@TemplateRex It might. You're welcome to waste a lot of time on an XY problem from 2011
 
They created a late review embargo in order to avoid bad reviews disclosing how messy the game was so they could get as many day 0 sales as possible.
 
like the equivalent of union { T* t, U* u }; or something
 
@Rapptz variant*
 
variant<T*, U*>?#
 
8:21 PM
@sehe not 2011, just last week
 
Wow, trying to make sure input in rust is a float is annoying.
 
@TemplateRex Mmm? How did I go so far wrong then. I'm on the phone
 
After a week of learning Rust, it is now my favourite language :).
 
@sehe no I mean, nice effort and I got something like that working myself. I was just wondering why Boost.ICL won't support out-of-the-box equal_range that returns iterators to the original intervals. But maybe it's not in the cards for that library. Although the section in Cormen et al suggests it should be possible
 
@exitc0de Can I quote you as saying: "blah, blah, blah, Rust sure is annoying"?
:-)
 
8:24 PM
@Puppy Not sure. That has no ownership semantics.
 
Except input.
 
@exitc0de Ah, I get it now.
 
user1804599
(cons cat (cons cat nil)) http://t.co/BmmyKhPEt8
 
@JerryCoffin Input in Rust is weird, but its not 1.0 yet, so.
 
reminds me of "but it's beta!" arguments
 
8:26 PM
Its pretty stable, just not very supported yet. Though I don't understand why.
 
@Rapptz It is Beta. Wait--no, it's Rust. Not beta, so no arguments.
 
i've heard beta arguments than that
3
 
If you all hate C++ and use it for software development, wouldn't Rust be a better language? (if there were more tools)
All is a generalisation.
 
@exitc0de define hate
 
@exitc0de Different doesn't necessarily mean better.
 
8:27 PM
Dislike.
Its as fast, and if you don't like C++'s unorganisedness then Rust is/will be cleaner.
Fast is a generalisation.
:P
 
Ell
@exitc0de that's quite a sweeping statement
imho
 
We don't hate C++
 
I don't hate C++.
 
Rust is not as fast in C++, since talking about language's speed is meaningless - languages don't have speed, their implementations have.
 
I just find it annoying sometimes.
 
8:29 PM
We (I speak like I know anybody's opinion around here, but I don't) are not happy with some of its features/the way it is put together
 
I'm always amused when language prophets come in here trying to convince us to convert to their better language.
 
user1804599
misfeatures
 
@Borgleader ...like @Puppy? hides
 
@TonyTheLion Then Rust is put together in a subjectively better way.
 
I wonder if libstdc++ supports std::swap in <utility>
I don't like Rust too much.
 
8:30 PM
@Griwes lol
 
I might give it another try in like 2 years or so but not now.
 
I know nothing about Rust, besides that its name always reminds me of steel that has had too much oxidation occur on it
 
I'm not a language prophet and am unqualified to encourage you to use Rust, just interested in why more people don't use Rust. Its similar to C++ in what it tries to do.
 
user1804599
 
user1804599
Looks yummy.
 
8:31 PM
@exitc0de Does it have templates yet?
 
@exitc0de It's unstable as hell.
 
@exitc0de I don't use Rust because I'm quite happy using C#
 
You'd be hard pressed to find a lot of libraries that work out of the box.
I recall you had issues with this too.
Why would you use a language that isn't even stable?
 
@rightføld Now I feel like eating this
 
8:32 PM
@Griwes Ish, sort of, not sure
 
@Griwes damn you, i thought that was a thing :(
 
What's a generic?
Because it has those.
Whatever they are.
 
@exitc0de Generics are not templates-ish.
@Borgleader :D
We could make it a thing. :D
 
Ell
@Griwes it has macros, idk how much they can do though
 
I know a week of Rust
 
8:33 PM
@Rapptz variant<unique_ptr<T>, unique_ptr<U>>?
 
Ell
unique_prt<variant<T, U>> is shorter :p
 
@Griwes To be fair, I have been known to make changes to accomodate some feedback I've gotten here, also I actually built the language in question.
 
user1804599
@Ell no subtype polymorphism
 
Ell
oh yeah.
 
@Puppy I was joking, you know.
 
8:35 PM
kek
so was I
I mean, me, make changes to accomodate others?
 
And all I can tell you is that its hard to ensure input is a float :L
 
mumble anyone?
 
:D
 
user1804599
Sure.
 
user1804599
Lemme install.
 
8:35 PM
lol
 
@exitc0de Like so?
 
damn
 
@LucDanton ewwwwwwwwwwwww wtf
 
Man, rust code looks so ugly.
 
@LucDanton I cannot read that :(
 
8:37 PM
?
the only weird part is &*line
 
Also I've taken a look into Rust's std.io.fs - it is hella ugly.
 
and I guess from_str::<f64> would be weird
 
(I think &*line is new, alternatives are line[] (feature-gated) or line.as_slice().)
 
the rest reads okay
 
Ok, ref, map, line &*?
 
8:38 PM
Possibly line[..] but I’ve never tried that. Oh looks like that’s not allowed.
 
No idea what any of them do
 
lol
 
@TemplateRex you know, did you think of a useful solution to that? I didn't think of a useful problem to implement that for, so I didn't
 
all this for cin >> mahFloat; ?
 
gotta admit it is a little strange if you look at it that way
 
8:39 PM
@Borgleader My point.
 
@sehe na not really.
 
even scanf does it better
despite its lack of typesafety lol
 
Thats why I want better input
 
except e.g. something like "get all items satisfying predicate present in interval X"
 
@exitc0de if this is your better language, ima stick to C++ tyvm
 
8:40 PM
@Rapptz Eh, from_str is not an analogue of scanf. Seems like an unfair comparison.
 
I mean, why would I need an interesting domain to be interested in an abstract problem? ;-)
 
@LucDanton Well, they were comparing your snippet to std::cin >> float_value;
lol I just pressed the "format" button
it makes it uglier
 
@Borgleader 'Except input.'
 
I assumed line-wise input, but there’s the usual map words . lines stuff otherwise or what have you.
 
@exitc0de input is kind of important...
 
8:42 PM
@Borgleader Only for console test applications - why would you need it for anything else?
 
And no-one in the history of programming got input and output right :/
 
Output is nice and easy
 
@exitc0de er..
 
@exitc0de Erm... text files.
 
@exitc0de so youre telling me its only ugly like this if you read from console? its better for text files?
 
8:43 PM
Looks like a generic stream API
 
@Borgleader Yes.
 
it doesn't seem terrible
 
@exitc0de well thats dumb as shit...
 
And specifically ensuring that console input is a certain type.
Its Beta! :D
 
@exitc0de It's Worsa!
 
8:44 PM
This is what you have to do: stackoverflow.com/questions/24254874/… D:
No language is perfect anyway
Hopefully it will improve.
But that solution is ugly! (stackoverflow.com/questions/24254874/…)
 
user1804599
lol read_line on stdin.
 
user1804599
fail
 
@exitc0de Syntax so much like C++... and yet so very different.
 
user1804599
Double fail actually, one for assuming encoding.
 
Why isn't that as simple as cin >> myFl;
 
user1804599
8:48 PM
It's just as complicated.
 
user1804599
Does lots of unrelated shit.
 
Its easier, shorter.
 
user1804599
Well, it's slightly simpler as it doesn't do whitespace detection and automatic parsing.
 
I'm going to have to write my own function to get input
 
user1804599
Reading, buffering, decoding, deciding the encoding, parsing and localisation must be kept separate.
 
Ell
8:50 PM
^this fo sho
 
user1804599
C++ I/O streams do all of those.
 
Wouldn't want to stand next to them
 
user1804599
putin hates me. Therefore I hate putin.
 
@exitc0de It’s also (typically) useless. You can’t ignore the error-checking (e.g. if(in >> input) { …) that comes with it.
 
8:53 PM
@rightføld Putin loves you hasn't the faintest clue that you exist.
 
I just want to write a program that will retry a loop until user enters a float.
What is the simplest way of doing this in Rust?
:L
 
> retry a loop
kek
 
loop {
continue;
}
 
Ell
I've no idea how to set out my factory!
 
Why don't you go to the Rust Lounge?
 
8:56 PM
No one is there
 
user1804599
Go to #rust on irc.mozilla.org.
 
@rightføld Show us how reading a float from standard input should look like according to you, then :P
 
@exitc0de Maybe theres a reason for that
 
cin >> myfloat;
 
Sorry, but I am specifically asking wrongfold about that :P
 
8:58 PM
float x = cin >> myfloat;
:D
 
That's just no. :D
 
@exitc0de youre trolling right?
right?!
 
What?
No one is replying to me on IRC D:
 
user1804599
If a quantum algorithm with complexity O(X) is run on a quantum computer emulator on a classical computer, is it still considered O(X)?
 
Ell
surely
 
9:01 PM
Stop asking questions about quantum computers and show us how you think reading a float from stdin should look like, dammit :P
 
io.read(io.stdin, my_float); obv
 
user1804599
ewwwwwwwwwwwww
 
user1804599
god no wtf
 
auto my_float = io.stdin.read<float>();
:D
 
maybe now he'll speak
 
9:04 PM
The read stuff is for binary I/O.
 
the way lua does it is io.stdin:read("*n")
 
No one will reply to me in irc D:
Aghr.
 
from my googling
lua assumes binary by default
and you have to specify "b" for io.open
I wonder what happens with io.stdin et al
 
Ell
@rightføld might not be too bad
 
user1804599
Such an API is waaaaaaay to ambiguous.
 
Ell
9:08 PM
stdin might be a PrimitiveStream :P
 
too
 
Result doesn’t seem to implement FromError, pity. I realised my previous example has an IoResult<Option<_>> or some such.
 
Ell
I think boost sink & source is a good api
 
@rightføld We are still waiting for your counterexample, you know.
 
look at this uglyness
explicit operator bool() const noexcept {
    return type == none ?
           false : type == surface ?
                   value.sur != nullptr : type == texture ?
                                          value.tex != nullptr : false;
}
 
Ell
9:12 PM
consume_whitespace(stdin); let float = parse_float(stdin);
 
@Griwes In my assembly language, it's done with a single op-code: RPM. Actually, that's the only op-cod it has. It stands for "Read Programmer's Mind".
2
 
Ell
@Rapptz man
 
@Rapptz Who wrote that? Why not just a chain of &&s? Duh.
 
:p
I did.
 
lol
 
9:13 PM
I don't think chain of && will work
 
Sure it will, why wouldn't it
Oh this is a switch
 
yup
 
Just use ifs like a normal person
This is nigh unreadable
 
I know, I wrote it like that on purpose (I already rewrote it to a switch)
 
Evening
 
9:16 PM
hi
 
Good evening!
 
Ell
Searching for wiki related things is really annoying
 
Do someone know what does a ~ b means in "Couldn't deduce type (a ~ b) of..." in Haskell?
 
Ell
wiki backend library gives Cairo and SDL :L
 
@Jefffrey Type equality
 
9:19 PM
Thanks
 
9:35 PM
mumble went down?
 
yea
seems like
 
nomic is down
I repeat, nomic is down
 
so basically everything is down, my world is down, my life is down
 
your wife is down
 
and dirty
 
9:36 PM
...on me
I'm sorry.
nomic is up
 
@Jefffrey You are a sorry excuse for a human being.
 
VM restart
 
@JerryCoffin :c
You are always so mean.
 
Also Murmur is shit and fails to set up a listening socket properly for the first time
 
@Jefffrey For the Nth time, I'm median, not mean.
 
9:38 PM
hmmm
I wonder if it's possible to convert this runtime error into a compiletime error.
 
I should remember not to let you make that joke next time.
@Puppy What error?
 
I'm 99th percentile
 
well, I have a fairly typical situation
 
should countries with massive number of cows contribute more to the climate change fund? after all cow farts & burps contribute more to the greenhouse gas </sarcasm>
 
got an object meeting interface X, need to perform operation for all derived classes, operation does not logically belong to derived class.
 
Ell
9:39 PM
who is good at trains?
 
nationalrail.co.uk
 
robot
 
currently I added a handler to a map for them
 
@Puppy derived classes of what
 
the interface.
 
9:41 PM
So the interface is a base class?
 
yep.
 
ok, go on..
 
I guess the core issue is that if you don't make an intrusive change, you can't force the class to implement or have associated with it any behaviour.
 
Ell
I think peak times are just in the morning but I can't tell from anything I read :L
 
@Jefffrey Indeed you should. If you don't stop, I'll have to look up some new form of average to be instead, and my learning something new...well, that can't be good.
 
9:43 PM
maybe I could have an optional extra interface that you can inherit from that has a template function on it, and then if you didn't declare and implement a specialization for it, then the compiler will error on it.
 
I have no idea what "operation does not logically belong to derived class" and "intrusive change" means.
 
it means that if you offer the operation as part of your interface, then you couple the interface and all derived classes to that operation
whereas there are some derived classes that could conceivably exist that don't need to offer this functionality.
 
Ell
@Puppy do you mean c# style interface when you say interface X?
 
@Ell Does it really matter?
it's a base.
 
Ell
@Puppy yah, you might mean a generic interface
I didn't know if you meant a base class or just an general interface
 
9:49 PM
that doesn't make any difference in this context.
 
It makes a difference if you then start talking about derived classes.
That was my misunderstanding in the beginning.
 
Implementing an interface is equivalent to deriving from a class that has no implementation
So it doesn't matter
 
the exact semantics of the base class don't matter except that they have no particular relation to the operation I want to perform per derived class.
 
user1804599
Introduce another base class in between.
 
Ell
@Puppy can't you just make a free function?
 
user1804599
9:57 PM
Or use multiple inheritance.
 
Ell
that takes X and does an operation
 
yeah but then how are you going to handle that operation on each derived class?
given that each derived class needs it's own customized implementation and there's no generic implementation that makes sense.
 
Ell
oh
visitor?
idk
 
If derived classes need to implement it, then just make it part of the interface
 
elections are over
 

« first day (1492 days earlier)      last day (3459 days later) »