mattn / mruby-require

39 stars 23 forks source link

Support LoadError#path #31

Closed ksss closed 8 years ago

ksss commented 8 years ago

I implemented LoadError#path.

begin
  require 'nothing'
rescue LoadError => e
  p e.message #=> 'cannot load such file -- nothing'
  p e.path #=> 'nothing'
end

And unified error message to "cannot load such file -- #{path}". mrb_load_fail based on rb_load_fail.

mattn commented 8 years ago

LGTM! Thanks.