Ruby 1.9.3p327(2012-11-10revision37606)
Defines | Functions | Variables
ext/nkf/nkf.c File Reference
#include "ruby/ruby.h"
#include "ruby/encoding.h"
#include "nkf-utf8/config.h"
#include "nkf-utf8/utf8tbl.c"
#include "nkf-utf8/nkf.c"
Include dependency graph for nkf.c:

Go to the source code of this file.

Defines

#define RUBY_NKF_REVISION   "$Revision: 27947 $"
#define RUBY_NKF_VERSION   NKF_VERSION " (" NKF_RELEASE_DATE ")"
#define getc(f)   (input_ctr>=i_len?-1:input[input_ctr++])
#define ungetc(c, f)   input_ctr--
#define INCSIZE   32
#define putchar(c)   rb_nkf_putchar(c)
#define PERL_XS   1

Functions

static int rb_nkf_putchar (unsigned int c)
rb_encodingrb_nkf_enc_get (const char *name)
int nkf_split_options (const char *arg)
static VALUE rb_nkf_convert (VALUE obj, VALUE opt, VALUE src)
static VALUE rb_nkf_guess (VALUE obj, VALUE src)
void Init_nkf ()

Variables

static unsigned char * output
static unsigned char * input
static int input_ctr
static int i_len
static int output_ctr
static int o_len
static int incsize
static VALUE result

Define Documentation

#define getc (   f)    (input_ctr>=i_len?-1:input[input_ctr++])

Definition at line 21 of file nkf.c.

Referenced by std_getc().

#define INCSIZE   32

Definition at line 24 of file nkf.c.

Referenced by rb_nkf_convert().

#define PERL_XS   1

Definition at line 59 of file nkf.c.

#define putchar (   c)    rb_nkf_putchar(c)

Definition at line 28 of file nkf.c.

Referenced by std_putc().

#define RUBY_NKF_REVISION   "$Revision: 27947 $"

Definition at line 10 of file nkf.c.

#define RUBY_NKF_VERSION   NKF_VERSION " (" NKF_RELEASE_DATE ")"

Definition at line 11 of file nkf.c.

Referenced by Init_nkf().

#define ungetc (   c,
 
)    input_ctr--

Definition at line 22 of file nkf.c.


Function Documentation

void Init_nkf ( )
int nkf_split_options ( const char *  arg)

Definition at line 77 of file nkf.c.

References count, FALSE, options(), and TRUE.

Referenced by rb_nkf_convert().

static VALUE rb_nkf_convert ( VALUE  obj,
VALUE  opt,
VALUE  src 
) [static]
rb_encoding* rb_nkf_enc_get ( const char *  name)
static VALUE rb_nkf_guess ( VALUE  obj,
VALUE  src 
) [static]
static int rb_nkf_putchar ( unsigned int  c) [static]

Definition at line 43 of file nkf.c.

References incsize, o_len, output, output_ctr, rb_str_resize(), result, and RSTRING_PTR.


Variable Documentation

int i_len [static]

Definition at line 35 of file nkf.c.

Referenced by rb_nkf_convert(), and rb_nkf_guess().

int incsize [static]

Definition at line 38 of file nkf.c.

Referenced by rb_nkf_convert(), and rb_nkf_putchar().

unsigned char* input [static]

Definition at line 33 of file nkf.c.

int input_ctr [static]

Definition at line 34 of file nkf.c.

Referenced by rb_nkf_convert(), and rb_nkf_guess().

int o_len [static]

Definition at line 37 of file nkf.c.

Referenced by rb_nkf_convert(), and rb_nkf_putchar().

unsigned char* output [static]
int output_ctr [static]

Definition at line 36 of file nkf.c.

Referenced by rb_nkf_convert(), and rb_nkf_putchar().

VALUE result [static]

Definition at line 40 of file nkf.c.

Referenced by ary_join_1(), ary_make_partial(), ary_reject(), ary_reject_bang(), code_status(), cParser_parse_quirks_mode(), cParser_parse_strict(), cState_generate(), cState_to_h(), date_strftime_with_tmx(), DEFINE_ENUMFUNCS(), do_select(), econv_convpath(), enum_all(), enum_any(), enum_max(), enum_min(), enum_none(), enum_one(), enum_zip(), env_rassoc(), env_select(), env_values_at(), eval_string_with_cref(), EVENTSINK_Invoke(), exec_recursive(), exec_recursive_i(), fbuffer_dup(), fbuffer_to_s(), filename_completion_proc_call(), finish_overlapped_socket(), fix_string_encoding(), flatten(), fole_each(), fstrndup(), gc_profile_result(), gmtime_with_leapsecond(), gmtimew(), h_conv(), init_leap_second_info(), initialize(), ip_eval(), ip_invoke_with_position(), json_string_unescape(), kanji_convert(), lib_merge_tklist(), lib_split_tklist_core(), localtime_with_gmtoff_zone(), localtimew(), method_missing(), mString_included_s(), mString_to_json_raw_object(), next_i(), ole_invoke(), ole_invoke2(), onig_st_insert_strend(), ossl_x509name_cmp(), ossl_x509name_eql(), ossl_x509stctx_verify(), ossl_x509store_verify(), p_gamma(), parser_yylex(), permute0(), proc_waitall(), q_gamma(), rb_ary_drop(), rb_ary_flatten(), rb_ary_flatten_bang(), rb_ary_join(), rb_ary_pop_m(), rb_ary_product(), rb_ary_sample(), rb_ary_select(), rb_ary_shift_m(), rb_ary_transpose(), rb_ary_zip(), rb_cstr_to_inum(), rb_dlcfunc_call(), rb_enc_sprintf(), rb_enc_vsprintf(), rb_ensure(), rb_equal(), rb_f_backquote(), rb_file_expand_path_internal(), rb_file_join(), rb_get_values_at(), rb_gmtime_r2(), rb_hash_select(), rb_hash_values_at(), rb_home_dir(), rb_io_inspect(), rb_localtime_r2(), rb_method_call(), rb_name_err_mesg_new(), rb_nkf_convert(), rb_nkf_putchar(), rb_obj_not_equal(), rb_obj_not_match(), rb_protect(), rb_reg_match_m(), rb_reg_preprocess_dregexp(), rb_reg_search(), rb_require_safe(), rb_rescue2(), rb_sprintf(), rb_str_cmp_m(), rb_str_crypt(), rb_str_dump(), rb_str_format(), rb_str_inspect(), rb_str_match_m(), rb_str_scan(), rb_str_slice_bang(), rb_str_split_m(), rb_strftime_with_timespec(), rb_struct_select(), rb_thread_wait_fd_rw(), rb_vm_make_jump_tag_but_local_jump(), rb_waitpid(), rb_waitpid_blocking(), rcombinate0(), readline_attempted_completion_function(), readline_readline(), recursive_join(), rpermute0(), ruby__sfvwrite(), scan_once(), strtol(), take_items(), thread_suppress_tracing(), time_add(), tk_funcall(), ttymode(), unescape_unicode(), username_completion_proc_call(), vm_exec(), zip_ary(), and zip_i().