🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by aotto1968 Fri, 27 Sep 2024 07:52
ruby internal technology question
#1
Author: aotto1968
Date: Fri, 27 Sep 2024 07:52
22 lines
1684 bytes
Hi, the following code from "symbol.h"

#if defined(HAVE_STMT_AND_DECL_IN_EXPR)
/* __builtin_constant_p and statement expression is available
  * since gcc-2.7.2.3 at least. */
#define rb_intern(str) \
     (RBIMPL_CONSTANT_P(str) ? \
      __extension__ ({ \
          static ID rbimpl_id; \
          rbimpl_intern_const(&rbimpl_id, (str)); \
      }) : \
      (rb_intern)(str))
#endif

#endif /* RBIMPL_SYMBOL_H */

uses

static ID rbimpl_id;

just to provide storage for the ID, why?
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads