« first day (1413 days earlier)      last day (3538 days later) » 

5:00 PM
...but I don't see other structs for zend_ast_decls
 
ast_decl is the separate structure
 
So add a new entry after the last one for zend_string *return_type?
In zend_ast_decl?
Or should I put it next to the other zend_strings?
 
Recommend me to code osmething guys.
I'm bored.. :/
 
Ahaaa finally know the difference between r+ and w+ :P
 
What's our line-length for php-src? I thought it was the standard 80 but I'm looking at longer than that in zend_api.h.
 
5:09 PM
Guys, please.
Help me, I wanna know what to code in PHP..
 
@HassanAlthaf Parse a subtitle movie format and create dictionaries that have the frequency of word use.
 
What do you mean?
 
Take a subtitle file and create a dictionary that knows how often a word is used in the movie.
 
LMAO
so easy piece of cake
 
That's what you think now.
 
5:11 PM
gimme a link to subtitle file
 
You haven't seen the subtitle file format yet :D
 
Difficulty level: don't use a library to parse the subtitle file.
 
Nope
I dont use libraries? :D
 
@HassanAlthaf It has to be code quality approved by Room 11 too.
 
ahaha
 
present ...
 
Cant download soz
out of bandwidth, using dads internet dongle
 
Thankfully subtitle files are just text.
 
meh it's pretty easy to parse
 
5:12 PM
Hey Joe, I'm attempting to start the return type implementation on master (can view progress here: github.com/morrisonlevi/php-src/tree/return_types). So far all it does is have the parser accept the return type (doesn't store anything yet).
 
@FlorianMargaine Depends on the format. Some include embedded information on where on the screen, and in what style, to draw the subtitle.
 
now I have an urge to create a subtitle file parser =o\
 
scamm
 
@Charles the srt format is easy to format.
 
subtitles is
full of shit
not just text
!!
 
5:14 PM
how would they work with just text?
 
ok then
 
@LeviMorrison gonna have a go yourself ?
 
imma use PHP str_replace() to remove em!!
 
you need to know when the text is to change in relation to the scene
 
@HassanAlthaf You asked for a project; I gave you one that will undoubtably help you learn but is not too complicated.
 
5:14 PM
@crypticツ There's a start and stop time, a sequence, and the thing to display, for example.
 
@JoeWatkins Yeah. Since you've already implemented it for 5.x I think I'll be able to get it a fair way there; we'll still have to solve the binding issue.
 
@LeviMorrison at it add the end as a zend_ast* child
the type is not a zend_string*
 
@NikiC Hmm... why not?
Aren't the types just strings? (like the name of the function?)
 
@LeviMorrison yeah that's a start ... only ... I think we need to do it differently ... I think we need a new opcode to verify type at runtime ...
 
5:16 PM
@LeviMorrison nop
 
it gives us a place to solve those problems in the last implementation
 
just look at the type: rule
you'll see that they aren't strings
 
yea sure florian
first let me do this
:D
 
@NikiC Oh, right, silly me. So when I pass it I do $<ast>7 ?
 
@LeviMorrison without the <ast>
forget about the <ast> thingies for now - I'll probably remove those anyway. the list/ast distinction doesn't make much sense anymore now that the grammar uses type annotations
 
5:19 PM
Okay. Thanks.
You think the entry should go before or after the children?
 
it's just another child
increment the number of children :)
 
@NikiC Okay, which position should it have? :D
 
@HassanAlthaf should take no more than say 8 lines of code, show us when you are done.
 
Wtf no more than 8 lines of code?
i mean wut
 
5:22 PM
@LeviMorrison the declaration should be child[4], where the return type is stored in decl->child[3]
 
So the last one. Any particular reason other than it will have a smaller diff?
 
@LeviMorrison no
if you like you can also move the body to [3] and use [2]
so it's in source order
 
Guys, I need a tiny help
How to explode everything
 
in an array
on new lines
 
5:25 PM
suspiciously, you have to have one more follower than I have ...
 
