« first day (2019 days earlier)      last day (2936 days later) » 

5:00 PM
@LeviMorrison Also works and gives the timeframe desired.
 
Eh, I disagree that returns are the only issue.
 
@Sara I have that feeling that 7.3 already might be PHP 8 … at least at current pace…
 
I definitely think adding something only for nullable returns is really a bad approach.
 
So we'd get like.... 3 years with nullable/union types, but no warnings about abusing class/array type hints (allowing them to be null), then five years of deprecation warning....

See y'all in 2025.
 
That's how inconsistencies are born...
 
5:01 PM
well it doesn't matter, we already have a way of specifying a nullable parameter, we just need the same for return types ...
 
@Sara Such an important feature for you, eh?
 
@bwoebi Yeah, the scope rate is pretty heavy right now. I thought about proposing enums and then I was like... "Ya know what? Pacing, bro."
 
they are the only burning issue, anyway ...
 
@Sara wiki.php.net/rfc/enum
 
@LeviMorrison Nah, if I'm writing code that cares about types, I'm doing it in Hack.
 
5:02 PM
@Sara except that there's already a RFC with patch
 
@LeviMorrison well, alrighty then
 
I actually think enums are a more important thing to add than nullable returns but I'm getting a lot of pressure that says otherwise.
 
I guess we'll care about that one after the nullable/union discussion is over
 
@LeviMorrison My wishlist for that feature: T::coerce(), T::assert(), and T::getValues()
 
@LeviMorrison yes and no. You can quite efficiently emulate enums with class constants today… but nullable returns are impossible
@Sara We wanted to keep enums methodless
 
5:04 PM
@bwoebi Not really. No type means it's basically useless for me.
 
@bwoebi What about the usecase of creating an html dropdown from an enum's values, then coercing that back into an enum on form submit? Seems like a pretty common use-case for enum.
 
a constant is the type it was when you created it, isn't it ?
 
Wes
i'm staring at array_unique() documentation trying to understand it needs a sort flag. it's not that i can't understand, it's that i don't want understand... on purpose
 
@Sara except that you probably will have a simple map from enum to value
 
@JoeWatkins consts should be able to infer their types, yes. Though I don't see harm in allowing them to be typed.
 
5:05 PM
constants could be typed, but nobody gave good reason to include that in the typed properties patch ... they are easier to type than props are ...
 
@bwoebi Why should you have to have that map though?
MyEnum $foo = MyEnum::coerce("bar"); // $foo = MyEnum::Bar;
Better than copypaste boilerplate code to provide a map for something you've already defined
 
The philosophy is: You may display different representations of enum values in different contexts. Like you'll display a different representation to end users in HTML than in database
@Sara but we provide a reflection API though
you can still access it
 
Yeah, but again. I'm having to write extra code.
Maybe not as much using Reflection, but still... unnecessary code.
 
and that's a good thing™.
 
Writing boilerplate is NEVER a good thing.
 
5:08 PM
because it's not boilerplate
 
Writing boilerplate makes you create dumb mistakes.
Well, we disagree. shrug
 
reducing boilerplate is not always easy ...
you get accused of proposing "sugar" rather than solving problems ...
agree, boilerplate is always a problem ...
 
@Sara I'm on your side when you say we should reduce boilerplate, but I disagree when you say this will lead to boilerplate.
 
whenever you say "you can already do that by doing ______" you are talking about boilerplate ... right ?
 
5:11 PM
If you write [E::FOO => "foo", E::BAR => "bar", ...] something is going wrong anyway
 
@bwoebi I can tell already exactly what enum_values(), enum_coerce(), enum_assert() functions I'll have to write to make these usable to me. These are not going to be interesting functions, they're going to be things the engine should have provided to me. That's boilerplate in my book.
 
just a question… what exactly is enum_assert()?
 
@bwoebi I don't, actually. But these enums have no values, so it's the best managable here.
 
@Sara Well, you can do that, but it IMHO is an anti-pattern
 
I think Enum::equal == enum_assert ?
 
