« first day (981 days earlier)      last day (3972 days later) » 

6:00 AM
rand(dims or [dims...]) maybe?
 
Oh, good thinking. I'm noticing rand((Int64...,),).
julia> rand((1,))
1-element Float64 Array:
 0.518263
 
ubuntu has so many updates that it broke update manager
haha
 
julia> rand(())
0-dimensional Float64 Array:
0.255644
In 0.2.
 
Can you Array{Int,0}(0)?
 
Nope.
 
6:04 AM
julia> import Random.rand

julia> rand(::()) = error("no nonsense")
# method added to generic function rand

julia> rand(())
ERROR: no nonsense
 in rand at none:1
Fix'd.
 
@Aboutblank: There are no updates for me on 13.04 today. You must be a lot behind.
 
@LucDanton Somehow reminds me of the line from the video: "This is really an example of how awesome Ruby is. But if you ever use this, then: Wat!"
 
6:22 AM
@wilx yeah I just installed 12.04 on my laptop.
 
Lol.
I do not understand how to use Clang in the slightest.
 
Ell
I didn't throw up yet still
 
Great; stop drinking before you do. :3c
 
Ell
I stopped hours ago
But its going to catch up :3
Gaaah
 
6:40 AM
@Borgleader Turns out Clang has options for setting its ABI compatible to MSVC, so we don't have to worry about too much craziness with VC++ versus Clang/GCC ABI conventions.
 
6:55 AM
The OpenGL API is strange. glShaderSource takes in a string which contains a whole file. If length is NULL, each string is assumed to be null terminated. If length is a value other than NULL. Are they trying to save 1 char out of 80?
 
@Mikhail Hmm?
 
Ell
I thought that parameter was the delimeter character
If you pass null its null terminated, if you pass. 69 its 69 terminated
 
@Ell const GLint *?
 
Ell
I can't remember, I'm still dizzy
 
7:03 AM
Maybe the OpenGL people are full of shit
 
Ell
Maybe they want it to be easier to pass the string how you like
Idk
 
7:19 AM
Hm.
@Rapptz People be majorly trippin', yo.
@Telkitty猫咪咪 You're alive!
I guess the hike didn't kill you after all.
 
This was an easy hike ...
@ThePhD hey!!!!!!!!!!!!
But there was a fair a bit of 'mountain turtling' - climbing up slowly with your arms and legs while carry your tent.
 
Hm.
I've never been hiking, so that actually sounds kind of fun.
 
5 hours each day
 
Not too shabby.
 
Ell
I'm dyingg
 
7:26 AM
@Mikhail No, they're supporting almost any format you might want to use (keep in mind, OpenGL is intended to be language independent, and what's simple in C or C++ isn't necessarily so easy in every other language).For C or C++, you almost always want to store the whole shader in one NUL-terminated string, so the length parameter will just be NULL. If you're using something like Pascal that normally uses counted strings, you'll probably prefer to use them here.
Well, I think I'm going to pack it in for tonight. Be good!
 
7:43 AM
Night!
@Telkitty猫咪咪 For 2 days?
 
yeah 5 hours each day
 
Ah.
@KonradRudolph Can you have a namespace inside of a struct?
struct A {

     namespace B {

     } // legal?
};
 
no
 
Ah.
 
why would you want a namespace inside a struct?
 
7:54 AM
I don't want it, was just checking if it was possible.
 
namespace::class::staticvariable
 
Mmm.
 
