Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:90685 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 43354 invoked from network); 18 Jan 2016 01:41:11 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 18 Jan 2016 01:41:11 -0000 Authentication-Results: pb1.pair.com header.from=php@golemon.com; sender-id=softfail Authentication-Results: pb1.pair.com smtp.mail=php@golemon.com; spf=softfail; sender-id=softfail Received-SPF: softfail (pb1.pair.com: domain golemon.com does not designate 209.85.215.44 as permitted sender) X-PHP-List-Original-Sender: php@golemon.com X-Host-Fingerprint: 209.85.215.44 mail-lf0-f44.google.com Received: from [209.85.215.44] ([209.85.215.44:33903] helo=mail-lf0-f44.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DA/53-20254-4B24C965 for ; Sun, 17 Jan 2016 20:41:09 -0500 Received: by mail-lf0-f44.google.com with SMTP id 17so108435681lfz.1 for ; Sun, 17 Jan 2016 17:41:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=golemon-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=P9WodnI+y72LjRA4A72zW71GXPa1nPSBIXTnzeB8tgQ=; b=QPPDXGFmehZMc0/X6x6mJgWw5flKiuUfVzFcYa7To1S0kfCpbZWr15HSeq0vYd7JuG 34aNQmisB0gpEbpnTJRenS3BZg7gbAdXjxWe2sv90fj/T+Gc/JPjz6xN9o/MLCb7gd0x 2H2wrzgSQZaHtXj+1vETmjsQaOi/kT0ttu5WaAGc7/tjhT8s0FDdNXK9eNoJ4wNkbeVm 12ULqPaSr+DhiK4ZnsYLaQb76v+R1aQ1l3b4J1N0pm3HdgUQiG6Rehl000BBeAq6/dsR pyN0veFz1FtXmZ6TWRfcvj5rtgOz1d/XYej1aYtFh1JvrK5e4aLUs+6DR2vG7X+kNT47 KpYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=P9WodnI+y72LjRA4A72zW71GXPa1nPSBIXTnzeB8tgQ=; b=SXEZUDbhQRxh7daY4i7M30MnF/wOa/swAMdJ3o+VF4+Fzo4MnrTuqIIMXWdG3pFNFW 4fK3QBv5lVkQVp1f8sP6RlhSobuC5ZRjV+DMegfUtErbJ7fHI2zwwFgeqJghJqI8oatX x0ecjeeECOF+4mBDS0yf6IoLqM5tmHs7k6Oi+EGM5CRSqnrMWtkKeJyJevUJtykwIDGr qCUNpDuJT6v8/Y4BJtYWvNfpfnTBk0UHmY+fzIKx/gicVkljLcuL6+MzA7oSnEpRtEra IyVRcjMxhfRd74rH23bHcSAfUZFgYbb4Q4ZWkcntSLzW59Pmh9AROxXk0RHdLBWFAj4X l8cw== X-Gm-Message-State: ALoCoQmQ8gOn6zT2kwAjX+TnG2x+ya3QAYCA4WPvyu+NjjsJi/iKgMGIZQYH+kbam9fNAJevzvpegJs+clSj6fyfBKIpvxMZRw== MIME-Version: 1.0 X-Received: by 10.25.17.89 with SMTP id g86mr6038354lfi.82.1453081266375; Sun, 17 Jan 2016 17:41:06 -0800 (PST) Sender: php@golemon.com Received: by 10.112.37.44 with HTTP; Sun, 17 Jan 2016 17:41:06 -0800 (PST) X-Originating-IP: [2620:10d:c090:180::9fff] In-Reply-To: References: <77.F6.12097.81D2C865@pb1.pair.com> <3F.20.05337.CEE68965@pb1.pair.com> Date: Sun, 17 Jan 2016 17:41:06 -0800 X-Google-Sender-Auth: Ifi2-4YfXQOVMeD8aW3EokDSjy0 Message-ID: To: Stig Bakken Cc: PHP internals , Andrea Faulds Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] Re: [RFC] Normalize token_get_all() output (with flag) From: pollita@php.net (Sara Golemon) On Sun, Jan 17, 2016 at 3:34 AM, Stig Bakken wrote: > On Jan 17, 2016 05:23, "Sara Golemon" wrote: >> >> Okay, i've got a starting point up at >> https://github.com/phplang/php-token . It's basically just >> token_get_all() and token_name() as they currently stand (I didn't >> even bother overriding the behavior in token_name() yet). I did >> change some of the codeflow layout a bit (and add support for scanning >> files in the process), but that's it. > > I really like this, funny really that it took until now for someone to get > enough of the old interface :) > > But rather than overloading the existing token_get_all() function with flags > that change its behavior, what about just adding a new function, say > token_get_all_assoc(), and give it a TOKEN_LINENUMS flag if you want to make > line numbers optional for performance? > Um.... this extension *is* a new interface... -Sara