5:13 PM
@bwoebi In psuedo-code: function enum_assert(EnumType $t, $value) { if (!$t->hasValue($value) throw new \InvalidArgumentException(...); return $t::{typeof($value)}; }
@bwoebi And we disagree. Which is okay.
 
then I don't get it ...
 
@JoeWatkins It's for turning something generically typed (like a string) into an Enum typed value. Throwing an exception if it's invalid.
 
@Sara but you have coerce?
 
Versus ::coerce(), which would return null on invalid member value
 
yeah ?
 
5:15 PM
ah
 
Just different failure modes
 
gotcha
 
I personally prefer coerce(), but assert() is nice for completeness.
Anyway, @LeviMorrison has dibs on enums, so I'll see where that goes.
I'm not saying that version would be "unusable" in PHP, just.... not how I'd have done it.
 
@Sara by the way, enum values are normal class constants
 
5:17 PM
@Sara Should you have a hhvm build handy just now, could you check if on github.com/nikic/hhvm/tree/fixLabelStartCheck there are test failures in test/slow/here_doc/ ?
 
you mean it still didn't build since that commit @NikiC :D ?
 
@NikiC I don't have a current build. I'm working from an AWS t2.micro which is.... not conducive to that.
 
I'm being told that the test I added is failing, but it works locally and as there are no output diffs I'm not sure what could be wrong
@Sara Oh yeah ... t2.micro sounds like it will spend the whole day compiling :D
 
days... plural
 
you might be cursed ...
 
5:18 PM
Well, if it managed at all. Probably not enough ram for some of the source files
 
@NikiC ugh, we do not have a syntax like Foo::{$val} for dynamic constant access?
I somehow thought to have that
 
@NikiC Did they say what the test.php.out shows?
 
@Sara nop
 
@Sara btw. the patch proposes reflect_enum($enum) returning ["enumclass", "name"] … so reflect_enum($enum)[1] pretty much does what you need
 
I can't imagine why that diff would have issues. It's too simple to fail.
 
5:21 PM
I just was sure to have some dynamic class const access (to replace your enum_assert)
 
@bwoebi They are?
 
Unless the lexer change isn't applying cleanly, but they should be telling you that properly.
 
@kelunik yes
 
@bwoebi Why?
 
@kelunik what should they then be?
A::B is class constant syntax
and also the way how enum values are accessed
 
5:22 PM
@Sara One would think ^^
 
@NikiC Oh! Maybe the test is failing in RepoAuth mode (because of the eval). Try adding a .norepo maybe?
 
@Sara oooooohhhhh
 
And whoever is oncall didn't bother to look into the details of the failure
hphp/test/run -r hphp/test/whateverpath/niki.php
 
@Sara Yep, that's it
 
<3
My brain is better than a t2.micro
 
5:25 PM
@Sara Thanks, never would've thought of that one
 
"fix" test in repoauth mode.... I'm not sure "fix" is the word you have in mind. :p
 
@Sara That's how I usually fix stuff :D
E.g. when I have a test failing on HHVM because reasons, I fix it by uncommenting the test :P
 
It's the "Shhhhhh!!!!!! SHUT UP!" fix
 
@bwoebi No, and I've ranted about this a few times, as has @Andrea.
 
@NikiC Ah, Orvid is oncall.... yeah... he's new. He doesn't know what to look for yet.
 
5:28 PM
And also how following other rules in our language one could expect Foo::$a to be a dynamic constant access...
 
Helloo
Can I ask a thing about php?
 
@MattewDeveloper nah go to the haskell chat
 
No, this room is for discussion of meat popsicles
 
@MattewDeveloper Sorry, you broke the room rules by asking if you can ask. (And since sarcasm isn't obvious in text.........)
 
((Yes, please ask. We just lack a proper sense of humor))
 
5:33 PM
heh
 
((We make up for it with an abundance of parentheses though.))
 
If I would become an backend developer, What I must study? Only PHP and MySQL?
 
(((Lisp?)))
 
I know HTML, CSS
 
@MattewDeveloper Ruby and ROR
 
5:34 PM
@MattewDeveloper If you know HTML, CSS, that's enough
 
@MattewDeveloper Great question, Mattew! I too know HTML, CSS.
 
I use the double-parens because I got used to using them as "aside voice" in role playing. Don't judge me.
 
(Okay, I'm done with the joking)
 
@LeviMorrison so, yet another thing we shall add with PHP 7.1?
 
5:34 PM
@NikiC forgot jquery ...
 
@MattewDeveloper backend dev is a very broad term
 
and you could be working with alot of different langs and whatever
 
But I can study PHP without beforeknow JS?
 
5:35 PM
@MattewDeveloper If we're casting a wide net, I'd say you should learn a number of languages...
 
Because I hate graphic and frontend
 
@bwoebi Something something unified symbol tables something something
 
OT: You understand me?
 
@MattewDeveloper Sure, they do different jobs in different places, and they both adhere to similar syntax rules, so learning one after the other shouldn't be difficult.
 
5:36 PM
@LeviMorrison how is that related to dynamic const access?
 
But I know the basic programming like variables, string, cicles, function etc.
 
@MattewDeveloper php sucks, learn cobol
 
@bwoebi There is an ambiguity between class constants and static properties...
 
@ChristophBühler Cobol sucks. Learn 8086 assembly.
 
5:36 PM
@MattewDeveloper you are going to hear that alot.. this sucks and that sucks
 
@NikiC not if you write it as Foo::{$a}
 
@ChristophBühler dafaq did I just see...
 
No, I learn machine language (01)
 
@bwoebi Ah sorry, missing context
I'd still say "ugh" to that
 
@RonniSkansing But PHP isn't good?
 
5:37 PM
its great
 
Foo::$a and Foo::{$a} oughtn't refer to totally different things
 
has a lot of issues
but runs on all the cheap hostings
 
but the backend dev must use PHP
 
@MattewDeveloper it hasnt hurt me
 
{} is not nice
 
5:38 PM
@NikiC Yeah, that's somewhat true though, but it's the best solution I have… Foo::${$a} would be dynamic access on class prop…
 
BTW, @bwoebi, in case you didn't know: constant(string): mixed
 
@MattewDeveloper learn to use a framework after you know the basics (yii or symfony)
 
its a nice gateway drug also
btw never learn yii
 
@LeviMorrison ah, true…
 
laravel? :P
 
5:39 PM
yii is great lol
 
I know about it, but forgot …
 
why would you ever recommend yii?
its horrible
horrible horrible horrible
 
no it's not?
 
The last 12 months before I got my job I worked with it
 
So, I know the basics of PHP, but with the basics I can not do much other than a simple code that prints 1 +1
 
5:40 PM
imo its horiibiiiible
I call it Whyy
 
@MattewDeveloper A backend dev can use any language they want to, including Javascript and can even simulate a back-end server using ALUs hard-coded into Minecraft redstone simulators... But yes, PHP is a popular web development back end language.
 
@JoeWatkins you're being voted on, do you feel fuzzy?
 
@MattewDeveloper don't listen to @RonniSkansing, he's a mad man
 
5:40 PM
Lets try a vote.. moment =)
 
@Leigh hehe
 
oh there's already a link there, i'm slow
 
strawpoll.me/10056142 (would you recommend Yii to a friend)
I will go first =)
 
Who is trolling that vote with yes votes?
 
no need for a poll, the proper answer is no, unless secretly you super hate that person, and there is some kind of television soap drama going on ...
3
 
5:42 PM
however, my problem is that I have studied many languages but I know just the basics, and then I would go with PHP to something more complex that serve me for web applications, I do not want to recreate facebook, but I'd like something that's not just print variable , create loops and things that do not serve
 
I'd be happy to recommend it to an enemy, though... It's not so bad that a person would have to be a psychopath to recommend it to someone they dislike.
 
@MattewDeveloper I would def recommend you to get started =) straight away
 
