Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006481OCamlOCaml generalpublic2014-07-10 18:122014-11-13 11:58
Reporterberenger 
Assigned Togasche 
PrioritynormalSeverityfeatureReproducibilityN/A
StatusresolvedResolutionwon't fix 
Platformunix-likesOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0006481: compiler option to enable color in important keywords of the output in a terminal
DescriptionHello,

Keywords such as (File, Warning, Error, line, characters),
if colored differently than the rest of the text
allow developpers to catch more easily with the eyes
important parts of the output messages.

If there was a way to allow choosing the color for
a given keyword, for example via an env. var. or
a .rc file, that would be wonderful.

I have used various ways to do that over the years out
of the compiler, but it always gets broken at some point.

Regards,
F.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0011850)
doligez (administrator)
2014-07-16 16:22

Are you talking about the toplevel? I don't think it would be worth the trouble implementing this.

Syntax-coloring rightly belongs in the text editor or IDE that you use to write OCaml code.
(0011855)
berenger (reporter)
2014-07-16 16:39

No, I am talking about the compiler messages.
(0012029)
berenger (reporter)
2014-08-20 18:10

Should I look only into yacc/error.c in order to enable this?
(0012031)
gasche (developer)
2014-08-20 20:51

No, those are the errors raised by the ocamlyacc program (when parsing a .mly file). The syntax errors for OCaml are handled in parsing/syntaxerr.ml, but they call utility function in parsing/location.ml that do the actual location-reporting and warning/error printing job.

Note that Merlin ( https://github.com/the-lambda-church/merlin [^] ) already does the job of giving visual signals about the error/warning status, and does many other things. Working with compiler messages outside a text editor is a waste of time, as long as it doesn't let you automatically jump to the error location in the right file -- a major time-saver. I'm skeptical about coloring the batch output for this reason.
(0012039)
doligez (administrator)
2014-08-21 11:23

If you are using your eyes to parse the output of the compiler looking for error and warning messages, you are doing it wrong. Emacs has had a mode for that for more than 25 years, and I expect other IDEs to have the same functionality. You shouldn't be using the compiler in a terminal, except for simple testing.

I'm strongly inclined to reject this feature wish because it represents a lot of implementation work and the benefit is negative (it discourages users from using a good IDE).

Any dissenting opinion?
(0012525)
berenger (reporter)
2014-11-13 11:27

this can be closed I think

- Issue History
Date Modified Username Field Change
2014-07-10 18:12 berenger New Issue
2014-07-16 16:22 doligez Note Added: 0011850
2014-07-16 16:22 doligez Status new => feedback
2014-07-16 16:39 berenger Note Added: 0011855
2014-07-16 16:39 berenger Status feedback => new
2014-08-20 18:10 berenger Note Added: 0012029
2014-08-20 20:51 gasche Note Added: 0012031
2014-08-21 11:23 doligez Note Added: 0012039
2014-08-21 11:23 doligez Status new => feedback
2014-11-13 11:27 berenger Note Added: 0012525
2014-11-13 11:27 berenger Status feedback => new
2014-11-13 11:58 gasche Status new => resolved
2014-11-13 11:58 gasche Resolution open => won't fix
2014-11-13 11:58 gasche Assigned To => gasche


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker