1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- #include "codepointiterator_internal.h"
- extern "C" {
- #define USE_BREAKITERATOR_POINTER 1
- #include "breakiterator_class.h"
- }
- using PHP::CodePointBreakIterator;
- static inline CodePointBreakIterator *fetch_cpbi(BreakIterator_object *bio) {
- return (CodePointBreakIterator*)bio->biter;
- }
- U_CFUNC PHP_FUNCTION(cpbi_get_last_code_point)
- {
- BREAKITER_METHOD_INIT_VARS;
- object = getThis();
- if (zend_parse_parameters_none() == FAILURE) {
- intl_error_set(NULL, U_ILLEGAL_ARGUMENT_ERROR,
- "cpbi_get_last_code_point: bad arguments", 0);
- RETURN_FALSE;
- }
- BREAKITER_METHOD_FETCH_OBJECT;
- RETURN_LONG(fetch_cpbi(bio)->getLastCodePoint());
- }
|