PHP Classes

Will Lazy Statements Make PHP 7 Programming More Efficient ? Lately in PHP podcast episode 74

Recommend this page to a friend!
  Blog PHP Classes blog   RSS 1.0 feed RSS 2.0 feed   Blog Will Lazy Statements ...   Post a comment Post a comment   See comments See comments (0)   Trackbacks (0)  

Author:

Viewers: 903

Last month viewers: 1

Categories: Lately in PHP Podcast, News

A recent proposal is being discussed for PHP 7 feature called lazy statements. It would allow developers to assign values to variables based on code that is only executed when the variable is accessed for the first time, thus avoiding executing the code if the variable ends up never being accessed.

That was one of the main topics discussed by Manuel Lemos and Arturs Sosins in the episode 74 of the Lately in PHP podcast hangout.

They also talked about the HTTPoxy vulnerability that affects some important PHP projects, as well the usual proposals for upcoming PHP versions like autoloading for global functions, different syntax for returning $this for classes that provide fluent interfaces, support for arbitrary method in the built-in PHP Web server, a new structured object notation for creating objects, etc..

They also mentioned features to be discontinued in PHP 7.1 like SSL 2 support and some extensions that will not ship with PHP 7.1 anymore.

This article includes a transcript of the podcast summary.

Listen to the podcast, or watch the hangout video, or read the summary transcript to learn more about these interesting PHP topics.




Loaded Article

Contents

Introduction (0:20)

Summary (1:01)

PHP 5.5.38, 5.6.24, 7.0.9 released (5:59)

HTTPoxy Security Vulnerability (6:06)

Proposal: Proposal for PHP 7 class method return (14:57)

Proposal: Dropping SSL 2 in 7.1 (18:43)

Proposal: Orphaned Extensions in PHP 7.1 (22:56)

Proposal: Function autoloading using dummy namespaces (25:25)

Proposal: Support for arbitrary HTTP methods in the built-in Web server (29:10)

Proposal: Lazy statements (30:16)

Proposal: Optionally return class name from GetType (34:12)

RFC: Structured Object Notation (36:36)

RFC: E_NOTICE for invalid array container (38:37)

ElePHPants being sent to PHP Innovation Award Winners (42:11)

JavaScript Innovation Award Winners of May 2016 (43:58)

JavaScript Innovation Award Rankings of 2016 (49:08)

PHP Innovation Award Winners of May 2016 (50:44)

PHP Innovation Award Rankings of 2016 (56:31)

Conclusion (59:11)


Contents

Listen or download the podcast, RSS feed and subscribe in iTunes

Watch the podcast video, subscribe to the podcast YouTube channel

Transcript of the summary


Click on the Play button to listen now.


Download Size: 51MB Listeners: 1056

Introduction music Harbour used with explicit permission from the author Danilo Ercole, from Curitiba, Brazil

View Podcast in iTunes

In iTunes, use the Subscribe to Podcast... item of the Advanced menu, and then enter the URL above to subscribe to this podcast.

Watch the podcast video

Note that the timestamps below in the transcript may not match the same positions in the video because they were based on the audio timestamps and the audio was compacted to truncate silence periods.

See the Lately in PHP podcast play list on YouTube and Subscribe to this channel there.

Show notes

  • HTTPoxy Security Vulnerability

Summary Transcript

We are going to start as always from the latest versions of PHP, starting with PHP 5.5.38, and then PHP 5.6.24 and then PHP 7.0.9

And we will cover one vulnerability that may be affecting your PHP applications or not, or even applications in other languages, that is related with a way to inject a value for a proxy server to send remote requests and there is another article here about precisely this topic, so it gives you an idea of what is this vulnerability so you can check if your applications are vulnerable or not.

Then we start talking about the usual PHP proposals. There were several proposals this past month. First we talk about a proposal that is meant to change a bit the way you use fluent calls to objects and it s an alternative to use the return $this statement, so the next call in the chain will be able to call the same object.

The next proposal is about dropping SSL 2 support in PHP 7.1 and we'll get back to this with more detail. Then there is a proposal to move some extensions without maintainers to the PECL repository. We will talk about which are those extensions and what is expected to happen.

There there is an idea to implement auto-loading for global functions using dummy namespaces, This is actually a revival of a past proposal that did not seem to be approved, so this is an alternative for that proposal.

Then we have a proposal to add support to HTTP methods in the built in PHP Web server besides GET and POST. Then there is a proposal for a feature that they call lazy statements that you can assign variables to some code that is only evaluated when the values of those variables are accessed for the first time.

Then there is a proposal to return the class name when you call the GetType function, instead of just the type that is just object. Then there is a RFC for what is called a structured object notation, which is meant to provide an alternative way to the way that you usually create objects and call its functions using a different syntax.

Then there is finally a proposal to issue a warning when you are trying to access a value that is not really an array and you request a certain index.




You need to be a registered user or login to post a comment

Login Immediately with your account on:



Comments:

No comments were submitted yet.



  Blog PHP Classes blog   RSS 1.0 feed RSS 2.0 feed   Blog Will Lazy Statements ...   Post a comment Post a comment   See comments See comments (0)   Trackbacks (0)