public function list() generates a syntax error

  • From: Geoff Hoffman < >
  • To: PHP NetBeans Users < >
  • Subject: public function list() generates a syntax error
  • Date: Wed, 7 Nov 2012 16:42:10 -0700

Sample code:

class foo { 
    public function list() {
        // stuff

Syntax error: Expected identifier, &

NetBeans complains hard about line 2. It's inside of a class scope, so I'm not sure why. Is that a bug? 

If it were complaining about PHP's built in list( ) function, the error should say something like list function exists in php core or some such.

Connect with us on twittergoogle+facebook, or linkedin.

Catch our next training in Phoenix Nov 12 - 16Chicago Nov 19 - 23San Jose Dec 3 - 7Los Angeles Dec 10 - 14 or See All.

This email, including any attachments, is for the sole use of the intended recipient and may contain confidential information. If you are not the intended recipient, please immediately notify us by reply email or by telephone, delete this email and destroy any copies. Thank you.

public function list() generates a syntax error

Geoff Hoffman 11/07/2012

Project Features

About this Project

PHP was started in November 2009, is owned by Petr Jiricka, and has 307 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20160708.bf2ac18). © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
Please Confirm