HEX
Server: Apache
System: Linux vps-cdc32557.vps.ovh.ca 5.15.0-156-generic #166-Ubuntu SMP Sat Aug 9 00:02:46 UTC 2025 x86_64
User: hanode (1017)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //usr/share/ri/3.0.0/system/Module/const_missing-i.ri
U:RDoc::AnyMethod[iI"const_missing:ETI"Module#const_missing;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph;	[	I"BInvoked when a reference is made to an undefined constant in ;TI"G<i>mod</i>. It is passed a symbol for the undefined constant, and ;TI"7returns a value to be used for that constant. The ;TI".following code is an example of the same:;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim;	[
I"!def Foo.const_missing(name)
;TI"1  name # return the constant name as Symbol
;TI"	end
;TI"
;TI"CFoo::UNDEFINED_CONST    #=> :UNDEFINED_CONST: symbol returned
;T:@format0o;
;	[I"LIn the next example when a reference is made to an undefined constant, ;TI"Kit attempts to load a file whose name is the lowercase version of the ;TI"Econstant (thus class <code>Fred</code> is assumed to be in file ;TI"G<code>fred.rb</code>).  If found, it returns the loaded class. It ;TI"Mtherefore implements an autoload feature similar to Kernel#autoload and ;TI"Module#autoload.;T@o;;	[I"$def Object.const_missing(name)
;TI"  @looked_for ||= {}
;TI"  str_name = name.to_s
;TI"A  raise "Class not found: #{name}" if @looked_for[str_name]
;TI"!  @looked_for[str_name] = 1
;TI"   file = str_name.downcase
;TI"  require file
;TI"  klass = const_get(name)
;TI"  return klass if klass
;TI"(  raise "Class not found: #{name}"
;TI"end;T;
0:
@fileI"
object.c;T:0@omit_headings_from_table_of_contents_below0I"&mod.const_missing(sym)    -> obj
;T0[I"	(p1);T@.FI"Module;TcRDoc::NormalClass00