From d20dec903fca4b54753dd86dbcdce9d9875f56c0 Mon Sep 17 00:00:00 2001 From: Eshel Yaron Date: Sun, 9 Jun 2024 19:26:36 +0200 Subject: [PATCH] hideif.el: Cease depending on Semantic --- lisp/progmodes/hideif.el | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index 98e567299a1..a0d60b64788 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -507,24 +507,17 @@ that form should be displayed.") (__STDC_HOST__ . hif-__STDC_HOST__) (__BASE_FILE__ . hif-__FILE__))) -(declare-function semantic-c-hideif-lookup "semantic/bovine/c" (var)) -(declare-function semantic-c-hideif-defined "semantic/bovine/c" (var)) - (defun hif-lookup (var) - (or (when (bound-and-true-p semantic-c-takeover-hideif) - (semantic-c-hideif-lookup var)) - (let ((val (assq var hide-ifdef-env))) - (if val - (cdr val) - (if (setq val (assq var hif-predefine-alist)) - (funcall (cdr val)) - hif-undefined-symbol))))) + (let ((val (assq var hide-ifdef-env))) + (if val + (cdr val) + (if (setq val (assq var hif-predefine-alist)) + (funcall (cdr val)) + hif-undefined-symbol)))) (defun hif-defined (var) (let (def) (cond - ((bound-and-true-p semantic-c-takeover-hideif) - (semantic-c-hideif-defined var)) ;; Here we can't use hif-lookup as an empty definition like `#define EMPTY' ;; is considered defined but is evaluated as nil. ((assq var hide-ifdef-env) 1) -- 2.39.2