From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Vivien Kraus via General Guile related discussions Newsgroups: gmane.lisp.guile.user Subject: Are char* and signed char* compatible (SCM_BYTEVECTOR_CONTENTS)? Date: Fri, 26 Feb 2021 10:33:09 +0100 Message-ID: <768f0a03350676677860ab874f79904a5acbe75b.camel@planete-kraus.eu> Reply-To: Vivien Kraus Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20303"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Evolution 3.34.2 To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Fri Feb 26 10:41:05 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 1lFZcN-00059A-Dv for guile-user@m.gmane-mx.org; Fri, 26 Feb 2021 10:41:03 +0100 Original-Received: from localhost ([::1]:51372 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lFZcM-0005iS-AO for guile-user@m.gmane-mx.org; Fri, 26 Feb 2021 04:41:02 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:32976) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lFZV0-0005nd-Ca for guile-user@gnu.org; Fri, 26 Feb 2021 04:33:27 -0500 Original-Received: from [2a00:5881:4008:2810::309] (port=36192 helo=planete-kraus.eu) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1lFZUw-0003pt-BR for guile-user@gnu.org; Fri, 26 Feb 2021 04:33:25 -0500 Original-Received: from planete-kraus.eu (localhost.lan [127.0.0.1]) by planete-kraus.eu (OpenSMTPD) with ESMTP id 0690a795 for ; Fri, 26 Feb 2021 09:33:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=planete-kraus.eu; h= message-id:subject:from:to:date:content-type:mime-version :content-transfer-encoding; s=*; bh=soQIAnv4j81iNxUqtt1qXykCcCc=; b= wcAb4s4b50sGV6JFFmg5SWao4+HtMkPSQ/eGqmTngdelBPaHASYYODG0gv6FKi/V WPBREGU13Ys3plOEHz5bD38usUicreg5grWgnGUOg3Pi8q6QqlxMTnDxkXMGuiZ7 j/mowCH1/BPYL7Hci1X0d130/2hH2M9oGKYZEKLOAaw= Original-Received: by planete-kraus.eu (OpenSMTPD) with ESMTPSA id c3f6841c (TLSv1.2:ECDHE-RSA-CHACHA20-POLY1305:256:NO) for ; Fri, 26 Feb 2021 09:33:12 +0000 (UTC) X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:5881:4008:2810::309 (failed) Received-SPF: pass client-ip=2a00:5881:4008:2810::309; envelope-from=vivien@planete-kraus.eu; helo=planete-kraus.eu X-Spam_score_int: 10 X-Spam_score: 1.0 X-Spam_bar: + X-Spam_report: (1.0 / 5.0 requ) BAYES_40=-0.001, DKIM_INVALID=0.1, DKIM_SIGNED=0.1, RDNS_NONE=0.793, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=no 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:17315 Archived-At: Hello, I’m trying to use a bytevector from C. 1. According to an example in the manual, SCM_BYTEVECTOR_CONTENTS can be assigned to a char*. 2. Also from the manual, it is a signed char*. 3. I've found this question online saying they are not compatible ( https://stackoverflow.com/questions/12769500/why-is-char-not-compatible-with-signed-char-or-unsigned-char ). As I understand it, at least one of the above 3 affirmations is incorrect. Could someone clarify this to me?