8:31 AM
Oh, no on SO :(
 
8:48 AM
@Mikhail maybe you are forgetting how old ogl is
 
8:59 AM
I have a C++ program where I'm passing pointers to everything in my functions. I've posted two questions in the past 3 or 4 months, and both times people told me I should be passing everything by reference. Is there a good reason why?
My code is like 2000 lines long and works perfectly. If I'm going to go back and change everything, I'd like to know why it's a good idea, that's all.
 
No null values, and unambiguous semantics regarding ownership.
 
Not sure what you mean about the semantics
Oh, also, are there any efficiency repercussions either way?
 
Ell
No
 
Old-fashioned C++ programs (as well as C programs) may use T* to designate a 'sink' argument that the callee is in charge of properly disposing of.
 
hey there!
i'm on a dedicated server, using Debian
 
9:02 AM
You can't know beforehand from just seeing that a function accepts a T* though. There is no such ambiguity with T&.
 
Oh. Okay, got it. I don't think I'll be changing the code then, I'll just keep it in mind for the future. Thanks
 
can you suggest some tips for security and load balacing please?
we are upgrading to Debian 7 actually..
 
@EricTressler Something to keep in mind is that the original creator of references (here used in a wider meaning that encompasses both C++ pointers and references) called the null reference his 'million-dollar mistake'. He later revised it to a billion-dollar mistake (inflation is pretty wild).
 
Hmm.. what about something like a linked list? What should the end node's "next" pointer be to, if not NULL?
 
The mistake not being 'null' but being the 'null reference'.
 
9:07 AM
it seems pretty hard to make a data structure out of generic objects without null pointers
oh
 
9:26 AM
@EricTressler what he regretted was the notion of all reference types being nullable. Null is useful at times, but it should be something you actively opt in to, not something that is available on every type you use
If a function expects an Address, or a Person, or whatever, it should be a syntactic error, caught at compile-time, if you pass in null instead.
 
@ThePhD dw2 is GCC's preferred exception handling mechanism //CC@DeadMG
DWARF is indeed a debug format as well, but that's at version 4 IIANM.
@Borgleader What do you mean by that? What would Sublime Text 2 need from a Clang build?
@EtiennedeMartel I used to build up to date toolchains and upload them to SF.net and promote them here.
Now I just use mingw-builds.
Because as the @cat said,
Jun 16 at 17:30, by Cat Plus Plus
I switched to mingw-builds because @rubenvb is lazy and doesn't want to do multilib.
he had a point, so I followed suit.
There. My duty here is done. Speak when being spoken to.
 
Ell
9:55 AM
The lounge is dead
 
@jalf Worse: in most languages that followed that idea it isn't even opt-out. It's just fuck-you-you're-stuck-with-it.
 
Ell
hi Bartek!
 
@Ell not the room you are looking for?
 
Ell
10:06 AM
I don't know what you mean? o.O
 
ergh... glm is not playing nice for me
 
Ell
why not?
 
compilation error in a glm header
 
@thecoshman What compiler?
 
gcc version 4.7.3
 
Ell
10:09 AM
Oh o.O what error?
 
Wtf does "o.O" mean?
 
@Ell a redefinition error dealing with glm's 'is_int' functions
I am writing up a SO question
 
@Mikhail goggly eyes
aarggh
the first image on Google Image search for “o.O” is … disturbing
actually, most of them are
wtf
 
if there are any ninjas around who fancy helping me with glm, take a peak
 
20 mins ago, by Ell
The lounge is dead
 
10:22 AM
 
@FredOverflow ¬_¬ you're pushing it
 
That wasn’t the picture I meant …
 
@FredOverflow ¬_¬
 
@KonradRudolph Well, there's lots of disgusting medical stuff, but I thought I'd rather post some boobs.
 
10:24 AM
well thanks for that ^^
 
boobs are just blobs of fat - with some glands and nerves & stuff :x
 
@thecoshman Have you ever put ¬_¬ into Google image search? :)
@Telkitty猫咪咪 with nipples!
 
Ell
@telkitty and mammary glands and nerves and stuff
Fat doesnt go hard when its cold
 
@Ell Butter sure does get hard in the fridge.
@JerryCoffin Actually, a pointer is just the phone number. If you have a piece of paper with a phone number on it, it's a pointer variable.
 
fat does go hard when cold - look at butter
 
10:30 AM
1 min ago, by FredOverflow
@Ell Butter sure does get hard in the fridge.
 
