/dpt/ - Daily Programming Thread

What are you working on, Sup Forums?

Previous thread:

Other urls found in this thread:

github.com/npm/www/issues/287
youtube.com/watch?v=RdE-d_EhzmA
github.com/npm/registry/issues/255#issuecomment-355771527
cx-freeze.readthedocs.io/en/latest/overview.html
github.com/ocornut/imgui
github.com/tc39/ecma262/pull/1062
twitter.com/NSFWRedditGif

ur slavaifu a shit

range(start, stop, step) for javacaca

why can't there be a good sys pl

c++ is the greatest language of all time

github.com/npm/www/issues/287

Oh god the cringe

OOP is the worst invention of all time.

objective C++ is objectively the greatest language of all time

Hasklell

"""""cute"""""

>make issue on git requesting a very simple feature
>dev labels it as 'help wanted'
>has been a duplicate feature request since October
>dev says they dont have the time
>download their source
>takes less than 30 mins to implement it
???

welcome to osdev

OODD > OOP
youtube.com/watch?v=RdE-d_EhzmA

I posted this 5 minutes ago before the new thread.
Does anyone have a link or something to a good SDL tutorial for games? I want to build a board game, like chess, it is played on an 8x8 board positioned like a diamond diagonally, and the rule set is simpler than chess.

is this you user?

FFDD
(Fast Food Driven Design)

I've spent 5 years autistically tweaking my VS13. Is there a seamless way to move over to VS17 while keeping:
Fonts&Colors
C# settings
ReSharper Settings
Keyboard shortcuts
Extension settings(through all compatiable with 17)

The only reason I'm considering upgrading is because although VS13 technically supports C# 6.0, it shows random errors in the console which is throwing me off and getting annoying. It still compiles, but shows errors.

No, I was looking for the postmortem of the npm debacle from a few days ago and found that by accident

I really like Haskell I just wish I could make the programs I like to make with it. It's shit for GUI and mobile. :/

What debacle?

going from Java to C++

Already about smart pointers and locks, abstract virtuals vs interfaces, any other things I should be aware of?

[spoilers] like if knowing c++ get me a job? [/spoilers]

leftPad 2: rockstar boogaloo
or
github.com/npm/registry/issues/255#issuecomment-355771527

ADD
(Alcohol Driven Development)

>Fonts&Colors
Because you care about such things?
>ReSharper Settings
Resharper is fucking useless
>Keyboard shortcuts
Seriously, use the default ones.
>Extension settings(through all compatiable with 17)
You shouldn't use extensions.

Java has more opportunities than C++, but there's still plenty to choose from.

>does gtk still have a stable release cycle, or did it switch to a rolling release meme (with the potential to break code just like js libraries) now?
>i would like to avoid c++ for now, but i want a gui to play with.

Any good books on python?

Sorry I'm way late.
cx-freeze.readthedocs.io/en/latest/overview.html
It was multiple years ago (2014?) but this rings a bell a little. I don't remember it being multi page though.
I don't remember any details really. Just that cxfreeze is not intuitive. I don't remember having to use a script to build a setup script.
Good luck.

I forgot to say thanks for the feedback from asking about a potential GLFW+GLEW substitution when I was suggested imgui.
I still haven't really evaluated the advice in full but imgui is pretty much exactly what I want from a gui library it seems like. Thanks a bunch.

Yes most people are that lazy.
Why is this surprise to you?

>imgui
hnnng
remember seeing a presentation by the lad, IIRC
shit's so cash in terms of usefulness

>So lazy I only evaluate problems when I absolutely need to

>imgui
>no documentation
>maintained by amateurs
>opengl

there's no better alternative

Does TravisCI seriously not have any environments newer than Ubuntu 14.04? That shit is prehistoric. None of my code works, not even cmake (because I use policy CMP0048 in my cmakelists). Almost none of my dependencies are available in the repos (glfw3, cmocka etc). Am I expected to manually source in my entire toolchain with scripts? Because if that's the case then I don't see how travis can be useful for anybody except python shitters who don't care about using ancient libraries. At this point it would be easier to run my own CI system with my own hardware or on a VPS.

no

>imgui
>no documentation
For sure there's none, you write your own IMGUI every time or use your latest. There's no universal library for IMGUI.

are your porting libcaca to java?

SDL2. Though you still need glew or elbow greasing it yourself.

we are talking about this github.com/ocornut/imgui

SDL2 manages windows, it doesn't provide GUI functionality like imgui.

These dumbasses thought it would be appropriate to name their library the exact same thing as the concept.

I don't get it. What's wrong with the picture??

>no duel cup stream because caster is stuck logging in to the game
>no server tv implemented and never will be
well id, can't even fucking watch tournaments when they are happening and there will be no demos.

Is Android the only sane gui for Java? Swing is fucking old and JavaFX is slow af

>JavaFX is slow af
it is?

there are qt bindings but fuck that.
javafx is really the best there is for java.
it is. Try to create big list or just add many items to scene and it gets really fucking slow.

I need to learn it.

>it is. Try to create big list or just add many items to scene and it gets really fucking slow.
that's a shame, I would've assumed they'd get the basics (culling lists to only the visible items, etc) down

github.com/tc39/ecma262/pull/1062
>the city of javascript

can someone explain to a brainlet the difference between a normal class and an abstract class?

stop saying brainlet

Why Tkinter so much easier to understand than GTK+????

It's far easier to made shit in C, then make the GUI in Python with help of Python API,

A normal class can be constructed, an abstract class can not.

Synapselet

>Hey, so - this makes me a little sad. JS is the only language I write, and I don't use semicolons. I know it's just a warning clause, but it sounds like the TC39 is saying we're bad for using the language in a particular way. And it, feels, well, a little hurtful.
Jesus christ what a pathetic display.

t. brainlet

An abstract class is missing the implementations of some methods (these methods are abstract) so you cannot create an instance of this class.
You can only create an instance of some class which inherits from the abstract class and defines these implementations.

so an abstract class is like a "starting point"? You make an abstract class then make another class that inherits the abstract class which you then create an object out of?

Sure.

any1 knows if it has improved with openjdk9?

>Java

>stop saying brainlet

I'd benchmark rather then rely on 4chin info. Might be that it only happens in specific conditions, or that it's still fast enough for your use case.
Make simple-as-fuck test progs in your candidate toolkits (realistic number of items, but focus on absolutely minimum dev time) and test

>dem gams
would bend over that terrace/10

>Not so much a contract, but more like - "yeah, we care about you whether or not you use semicolons".

Imagine what CS would be if silicon valley had been anywhere else but commiefornia.

so does this live up to the standard of the previous edition? reading the trump hate coming from bloch's twitter seriously turned me off

semicolon insertion is fucking awful

nothing is wrong just that she's kinda cute for a programmer

>b-but muh feature only takes 30 minutes to implement
Get in line...

>Not separating an author rom his political opinions
wew lads.
Stop making excuses, download a pdf and see for yourself

Stop it.

>every reasonable person I've ever met hates this guy
>they're all crazy

Quake Champions?
What a mess. I can hardly believe they haven't pushed to make it seem like it's outsourced to Sabre.

I still don't get why so many new modern languages seem to be trying to do away with parentheses
Surely I can't be the only one who thinks they do improve readability

eg
for (i=0; i

learn haskell and you'll understand

Smite worlds had two .net RTE's this year during matches.
if only the world ran on FP.

>perfectly okay to bash trump
>show any support and HR is on your ass
IT WAS HER TURN

Name 200 languages that have this style of for loop without parentheses

They do given enough sugar.
foreach(x; 1..11) //thing
old for loops are awful.

for n in 1...11:
// something

would be superior

new languages have to do something different or they wouldn't be new
just use C++ or java

yeah, that's what i meant, but muscle memory fucked me. ()s are a relic that need gotten rid of.

A language where foreach(x; 1..11) is anything but a syntax error has no right to exist.

Why do you hate nice things?

It's not even that egregious

>be Go developer
>import package
>but GitHub is down
>code doesn't work

kek

A calculator program that has a ui with buttons for input but only does single digits ints and basic addition subtraction with no error checking.
From a scale of 1 - 10 with 1 being hello world and 10 being real shit, what would you rate the difficulty of this? I'm trying to practice writing in a mvc design style

Perl6/Rakudo
for 0..^10 -> $i {
// something
}

I say any language with a foreach should be avoided. It's just pointless. Why don't people respect human pattern recognition? It's one thing we all share.

>It's just pointless.
It's much more powerful and convenient for range-based operations.

>Why do you hate nice things?
You need to have brain damage to think that's nice. Nothing about it implies the introduction of a binding. The semicolon is a separator, and it separates the x from the range. I don't know D, but I'm willing to bet it's inconsistent with any other form of variable declaration. Just another brain-damaged aspect of a brain-damaged language.

>be Rust developer
>cargo update
>but crates.io is down
>code doesn't work

I mean, unless you have a distributed package management system you are going to probably have a single point of failure somewhere.

abstract classes are used to provide a contract from which other classes derive methods


for example, you could have a Vehicle Abstract Class and then implement Drive() differently across 2 separate classes, like Manual and Automatic

That way you're changing the implementations of concrete classes if you need to. Changing Drive() in one class doesnt fuck the inherited implementation in other classes

>foreach gives you a range
That's slightly worse.

>Modern
C wasn't the first language, kiddo

>The semicolon is a separator, and it separates the x from the range.
it's literally just sugar for the iterator of the range type. But i guess you love explicitly typing redundancies.
how so?

Not as brain-damaged as nitpicking really minor shit

>it's literally just sugar for the iterator of the range type
Anyone who defends using a separator to signify a connection between the two separated elements should be shot.

> But i guess you love explicitly typing redundancies.
What does "explicit typing" have to do with anything, you mental midget?