Spelling fixes.
[bpt/emacs.git] / lisp / cedet / semantic / bovine / c.el
index 03d3704..9a862c6 100644 (file)
@@ -1,7 +1,6 @@
 ;;; semantic/bovine/c.el --- Semantic details for C
 
-;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
-;;   2008, 2009, 2010  Free Software Foundation, Inc.
+;; Copyright (C) 1999-2011  Free Software Foundation, Inc.
 
 ;; Author: Eric M. Ludlam <zappo@gnu.org>
 
@@ -94,8 +93,8 @@ NOTE: In process of obsoleting this."
 ;; Compiler options need to show up after path setup, but before
 ;; the preprocessor section.
 
-(when (member system-type '(gnu gnu/linux darwin cygwin))
-  (semantic-gcc-setup))
+(if (memq system-type '(gnu gnu/linux darwin cygwin))
+    (semantic-gcc-setup))
 
 ;;; Pre-processor maps
 ;;
@@ -241,7 +240,7 @@ Return the defined symbol as a special spp lex token."
                        (goto-char (match-end 0))
                        (looking-at "(")))
           (semantic-lex-spp-replacements-enabled nil)
-          ;; Temporarilly override the lexer to include
+          ;; Temporarily override the lexer to include
           ;; special items needed inside a macro
           (semantic-lex-analyzer #'semantic-cpp-lexer)
           (raw-stream
@@ -250,7 +249,7 @@ Return the defined symbol as a special spp lex token."
                                                 (point))))
           )
 
-      ;; Only do argument checking if the paren was immediatly after
+      ;; Only do argument checking if the paren was immediately after
       ;; the macro name.
       (if with-args
          (semantic-lex-spp-first-token-arg-list (car raw-stream)))
@@ -345,7 +344,7 @@ Uses known macro tables in SPP to determine what block to skip."
                 (string= sym "0"))
            (and ifdef (not (semantic-lex-spp-symbol-p sym)))
            (and ifndef (semantic-lex-spp-symbol-p sym)))
-       ;; The if indecates to skip this preprocessor section
+       ;; The if indicates to skip this preprocessor section.
        (let ((pt nil))
          ;; (message "%s %s yes" ift sym)
          (beginning-of-line)
@@ -651,7 +650,7 @@ as for the parent."
                (setq depth 0)
 
                ;; This is a copy of semantic-parse-region-default where we
-               ;; are doing something special with the lexication of the
+               ;; are doing something special with the lexing of the
                ;; contents of the semantic-list token.  Stuff not used by C
                ;; removed.
                (let ((tokstream
@@ -1002,6 +1001,13 @@ if something is a constructor.  Value should be:
 where typename is the name of the type, and typeoftype is \"class\"
 or \"struct\".")
 
+(define-mode-local-override semantic-analyze-split-name c-mode (name)
+  "Split up tag names on colon (:) boundaries."
+  (let ((ans (split-string name ":")))
+    (if (= (length ans) 1)
+       name
+      (delete "" ans))))
+
 (defun semantic-c-reconstitute-token (tokenpart declmods typedecl)
   "Reconstitute a token TOKENPART with DECLMODS and TYPEDECL.
 This is so we don't have to match the same starting text several times.
@@ -1086,7 +1092,7 @@ Optional argument STAR and REF indicate the number of * and & in the typedef."
              ;; `throws' as a common name for things that toss
              ;; exceptions about.
              :throws (nth 5 tokenpart)
-             ;; Reemtrant is a C++ thingy.  Add it here
+             ;; Reentrant is a C++ thingy.  Add it here
              :reentrant-flag (if (member "reentrant" (nth 6 tokenpart)) t)
              ;; A function post-const is funky.  Try stuff
              :methodconst-flag (if (member "const" (nth 6 tokenpart)) t)
@@ -1122,7 +1128,7 @@ Optional PARENT and COLOR are ignored."
 
 (define-mode-local-override semantic-format-tag-canonical-name
   c-mode (tag &optional parent color)
-  "Create a cannonical name for TAG.
+  "Create a canonical name for TAG.
 PARENT specifies a parent class.
 COLOR indicates that the text should be type colorized.
 Enhances the base class to search for the entire parent
@@ -1559,13 +1565,6 @@ These are constants which are of type TYPE."
           (string= (semantic-tag-type type) "enum"))
       (semantic-tag-type-members type)))
 
-(define-mode-local-override semantic-analyze-split-name c-mode (name)
-  "Split up tag names on colon (:) boundaries."
-  (let ((ans (split-string name ":")))
-    (if (= (length ans) 1)
-       name
-      (delete "" ans))))
-
 (define-mode-local-override semantic-analyze-unsplit-name c-mode (namelist)
   "Assemble the list of names NAMELIST into a namespace name."
   (mapconcat 'identity namelist "::"))
@@ -1871,5 +1870,4 @@ For types with a :parent, create faux namespaces to put TAG into."
 ;; generated-autoload-load-name: "semantic/bovine/c"
 ;; End:
 
-;; arch-tag: 263951a8-0f18-445d-8e73-eb8f9ac8e2a3
 ;;; semantic/bovine/c.el ends here