# File lib/rcodetools/completion.rb, line 322
322: def completion_code(code, lineno, column=nil)
323: elisp = "(progn\n"
324: table = "(setq rct-method-completion-table '("
325: alist = "(setq alist '("
326: begin
327: candidates(code, lineno, column).sort.each do |minfo|
328: meth, description = split_method_info(minfo)
329: table << format('("%s") ', meth)
330: alist << format('("%s\t[%s]") ', meth, description)
331: end
332: table << "))\n"
333: alist << "))\n"
334: rescue Exception => err
335: return error_code(err)
336: end
337: elisp << table << alist
338: elisp << %[(setq pattern "#{prefix}")\n]
339: elisp << %[(try-completion pattern rct-method-completion-table nil)\n]
340: elisp << ")" # /progn
341: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.