From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6132 invoked by alias); 17 Jan 2014 20:25:49 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 5755 invoked by uid 48); 17 Jan 2014 20:25:46 -0000 From: "jistone at redhat dot com" To: systemtap@sourceware.org Subject: [Bug translator/16464] New: Token should be a mandatory part of staptree constructors Date: Fri, 17 Jan 2014 20:25:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: translator X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: jistone at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-q1/txt/msg00039.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=16464 Bug ID: 16464 Summary: Token should be a mandatory part of staptree constructors Product: systemtap Version: unspecified Status: NEW Severity: minor Priority: P2 Component: translator Assignee: systemtap at sourceware dot org Reporter: jistone at redhat dot com This is a cleanup task, with no particular known failure at the moment, but see PR16166 for example where we've been bitten before. Every staptree expression and statement should have an associated token, but currently this is left to programmer diligence to assign it. This really ought to be set as part of the constructor. This also requires trickling it down from the constructors of all the inherited classes. I believe it's also true that the chosen token of an expression or statement will never change. If so, we should also make the pointer itself const, changing it to "const token* const". We might even make it "const token&", to emphasize its nonnull-ness, but that would increase the scope of refactoring. -- You are receiving this mail because: You are the assignee for the bug.