From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Matt Wette Newsgroups: gmane.lisp.guile.user Subject: [ANN] nyacc 1.05.0 released Date: Sun, 5 Sep 2021 10:11:42 -0700 Message-ID: <63c5dd05-b882-c351-49ed-2b78b20d7245@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17093"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 To: Guile User Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Sun Sep 05 19:12:01 2021 Return-path: Envelope-to: guile-user@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 1mMvgX-0004IJ-1i for guile-user@m.gmane-mx.org; Sun, 05 Sep 2021 19:12:01 +0200 Original-Received: from localhost ([::1]:37964 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mMvgV-0000K4-UJ for guile-user@m.gmane-mx.org; Sun, 05 Sep 2021 13:11:59 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48420) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mMvgK-0000Jw-ES for guile-user@gnu.org; Sun, 05 Sep 2021 13:11:48 -0400 Original-Received: from mail-pj1-x1035.google.com ([2607:f8b0:4864:20::1035]:41682) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mMvgI-0006kp-Ky for guile-user@gnu.org; Sun, 05 Sep 2021 13:11:48 -0400 Original-Received: by mail-pj1-x1035.google.com with SMTP id z24-20020a17090acb1800b0018e87a24300so3036267pjt.0 for ; Sun, 05 Sep 2021 10:11:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:from:subject:message-id:date:user-agent:mime-version :content-transfer-encoding:content-language; bh=v1QOfBS1XVzGwWt50xLYDD8Fi0X9q0D4/pfpltFgGhI=; b=aiqoxoHhL9W3nPZ4e5l80YDBSIL0SeDD9a3klkMYA0NglvRm/rVFEe8mYPcTJJJ80V KZoDugdzQFDeQ25BGrxlCHdmuBaOsSyP0fUzAzU5LfwY2cAhVfnEBjkiBqg4awqpt+yh Cw7l0F+tStrxgQS64dVoJky7jYt7fgBull82KDUDbKQ1unZOhA7Z7MH/XOHaOKRccikQ ddlP37SaA4h9eS/2Mp/8lJdZwc6AweeYU/QrXuGk+dD2PIRKuYs7urPPe+j74MoyAIzw 2NiykjB5pmtW/o9HqBuW47w92+yfGvcdK/Q7x4R1vC5EsfpYJVUhYmqQRLkON8Qoy9Zz 4XUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding:content-language; bh=v1QOfBS1XVzGwWt50xLYDD8Fi0X9q0D4/pfpltFgGhI=; b=kEHQ6XOdylbc2iRcHRgTpsYUN6zoN1AnDox/Hac272DCZ2zyitaIyyr0ag7i7knyda 9U1Ohc36LL1PIDOcnSH+dmdYOenYJrro0uCaZxl1Bf+w+uW7coHqRRy9awlfXlEc36oP ZxpGayEsHFxefndmGKCtJMQLNr+gt/Lk120Cz1Tk2x0lp41jJAmSvhVXemaGXg/aiGDn XgnPHIobREp3ocKhj+4kUYWTbeNjHxC8zrCW7931zTa0F3PgJpE6D2Kf/VMqj8wek9bP o9MlyQHJx2VH/QcXkwq76rNT+BWDpDh0m/K0j/H2crIOMwrWZ3GfdTUCaREq8FUkzW6G 9QZw== X-Gm-Message-State: AOAM5329Wmkwx0bZlVWbWyRG9xutym4i04sfCD/rPpkVq9oTIN/251Cc Ng6tE4GrjxSPXkPGdPL3phj9s1M5VNk= X-Google-Smtp-Source: ABdhPJwlAas4D+MoCd2sJHCHbSkwp+8fKu6sOsBAfqd6nyLLtkU/NcQD2AA9tkKc80nVnNDvxnQSLQ== X-Received: by 2002:a17:90a:af86:: with SMTP id w6mr9839555pjq.8.1630861904257; Sun, 05 Sep 2021 10:11:44 -0700 (PDT) Original-Received: from [192.168.2.163] (64-52-176-132.championbroadband.com. [64.52.176.132]) by smtp.gmail.com with ESMTPSA id y5sm6184579pgs.27.2021.09.05.10.11.43 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 05 Sep 2021 10:11:43 -0700 (PDT) Content-Language: en-US Received-SPF: pass client-ip=2607:f8b0:4864:20::1035; envelope-from=matt.wette@gmail.com; helo=mail-pj1-x1035.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: guile-user@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:17716 Archived-At: NYACC, for Not Yet Another Compiler Compiler, is set of guile modules for generating parsers and lexical analyzers. It also provides sample parsers and pretty-printers using SXML trees as an intermediate representation. It provides a decent C parser and a `FFI Helper' tool to help create Guile Scheme bindings for C-based libraries. It provides (partially implemented) compilers based on above mentioned parsers to allow execution with Guile as extension languages. NEWS for V1.05.0 * remove dependence on srfi-43, vector operations; this was causing issues with some Guile versions 2.0.X * cleaned up c99-error exception messages in compile-ffi * examples/ffi/termios.ffi: added def-keepers * in following, $ENL = examples/nyacc/lang * removed $ENL/ecmascript * $ENL/javascript: merged body.scm into parser.scm * install/uninstall read-line-code now returns # * $ENL/tcl/parser.scm: fixed reading array index as number; (1,2,3) was read as number, now as string * scripts/compile-ffi: add option -s to show includes being read * c99 parser def-help now adds apple dependencies * worked on ffi-helper per-decl usage (i.e. C-decl syntax) * updated "make check" to provide overall sucess/fail message Example using FFI helper w/o define-ffi-module: mwette$ guile ... scheme@(guile-user)> ,use (nyacc lang c99 ffi-help) scheme@(guile-user)> ,pp (C-decl->scm "struct foo { int x; double y; };") $1 = (bs:struct (list `(x ,int) `(y ,double))) scheme@(guile-user)> scheme@(guile-user)> ,use (bytestructures guile) scheme@(guile-user)> ,use (system ffi-help-rt) scheme@(guile-user)> (use-modules ((system foreign) #:prefix ffi:)) scheme@(guile-user)> scheme@(guile-user)> (define struct-foo-desc (C-decl "struct foo { int x; double y; };")) scheme@(guile-user)> (define-fh-compound-type struct-foo struct-foo-desc struct-foo? make-struct-foo) scheme@(guile-user)> (make-struct-foo) $2 = # scheme@(guile-user)> scheme@(guile-user)> (define my-sqrt (C-decl "double sqrt(double);")) scheme@(guile-user)> (my-sqrt 4.0) $3 = 2.0 scheme@(guile-user)> mwette$ guile ... scheme@(guile-user)> ,use (nyacc lang c99 ffi-help) scheme@(guile-user)> ,d load-include-file - Procedure: load-include-file filename [#:pkg-config pkg] This is the functionality that Ludo was asking for: to be at guile prompt and be able to issue (use-modules (nyacc lang c99 ffi-help)) (load-include-file "cairo.h" #:pkg-config "cairo") scheme@(guile-user)> (load-include-file "cairo.h" #:pkg-config "cairo") ... NYACC maturity is production/stable level. NYACC is free software; the full source distribution is available through * the tarball repository: https://download.savannah.gnu.org/releases/nyacc/ * the git repository: git://git.savannah.nongnu.org/nyacc.git home page, project page and user's guides: * https://www.nongnu.org/nyacc * https://savannah.nongnu.org/projects/nyacc * https://www.nongnu.org/nyacc/nyacc-ug.html * https://www.nongnu.org/nyacc/ffi-help.html Report bugs: * https://savannah.nongnu.org/bugs/?group=nyacc Get support: * https://savannah.nongnu.org/support/?group=nyacc