top 1% C users but not in list :(
 
Line one text here
Line two text here
Line three text here
Then you do some magic like, $lines = something something so that each line represents one slot in the array?
 
When you run out of tea spoons it's time to start the dishwasher
 
OH WAIT I KNOW HOW :D
 
5:28 PM
@Hassann didn't you want to do code something? If you ask us all the time you won't really learn..
 
Yea florian
I am doing the
.srt file thingy
 
inline composer support: ♫vendor/package♫
 
@JoeWatkins you really like Go, don't you...
 
mah gawd
 
hehe
 
5:41 PM
I rage quit!!
 
@FlorianMargaine Go is awesome.
 
@HassanAlthaf so soon?
 
OH WAIT
 
well.. that was quick
 
I GOT THE PROBLEM!!!
Array ( [0] => 1 [1] => 00:01:41,685 --> 00:01:43,044 [2] => Lucky ring on [3] => [4] => 2
Each 4th slot is empty
grrr cant get rid of
empty slots. :/
 
5:44 PM
@HassanAlthaf how are you fetching the file?
 
return file($file, FILE_IGNORE_NEW_LINES);
 
You should be using file() with FILE_SKIP_EMPTY_LINES | FILE_IGNORE_NEW_LINES
 
I am..
 
no you are not
you are ignoring the newlines, but still allowing the empty lines
 
Oh thanks man
I guess my logic will work now
 
5:47 PM
I wouldn't ignore newlines personally....
 
why not?
 
so that you can split by double newline and be almost done with the parsing
 
All it does is make sure the newline is not appended to the end of the row string
well that is assuming the srt file is well formed
a parser should not assume =oP
 
you don't assume your file is well formed?
how do you parse then?
 
Dunno, how do C parsers do it?
 
5:50 PM
if it happens to be missing a newline or contains an additional one the whole parse fails.
whitespace is something I always assume may differ in a file
 
in that format, the delimiter for record is a blank line, not a new line ...
 
Argh
I am doing it properly
But there are places
Where there are 3
i mean 2 dialogues
:/
	public function removeUnwantedLines($content)
	{
		$counter = 0;
		for($i = 0; $i < count($content); $i++) {
			if($counter == 2) {
				$newContent[] = $content[$i];
			}
			$counter++;
			if($counter == 3) {
				$counter = 0;
			}
		}
		print_r($newContent);
	}
 
yes, subtitles can be on 2 lines
 
ok thats it!
Imma remove
 
or they may be on 3 lines too
 
5:51 PM
All integer
lines
which has even 1 number
will be removed
 
how about you think a little about it before writing code?
 
Successfully seperated all dialogues
From those unwanted bs
lol
 
@HassanAlthaf if a dialogue has a number, it will be taken off?
 
FUCKKKK :l
HMMM
OK
IF IT DOESNT HAVE ANY ALPHABETS IN IT
THE LINE WILL BE REMOVED!!
 
please unset your caps lock.
 
		for($i = 0; $i < count($content); $i++) {
			if(preg_match('/[a-z][A-Z]/', $content[$i])) {
				$newLines[] = $content[$i];
			}
		}
		print_r($newLines);
Now why is not working? :l
gtg 11:27 PM
Didnt notice time
Seeya tomorrow
 
:-)
 
@HassanAlthaf Night :D
 
user2286243
Hi everyone
 
@HassanAlthaf try to follow the format "specification" at least... en.wikipedia.org/wiki/SubRip#SubRip_text_file_format
 
6:01 PM
@PeeHaa Oi! Why can't I scrape your website? :p
nm it's not you.
https seems the issue
 
@FlorianMargaine Why must you talk about Microsoft here?
 
@rdlowrey Could be me but I am getting a null response from scraping in the reactor we'd been working on.
He's so full of energy -_-
Gawd refactoring is like mind-porn.
 
@Machavity ... I don't... get it?
 
Hrm, chat references are too subtle it seems. Quote somebody and the arrow to what you replied to gets lost
just wound up being a poorly timed MS joke
 
6:21 PM
Guys do you know any global ban library?
 
Wut?
 
@Machavity no, I did see the arrow. I still didn't get it.
 
ThW
6:36 PM
Hello
 
morning @ThW
 
user1994804
After some Awesome Help from @BadHorsie I now call an AJAX from document.addEventListener('DOMContentLoaded', function() { vs onScroll but now I can't get anything from my AJAX call
 
user1994804
I've tried experimenting in many different ways but Im just guessing now.
 
Guys what is best use of GMP? I didn't get the meaning of the function yet :P
 
user1994804
and any help would be most appreciated
 
user1994804
6:43 PM
Please see AJAX at bottom here: view-source:classifieds.your-adrenaline-fix.com/…
 
user1994804
Right now the file called by AJAX just has echo 'SomeText '; and return 'MoreText'; but I'm not getting ANYTHING back
 
ThW
@YourAdrenalineFix have you checked the requests in the developer tools of your browser?
 
@JoeWatkins I was thinking about you today when we talked about C, have you ever tried Go?
 
user1994804
@THW I am VERY Unfamiliar with Chrome Dev Tools Console. Only lightly used to view source a few times
 
user1994804
and at present wouldn't know what to make of any info
 
6:50 PM
@BenjaminGruenbaum I've read about it, haven't used it for anything yet though ...
 
user1994804
Do u see anything you could clue me in on?
 
@BenjaminGruenbaum I think you've talked about this before (apologies if it was someone else)...do you have any resources that list the different methods needed for output sanitization of user data in different scopes?
 
morning btw @BenjaminGruenbaum
 
@YourAdrenalineFix Firebug might be better then. It's the original inspector tool
 
ThW
@YourAdrenalineFix I prefer Firebug (better variable output). But you need to locate your error, check the request/response data
 
user1994804
6:51 PM
I WISH I could see an error. That would be the golden clue
 
@Danack I have talked about it before but there is no one rule that solves it - you should read about XSS at OWASP.
@JoeWatkins morning, thanks btw was wondering.
 
@Fabien huh
ow PEBKAC :)
 
Hey that's not proven yet -_- :P
 
Guilty until proven innocent :D
 
user1994804
I See: Uncaught SyntaxError: Unexpected token ;
 
ThW
@ircmaxell That's what you was working at?
... amazing
 
well, it's a project I've been doing on the side
 
YAY YAY YAY
 
posted on August 29, 2014 by Anthony Ferrara

Over 1.5 years ago, I introduced PHPPHP to the world. It was the first implementation of the PHP language written in PHP itself. But PHPPHP suffered from a few problems which relegated it to toy status (such as performance). Today, I get to introduce you to another implementation of PHP, written in PHP. But this one is no toy. This one... This one is fun... Read more »

 
:-D
 
7:12 PM
@ircmaxell if I signed the CLA for other Google projects I did PRs for like Angular do I need to sign it again?
 
nope
as long as I can lookup your email, all is well
 
OMGROTFL
Google backed PHP compiler in PHP outperforms HHVM http://bit.ly/1pqMaFL (cmts http://bit.ly/1zSG3dC)
 
You might want to add coding style guidelines etc
@ircmaxell I posted your blog to YC, maybe that's it
 
7:14 PM
Yup
 
@BenjaminGruenbaum yeah that's you
 
Figured it'd help with stars and exposure and all.
Chose a "newspaper" name, hope you don't mind, might want to upvote it so it gets to the frontpage and gets you more traffic :D
 
that's some clickbait for sure
 
Obviously :D
 
@ircmaxell uh
 
7:15 PM
"Google backed?"
 
I'd feel bad upvoting it with that title...
 
seriously
I commented at least saying it was a 20% time project, and is "not official"
 
I can remove it if you want. The point was getting visits to your blog to get some contributers :D
 
perhaps "Google 20% project" instead of "Google backed"...
because it's definitely not google backed
 
Renamed.
I was going for clicks, if it's not you saying it it's ok :)
 
7:18 PM
Someone else can take the helm on the PSR-7 HTTP message proposal if they'd like: https://groups.google.com/d/msg/php-fig/XwFcqSmqzGk/eZG5QU44k3kJ
@rdlowrey I choose you!
 
yeah, just "Google backed" is kinda weird...
@ircmaxell: I don't know a stronger attribute, so you are totally insane. (In a very positive manner)
 
@ircmaxell: That is just sheer awesome! - take your loops and "Wreck it" ? :)
 
