[llvm] fix the logic in setting emacs keymap for tablegen (PR #100959)

Haoning Ye via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 28 19:23:15 PDT 2024


https://github.com/YHN-ice created https://github.com/llvm/llvm-project/pull/100959

it is probably a typo

>From 6388c51a12a79b57631bfba5e6e27da719c23066 Mon Sep 17 00:00:00 2001
From: Haoning <HaoningYe at outlook.com>
Date: Sun, 28 Jul 2024 22:14:22 -0400
Subject: [PATCH] fix the logic in setting emacs keymap for tablegen

probably a typo
---
 llvm/utils/emacs/tablegen-mode.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/utils/emacs/tablegen-mode.el b/llvm/utils/emacs/tablegen-mode.el
index b1cc1cb36c06e..34a1f79514031 100644
--- a/llvm/utils/emacs/tablegen-mode.el
+++ b/llvm/utils/emacs/tablegen-mode.el
@@ -90,7 +90,7 @@
 (defvar tablegen-mode-hook nil)
 (defvar tablegen-mode-map nil)   ; Create a mode-specific keymap.
 
-(if (not tablegen-mode-map)
+(if tablegen-mode-map
     ()  ; Do not change the keymap if it is already set up.
   (setq tablegen-mode-map (make-sparse-keymap))
   (define-key tablegen-mode-map "\t"  'tab-to-tab-stop)



More information about the llvm-commits mailing list