¬_¬ god damn you @Fred
 
What possible use does an octocup have? You never have to rotate a cup by more than 22° again or what?
 
@FredOverflow what if eight people were say around a table trying to share a mug?
you can't expect them all give it a slight turn ready for the next sipper
 
Is that a concurrency problem like the dining philosophers?
 
it's more a through put problem
concurrency would be solve via straws silly
 
10:43 AM
oh wow I missed the Systems Programmer Invasion yesterday.
 
Ell
Dang. Okay, fat doesn't go hard when you fondle it and put it in your mouth
 
That's what she said (unfortunately ;_;)
 
Ell, why do you not get a customized avatar - generic ones make users look newbish ... kinda
 
The room has become less pleasant lately..
I have been spending less time here.
Maybe these two things are correlated
 
Lounge was cool last few times when I was here (Thurday/Friday)
 
10:54 AM
@FredOverflow hey, I remember you wanting to buy an interview preparation book, is that right?
 
Hi, yersterday I made this question but nobody answered,could you resolve my doubt please? consider A a class and B its subclass, A*a1=new A();
A*a2=new A();
B*b=new B();
a2=b;
a2=a1; is this correct? a2 dynamic type after a2=b is B, and at runtime a2=a1 is a possibile assignment?
 
Jun 13 at 13:43, by thecoshman
New here? Why not spare some heartache and read the newbie hints.
 
@newbie we didn't answer because that question sucks
you know, we read the chat thoroughly
 
@newbie post on:
 
oh man it feels so good to be doing 3D stuff again
 
10:59 AM
ok, sorry for have tried to stole 5 seconds of your life with a dumb question that sucks, bye
 
@newbie you wouldn't learn a thing if I answered you
 
user142019
@newbie bye.
 
user142019
Hope to never see you ever again!
 
user142019
</asshole-mode>
 
user142019
inb4 he thinks I'm calling him an asshole.
 
11:06 AM
@bamboon The Google Resume? Yup, bought and read it. Why?
 
Ell
Hi @rightfold
 
user142019
Hi @Ell
 
@rightfold inb4 would be a great name for a programming language that anticipates the programmer's intent.
 
@rightfold Hi Joe. Hi Mike. So you've fixed the bug?
 
Ell
I keep forgetting he calls himself STL
 
user142019
11:11 AM
Lambdas in C++ suck.
 
not as much as assignment operator
@Ell I've experimented with GLId a bit yesterday
the conclusion was that template is fuckingly crappy there, and type erasure would work better for deleter
 
@rightfold Syntax and lack of polymorphism?
 
user142019
HOFs in C++ are terrible.
 
@FredOverflow latter fixed in C++14
 
user142019
@FredOverflow both, no expression bodies, and there's no decent way to take functions as parameters in general.
 
11:13 AM
OOP is terrible
 
user142019
You have std::function, which in some cases requires explicit conversion, and you have template<typaname F>, which accepts every type ever which is terrible.
 
user142019
OOP is not terrible.
 
People make it terrible
 
Jun 13 at 13:43, by thecoshman
New here? Why not spare some heartache and read the newbie hints.
 
How to suck horrifically? Oh wait, you should already know that.
 
user142019
11:13 AM
It's terrible when you have to do something that is not simulations.
 
I recently learned about Entity Component Systems
 
user142019
Sounds like Java.
 
OOP is terrible without functional and generic traits
 
Yeah, it's the "component" part isn't it
Sounds fluffy
 
and the Entity.
 
11:15 AM
Running mkvmerge is probably not a good idea over a wifi networked samba read/write location
 
It's really good though
 
user142019
What does it do?
 
user142019
Because the name is less descriptive than the brown substance that leaves my ass daily.
2
 
The concept is to have all objects in a game based on components, meaning you'd have structures with pure like like Clickable, Hoverable, Sizeable, Positionable
 
user142019
You cannot do that.
 
11:16 AM
How to get the hint?
 