yeah, I never thought of that! So awesome
already over 1k views of the blog post... in 26 minutes... Not bad
 
yeah ... I like him, very smart, shame we don't see him around so much anymore ...
 
> I think that trying to define an interface for something as broad as HTTP in PHP is a losing battle that will likely never come to a consensus or garner much adoption if it does.


Well it's about time he realized it...
argh, how do I unquote a quote... stupid markdown
 
7:30 PM
@ircmaxell you might want to clarify contributing if you're interested in PRs
 
Oh
@ircmaxell So basically Reki-CT is HPHP back from the dead? :P
 
well, sort-of but not really
it's not all-or-nothing like HPHP
this is "run inside and along side" an existing engine. So you can port a single solitary function from an entire app
 
@Charles I don't know. And, yes although you can't make a single interface that satisfies everybody, that's the wrong goal. You should aim to make multiple small interfaces that are correct (i.e. accurately represent the underlying thing) and then more complicated interfaces, that are application specific can be built on them.
The caching PSR is a good example of how not to do it....a one interface to rule them all.
 
@ircmaxell Doesn't look like it, I see it in the new list.
 
7:33 PM
nope
 
I can see the post but no comments
 
there are no comments, just wanted to make sure that it was there
 
I see it
I wanna comment ... but all I can think is "at last" and "epic" ... which just makes me look like a stoner ...
 
to be fair, a major release, on a friday before a long weekend :-D
 
> Nothing seems like it will catch up with the global dominance that is Javascript
 
7:39 PM
Well, let them believe what they want to
 
seems biased ... can't get away from the fact I am biased, but at least my bias is grounded in reality and supported by evidence ...
 
@ircmaxell Seems like a legit comment
 
I don't disagree at all
 
Could also compare this to asm.js - you can practically compile asm.js, as a js subset, as fancy machine code. but that doesn't propagate to js as a whole
 
7:42 PM
in fact, that's the premise of the project. It's not designed to be a new standalone thing. But to work along side an existing implementation. Leave the dynamic parts to a dynamic system. But if you can gain on a more static subset, then do so
 
@ircmaxell yeah, just surprised to see a not-totally-stupid comment in a php thread on hn ;)
 
definitely :-D
 
haha
I don't comment there ... I signed up, but don't like atmosphere ...
 
and HN is down for me :-)
 
PHP broke HN.
 
7:43 PM
@JoeWatkins The types of people that regularly comment on HN are the exact types of people that make working in the tech industry in the Silicon Valley something I would never, ever consider again. I say this as a native of the area, too.
 
agree
 
q on reddit
 
how long did that first part take me? I had a POC in about a night, right? like 5 hours?
 
something like it yeah
 

« first day (1413 days earlier)      last day (3538 days later) »