« first day (1628 days earlier)      last day (3320 days later) » 

9:00 PM
The last question of any kind of import is what to do with self and parent.
 
@LeviMorrison good point!
 
@LeviMorrison that should be fully qualified by that point, no? doesn't the compiler compile it out?
 
@ircmaxell At least when I did my implementation it compiled it out but that wasn't stored.
 
ah
 
9:01 PM
Had something to do with better error messages, I think.
I'm okay with storing it after resolving it to its actual name.
 
I think we should return the resolved name for self/parent from reflection if only to allow compile-time resolving this in the future
Would have a problem there otherwise
And also, chances are people are just gonna manually resolve anyway...
 
$ sapi/cli/php -r 'class Foo { public function bar(self $foo) {} } $r = new ReflectionMethod("Foo", "bar"); var_dump($r->getParameters()[0]->getClass());'
object(ReflectionClass)#3 (1) {
  ["name"]=>
  string(3) "Foo"
}
 
Sounds fine to me.
 
By the way, let's deprecate parent and static from argument types [and return types if they are allowed there currently]
 
Is "static" allowed? I thought it wasn't
 
9:06 PM
Static is not allowed.
In parameter types it violates type soundness.
 
Ah okay, parent then
 
actually, do we want getClass() method? Which returns a ReflectionClass instance?
 
In return types it's just not supported.
No. Just do new ReflectionClass($type).
 
agree with levi
 
(or new ReflectionClass((string) $type))
 
9:08 PM
kk
 
Possibly of interest @LeviMorrison mtuner.net
 
@Danack Have you used it?
 
@ircmaxell @LeviMorrison Great work everyone, nice that this got wrapped up so quickly. Now just gotta push this through internals ^^
 
@LeviMorrison nope.
 
@NikiC "wrapped" :-P
 
9:10 PM
I'd like to be the one to actually implement it if we aren't in a hurry.
 
@LeviMorrison for practice?
Personally I'd like to have this in sooner rather than later
 
for credit perhaps
which he does really deserve
 
@NikiC Because I didn't ship return types with it.
 
@nikita2206 parent is allowed even if there is no parent 3v4l.org/XTb53
 
9:13 PM
@ircmaxell This was pretty funny :)
"That's not just a cloud, honey."
 
@LeviMorrison "Okay"
that last line killed me
 
@ircmaxell totally
 
@marcio yep
 
@ircmaxell @LeviMorrison just one last thing - we don't want to use any null object pattern on this, right? If there's no typehint, then getType() and getReturnType() just return null?
(Alternatively throw an exception and require using hasType/hasReturnType beforehand - dunno about that, seems unnecessary)
 
9:28 PM
I do want to use a null object, but considering the rest of reflection doesn't use it (and returns null) I think consistency is more important there
 
lol
 
Guys , i REALLY need your help with something real quick
I have this site that echo data as Json : www.roimulia.com/db.php
 
9:43 PM
@LeviMorrison eih… first thought… does it accept a class name!? (or an actual object of a class?)
 
And this other site that is working good for me when i parse it in xCode
For some reason m i belive that the PHP code for my url is on some way bad
Do you see any diffrence between the two pages?
Please it's very important :/
 
@ircmaxell you have much fun posting vids today ...
 
@hakre Mind check it mate?
 
Each byte I touch costs hard money.
2
 
@roimulia Just make sure you stay under 8 bits
 
9:48 PM
I will buy you PIZZA
guys this is my code : header('Content-Type: application/json');



try {
$pdo = new PDO('mysql:host=localhost;dbname=xx3mg', $user, $pass,array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES utf8"));
$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);

} catch(PDOException $e) {
echo 'ERROR: ' . $e->getMessage();
}


$statement = $pdo->query("SELECT * FROM Post_Table ORDER BY DATE_CREATE DESC LIMIT 100 OFFSET 0");

$results = $statement->fetchAll(PDO::FETCH_ASSOC);
$results = array("decisions"=>$results);
Does it look like the json dosent echo correctly?
Im already 4 days on that piece of code and it making me crazy
 
PIZZA, BEER, ITALIAN JAMBON, FRENCH CHEESE, CHAMAGNE, FRUITS, FRESH SALADS and STOP SPAMMING THE ROOM WITH CODE YOU HAVE TO READ BUT NONE ELSE MUST READ IT.
 
I'm sorry , its not a shame to ask for help :( im helping when ever i can
and this time i need help
 
In long years of PHP system experience I've found out that echo most often operates correctly and is not the culprit.
9
I take one euro per byte.
on your bill so far: "echo correctly?"
 
@roimulia use a gist -.-
 
and "In long years of PHP system experience I've found out that echo most often operates correctly and is not the culprit."
 
9:54 PM
im trying and i still think everything is okay
but still something wrong
 
the truth is, only in theory right and wrong. in reality there is google search.
 
Dude im killing google for 5 hours
I thought it might be in xCode
 
that sentence I have to bill with 4 euros per character because of a 32 bit charset.
 
but than i switched to another url . and it worked perfectly
so i copied the data from the good url to a file , and upload it to my server
and it worked as well
Conclusion - something wrong with my php
Hakre can you please assist me?
I dont want to bag
Just one time favor
 
from the help I've given so far, what would you estimate, how much more help do you need?
 
10:00 PM
I need as simple as that
 
and in numbers, that would be?
 
if you are a PHP programmer you would know if something missing in this code
I dont
If you would come to NSChat and asked quetions
i can promise you i would help you as much as i can
 
i'm just asking as you showed interest. so in numnbers, how many times more than what I've done so far?
 
ok relax
 
Actually beside being sarcastic , you havent done much
And that's a shame , but do what ever make's you feel good . I just hope for you that in real life , when a real person stand infront of you
try to be kinder
 
10:09 PM
@NikiC not exactly debugging, just fixing obvious problems with that test, but I was lazy and not start the vm with the mysql instance to actually execute the test, made two stupid copypaste errors :/ classic
but yeah, curious what kind of exception did we got in master in that test which revealed the problem that we had the wrong variable name in the catch debug output
 
10:32 PM
@roimulia var_dump($aVariableHere); die; each line of your code ensuring that each variable holds exactly the data you expect at all times.
also read room-11.github.io if you have time. It will lead to better ways for asking help in this channel
 
10:49 PM
@NikiC is it expected that fastroute will barf when a route definition contains capturing groups? Needed an optional param and did something like {foo:([^/]*)?}
Turned it into a non-capturing group and it worked correctly.
Looks like the barf is actually in my code - it sees FOUND but the handler is null, probably because the regex broke, and calling null as a function kinda doesn't work.
 
11:56 PM
@NikiC FYI don't waste your time reviewing my PR yet. I see you have plenty of stuff to review so just focus on the high priority things first :)
 

« first day (1628 days earlier)      last day (3320 days later) »