Welcome Guest, Not a member yet? Register   Sign In
PHP 7.2 released
#36

(07-31-2019, 03:41 AM)nitin.d12 Wrote:
(12-01-2017, 08:35 AM)Narf Wrote: PHP 7.2 release announcement

In addition to the new features and other general improvements, it's even faster than 7.0 and 7.1! Go try it, and even upgrade to it if you can. Smile

Of course, if you encounter any CodeIgniter bugs related to it, you should also report them to us. 

I am a great believer in compiled languages because sloppy code prevents a successful compile. Google's Golang compiler is so strict it will not even compile if there are functions or variables declared and not used!!!

PHP was initially a very sloppy language and is now changing. To take fully advantage of the new features it is essential to use the new features which will reduce processing time. If only by a little bit Smile

It took me a couple of hours to create a PHP file to iterate through the ./system directory, add the strict declaration and remove all the errors and warnings.
 
I think this should be fixed now rather than later. Once done any additional scripting will fail fast and make debugging far easier.

Also best to declare function type parameters and return values:
PHP Code:
<?php 
declare(strict_types=1); // FILE WIDE declaration, NOT inherited with include/rquire
 
//==================================
Public function test
(
  object $conn  =  NULL,
  string $host  'localhost',
  string $user  'joe-blogs',
  string $pass  '123456',
  string $dbase 'myDataBase',
  string $table 'myTable'
)
:
bool // returned type validation
{
  $result FALSE;

  //...
  //...
  //...

  return $result;

Reply


Messages In This Thread
PHP 7.2 released - by Narf - 12-01-2017, 08:35 AM
RE: PHP 7.2 released - by Wouter60 - 12-01-2017, 10:51 AM
RE: PHP 7.2 released - by Narf - 12-02-2017, 04:18 AM
RE: PHP 7.2 released - by Wouter60 - 12-05-2017, 11:51 AM
RE: PHP 7.2 released - by SomeGuy - 12-01-2017, 11:15 AM
RE: PHP 7.2 released - by happyape - 12-13-2017, 06:29 AM
RE: PHP 7.2 released - by ivantcholakov - 12-01-2017, 11:44 AM
RE: PHP 7.2 released - by skunkbad - 12-01-2017, 04:42 PM
RE: PHP 7.2 released - by InsiteFX - 12-02-2017, 04:35 AM
RE: PHP 7.2 released - by sv3tli0 - 12-03-2017, 08:30 AM
RE: PHP 7.2 released - by Narf - 12-04-2017, 03:34 AM
RE: PHP 7.2 released - by gdhnz - 12-04-2017, 12:33 PM
RE: PHP 7.2 released - by Narf - 12-06-2017, 04:19 AM
RE: PHP 7.2 released - by nguyenthao - 12-22-2017, 01:19 AM
RE: PHP 7.2 released - by InsiteFX - 12-22-2017, 04:03 AM
RE: PHP 7.2 released - by jewelbdx - 01-03-2018, 11:36 AM
RE: PHP 7.2 released - by dave friend - 01-03-2018, 05:17 PM
RE: PHP 7.2 released - by Narf - 01-04-2018, 01:18 AM
RE: PHP 7.2 released - by rolly - 01-20-2018, 10:48 AM
RE: PHP 7.2 released - by CodeIgniter-Indonesia - 02-02-2018, 12:24 AM
RE: PHP 7.2 released - by InsiteFX - 02-02-2018, 04:05 AM
RE: PHP 7.2 released - by dexusmedia - 04-02-2018, 11:49 AM
RE: PHP 7.2.4 released - by InsiteFX - 04-03-2018, 03:17 AM
RE: PHP 7.2 released - by itstrisha - 04-25-2018, 02:48 AM
RE: PHP 7.2 released - by InsiteFX - 04-25-2018, 04:01 AM
RE: PHP 7.2.5 released - by InsiteFX - 04-27-2018, 04:19 AM
RE: PHP 7.2 released - by digi4shop - 05-04-2018, 02:07 PM
RE: PHP 7.2 released - by stef25 - 05-23-2018, 07:55 AM
RE: PHP 7.2 released - by Paradinight - 05-23-2018, 10:25 AM
RE: PHP 7.2 released - by InsiteFX - 05-23-2018, 09:25 AM
RE: PHP 7.2 released - by InsiteFX - 05-24-2018, 03:33 PM
RE: PHP 7.2 released - by arinfotech - 09-15-2018, 04:20 AM
RE: PHP 7.2 released - by InsiteFX - 09-15-2018, 08:39 AM
RE: PHP 7.2 released - by ebizzinfotech - 06-03-2019, 10:50 PM
RE: PHP 7.2 released - by nitin.d12 - 07-31-2019, 03:41 AM
RE: PHP 7.2 released - by John_Betong - 07-31-2019, 09:48 PM
RE: PHP 7.2 released - by ericasanchez - 01-09-2021, 12:36 PM



Theme © iAndrew 2016 - Forum software by © MyBB