Bug 30091 - specs file: `@LANGUAGE' not documented
Summary: specs file: `@LANGUAGE' not documented
Status: ASSIGNED
Alias: None
Product: gcc
Classification: Unclassified
Component: driver (show other bugs)
Version: 4.1.1
: P3 normal
Target Milestone: ---
Assignee: Tom Tromey
URL:
Keywords: documentation
Depends on:
Blocks:
 
Reported: 2006-12-06 17:27 UTC by Thomas Schwinge
Modified: 2021-12-19 23:12 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2007-01-21 03:08:03


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Schwinge 2006-12-06 17:27:15 UTC
It seems to me that neither in the manual nor in the commentary in `gcc.c' it is documented that one can use `@LANGUAGE' to introduce a new `LANGUAGE' to gcc when using custom specs files via `gcc -specs=FILE'.


Is it advisible to have the specs syntax's documentation both in the Texinfo manual and as comments in `gcc.c'?  Are they kept in sync?
Comment 1 Thomas Schwinge 2006-12-06 18:22:21 UTC
It is also not documented that `#COMMENT' can be used to embed comments.


And `\f' (form feed, `^L') could be added to list of white space (in the skip_whitespace function): it's convenient to separate units in hand-made specs files by form feed characters.
Comment 2 Andrew Pinski 2006-12-08 09:25:03 UTC
specs are an internal format really.  It is very subject to change each release.  Also some time in the future we might decide to get rid of the specs.
Comment 3 Tom Tromey 2007-01-21 03:08:03 UTC
I have a patch to document '#' and '@'.
I'll submit it shortly.

Currently gcc.c and invoke.texi are mostly kept in sync.
However I haven't audited to make sure they are fully in sync.

Adding support for \f is probably more complicated than just
changing skip_whitespace.  I think it is fine to just leave
the code as is; users can use multiple blank lines and also
comments to separate chunks of spec files.
Comment 4 sandra 2018-11-18 01:21:14 UTC
It looks like the proposed patch from 2007 was never posted.

I'm confused, it looks like @language is already documented, while # is documented as causing an error instead of a comment (and it looks like the code tries to do both things with it, which doesn't seem like it would work).  I don't know much about spec files, though.  :-S