|Anonymous | Login | Signup for a new account||2015-01-25 19:26 CET|
|Main | My View | View Issues | Change Log | Roadmap|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0003725||OCaml||OCaml general||public||2005-07-16 19:04||2013-07-31 00:01|
|Target Version||Fixed in Version|
|Summary||0003725: Ocamldep should search for .mly & .mll files|
|Description||Full_Name: Mike Furr|
Submission from: pcp0010743271pcs.howard01.md.comcast.net (18.104.22.168)
Ocamldep outputs a dependency only for those modules which it can find in the
current search path. However, this search only looks for files ending in .ml or
.mli. Thus if a module uses a lexer or parser defined in a .mll or .mly file,
the dependency will not be shown if these have not yet been compiled into their
respective implementation files. As I typically setup my projects to build
dependencies before any compilation (including that of .mll and .mly files), it
would be nice if ocamldep searched for these file extensions as well.
I think that .mly and .mll are just one case of a more general problem - people often use various tools for generating the source files. And those tools are often custom to a project and use custom extensions. For example, the Harmony project generates .mly from .srcy.
My proposal would be to have ocamldep take a list of "implementation suffixes" and another list of "interface suffixes" on the command line.
This way ocamldep without any special options would be equivalent to something like
ocamldep -intf .mli -intf .mly -impl .mli -impl .mll -impl .mly
and people with non-standard extensions would be able to add them to the list ("-impl .srcy").
edited on: 2013-07-28 22:53
I think the feature proposal of nogin is sound and would make for a good (but non-trivial) "junior job". Adding .mll and .mly to the base set of implementation extensions would also solve the related issue.
|The compiler already has an "-intf-suffix" option that allows you to specify the suffix for interface files, so it certainly makes sense to add "-intf-suffix" and "-impl-suffix" options to ocamldep. (It probably also makes sense to add "-impl-suffix" to the compiler).|
I opened the issue 6110 that addresses the -impl-suffix option in the compiler.
Regarding the -intf-suffix/-impl-suffix in ocamldep, it seems that the already existing options -ml-synonym/-mli-synonym are already providing this feature, and thus no further modification is needed.
The thing that is currently not done is to automatically add some files extensions to the list of synonyms, but it is probably not as crucial nowadays with the existence of -ml-synonym/-mli-synonym.
|2005-11-18 10:13||administrator||New Issue|
|2006-06-12 22:02||nogin||Note Added: 0003676|
|2009-08-19 13:20||xclerc||Relationship added||related to 0004519|
|2011-06-06 16:14||xclerc||Relationship added||related to 0005216|
|2013-07-28 22:52||gasche||Tag Attached: junior_job|
|2013-07-28 22:53||gasche||Note Added: 0009947|
|2013-07-28 22:53||gasche||Note Edited: 0009947||View Revisions|
|2013-07-29 01:06||lpw25||Note Added: 0009957|
|2013-07-30 23:58||vbmithr||Note Added: 0010029|
|2013-07-31 00:01||lpw25||Relationship added||related to 0006110|
|Copyright © 2000 - 2011 MantisBT Group|