403Webshell
Server IP : 82.208.35.60  /  Your IP : 216.73.216.89
Web Server : Apache/2.4.55 (FreeBSD) OpenSSL/1.1.1q-freebsd PHP/7.3.31
System : FreeBSD server7.d2m.cz 12.4-RELEASE-p9 FreeBSD 12.4-RELEASE-p9 GENERIC amd64
User : studiokobylisy_cz ( 1008)
PHP Version : 7.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /usr/local/share/slsh/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/local/share/slsh/require.sl
% These functions were taken from the jed editor

private variable Features;
if (0 == __is_initialized (&Features))
  Features = Assoc_Type [Int_Type,0];

private define pop_feature_namespace (nargs)
{
   variable f, ns = current_namespace ();
   if (nargs == 2)
     ns = ();
   f = ();
   if ((ns == NULL) or (ns == ""))
     ns = "Global";
   return strcat (ns, ".", f);
}

define _featurep ()
{
   variable f;
   f = pop_feature_namespace (_NARGS);
   return Features[f];
}

define provide ()
{
   variable f = pop_feature_namespace (_NARGS);
   Features[f] = 1;
}

define require ()
{
   variable feat, file;
   variable ns = current_namespace ();
   switch (_NARGS)
     {
      case 1:
	feat = ();
	file = feat;
     }
     {
      case 2:
	(feat, ns) = ();
	file = feat;
     }
     {
      case 3:
	(feat, ns, file) = ();
     }
     {
	usage ("require (feature [,namespace [,file]])");
     }

   if (_featurep (feat, ns))
     return;

   if (ns == NULL)
     () = evalfile (file);
   else
     () = evalfile (file, ns);

   if (feat == file)
     provide (file, ns);
   else if (_featurep (feat, ns))
     vmessage ("***Warning: feature %s not provided by %s", feat, file);
}

$1 = path_concat (path_dirname (__FILE__), "help/require.hlp");
if (NULL != stat_file ($1))
  add_doc_file ($1);


Youez - 2016 - github.com/yon3zu
LinuXploit