<< Back to previous view

[PCC-394] error: out of macro space! Created: 20/Jun/12  Updated: 28/Jul/12

Status: Resolved
Project: pcc
Component/s: C preprocessor
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: Hannes Loeffler Assignee: Anders Magnusson
Resolution: Fixed Votes: 0

File Attachments: File macro.c    

 Description   
Hi,

I am not sure if this is really a bug or just my poor understanding of the preprocessor but the attached file will cause an error message if run with 'cpp macro.c':

macro.c:10: error: out of macro space!

The problem is obviously caused by the terminating slash in line 2. If removed cpp expands the macros just fine.

 Comments   
Comment by Anders Magnusson [ 27/Jul/12 09:44 PM ]
The construction // is created inside the macro while expanding, causing cpp to assume that it is a comment.
Logic must be added to distinguish this from a comment that is legal, created by -C for lint.
Comment by Anders Magnusson [ 28/Jul/12 10:21 PM ]
Fixed now, thanks for the bug report!
Generated at Sun Dec 21 20:23:41 CET 2014 using JIRA Enterprise Edition, Version: 3.13.1-#333.