From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt1-x82b.google.com (mail-qt1-x82b.google.com [IPv6:2607:f8b0:4864:20::82b]) by sourceware.org (Postfix) with ESMTPS id D2236385842E for ; Mon, 3 Jan 2022 17:04:15 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D2236385842E Received: by mail-qt1-x82b.google.com with SMTP id l17so30960365qtk.7 for ; Mon, 03 Jan 2022 09:04:15 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=EJF1vRdz9VVRLZX/kJTcc7W4v2CRPQ1B+XyBkq9yqcQ=; b=EI8JK8AZVIm+0+TRm99fHforr+KTHil+NrDAedXz49QPk9p2QYvQY6kSVnUx2cGHVu Ff/kjdtFjkTOaddOpBRXBeU8q2tNgc6y4NBOGKpIQzEZ5w0BtfcwSbIJEmMdfVkAIUAS BhYWAgpj5Dnf8CAdgFJKdriNGkyLmoiFKxSTTiJhnEhN5jRKtUCu4AZLzii2wokJI/tN PE1JTthgLco8/ZuzrpAAgGL8zlmD9ESfEmCZrCcPIsodNf/ExRIGAjj/DHUo7FeXEGkt odXha6W0Wgkja85zqZXwgNQzDE3xvztopF8KxaYjqRLfONZoOgBT3BooF10LMz0SY9sK SwDA== X-Gm-Message-State: AOAM533naHrOWfTJAq6y640BcTJgDDqB4PNUmsWbkgHaAfo6SxJXH+o/ keT3Q1nXyExZx9VZss5iqFd4FQ== X-Google-Smtp-Source: ABdhPJxGhMuwTSWL6saeml2IANz4ZoV68jV84iDt3pYHyMqp5WOPo8olK7AP9QmrunodjC6rov4mTQ== X-Received: by 2002:a05:622a:1756:: with SMTP id l22mr40526823qtk.86.1641229455420; Mon, 03 Jan 2022 09:04:15 -0800 (PST) Received: from ?IPV6:2804:431:c7ca:a350:6969:50a8:eab8:8f2f? ([2804:431:c7ca:a350:6969:50a8:eab8:8f2f]) by smtp.gmail.com with ESMTPSA id w14sm30108573qkp.54.2022.01.03.09.04.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 03 Jan 2022 09:04:15 -0800 (PST) Message-ID: <2d754405-7aff-9fab-ca22-2ece84b3468b@linaro.org> Date: Mon, 3 Jan 2022 14:04:13 -0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.4.0 Subject: Re: examples of customized printf Content-Language: en-US To: Basile Starynkevitch , libc-help@sourceware.org References: <9eecb822-d055-20c1-44ee-82ce83fce54a@starynkevitch.net> From: Adhemerval Zanella In-Reply-To: <9eecb822-d055-20c1-44ee-82ce83fce54a@starynkevitch.net> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.6 required=5.0 tests=BAYES_00, BODY_8BITS, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, KAM_SHORT, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: libc-help@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-help mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2022 17:04:17 -0000 On 28/12/2021 07:31, Basile Starynkevitch wrote: > Hello all,, > > > For the RefPerSys project (see http://refpersys.org/ and code on https://github.com/RefPerSys/refpersys-in-c/ ....) we need several examples of > > >      Customizing |printf| > > > We want %V to print RpsValue_t ( intptr_t, when odd it is a tagged integer, when even and non-null it is a valid pointer to some struct). > > > Examples of customizing printf for GNU guile could be enough. > > > > Happy new year 2022. You can reference glibc own manual [1] on how to customize the printf. Keep in mind this is a gnu extension. [1] https://www.gnu.org/software/libc/manual/html_node/Customizing-Printf.html