This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
[Bug translator/11617] New: Gluing string literals doesn't work with token substitution
- From: "jistone at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: systemtap at sources dot redhat dot com
- Date: 21 May 2010 18:55:50 -0000
- Subject: [Bug translator/11617] New: Gluing string literals doesn't work with token substitution
- Reply-to: sourceware-bugzilla at sourceware dot org
For the string-gluing feature of bug #11208, the lexer peeks ahead after seeing
a string in case there are other strings to merge in. This fails when it
encounters something that would end up a string through token substitution (as
noticed in bug #10025 comment #11). Examples that ought to work:
stap -l 'kernel.function("do_" @1 "_open")' filp
stap -l 'kernel.function("do_" %( 1==1 %? "filp" %) "_open")'
stap -l 'kernel.function("do_" %( 1==1 %? @1 %) "_open")' filp
I think it would be easier to achieve this by moving the glue out of the lexer
and into parse_literal, roughly: "while(peek()->type == tok_string)
append(...)". We would lose the effect that comments force separation, but we
could also add a just-ate-comment flag somewhere similar to the
just-ate-whitespace flag suggested in bug #10025.
--
Summary: Gluing string literals doesn't work with token
substitution
Product: systemtap
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: translator
AssignedTo: systemtap at sources dot redhat dot com
ReportedBy: jistone at redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=11617
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.