mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-13 05:07:03 +03:00
* Fix Lexeme.check_flag
This commit is contained in:
parent
9e7bfe8449
commit
e7e529edf4
|
@ -72,7 +72,8 @@ cdef class Lexeme:
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
cdef inline bint check_flag(const LexemeC* lexeme, attr_id_t flag_id) nogil:
|
cdef inline bint check_flag(const LexemeC* lexeme, attr_id_t flag_id) nogil:
|
||||||
return lexeme.flags & (1 << flag_id)
|
cdef flags_t one = 1
|
||||||
|
return lexeme.flags & (one << flag_id)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
cdef inline bint set_flag(LexemeC* lex, attr_id_t flag_id, int value) nogil:
|
cdef inline bint set_flag(LexemeC* lex, attr_id_t flag_id, int value) nogil:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user