user142019
How can you assign a pointer to an array.
 
making stuff in large scale projects becomes easy as fuck
 
user142019
They are completely different types.
 
@Magtheridon96 i think there's something fundamentally wrong in it
 
@rightfold You mean I have to write return? Wasn't that also going to be fixed?
 
11:17 AM
these are interfaces, right?
 
user142019
It's like assigning a hash table to a socket.
 
In the articles I've read, they kept preaching about "pure" ECSs in which your structs would have nothing more than pure data and no code
 
user142019
@FredOverflow I didn't say they were going to suck forever.
 
@Magtheridon96 Then you know it's bullshit.
 
I dont know what's wrong with my question
 
11:18 AM
@KarimkhanPathan Firstly, it's a question and this is the chat, not the helpdesk.
 
@KarimkhanPathan first problem is that it exists.
 
@rightfold That sounds useful for hiding weed in a socket.
 
@DeadMG The idea to just add components to an object and get it to work magically sounds like a wet dream :c
 
second is that it involves arrays and pointers
 
@Magtheridon96 It's not going to.
 
user142019
11:19 AM
@Magtheridon96 Ah, so Entity Component Systems is a fancy name for interfaces, like Dependency Injection is a fancy name for polymorphism.
 
user142019
@FredOverflow Dat pun.
 
2 mins ago, by Bartek Banachewicz
these are interfaces, right?
 
pro tip: every solution that makes a complex task sound easy is almost certainly shitting you.
 
user142019
@KarimkhanPathan Stack Overflow
 
@KarimkhanPathan What question? Linky?
 
user142019
11:19 AM
@FredOverflow Bin.
 
Interfaces is a Java word ;_;!
 
user142019
@Magtheridon96 No.
 
But they use it more
 
-5
Q: How to convert sentence into array of string in c++?

user2500861I want to convert entire sentence into array like: sentence: my name is john Which should be stored in some array like array[]={my,name,is,john} How to do this?

 
user142019
Interfaces are classes with only unimplemented abstract non-static member functions and no non-static data members.
 
11:20 AM
@rightfold eew, pointers
 
Cleanup on aisle holy shit get the hint please.
 
user142019
I still got the binbot. :P
 
oh, wait
Fred, you bastard, my cleanup was entirely unjustified.
 
@rightfold I always think of classes as interfaces with implementation :D
@DeadMG What are you talking about?
 
@FredOverflow I nuked his question dump, but turns out you actually asked for it.
 
user142019
11:23 AM
Almost all answers are horrible.
 
Everything is horrible
3
 
@DeadMG You could have nuked my post as well, problem solved ;)
 
wow, a €100 pogoplug for €30?
 
user142019
-1 for using namespace std;. -1 for cplusplus.com. — rightfold 34 secs ago
 
@rightfold The Haskell answer would be words "my name is john" :)
 
11:26 AM
@rightfold there is nothing wrong with using namespace std; in 10-line code samples.
 
meh, not really
 
user142019
Jerry's answer is neat.
 
user142019
And best.
 
@rubenvb There is also nothing right with it.
 
@FredOverflow how is it running ArchLinuxArm for torrenting and file serving?
 
11:27 AM
@rubenvb wat
 
Cause my Pi is just a tad slow, and I could still use it to view movies off of the PogoPlug.
oh crap
never mind
mind lapse
 
@rubenvb Everything is wrong with using namespace std; when the one using it doesn't put big, shiny warning saying "DON'T YOU FUCKING DARE TO EVER PUT THIS IN A HEADER YOU MOTHERFUCKER" next to it.
 
@Griwes ah, but when is int main in a header. You guys should chill out.
 
@rubenvb When such warning is not present, the noo-- idiots will stick it everywhere they use anything from std::.
Which is bad.
And note how most of "programmers" are idiots.
 
screw the idiots.
 
11:34 AM
The problem is, by the fact that most of "programmers" are idiots, almost every Real Programmer has to work with at least several "programmers".
Or at least deal with code written by such.
 
