Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 328578

Summary: Anonymous (lambda) function assigned to variable gives 'syntax error' coloring.
Product: z_Archived Reporter: Christ van Willegen <christ>
Component: PDTAssignee: PHP Core <php.core-inbox>
Status: CLOSED INVALID QA Contact: Ilina Stefanova <ilina.s>
Severity: trivial    
Priority: P3 CC: ganoro, kalin.a
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:
Attachments:
Description Flags
Attachment showing the faulty syntax highlighting. none

Description Christ van Willegen CLA 2010-10-25 05:12:29 EDT
Build Identifier: 20100917-0705

When I assign a lambda, or anonymous, function to a variable, the Syntax Checker for PHP does not accept this, and gives "syntax error, unexpected 'function'".

Reproducible: Always

Steps to Reproduce:
1. Assign a lambda function to a variable
2. Observe that the PHP syntax checker draws a red line under 'function' to indicate a syntax error.
Comment 1 Christ van Willegen CLA 2010-10-25 05:16:19 EDT
Created attachment 181620 [details]
Attachment showing the faulty syntax highlighting.

Attachment showing the syntax coloring bug
Comment 2 Roy Ganor CLA 2010-10-25 07:58:10 EDT
you should set your project interpreter to PHP 5.3.

Project > Properties > PHP Interpreter > Enable project specific > PHP 5.3
Comment 3 Kalin CLA 2011-07-29 06:53:09 EDT
Verified according to Comment 2
Closing...