cosa potrei studiare?
 
be it js, php, java etc
 
what I could study of arguments?
 
5:43 PM
@MattewDeveloper Find someone who you can sit down with in person and learn from.
 
Sorry, I've wrong language lol
 
Seriously, what is happening to that vote?!
 
@Ghedipunk SO isn't good for ask answers and similar thing?
 
@NikiC seems I should have enabled the captcha
 
5:44 PM
@MattewDeveloper You'd like to have an argument? youtube.com/watch?v=kQFKtI6gn9Y
 
Well that is how Yii marketing works
@NikiC
 
Sorry bout the double ping
 
47:10, I'd say YII wins it all
 
Yes congrats
 
5:45 PM
@RonniSkansing you think it's better if I learn good programming in languages such as C / C ++ or I can also start from php?
 
May you Yii's be fruitfull
 
@RonniSkansing Ah, so the thing is just cookie based or something?
 
@NikiC yep
 
@MattewDeveloper Really, at the point where you are with where you're learning, you really do want to find someone in person. You have the very basics, but don't have a direction yet... and text is a very poor medium for individual learning.
 
it wins nothing, nothing but everlasting, and well deserved disdain ...
 
5:45 PM
I can open a private window and vote again ... useless
 
@MattewDeveloper I started learning just like you.. I sat down at the computer at started learning all by myself
just do it, get started
 
