[ruby-core:105599] [Ruby master Feature#13125] MRI has too much Qtrue : Qfalse;
From:
"jeremyevans0 (Jeremy Evans)" <noreply@...>
Date:
2021-10-07 20:40:47 UTC
List:
ruby-core #105599
Issue #13125 has been updated by jeremyevans0 (Jeremy Evans). Status changed from Open to Closed `RBOOL` was recently introduced for this purpose. ---------------------------------------- Feature #13125: MRI has too much Qtrue : Qfalse; https://bugs.ruby-lang.org/issues/13125#change-94071 * Author: shyouhei (Shyouhei Urabe) * Status: Closed * Priority: Normal ---------------------------------------- ``` % git grep -P 'Q(true|false|nil|undef)\s+:\s+Q(true|false|nil|undef)' | wc -l 211 ``` Out of those 211 occurrences the most interesting lines include: ``` complex.c:#define f_boolcast(x) ((x) ? Qtrue : Qfalse) math.c:#define f_boolcast(x) ((x) ? Qtrue : Qfalse) range.c:#define RBOOL(v) ((v) ? Qtrue : Qfalse) rational.c:#define f_boolcast(x) ((x) ? Qtrue : Qfalse) ``` I strongly believe that we need an orthodox way to do this. -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>