| Anonymous | Login | Signup for a new account | 2013-05-26 07:17 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||||
| 0002667 | OCaml | OCaml general | public | 2004-06-12 17:03 | 2004-06-15 16:47 | ||||||
| Reporter | administrator | ||||||||||
| Assigned To | |||||||||||
| Priority | normal | Severity | feature | Reproducibility | always | ||||||
| Status | acknowledged | Resolution | open | ||||||||
| Platform | OS | OS Version | |||||||||
| Product Version | |||||||||||
| Target Version | Fixed in Version | ||||||||||
| Summary | 0002667: dynlink and toplevel | ||||||||||
| Description | Full_Name: James Scott Version: 3.07+2 OS: Linux and Windows Submission from: d80-170-139-232.cust.tele2.fr (80.170.139.232) When using Dynlink from the Toplevel: Modules which are loaded by #load or given on the command line are not resolved from Dynlink-loaded code. e.g. $ cat Loader.ml let dynload_helper_ref = ref (None: int option) let doit fname = let _ = Dynlink.init () in let _ = Dynlink.loadfile fname in !dynload_helper_ref $ cat Loadee.ml Loader.dynload_helper_ref := Some 1 $ cat Test.ml let _ = Loader.doit "Loadee.cmo" ;; $ ocamlc -c Loadee.ml $ ocamlc -a -o llib.cma Loader.ml $ ocaml dynlink.cma llib.cma Test.ml Exception: Dynlink.Error (Dynlink.Linking_error ("Loadee.cmo", Dynlink.Undefined_global "Loader")). But this works: $ ocamlmktop dynlink.cma llib.cma $ ./a.out < Test.ml Objective Caml version 3.07+2 # - : int option = Some 1 | ||||||||||
| Tags | No tags attached. | ||||||||||
| Attached Files | |||||||||||
Notes |
|
|
(0000224) administrator (administrator) 2004-06-15 16:47 |
the example is not good, but the point is valid -DD 2004-06-15 |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2005-11-18 10:13 | administrator | New Issue | |
| Copyright © 2000 - 2011 MantisBT Group |