@ChristophBühler deciding on technology based on popular vote is like using the same for picking boat name: cbsnews.com/news/…
 
pick a lang and start reading/poking at it
 
@Ghedipunk I know, but I can't spend money on a tutor or a programming school, I have only 13 years old, and I only do 2 ° average (2nd in the Italian media is the 7th year of school
 
@tereško not really.. but funny story ^^
 
5:48 PM
what "not really"
 
@RonniSkansing Ok, nobody has learned you for direction you?
 
@MattewDeveloper The best way to learn when you don't have a tutor is to make mistakes. Just start trying to do things, and see why it breaks.
 
@MattewDeveloper learn english before you learn php :P
 
@ChristophBühler You don't understand me?
 
@MattewDeveloper nope I just started
 
5:49 PM
@RonniSkansing Sorry for being rude on the internet
 
ok @RonniSkansing
 
I am awful at gfx, but with web by learning html and css first
 
What was your first language?
 
just the basics
 
@tereško so what I'm gathering is I should learn Technology McTechnologyFace asap
 
5:49 PM
fwiw, me too, I'm not allowed to do stuff you look at ... it's forbidden ...
 
@MattewDeveloper German, yours?
 
I think they did name one of the rescue boats boaty mc boatface ...
 
@ChristophBühler English isn't my first language, I'm italian
 
@MattewDeveloper dunno
 
5:50 PM
I mainly write php.. but I dable in alot of other langs
 
dunno = i don't know?
 
@MattewDeveloper Is there php in italian? Didn't know that
 
yes
Are you on windows?
 
@ChristophBühler Why? are there much developer in ita for php
 
@ChristophBühler it's really easy to see why what people say doesn't matter ... try this, put on a dress, grab a shotgun, go to a bar and point the shotgun at people and ask them if you are pretty ...
 
5:51 PM
@RonniSkansing I've windows with in dualboot debian
 
@JoeWatkins my mom always told me I'm special
 
boot up in windows and start installing a lamp stack
 
@MattewDeveloper you are too kind ^^
 
or just php if you just want to get started on php only
 
@RonniSkansing I've xampp with apache and mysql
 
5:53 PM
@MattewDeveloper that's good. I'd use the atom editor
 
Great I guess you are ready to start?
 
@MattewDeveloper atom.io
 
I use....
vim
 
@ChristophBühler maybe you are, I dunno ... but yii ... it's crap ... We::Know This::From Experience::And Reading::So Much::Of It::In Crappy::Questions ....
 
@ChristophBühler
Yes, I am young, do not say "When I am 13 years I played the Pokemon" and thing like this
 
5:54 PM
and working with it
 
Ok, I've only need of vim + apache, right?
 
how unfortunate ... I'm sorry Ronni ...
 
@MattewDeveloper vim + php
 
@JoeWatkins yes, but its okay, I got a new job a month ago
(started this month)
 
5:55 PM
yay ...
 
@MattewDeveloper You.. are 13?
 
hows it going ?
 
@ChristophBühler uff, yes
Don't tell me I'm too small
I have a life too,
 
That's what whe said ._.
 
we don't make inappropriate jokes when children are present ...
 
5:57 PM
@MattewDeveloper I think it's good to start at a young age..
@JoeWatkins haha good one
 
I'm not joking ...
 
