1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-14 09:39:42 +00:00
Commit Graph

61 Commits

Author SHA1 Message Date
Kapuze Martin
277a254a42 Enable Python type hints and non-trivial base classes in wisent
* admin/grammars/python.wy: Enable understanding Python type hints
and non-trivial base classes (bug#46817).

Copyright-paperwork-exempt: yes
2021-02-28 18:09:15 +01:00
Paul Eggert
ba05d005e5 Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright".
2021-01-01 01:13:56 -08:00
Paul Eggert
365e01cc9f Update copyright year to 2020
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
2020-01-01 00:59:52 +00:00
Stefan Kangas
6aa0e0c754 Clarify C void type description in semantic
* admin/grammars/c.by: Clarify void type.  (Bug#9222)
2019-10-14 21:36:59 +02:00
Paul Eggert
946a56a10f Update some URLs
This mostly changes http: to https: in URLs.  It also updates
some URLs that have moved, removes some URLs that no longer
work, recommends against using procmail (procmail.org no
longer works), and removes some mentions of the
no-longer-existing Gmane, LPF and VTW.
It doesn't update all URLs, just the ones I had time for.
* GNUmakefile (help):
* admin/admin.el (manual-doctype-string):
* admin/charsets/Makefile.in (${charsetdir}/ALTERNATIVNYJ.map):
* admin/charsets/mapconv:
* lisp/net/soap-client.el (soap-create-envelope):
* lisp/org/org.el (org-doi-server-url):
* lisp/textmodes/bibtex.el (bibtex-generate-url-list):
Prefer https: to http: un URLs.
2019-09-23 00:12:52 -07:00
Eric Ludlam
ba51c80c30 Allow bad tags in Scheme
* admin/grammars/scheme.by (scheme-in-list): Allow bad tags in
Scheme (bug#36521).
2019-07-14 13:51:20 +02:00
Lars Ingebrigtsen
390b4bc1e2 Allow specifying the expected number of shift/reduce conflicts
* admin/grammars/grammar.wy: Add %expectedconflicts.

* lisp/cedet/semantic/grammar-wy.el
(semantic-grammar-wy--keyword-table): Ditto.

* lisp/cedet/semantic/grammar.el
(semantic-grammar-expected-conflicts): New function.
(semantic-grammar-insert-defconst-with-eval): New function.
(semantic-grammar-create-package): Output the number of expected
shift/reduce conflicts.

* lisp/cedet/semantic/wisent/comp.el (wisent-total-conflicts):
Don't output the warning if the number of shift/reduce conflicts
is expected.
(wisent-expected-conflicts): Made obsolete.
2019-06-19 13:48:49 +02:00
Lars Ingebrigtsen
4956e7610c Revert "Add a mechanism to specify expected shift/reduce .wy conflicts"
This reverts commit f21ec24524.

*sigh*  Revert again because this created a bootstrap problem in a different part of the process.
2019-06-18 16:08:47 +02:00
Lars Ingebrigtsen
f21ec24524 Add a mechanism to specify expected shift/reduce .wy conflicts
* admin/grammars/python.wy: Set the expected number of
shift/reduce conflicts to four.

* lisp/cedet/semantic/grammar.el
(semantic-grammar-expected-conflicts): New function.

* lisp/cedet/semantic/wisent/comp.el (wisent-total-conflicts): Use
it to suppress warnings about the expected number of shift/reduce
conflicts.
2019-06-18 16:05:08 +02:00
Lars Ingebrigtsen
90b44f336c Revert "Add a mechanism to specify expected shift/reduce .wy conflicts"
This reverts commit d715ae8788.

This commit led to a build error, so revert for now.
2019-06-18 15:59:16 +02:00
Lars Ingebrigtsen
d715ae8788 Add a mechanism to specify expected shift/reduce .wy conflicts
* admin/grammars/python.wy: Set the expected number of
shift/reduce conflicts to four.

* lisp/cedet/semantic/grammar.el
(semantic-grammar-expected-conflicts): New function.
* lisp/cedet/semantic/wisent/comp.el (wisent-total-conflicts): Use
it to suppress warnings about the expected number of shift/reduce
conflicts.
2019-06-18 15:56:18 +02:00
Lars Ingebrigtsen
57cf715113 Add types to some no-type tokes in js.wy
* admin/grammars/js.wy: Add types to the FALSE, TRUE and QUERY tokens.

Without the types, you'd get the warning

*Warning* default value of <<no-type>> tokens changed to QUERY, was NULL_TOKEN
*Warning* default value of <<no-type>> tokens changed to TRUE, was QUERY
*Warning* default value of <<no-type>> tokens changed to FALSE, was TRUE

I think this should be harmless, and it doesn't seem to break handling
.js files.
2019-06-18 11:33:40 +02:00
Lars Ingebrigtsen
010db58e03 Comment out useless nonterminals from python.wy 2019-06-18 11:33:40 +02:00
Lars Ingebrigtsen
1b855aa8dd Remove nonterminals that semantic claims are useless
* admin/grammars/js.wy (VariableStatement): Remove useless
nonterminals.

Debug output from wisent:

Useless nonterminals:

   StatementList
   BlockExpand
2019-06-18 11:33:40 +02:00
Paul Eggert
852d281769 Update author/maintainer info
Update email addresses and fix spellings of some author and
maintainer names.
2019-05-26 01:00:16 -07:00
Paul Eggert
797ee5871e Remove Maintainer: when it duplicates Author:
The convention is that a file with Author: but not Maintainer:
means the author is a maintainer, which makes it confusing
when a file lists the same person as author and maintainer.
Avoid the confusion by removing the duplicate Maintainer: line.
2019-05-26 01:00:15 -07:00
Paul Eggert
ba809612c0 Merge from origin/emacs-26
2fcf2df Fix copyright years by hand
26bed8b Update copyright year to 2019
2814292 Fix value of default frame height.  (Bug#33921)
2018-12-31 17:57:29 -08:00
Paul Eggert
26bed8ba10 Update copyright year to 2019
Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
2019-01-01 01:01:13 +00:00
Glenn Morris
e8edf4ad60 Quieten cedet "might not be defined at runtime" compile warnings
* admin/grammars/scheme.by (semantic-parse-region):
* lisp/cedet/ede.el (ede--project-inode):
* lisp/cedet/semantic/texi.el (semantic-analyze-context):
Declare.
2018-02-28 13:40:26 -05:00
Glenn Morris
4fa90ff8f5 Merge from origin/emacs-26
e5a2933 (origin/emacs-26) lisp/vc/: documentation fixes
f21f8e6 Document 'desktop-files-not-to-save'
d8917eb Improve documentation of Profiling features
b228839 Improve indexing of "performance" in ELisp manual
ab67b3e Minor change in Emacs manual's VC chapter
c352434 Avoid memory corruption with specpdl overflow + edebug (Bug#3...
593bbda Document comment-fill-column in the manual (Bug#11636)
bd4cc8d * doc/emacs/dired.texi (Marks vs Flags): Copyedits.
69107f3 ; Fix doc typos related to indefinite articles
aaad1e6 Merge branch 'emacs-26' of git.savannah.gnu.org:/srv/git/emac...
5906418 More fixes for the Emacs manual
9ab3df1 ; Fix doc typos related to indefinite articles
66a4e65 ; Fix doc typos related to indefinite articles
35e5c57 ; Fix doc typos related to indefinite articles
2018-02-17 07:50:28 -08:00
Glenn Morris
69107f347b ; Fix doc typos related to indefinite articles 2018-02-16 17:33:57 -05:00
Paul Eggert
bb267f17f9 Merge from origin/emacs-26
63b04c11d5 Fix copyright years by hand
5c7dd8a783 Update copyright year to 2018
220a9ecba1 Merge from Gnulib
312c565566 Don't add empty keyboard macro to macro ring (Bug#24992)
39ca289a7a Allow customization of decoding of "man" command
f8240815ea * etc/NEWS: Add security consideration note on passphrase ...
0c78822c70 Fix subtle problem with scroll-down when scroll-margin is ...
acd289c5a4 Fix problems with indexing in User manual
b240c7846b * lisp/help.el (describe-key): Only (copy-sequence elt) wh...
e879a5444a * src/buffer.c (Frestore_buffer_modified_p): Fix bug#29846
81b1028b63 Improve documentation of 'inhibit-modification-hooks' and ...
7175496d7a Fix doc string of 'enable-recursive-minibuffers'
5b38406491 Fix documentation of delsel and of killing text

# Conflicts:
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
2018-01-01 01:13:04 -08:00
Paul Eggert
5c7dd8a783 Update copyright year to 2018
Run admin/update-copyright.
2018-01-01 00:57:59 -08:00
Philipp Stephani
6fc0397388 Work around reader limitations for old-style backquotes.
See Bug#28759.

* admin/grammars/make.by: Escape ,@ to avoid old-style backquote
detection
2017-12-09 21:05:41 +01:00
Paul Eggert
bc511a64f6 Prefer HTTPS to FTP and HTTP in documentation
Most of this change is to boilerplate commentary such as license URLs.
This change was prompted by ftp://ftp.gnu.org's going-away party,
planned for November.  Change these FTP URLs to https://ftp.gnu.org
instead.  Make similar changes for URLs to other organizations moving
away from FTP.  Also, change HTTP to HTTPS for URLs to gnu.org and
fsf.org when this works, as this will further help defend against
man-in-the-middle attacks (for this part I omitted the MS-DOS and
MS-Windows sources and the test tarballs to keep the workload down).
HTTPS is not fully working to lists.gnu.org so I left those URLs alone
for now.
2017-09-13 15:54:37 -07:00
Paul Eggert
5badc81c1c Update copyright year to 2017
Run admin/update-copyright.
2016-12-31 19:42:26 -08:00
Paul Eggert
0e963201d0 Update copyright year to 2016
Run admin/update-copyright.
2016-01-01 01:34:24 -08:00
Paul Eggert
4e23582925 Less 'make' chatter for admin/grammars
* grammars/Makefile.in (AM_DEFAULT_VERBOSITY, AM_V_GEN)
(am__v_GEN_, am__v_GEN_0, am__v_GEN_1, AM_V_at, am__v_at_)
(am__v_at_0, am__v_at_1): New macros, from src/Makefile.in.
(${bovinedir}/%-by.el, ${bovinedir}/scm-by.el)
(${cedetdir}/semantic/%-wy.el, ${wisentdir}/%-wy.el)
(${wisentdir}/javat-wy.el, ${cedetdir}/srecode/srt-wy.el): Use them.
2015-01-03 18:54:34 -08:00
Paul Eggert
7e09ef09a4 Update copyright year to 2015
Run admin/update-copyright.
2015-01-01 14:26:41 -08:00
David Engster
5d4da32d4e Update from CEDET trunk.
* grammars/c.by (template-type): Add :template-specifier and
:typevar to capture extra details about the template.
(opt-post-fcn-modifiers): Splice in the found symbol into the
return value correctly.
(QUESTION): New punctuation.
(expression): Add ternary conditional support.

* grammars/scheme.by (MODULE): New token.
(scheme): Handle expanding the MODULE tag.
(scheme-list): Remove closeparen required match.
(scheme-in-list): Remove extraneous matches for DEFINE.  Add
support for MODULE Simplify matching for code & make work.
(name-args, name-arg-list, name-arg-expand): Make it work.

* semantic.el (semantic-mode): Add/remove 3
completion-at-point-functions.
(semantic-completion-at-point-function): Removed.
(semantic-analyze-completion-at-point-function)
(semantic-analyze-notc-completion-at-point-function)
(semantic-analyze-nolongprefix-completion-at-point-function): New
completion at point functions.

* semantic/doc.el (semantic-doc-snarf-comment-for-tag): Fix case
when comment-end is empty string.

* semantic/debug.el
(semantic-debug-parser-debugger-source): New buffer local
variable.
(semantic-debug-interface): Add 'nil' initform to overlays.
(semantic-debug-mode): Remove read-only tags from buffers on exit.
(semantic-debug): Add autoload cookie.  Force the language
specific debugger to load.

* semantic/db.el (generic::semanticdb-full-filename): New generic
method to allow this method to be used on buffer names via an
associated database.

* semantic/symref.el
(semantic-symref-cleanup-recent-buffers-fcn): When cleaning up
buffers, don't clean up buffers that are being used (i.e., in a
window) when the hook fires.
(semantic-symref-recently-opened-buffers): New tracking variable.
(semantic-symref-cleanup-recent-buffers-fcn): New hook fcn.
(semantic-symref-result-get-tags): Move logic into
`semantic-symref-hit-to-tag-via-buffer', and cleanup buffers via
the symref cleanup function in post-command-hook.
(semantic-symref-hit-to-tag-via-buffer): Logic that used to be
from above.
(semantic-symref-hit-to-tag-via-db): New.

* semantic/analyze.el:
(semantic-analyze-find-tag-sequence-default): If first entry in
sequence is the only one, apply tagclass filter.
(semantic-analyze-princ-sequence): Show slot even if empty.
(semantic-analyze-find-tag-sequence)
(semantic-analyze-find-tag-sequence-default): Add flags argument.
Add support for forcing the final entry of the sequence to be of
class variable.
(semantic-analyze-find-tag): Fix bug where input class filter was
ignored if there was a typecache match.
(semantic-analyze-current-context-default): For assignments, the
assignee now must be of class variable.

* semantic/analyze/complete.el
(semantic-analyze-possible-completions-default): Add
'no-longprefix' flag.  When used, the prefix and prefixtypes are
shortened to just the last symbol.

* semantic/bovine/c.el (semantic-c-do-lex-if): Catch errors from
'hideif', and push to the parser warning stack.
(semantic-lex-cpp-define): When a comment is at the end of a
macro, do not subtract an extra 1 from the found position.  Fixes
bug with: #define foo (a)/**/ adding an extra ')' to the stream.

* semantic/bovine/scm.el (semantic-lex-scheme-symbol): Allow
symbols to be one char long.

* semantic/bovine/grammar.el
(bovine-grammar-calculate-source-on-path): New.
(bovine-grammar-setupcode-builder): Use it.

* ede.el (ede/detect): New require.
(ede-version): Bump version
(ede-initialize-state-current-buffer): Use new
`ede-detect-directory-for-project' to detect projects first
instead of depending on currente dir only.
(ede-delete-project-from-global-list): New.
(ede-flush-deleted-projects): Use above.
(ede-check-project-query-fcn): New variable
(ede-check-project-directory): Use above when querying the user.
Added to support unit testing of this security measure.
(ede-initialize-state-current-buffer): Use
`ede-directory-project-cons' instead of the -detect- fcn to take
advantage of the cache.  Pass found project into
`ede-load-project-file'.
(ede-load-project-file): Add new input DETECTIN.
(ede-rescan-toplevel): Get the proj root a better way.
(ede-load-project-file): Return the loaded object.  When asking
for existing project, ask for an exact match.
(ede-initialize-state-current-buffer): Simplify some conditional
logic.
(ede-load-project-file): Simplify conditional logic.
(ede-global-list-sanity-check): New Testing fcn.
(ede-parent-project): Replace old code with call to faster
`ede-find-subproject-for-directory'.
(ede-load-project-file): Use
`ede-directory-get-toplevel-open-project' instead of above
deleted.  Rename "pfc" to "autoloader".  Use
`ede-directory-project-cons' to detect a project.  Delete no
project found case where we search up the tree.

* ede/auto.el (ede-project-autoload): Fix doc typo.  Add
`:root-only' slot.
(ede-auto-load-project): Doc update: warn to not use.
(ede-dir-to-projectfile): Deleted.
(ede-project-autoload-dirmatch): Add subdir-only slot.  Make
configdatastash unbound by default.
(ede-do-dirmatch): If subdir-only is true, then don't allow exact
matches.  Account for configdatastash as unbound.  Assume value of
nil means no tool installed.  Make sure loaded path matches from
beginning.  Stash the regexp, not the raw string.
(ede-project-class-files): Note that makefile and automake are not
root only.
(ede-auto-detect-in-dir): New (for use with `ede/detect.el').
(ede-project-dirmatch-p): Deleted.
(ede-project-root-directory): Remove body, return nil.
(ede-project-autoload): :proj-root-dirmatch can be null & doc fix.
(ede-auto-detect-in-dir): If there is no :proj-file, check for a
dirmatch.

* ede/generic.el (ede/config): Replace require of ede.
(ede-generic-new-autoloader): Generic projects are now safe by
default.  Note this is NOT a root only project.
(project-rescan, ede-project-root, ede-generic-target-java)
(ede-java-classpath, ede-find-subproject-for-directory): New.
(ede-enable-generic-projects): Add new autoloaders for git, bzr,
hg, sv, CVS.
(ede-generic-vc-project)
(ede-generic-vc-project::ede-generic-setup-configuration): New.
(ede-generic-config): Remove slots: c-include-path,
c-preprocessor-table, c-preprocessor-files, classpath,
build-command, debug-command, run command.  Inherit from
ede-extra-config-build, ede-extra-config-program.  Make
run-command :value match :custom so only strings are accepted.
Add some more :group slot specifiers.
(ede-generic-project): Add mixins `ede-project-with-config-c' and
`ede-project-with-config-java'. Inherit from
`ede-project-with-config-build',
`ede-project-with-config-program'.  Subclass
`ede-project-with-config'.  Remove duplication from new baseclass.
(ede-generic-target): Inherit from `ede-target-with-config-build',
`ede-target-with-config-program'. Subclass `ede-target-with-config'.
(ede-generic-target-c-cpp): Add mixin `ede-target-with-config-c'.
(ede-generic-target-java): Add mixin `ede-target-with-config-java'.
(ede-preprocessor-map, ede-system-include-path)
(edejava-classpath): Deleted, moved to config.el.
(project-compile-project, project-compile-target)
(project-debug-target, project-run-target): Deleted.
(ede-generic-get-configuration, ede-generic-setup-configuration)
(ede-commit-project, project-rescan)
(ede-generic-project::ede-customize)
(ede-generic-target::ede-customize)
(ede-generic-config::eieio-done-customizing)
(ede-generic-config::ede-commit): Deleted.  Subsumed by new
baseclass.
(ede-preprocessor-map, ede-system-include-path)
(project-debug-target, project-run-target): Call new
`ede-config-get-configuration' instead of old version.
(ede-generic-load): Do not add to global list here.

* ede/files.el (ede-find-project-root)
(ede-files-find-existing)
(ede-directory-get-toplevel-open-project-new): Deleted.
(ede-project-root-directory): Use `ede-project-root' first.
(ede-project-directory-remove-hash)
(ede--directory-project-from-hash)
(ede--directory-project-add-description-to-hash): Rename to make
internal symbols (via --).  Expand input dir first.
(ede-directory-project-p): Doc fix (note obsoleted.)
(ede-toplevel-project-or-nil): Alias to `ede-toplevel-project'.
(ede-toplevel-project): Doc Fix.  Delete commented out old code.
Simplify returning result from ede-detect-directory-for-project.
(ede-directory-get-open-project): Support when
inodes are disabled.  If disabled to str compare on root project.
(ede-directory-get-toplevel-open-project): Enabled nested
projects.  When doing directory name matching, save the 'short'
version of an answer (non-exact match) and eventually select the
shortest answer at the end.  Expand the filename of tested
projects.  Better support for when inodes are disabled.  Add
'exact' option so that it will return a project that is an exact
match.
(ede-find-subproject-for-directory): Small optimization to run
`file-truename' less often.
(ede-directory-project-p): Move content, then use
`ede-directory-project-cons'.  Use
`ede-detect-directory-for-project', replacing old detection loop.
(ede-directory-project-cons): New, from above.
(ede-toplevel-project): Toss old scanning code.  Use
`ede-detect-directory-for-project' instead.
(ede-directory-get-toplevel-open-project-new): New.

* ede/linux.el (ede-linux-project-root): Deleted.
(ede-project-autoload): Remove dirmatch entry - it is no longer
needed.

* lisp/cedet/ede/proj.el (project-rescan): Replace direct
manipulation of `ede-projects' with equivalent and better
functions.
(ede-proj-load): Replace call to test if dir has project to
explicity ask filesystem if Project.ede is there.

* ede/config.el:
* ede/detect.el: New files.

* ede/project-am.el (project-run-target): Add "./" to program to
run for systems where '.' isn't in PATH.
(project-am-load): Remove old code regarding `ede-constructing'.
Just read in the makefiles.

* ede/linux.el (ede-linux-load): Do not add to global list here.
Don't check for existing anymore.
(project-rescan): New.
(ede-linux-project-list, ede-linux-file-existing): Deleted.
(ede-linux-project-root): Delete body.  Need symbol for autoloads
for now.
(ede-linux-project): No longer instance tracker.
(ede-project-autoload): Don't provide :proj-root

* ede/emacs.el (ede-emacs-load): Do not add project to global list
here.  Don't look for existing first.
(ede-project-autoload): Remove dirmatch entry - it is no longer
needed.  Don't provide proj-root anymore.
(ede-emacs-project-list, ede-emacs-file-existing): Delete.
(ede-emacs-project-root): Remove body (need symbol for loaddefs
still).
(ede-emacs-project): Do not instance track anymore.

* ede/cpp-root.el (initialize-instance): Remove commented code.
Add note about why we are adding the project to the master list.
Make sure if we are replacing a prev version, remove from global
list.
(ede-cpp-root-file-existing)
(ede-cpp-root-project-file-for-dir)
(ede-cpp-root-count, ede-cpp-root-project-root, ede-cpp-root-load)
(ede-project-autoload cpp-root): Deleted.
(ede-project-root-directory): Return :directory instead of
calculating from :file.
(project-rescan): New.

* ede/base.el (ede-toplevel): Only use buffer cached value if
subproj not passed in.

* srecode/java.el (srecode-semantic-handle-:java): Fix case when
an EDE project didn't support java paths.

* lisp/cedet/ede/proj-elisp.el
(ede-proj-target-elisp::ede-proj-tweak-autoconf): Kill buffer
after saving modified elisp-comp script, as to avoid "file has
changed on disk; really edit the buffer" questions when script
gets rewritten.

* emacs-lisp/eieio-custom.el (eieio-customize-object): Set
eieio-cog (current group) to g, which is an improved form of input
group.

* srecode/doc-cpp.srt (mode): Set to c mode so this works with
both C and C++.
2014-11-10 01:04:30 +01:00
Glenn Morris
c8bd285ff8 * admin/grammars/Makefile.in (bootstrap-clean): Don't delete Makefile,
for sake of top-level maintainer-clean rule.
2014-06-28 17:46:40 -07:00
Glenn Morris
4f2a67acd0 admin/grammars: Use pattern rules in Makefile
* admin/grammars/Makefile.in (${bovinedir}/c-by.el, ${bovinedir}/make-by.el):
(${wisentdir}/js-wy.el, ${wisentdir}/python-wy.el): Replace with pattern rules.
(${bovinedir}/scm-by.el, ${wisentdir}/javat-wy.el)
(${cedetdir}/srecode/srt-wy.el): Use $<.
2014-06-24 23:23:04 -07:00
Glenn Morris
e088b01d29 Avoid EMACSDATA in user environment interfering with building
* admin/grammars/Makefile.in (EMACSDATA, EMACSDOC, EMACSPATH):
* leim/Makefile.in (EMACSDATA, EMACSDOC, EMACSPATH):
* lisp/Makefile.in (EMACSDATA, EMACSDOC, EMACSPATH):
* test/automated/Makefile.in (EMACSDATA, EMACSDOC, EMACSPATH):
Unexport.

Fixes: debbugs:16429
2014-04-10 23:51:49 -07:00
David Engster
a60a2b6db2 Grammar bug fixes from CEDET upstream.
* grammars/c.by (function-pointer): Correctly deal with anonymous
function pointers.
(opt-brackets-after-symbol): New.
(multi-stage-dereference): Use it.  Add rules for explicit
matching the last dereference.
2014-02-06 21:57:24 +01:00
Paul Eggert
c91c771dbe Spelling fixes. 2014-01-15 22:24:06 -08:00
Paul Eggert
ba3189039a Update copyright year to 2014 by running admin/update-copyright. 2014-01-01 07:43:34 +00:00
David Engster
b0fe992f36 Merge with CEDET upstream.
* admin/grammars/c.by (expr-binop): Add MOD.
(variablearg): Add 'opt-assign'.
(variablearg, varnamelist): Add default values so that it can be
later expanded into the tag.
(opt-stuff-after-symbol): Rename to 'brackets-after-symbol' and
remove empty match.
(multi-stage-dereference): Adapt to above rename.
(unaryexpression): Use 'symbol' instead of 'namespace-symbol',
since the latter also leads to an empty match at the end which
would make this too greedy.
(variablearg-opt-name): Support parsing of function pointers
inside an argument list.

* semantic/analyze.el
(semantic-analyze-find-tag-sequence-default): Always add scope to
the local miniscope for each type.  Otherwise, structure tags are
not analyzed correctly.  Also, always search the extended
miniscope even when not dealing with types.

* semantic/ctxt.el (semantic-get-local-variables-default): Also
try to parse local variables for buffers which are currently
marked as unparseable.  Otherwise, it is often impossible to
complete local variables.

* semantic/scope.el (semantic-analyze-scoped-types-default): If we
cannot find a type in the typecache, also look into the the types
we already found.  This is necessary since in C++, a 'using
namespace' can be dependend on a previous one.
(semantic-completable-tags-from-type): When creating the list of
completable types, pull in types which are referenced through
'using' statements, and also preserve their filenames.

* semanitc/bovine/c.el (semantic/analyze/refs): Require.
(semantic-analyze-tag-references): New override.  Mainly copied
from the default implementation, but if nothing could be found (or
just the tag itself), drop all namespaces from the scope and
search again.  This is necessary for implementations which are
defined outside of the namespace and only pull those in through
'using' statements.
(semantic-ctxt-scoped-types): Go through all tags around point and
search them for using statements.  In the case for using
statements outside of function scope, append them in the correct
order instead of using 'cons'.  This is important since using
statements may depend on previous ones.
(semantic-expand-c-tag-namelist): Do not try to parse struct
definitions as default values.  The grammar parser seems to return
the point positions slightly differently (as a cons instead of a
list).  Also, set parent for typedefs to 'nil'.  It does not
really make sense to set a parent class for typedefs, and it can
also lead to endless loops when calculating scope.
(semantic-c-reconstitute-token): Change handling of function
pointers; instead of seeing them as variables, handle them as
functions with a 'function-pointer' attribute.  Also, correctly
deal with function pointers as function arguments.
(semantic-c-reconstitute-function-arglist): New function to parse
function pointers inside an argument list.
(semantic-format-tag-name): Use 'function-pointer' attribute
instead of the old 'functionpointer-flag'.
(semantic-cpp-lexer): Use new `semantic-lex-spp-paren-or-list'.

* semantic/bovine/gcc.el (semantic-gcc-setup): Add 'features.h' to
the list of files whose preprocessor symbols are included.  This
pulls in things like __USE_POSIX and similar.

* semantic/format.el (semantic-format-tag-prototype-default):
Display default values if available.

* semantic/analyze/refs.el (semantic-analyze-refs-impl)
(semantic-analyze-refs-proto): Add 'default-value' as ignorable in
call to `semantic-tag-similar-p'.

* semantic/db-mode.el (semanticdb-semantic-init-hook-fcn): Always
set buffer for `semanticdb-current-table'.

* semantic/db.el (semanticdb-table::semanticdb-refresh-table): The
previous change turned up a bug in this method.  Since the current
table now correctly has a buffer set, the first clause in the
`cond' would be taken, but there was a `save-excursion' missing.

* semantic/lex-spp.el (semantic-c-end-of-macro): Declare.
(semantic-lex-spp-token-macro-to-macro-stream): Deal with macros
which open/close a scope.  For this, leave an overlay if we
encounter a single open paren and return a semantic-list in the
lexer.  When this list gets expanded, retrieve the old position
from the overlay.  See the comments in the function for further
details.
(semantic-lex-spp-find-closing-macro): New function to find the
next macro which closes scope (i.e., has a closing paren).
(semantic-lex-spp-replace-or-symbol-or-keyword): Go to end of
closing macro if necessary.
(semantic-lex-spp-paren-or-list): New lexer to specially deal with
parens in macro definitions.

* semantic/decorate/mode.el (semantic-decoration-mode): Do not
decorate available tags immediately but in an idle timer, since
EDE will usually not be activated yet, which will make it
impossible to find project includes.

* semantic/decorate/include.el
(semantic-decoration-on-includes-highlight-default): Remove
'unloaded' from throttle when decorating includes, otherwise all
would be loaded.  Rename 'table' to 'currenttable' to make things
clearer.

* ede/linux.el (cl): Require during compile.

* ede/linux.el (project-linux-build-directory-default)
(project-linux-architecture-default): Add customizable variables.
(ede-linux-project): Add additional slots to track Linux-specific
information (out-of-tree build directory and selected
architecture).
(ede-linux--get-build-directory, ede-linux--get-archs)
(ede-linux--detect-architecture, ede-linux--get-architecture)
(ede-linux--include-path): Added function to detect Linux-specific
information.
(ede-linux-load): Set new Linux-specific information when creating
a project.
(ede-expand-filename-impl): Use new and more accurate include
information.

* semantic/scope.el (semantic-calculate-scope): Return a clone of
the scopecache, so that everyone is working with its own (shallow)
copy.  Otherwise, if one caller is resetting the scope, it would
be reset for all others working with the scope cache as well.
2013-12-12 22:33:06 +01:00
Glenn Morris
d715c01933 * admin/grammars/Makefile.in: Ensure output files are writable. 2013-11-30 09:54:40 -08:00
Glenn Morris
f9b697ddaa Stop keeping (all but one) generated cedet grammar files in the repository
* configure.ac (SUBDIR_MAKEFILES, AC_CONFIG_FILES):
Add admin/grammars Makefile.

* Makefile.in (distclean, bootstrap-clean, maintainer-clean):
Also clean admin/grammars, if present.

* admin/grammars/README: Remove.

* admin/grammars/Makefile.in: New file.

* admin/grammars/c.by, admin/grammars/java-tags.wy, admin/grammars/js.wy:
* admin/grammars/python.wy: Update declarations to match generated outputs.

* lisp/Makefile.in (semantic): New.
(compile-main): Depend on semantic.

* lisp/cedet/semantic/bovine/grammar.el (bovine--make-parser-1):
New function, split from bovine-make-parsers.
(bovine-make-parsers): Use bovine--make-parser-1.
(bovine-batch-make-parser): New function.

* lisp/cedet/semantic/wisent/grammar.el (wisent--make-parser-1):
New function, split from wisent-make-parsers.
(wisent-make-parsers): Use wisent--make-parser-1.
(wisent-batch-make-parser): New function.

* lisp/cedet/semantic/db.el (semanticdb-save-all-db):
Avoid prompting in batch mode.

* lisp/cedet/semantic/grammar.el (semantic-grammar-footer-template):
Disable version-control and autoloads in the output.
(semantic-grammar-create-package):
Add option to return nil if output is up-to-date.

* lisp/cedet/semantic/bovine/c-by.el, lisp/cedet/semantic/bovine/make-by.el:
* lisp/cedet/semantic/bovine/scm-by.el, lisp/cedet/semantic/wisent/javat-wy.el:
* lisp/cedet/semantic/wisent/js-wy.el, lisp/cedet/semantic/wisent/python-wy.el:
* lisp/cedet/srecode/srt-wy.el: Remove generated files from repository.

* .bzrignore: Update for this.
2013-11-29 18:06:34 -08:00
David Engster
890f78904a Merge from CEDET upstream (8564).
* lisp/emacs-lisp:

	* emacs-lisp/eieio.el (eieio--defalias, eieio-hook)
	(eieio-error-unsupported-class-tags, eieio-skip-typecheck)
	(eieio-optimize-primary-methods-flag, eieio-initializing-object)
	(eieio-unbound, eieio-default-superclass)
	(eieio--define-field-accessors, method-static, method-before)
	(method-primary, method-after, method-num-lists)
	(method-generic-before, method-generic-primary)
	(method-generic-after, method-num-slots)
	(eieio-specialized-key-to-generic-key)
	(eieio--check-type, class-v, class-p)
	(eieio-class-name, define-obsolete-function-alias)
	(eieio-class-parents-fast, eieio-class-children-fast)
	(same-class-fast-p, class-constructor, generic-p)
	(generic-primary-only-p, generic-primary-only-one-p)
	(class-option-assoc, class-option, eieio-object-p)
	(class-abstract-p, class-method-invocation-order)
	(eieio-defclass-autoload-map, eieio-defclass-autoload)
	(eieio-class-un-autoload, eieio-defclass)
	(eieio-eval-default-p, eieio-perform-slot-validation-for-default)
	(eieio-add-new-slot, eieio-copy-parents-into-subclass)
	(eieio--defgeneric-init-form, eieio-defgeneric-form)
	(eieio-defgeneric-reset-generic-form)
	(eieio-defgeneric-form-primary-only)
	(eieio-defgeneric-reset-generic-form-primary-only)
	(eieio-defgeneric-form-primary-only-one)
	(eieio-defgeneric-reset-generic-form-primary-only-one)
	(eieio-unbind-method-implementations)
	(eieio--defmethod, eieio--typep)
	(eieio-perform-slot-validation, eieio-validate-slot-value)
	(eieio-validate-class-slot-value, eieio-barf-if-slot-unbound)
	(eieio-oref, eieio-oref-default, eieio-default-eval-maybe)
	(eieio-oset, eieio-oset-default, eieio-slot-originating-class-p)
	(eieio-slot-name-index, eieio-class-slot-name-index)
	(eieio-set-defaults, eieio-initarg-to-attribute)
	(eieio-attribute-to-initarg, eieio-c3-candidate)
	(eieio-c3-merge-lists, eieio-class-precedence-c3)
	(eieio-class-precedence-dfs, eieio-class-precedence-bfs)
	(eieio-class-precedence-list, eieio-generic-call-methodname)
	(eieio-generic-call-arglst, eieio-generic-call-key)
	(eieio-generic-call-next-method-list)
	(eieio-pre-method-execution-functions, eieio-generic-call)
	(eieio-generic-call-primary-only, eieiomt-method-list)
	(eieiomt-optimizing-obarray, eieiomt-install)
	(eieiomt-add, eieiomt-next, eieiomt-sym-optimize)
	(eieio-generic-form, eieio-defmethod, make-obsolete)
	(eieio-defgeneric, make-obsolete): Moved to eieio-core.el
	(defclass): Remove `eval-and-compile' from macro.
	(call-next-method, shared-initialize): Instead of using
	`scoped-class' variable, use new eieio--scoped-class, and
	eieio--with-scoped-class.
	(initialize-instance): Rename local variable 'scoped-class' to
	'this-class' to remove ambiguitity from old global.

	* emacs-lisp/eieio-core.el: New file.  Derived from key parts of
	eieio.el.
	(eieio--scoped-class-stack): New variable
	(eieio--scoped-class): New fcn
	(eieio--with-scoped-class): New scoping macro.
	(eieio-defclass): Use pushnew instead of add-to-list.
	(eieio-defgeneric-form-primary-only-one, eieio-oset-default)
	(eieio-slot-name-index, eieio-set-defaults, eieio-generic-call)
	(eieio-generic-call-primary-only, eieiomt-add): Instead of using
	`scoped-class' variable, use new eieio--scoped-class, and
	eieio--with-scoped-class.

	* emacs-lisp/eieio-base.el (cl-lib): Require during compile.

* admin/grammars:

	* grammars/srecode-template.wy (variable): Accept a single number
	as a variable value.  Allows the 'priority' to be set to a number.
	(wisent-srecode-template-lexer): Move number up so it can be
	created.

* etc/srecode:

	* srecode/c.srt (header_guard): Add :c parameter so it works
	standalone

* lisp/cedet:

	* semantic/edit.el (semantic-change-function): Use
	`save-match-data' around running hooks.

	* semantic/decorate/mode.el
	(semantic-decorate-style-predicate-default)
	(semantic-decorate-style-highlighter-default): New.
	(semantic-decoration-mode): Do not require
	`semantic/decorate/include' anymore.
	(semantic-toggle-decoration-style): Error if an unknown decoration
	style is toggled.
	(define-semantic-decoration-style): Add new :load option.  When
	:load is specified, add autoload tokens for the definition
	functions so that code is loaded when the mode is used.
	(semantic-decoration-on-includes): New autoload definition for
	highlighting includes.

	* semantic/bovine/c.el (semantic-lex-c-ifdef): Allow some misc
	characters to appear after the tested variable.

	* semantic/ede-grammar.el (project-compile-target): Calculate full
	src name via ede-expand-filename instead of the crutch of the
	current buffer.  Enables this target to compile in batch mode.

	* semantic/idle.el
	(semantic-idle-symbol-maybe-highlight): Wrap highlighting of
	remote symbol with `save-excursion'.
	(semantic-idle-scheduler-work-parse-neighboring-files): Instead of
	using directory-files on each found mode pattern, collect all the
	patterns for the current mode, and then for each file, see if it
	matches any of them.  If it does, parse the file.  (Patch
	inspiration from Tomasz Gajewski.)

	* semantic/ctxt.el (semantic-ctxt-end-of-symbol): New.
	(semantic-ctxt-current-symbol-default): New.

	* semantic/bovine/el.el (semantic-default-elisp-setup): Add
	autoload cookie.  Explain existence.
	(footer): Add local variable for loaddefs.

	* semantic/db.el (semanticdb-file-table-object): Add new filter,
	only checking for regular files too.

	* semantic/wisent/python.el
	(semantic-format-tag-abbreviate): New override.  Cuts back on size
	of code tags.

	* srecode/compile.el (srecode-compile-templates): Fix warning
	punctuation.  Remove status messages to clean up testing output

	* ede/base.el (ede-project-placeholder-cache-file): Update doc to
	mention 'nil' value.
	(ede-save-cache): Disable cache save if file is nil.

	* ede.el (ede-initialize-state-current-buffer): Flush deleted
	projects.
	(global-ede-mode): Always append our find-file-hook to the end.
	(ede-flush-deleted-projects): New command.

	* ede/cpp-root.el (ede-preprocessor-map): Protect against init
	problems.

	* ede/proj.el (ede-proj-target): Added a new "custom" option for
	custom symbols representing a compiler or linker instead of
	restricting things to only the predefined compilers and linkers.

	* semantic.el (semantic-mode-map): To avoid showing showing
	Development menu twice, only disable menu item if menu-bar is
	actually enabled, otherwise the popup 'global menu' might display
	a disabled Development menu.

	* semantic/complete.el
	(semantic-displayor-show-request): Fix which slot in obj is set to
	the max tags.
2013-06-02 15:33:09 +02:00
Paul Eggert
f5572543da Fix encoding problem in javat-wy.el.
* admin/grammars/java-tags.wy (CHAR): Remove "('\u0000' to '\uffff')"
from summary, as this causes javat-wy.el to contain both a null byte
and a byte sequence that is not valid UTF-8, which is inconvenient.
* lisp/cedet/semantic/wisent/javat-wy.el: Regenerate.
2013-03-03 23:25:17 -08:00
Paul Eggert
ab422c4d68 Update copyright notices for 2013. 2013-01-01 09:11:05 +00:00
Chong Yidong
0db901c17a Update for admin/grammars/README. 2012-10-06 22:22:31 +08:00
Chong Yidong
9414dd8d50 Move bovine-grammar and wisent-grammar into lisp/ directory.
* lisp/files.el (auto-mode-alist): Add .by and .wy (Semantic grammars).

* cedet/semantic/bovine/grammar.el:
* cedet/semantic/wisent/grammar.el: Move from admin/grammars.  Add
autoloads for bovine-grammar-mode and wisent-grammar-mode.
2012-10-06 22:18:35 +08:00
Paul Eggert
735135f9bc Spelling fixes. 2012-10-04 22:57:24 -07:00
Chong Yidong
62a81506f8 Update CEDET from upstream. 2012-10-02 02:10:29 +08:00
Glenn Morris
1259009aa1 Merge from emacs-23; up to 2012-01-19T07:15:48Z!rgm@gnu.org. 2012-01-18 23:21:25 -08:00
Glenn Morris
acaf905b11 Add 2012 to FSF copyright years for Emacs files 2012-01-05 01:46:05 -08:00
Paul Eggert
22bcf20469 Spelling fixes. 2011-12-30 17:27:15 -08:00
Paul Eggert
99d990817c Spelling fixes. 2011-12-18 22:21:24 -08:00