From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eduardo Ochs Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Re: Make peg.el a built-in library? Date: Sun, 5 Feb 2023 13:19:10 -0300 Message-ID: References: <875yvtbbn3.fsf@ericabrahamsen.net> <877d07a16u.fsf@localhost> <87tu3asg2r.fsf@ericabrahamsen.net> <87edud25ov.fsf@localhost> <87a6511ku0.fsf@ericabrahamsen.net> <87wn85z0zl.fsf@ericabrahamsen.net> <87leobplpv.fsf_-_@ericabrahamsen.net> <87o7r5ikpm.fsf@web.de> <87bkn5wl7o.fsf@localhost> <87a62p2v3c.fsf@web.de> <874js0e2jm.fsf@localhost> <87v8kgce0n.fsf@localhost> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="34584"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Michael Heerdegen , emacs-devel@gnu.org To: Ihor Radchenko Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Feb 05 17:20:21 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pOhkb-0008q4-DX for ged-emacs-devel@m.gmane-mx.org; Sun, 05 Feb 2023 17:20:21 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pOhji-0004i4-Uh; Sun, 05 Feb 2023 11:19:26 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pOhjh-0004ht-Qm for emacs-devel@gnu.org; Sun, 05 Feb 2023 11:19:25 -0500 Original-Received: from mail-yb1-xb2c.google.com ([2607:f8b0:4864:20::b2c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pOhjf-0001bh-Go for emacs-devel@gnu.org; Sun, 05 Feb 2023 11:19:25 -0500 Original-Received: by mail-yb1-xb2c.google.com with SMTP id 23so4669007ybf.10 for ; Sun, 05 Feb 2023 08:19:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=KQM+ZtV1pohkj/l2F1XgcA8UYTDVrBETuD6j17KUkiM=; b=dQHYRayDNGeaOHMM37ujQg1Nya2NcWzLzwbwMW14WhT6XcLa4mAC2EK+ef7KOTeu1T Vmlh1CKSnHGj8RDUoybgJgJ5U9fKZRlw9srONm8w+JnhdtQnNvob/X/y6Ho9ec26cr8K HweHukx5Y21/ZxaqNijcUD/Dg1vikV5HD9sepBuQ+Q5Ll8QUfbx/1r5Lnh4HsYME8JsD ygnt2PsMwtAa3IvWXFJVOr6QyddUyn2U1SLE4lvcXue5kITUo9En7eopl5bkpb1i2N9l KDj9Ho6UaRaX9LkySsdN/Fq3YkGLvkrD3VjDNoGY3a+9QmOp3KrxqNxMsFCuIBelgFln dtDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=KQM+ZtV1pohkj/l2F1XgcA8UYTDVrBETuD6j17KUkiM=; b=DyR3zAz0cT5JLLPvd9BqhUzyhv02jCQuCuZyzCgms3q41dBhOXu45aeDloMQl52dll HEVnqaPhaKhektvQxqMIaAK4Z03eTRZZcHLvFLt+kZuhOpD/BrBnfHF62jvq6F1/8eEQ RmtFrN0H0val3dFVkgBpouEruxO/1FhQTxb0oxk772oXZ5XjVMScT2OvtV/Rk1yo7Z9i qn3INtA4Vq3F2YZSgO0stNR8nEaOSwNL+yJToAqPFQEttxZ+68KQoMkiNvaicSSvbGPn 1S8bW6w88aO6vRRRaxdboKndk27hkbAQLK3naGaGbgZl+/KkSQT31cdp2kzpFzX0mBgp zwZg== X-Gm-Message-State: AO0yUKUMtWjnYDnQKwvT+JlJkyfMSU7XInUTn+/dMTcxZT+KFNxGodA4 LHBU7PwmpvTUqvYUDwm6gVIsXqgIke3+xQQouvw= X-Google-Smtp-Source: AK7set885kXmwUQw3cR+WBokitX6f9eO8thuUTMARXTglPvVj9y7UGcxGYY5bw85Unok13saOt7KYJIkoXW40gXXZes= X-Received: by 2002:a05:6902:1006:b0:80b:6369:e336 with SMTP id w6-20020a056902100600b0080b6369e336mr1434247ybt.561.1675613962254; Sun, 05 Feb 2023 08:19:22 -0800 (PST) In-Reply-To: <87v8kgce0n.fsf@localhost> Received-SPF: pass client-ip=2607:f8b0:4864:20::b2c; envelope-from=eduardoochs@gmail.com; helo=mail-yb1-xb2c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:303004 Archived-At: On Sun, 5 Feb 2023 at 12:44, Ihor Radchenko wrote: > > Eduardo Ochs writes: > > >> > AFAIR not all Emacs regexp features work in PEGs - backrefs for example. > >> > Or match data handling. > >> > >> Sure. But if we make Emacs regexp a valid PEG construct, they will work. > >> It is the whole point. > > > > I played a bit with peg.el some time ago - it is very elegant and it's > > very easy to inspect how it does things, but it is much slower than > > Lua's LPEG... > > What do you mean by slower? I wrote a simple peg.el parser and it took two seconds to parse an input that has just 2KB. The lpeg parser that I use to htmlize some of my files take about 0.5s to parse a file with 3MB and to return the htmlized version. [[]], E.