mm
are you saying "Real Programmer" is something different from "programmer"?
can you please elaborate
 
user142019
There are real programmers and imaginary programmers.
 
user142019
The situation is quite complex.
 
like ... html programmers ... real or not?
 
i got a coworker who as first thing in a ctor always does "bzero(this, sizeof (ThisClass));"
5
 
11:36 AM
@JohannesSchaub-litb "Programmers" = programmers (a.k.a. Real Programmers) + idiots thinking they're programmers.
 
and if the class has virtual functions, he declares a first dummy member and a last dummy member and does "bzero(&firstDummyMember, &lastDummyMember - &firstDummyMember);"
 
@JohannesSchaub-litb What.
What.
 
I've created a Qt application that is basically a fullscreen window that fades in/out. How can I install it on my computer to be able to run it from terminal?
 
@Griwes Oh wait, on second thought, I think we are talking about "dumb programmers", "lazy programmers", "padentic programmers" etc
 
when I had to tell him that there is no way in C++ to inhibit destructor calls for local variables he said "oh shit. c++ is all messy"
 
11:38 AM
I would like something like this:

$ appname fadein
> The black window will fade in
$ appname fadeout
> The black window will fade out
 
user142019
@JohannesSchaub-litb He is speaking the truth, but it's unrelated.
 
I am on Ubuntu 13.04.
 
@Griwes his rationale is that he doesn't want to add members to both the class body and to some init list
 
lol
 
user142019
He's a moron.
 
11:39 AM
rationale-so-broken
 
perhaps "MyClass():MyClass() { }" should be allowed? it would value-init the class
 
@JohannesSchaub-litb what
@JohannesSchaub-litb that's delegating constructor syntax, no?
 
i.e if a default constructor delegates to itself, it means "value init"
 
user142019
Maybe uninitialized objects should not exist in C++ and C++ needs some sanity?
 
@Johnツ you will need GLX window for that
 
Ell
11:40 AM
@rightfold I never really got dependency injection
 
Xeo
@JohannesSchaub-litb T my_member{};?
 
or some other trick. perhaps "MyClass():default() { }" would apply the initializer "()" to all non-static data members
 
user142019
@Ell it's polymorphism and nothing more.
 
@BartekBanachewicz Thanks, looking now for docs...
 
@Xeo I mentioned it. he said "oh why don't we use C++11" xD
 
user142019
11:41 AM
@JohannesSchaub-litb No, all primitive types must have default ctors.
 
@Johnツ they will be hard. GLX is a piece of crap. In general window transparency is OS-specific, thus meh.
 
user142019
Because uninitialized objects are completely worthless and unsafe.
 
@rightfold huh
i don't understand what you mean
 
user142019
int x; // should be 0, not uninitialized
 
@Johnツ, that looks like a serious abuse of katakana.
 
Xeo
11:42 AM
@rightfold Purrformance
 
@BartekBanachewicz No, the fade in/out works. What I have to do is to run it from Terminal.
 
user142019
OH NO!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 
@Johnツ um wat? can't you just run it?
 
@rightfold C++: you don't pay for what you don't use!
 
user142019
[[uninitialized]] int x; // uninitialized
 
user142019
11:42 AM
Ohey purrformance!
 
@rightfold "x" is default-initialized. but its value will be indeterminate if that is not a namespace-scope declaration
 
@BartekBanachewicz How can I connect the Terminal with my qt application?
I have no idea. I am beginner in qt...
 
user142019
C++ is an unsafe piece of shit.
 
Xeo
@rightfold Ohey slowing down C code
Really, being compatible with C was a great factor for C++
 
@Johnツ you have to write $ /path/to/your/binary, simple as that.
 
user142019
11:43 AM
C is not C++ and must not be compiled as C++ but as C.
 
int x = void;
IIRC, this is valid syntax in some C like language
declaring explicitly that an initializer is missing
 
