Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] View of /sml/trunk/src/runtime/c-libs/dl/dlerror.c
ViewVC logotype

View of /sml/trunk/src/runtime/c-libs/dl/dlerror.c

Parent Directory Parent Directory | Revision Log Revision Log

Revision 772 - (download) (as text) (annotate)
Thu Jan 4 15:36:41 2001 UTC (19 years, 8 months ago) by blume
File size: 594 byte(s)
merging changes from private branch
/* dlerror.c
 * COPYRIGHT (c) 2000 by Lucent Technologies, Bell Laboratories

#include "ml-unixdep.h"
#include <dlfcn.h>
#include "ml-base.h"
#include "ml-values.h"
#include "ml-objects.h"
#include "ml-c.h"
#include "cfun-proto-list.h"

/* _ml_P_Dynload_dlerror : unit -> string option
 * Extract error after unsuccessful dlopen/dlsym/dlclose.
ml_val_t _ml_U_Dynload_dlerror (ml_state_t *msp, ml_val_t ml_handle)
  char *e = dlerror ();
  ml_val_t r, s;

  if (e == NULL)
    r = OPTION_NONE;
  else {
    s = ML_CString (msp, e);
    OPTION_SOME (msp, r, s);
  return r;

ViewVC Help
Powered by ViewVC 1.0.0