[前][次][番号順一覧][スレッド一覧]

ruby-changes:41596

From: duerst <ko1@a...>
Date: Wed, 27 Jan 2016 18:53:44 +0900 (JST)
Subject: [ruby-changes:41596] duerst:r53670 (trunk): * enc/unicode.c: Fixed bit mask in macro OnigCodePointCount

duerst	2016-01-27 18:54:38 +0900 (Wed, 27 Jan 2016)

  New Revision: 53670

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=53670

  Log:
    * enc/unicode.c: Fixed bit mask in macro OnigCodePointCount

  Modified files:
    trunk/ChangeLog
    trunk/enc/unicode.c
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 53669)
+++ ChangeLog	(revision 53670)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Wed Jan 27 18:53:40 2016  Martin Duerst  <duerst@i...>
+
+	* enc/unicode.c: Fixed bit mask in macro OnigCodePointCount
+
 Wed Jan 27 17:54:42 2016  Martin Duerst  <duerst@i...>
 
 	* enc/unicode.c: Protect code point count by macro, in order to
Index: enc/unicode.c
===================================================================
--- enc/unicode.c	(revision 53669)
+++ enc/unicode.c	(revision 53670)
@@ -72,7 +72,7 @@ static const unsigned short EncUNICODE_I https://github.com/ruby/ruby/blob/trunk/enc/unicode.c#L72
 };
 
 /* use bottom bytes for actual code point count; 3 bits is more than enough */
-#define OnigCodePointCount(n) ((n)&0x111)
+#define OnigCodePointCount(n) ((n)&0x7)
 
 typedef struct {
   int n;

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]