| Anonymous | Login | Signup for a new account | 2013-05-25 08:39 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 | ||||||
| 0005566 | OCaml | OCaml standard library | public | 2012-03-29 10:06 | 2012-04-03 11:11 | ||||||
| Reporter | Hendrik Tews | ||||||||||
| Assigned To | |||||||||||
| Priority | normal | Severity | feature | Reproducibility | have not tried | ||||||
| Status | acknowledged | Resolution | open | ||||||||
| Platform | OS | OS Version | |||||||||
| Product Version | 3.12.1 | ||||||||||
| Target Version | Fixed in Version | ||||||||||
| Summary | 0005566: Duplicate Dynlink.is_native as Sys.is_native | ||||||||||
| Description | I would like to suggest to have the is_native flag also in module Sys. This way, code running in the toplevel could distinguish whether it is running inside ocaml or inside ocamlnat, in order to decide whether it should call Topdirs.load_file with cmo or cmxs arguments. | ||||||||||
| Tags | No tags attached. | ||||||||||
| Attached Files | |||||||||||
Notes |
|
|
(0007223) protz (manager) 2012-03-29 10:38 |
I can already run the following sequence in a toplevel: #use "topfind";; #require "dynlink";; Dynlink.is_native;; Is that not enough? There's different Dynlink implementations in the source tree, so it's easy to define is_native as being true or false, but I'm not sure how we would do that inside the Sys module... |
|
(0007233) Hendrik Tews (reporter) 2012-03-29 11:46 |
Having Sys.is_native is useful especially in those cases where the dynlink library is not required. In those cases one doesn't really want to load findlib and dynlink to access just one boolean. One can always check at program invocation whether one is going to run a native program and use different source code or additional arguments for the native program. |
|
(0007234) frisch (developer) 2012-03-29 12:39 |
> I'm not sure how we would do that inside the Sys module... We could have the runtime environment provide such a function (with different implementation in byterun and asmrun). |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2012-03-29 10:06 | Hendrik Tews | New Issue | |
| 2012-03-29 10:38 | protz | Note Added: 0007223 | |
| 2012-03-29 10:38 | protz | Status | new => feedback |
| 2012-03-29 11:46 | Hendrik Tews | Note Added: 0007233 | |
| 2012-03-29 11:46 | Hendrik Tews | Status | feedback => new |
| 2012-03-29 12:38 | frisch | Status | new => acknowledged |
| 2012-03-29 12:39 | frisch | Note Added: 0007234 | |
| Copyright © 2000 - 2011 MantisBT Group |