ruby/template/known_errors.inc.tmpl

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 строки
565 B
Cheetah
Исходник Обычный вид История

/** -*-c-*-
* DO NOT EDIT
* This file is automatically generated by tool/generic_erb.rb from
* template/known_errors.inc.tmpl and defs/known_errors.def.
*/
2024-01-11 16:46:49 +03:00
% error_names = ARGF.readlines.map {|line| [$1, $2] if /\A([A-Z]\S+)(?:\s+(\S.*))?/ =~ line}.compact
% error_names.each do |name, doc|
#if 0
/* <% if doc %>"<%= doc %>"<% else %>\<%= name %><% end %> error */
rb_define_const(rb_mErrno, "<%=name%>", e<%=name%>);
#endif
#ifdef <%=name%>
defined_error("<%=name%>", <%=name%>)
#else
undefined_error("<%=name%>")
#endif
% end