[cfe-commits] BCPL comments not recognized when computing preamble
Matthias Kleine
matthias_kleine at gmx.de
Thu Aug 25 01:05:45 PDT 2011
On Aug 24, 2011, at 7:17 PM, Argyrios Kyrtzidis wrote:
> On Aug 24, 2011, at 9:21 AM, Matthias Kleine wrote:
>
>> Is there any reason Lexer::ComputePreamble does not take external LangOptions into account, but uses default-constructed ones? As a result, source files that start with BCPL-comments are recognized as having no preambles, even if the file's language supports such comments.
>>
>> Would the attached patch solve the problem?
>
> Look good, could you also please add a test case as well ?
I extended an existing preamble-test to reproduce the failing behavior. Here's a patch.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_pass_lang_options_to_compute_preamble.patch
Type: application/octet-stream
Size: 632 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20110825/b03a2d32/attachment.obj>
-------------- next part --------------
Cheers,
Matthias
More information about the cfe-commits
mailing list