lib/qlang/api/func_api.rb in qlang-0.0.27180000 vs lib/qlang/api/func_api.rb in qlang-0.0.27182000

- old
+ new

@@ -1,13 +1,15 @@ module Qlang module Api module FuncApi def execute(func_name, args, contents) - case $type - when :R + case $meta_info.lang + when :r "#{func_name} <- function(#{ args.join(' ,') }) #{contents}" - when :Ruby + when :ruby "#{func_name}(#{ args.join(' ,') }) <= #{contents}" + else + fail "Function is not implemented for #{LANGS_HASH[$meta_info.lang.to_s]}" end end module_function :execute end