@JoeWatkins I think its going okay so far, I am starting to like the place, but lets see how it turns out after a couple of months.. =)
 
tough there is some Laravel at times
 
this tutorial is good?
 
5:58 PM
but I think it has and will only help me sharpen my skills to actually confront laravel lovers
with the actual concerns
 
@MattewDeveloper you better never talk to women and learn every word of this book in the next few years, and you are one of us amazon.com/dp/0321992784/?tag=stackoverfl08-20
 
meh, we can hate X thing for many valid reasons, but that does not diminish it's business value ...
 
sometimes we have to do things we don't necessarily want to tell other people about, part of working for someone else :)
 
@ChristophBühler But Is good this method for learn: I see code, i write code, i ask repeat etc.
(for html&css I have do it)
 
6:00 PM
but really.. working with programming is really the best job I can imaging.. even if its sometimes crap
its soo less crap that would it could have been
 
agree :D
I liked it when it was a bit harder ...
but whatever, it's still fun ...
 
Oh fun. Sometimes I wish I could make it abit easier
 
@JoeWatkins lol just don't code PHP.. there is enough hard stuff to do
 
just a tidy bitsy
but everyday brings abit of new tricks or confidence
 
user895378
@Leigh It does, but we rely heavily on confirms and mandatory acks at work so that doesn't work for me :/
 
6:01 PM
yea.. I think I could do this for the rest of my life
 
user895378
@bwoebi yeah, most likely
 
Fair enough
 
I'm out peepz, lata
 
laters
 
6:03 PM
anyway, I know the basics basics (variable, string, function and loop), now I could try to do an easy script with random, variable, echo, string in php
Now I go to code, If I've any problem Can I ask here?
?
@RonniSkansing @ChristophBühler
 
@MattewDeveloper sure, you can always ask
 
Ok :D
Now I go to code, see you later
 
@RonniSkansing nice CV - I like
 
Thank you! But fair warning to everyone else, its not frydai so dont check my cv
 
anyone know this :O ?
 
6:10 PM
People here use butterflies
 
@littlepootis There's an Emacs command for that.
 
Yeee
my code work
 
Ekn
evenings
 
Good evening @Ekn
 
6:23 PM
@MattewDeveloper do you know a little JS?
 
A few
only basics + dom + event
 
@MattewDeveloper if you wanna be professional, program everything in JS and then "eval" it in PHP
 
@ChristophBühler why?
Ah
So, I can't study PHP?
before php*
 
it's a joke..
just learn PHP
 
and JS
 
6:25 PM
go back to the code - nothing to see in here
 
and learn lots of other shit because JS and PHP aren't going to take you anywhere. Learn pentesting, unix, web servers, learn a functional programming language, learn about alg, DS, design patterns, learn java and write blogposts criticizing it sup bro
 
@littlepootis are you okay?
 
Feb 1 at 6:44, by Joe Watkins
forget about learning languages, learn about programming ... you should be in a position that whenever a new language comes along, you only need to skim through a manual and you can use it ... favourite languages will emerge, eventually ...
 
@AnmolRaghuvanshiVersion2.0 and learn languages too
 
@MattewDeveloper 1. learn css / html / php. 2. learn programming
 
6:33 PM
@MadaraUchiha @NikiC eli.thegreenplace.net/2016/…
 
6:53 PM
Any ideas why when I set a password on my database I can no longer connect with PHP? It works when there is no password, but doesn't when I add one.
 
@Waxi Yes, your authentication is messed up (and unless we get more details about how you're authenticating to your database, that's the most help we can give you.)
 
Hi guys!
First time in stackoverflow chat
 
Wes
welcome
 
@Ghedipunk Well, I'm using new mysqli() to connect and it works when root doesn't have a password. When I add a password, it fails to connect. I have users root@localhost, root@127.0.0.1, root@::1, and root@%...all with the same password, but nothing. I was using Adminer to manage my users.
 
thanks
Anyone good with telegram bots written in php? That's why I came here
 
Wes
@kelunik why didn't you use a fixed header?
 
@Wes Has it's own issues, e.g. with scrolling to hash fragements.
 

« first day (2019 days earlier)      last day (2936 days later) »