Recently, I wrote a neovim plugin for myself that automates/facilitates
common dejagnu testsuite tasks for c++ frontend bug fixing:
- Searching/executing tests from within neovim
- Extracting cc1plus invocations from xg++ for GDB debugging
- Running testsuite cases with proper libstdc++ include paths
- wraps nvim-gdb so that cc1plus can be directly invoked and opened in
gdb inside nvim
The plugin can be found here: https://github.com/riogu/gcc1plus
Given that we have vim-gcc-dev/ in contrib/, i believe that extending
this to neovim would make working with the ecosystem easier, since we
would have a config that streamlines a lot of the process around testing
a patch and searching for regressions. In addition, i intend on adding
support for libstdc++ tests too. It's also extendable to other frontends
and offers a unified base config for others to add features they find
useful.
The plugin is currently licensed under GPLv3.0, but it can be changed if
necessary.
For now, I'm proposing adding a README in contrib/nvim-gcc-dev/ that
directs developers to the plugin on GitHub (as is standard for neovim
plugins). However, if people prefer to maintain the plugin directly in
contrib/, I'm happy to integrate it and update it through patches.
I'm interested to know if people think this is useful/worth expanding
with more features.
I've included a patch below with these changes.
---
>From 35cb03a888eac09dc43bbf5dbdb1b33105b14dfc Mon Sep 17 00:00:00 2001
From: Egas Ribeiro <[email protected]>
Date: Wed, 5 Nov 2025 14:22:16 +0000
Subject: [PATCH] contrib: Add Neovim plugin directory
Add a README for gcc1plus, a Neovim plugin that streamlines GCC
testsuite workflows for C++ frontend development. The plugin provides
integrated debugging and testing capabilities including interactive test
search, GDB integration for cc1plus debugging, DejaGNU directive parsing,
and testsuite execution with proper libstdc++ paths.
The plugin is maintained externally on GitHub
(https://github.com/riogu/gcc1plus) and can be installed through standard
Neovim plugin managers. This README serves as a discovery point for
contributors using Neovim and mirrors the structure of vim-gcc-dev/.
The plugin is licensed under GPLv3.0 and may be integrated more directly
into contrib/ if maintainers prefer to handle updates through patches.
contrib/ChangeLog:
* nvim-gcc-dev/README: New file.
---
contrib/nvim-gcc-dev/README | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)
create mode 100644 contrib/nvim-gcc-dev/README
diff --git a/contrib/nvim-gcc-dev/README b/contrib/nvim-gcc-dev/README
new file mode 100644
index 00000000000..95116b1a001
--- /dev/null
+++ b/contrib/nvim-gcc-dev/README
@@ -0,0 +1,36 @@
+Neovim Plugin for GCC Development
+==================================
+
+This directory contains the gcc1plus plugin, a Neovim addon that streamlines
+GCC testsuite workflows for C++ frontend development.
+
+Installation
+------------
+
+The plugin is installed through standard Neovim plugin managers
+(lazy.nvim, packer.nvim, vim-plug). See the GitHub repository for complete
+installation instructions and usage examples.
+
+Example with lazy.nvim:
+```lua
+{
+ 'riogu/gcc1plus',
+ dependencies = {
+ { 'sakhnik/nvim-gdb', build = './install.sh' },
+ },
+}
+```
+
+Features
+--------
+
+ - Interactive test search `:FindTest`
+ - GDB integration for cc1plus debugging
+ - DejaGNU directive parsing
+ - Testsuite execution with proper libstdc++ paths
+
+Documentation
+-------------
+
+For complete documentation and usage examples:
+ https://github.com/riogu/gcc1plus
--
2.51.0