@FredOverflow ok interesting, does the book also cover technical stuff?
 
user142019
Also
 
actually I think we need a way for the class init lists to say "behave as though this class has no constructors
 
user142019
using an uninitialized variable is UB
 
11:45 AM
@BartekBanachewicz I don't want to use paths.. I want to install it and run it with a terminal command: myappname fadein
 
perhaps with "volatile"
MyClass():volatile MyClass() { }
 
user142019
and if you don't want UB you have to initialize it explicitly, which the compiler can detect
 
then it means to value init the class first
 
user142019
and optimize out the implicit = 0.
 
@bamboon It doesn't say anything about C++ templates if that's what you're asking :)
 
11:45 AM
@Johnツ so you have to either a) put the binary in one folder that's on $PATH or b) add the binary folder to $PATH
 
Why would I want to waste time initializing a large buffer to 0 if the first thing that happens is a pile of network/file data gets read into it?
 
@FredOverflow ^^, no I mean rather questions about algorithms etc, maybe how to approach these?
 
@bamboon algorithms are overrated
 
user142019
Have syntax to make it explicitly uninitialized.
 
@BartekBanachewicz Which is the binary file? The executable one?
 
11:47 AM
@JohannesSchaub-litb How about static? ;)
 
@Johnツ yep. if you are writing in C++, at least. Script/managed languages differ a bit in that regard.
 
@bamboon nope
 
@BartekBanachewicz Yes.. thanks! Looking in the link you sent me.
 
Ohai :)
 
Ell
Hi
 
11:48 AM
@FredOverflow ok, thanks anyway.
 
ohai Lion
 
@FredOverflow neat
 
Ell
I don't understand how you can find regressions with git :S byte.kde.org/~zrusin/git/git-cheat-sheet-medium.png
like, conceptually
 
@FredOverflow also it would allow a "quasi aggregate" that has ctors just for the purpose of calling some function to use aggregate init to init itself
 
Whazzap?
 
11:49 AM
struct Foo { string name; int age; Foo():static Foo{"devil", 666} { ... } };
 
@Johnツ I think it has all the stuff you might need, with setting the path for system, for one user, for one login session etc etc. I usually make a special path for all helpful stuff I use, such as /home/me/sbin and add it.
 
Xeo
@rightfold Not gonna happen at this point.
 
user142019
I know.
 
user142019
It will never happen.
 
@BartekBanachewicz And will I can to publish it somewhere to be able to install it with sudo apt-get install appName?
 
11:50 AM
A ctor implementation itself should be allowed to subvert its ctors like that, IMHO
 
user142019
@JohannesSchaub-litb MyClass : ...() { } :)
 
@Johnツ no, that's more complicated. apt searches in repositories, so your app would have to be added to them.
 
@rightfold what do you mean?
 
user142019
Syntax.
 
11:51 AM
@Xeo i'm going to ask std-proposals whether they agree
 
@BartekBanachewicz Ok, thanks! Following you on Github. :-)
 
perhaps they know an even better syntax
 
@Johnツ this forum thread might have some relevant info Criteria for adding an app to os-wide repos are strict, though, but perhaps you might be okay with some other repositories; that requires the os user to add those repos to their system, which is considered, in general unsafe, as it allows arbitrary code to be installed.
 
@BartekBanachewicz But I guess that anybody can add my repository to its system and then to run sudo apt-get install ... .
 
if it's only a small app, distribution via opensource channel is usually preferred, and you can provide stuff like make install that will compile the code and put the binary in user system folders
 
11:55 AM
Yes, that's also good.
 
Xeo
I honestly didn't expect my answer-tick question to get that much attention.
 
@Johnツ some people even prefer installing stuff like that, because you can have the bleeding edge (binaries in repos are updated less often, and for example stable Debian can have ones that are one year old or even older).
So if you want to have, say, the version from yesterday night, you have to get the sources and build them yourself anyway.
 

« first day (981 days earlier)      last day (3972 days later) »