With 2.86 on recent linuxfromscratch (gcc-13) using '--disable-lsp' I get
symbolmaps.h: In constructor ‘AsymptoteLsp::SymbolInfo::SymbolInfo()’:
symbolmaps.h:137:25: error: ‘nullopt’ was not declared in this scope; did you mean ‘std::nullopt’?
137 | SymbolInfo() : type(nullopt), pos(1, 1) {}
| ^~~
| std::nullopt
It seems that the change to common.h for 2.86 included an option for non-old cplusplus only in the HAVE_LSP part.
Following fixes the build and passes my limited testing:
With 2.86 on recent linuxfromscratch (gcc-13) using '--disable-lsp' I get
symbolmaps.h: In constructor ‘AsymptoteLsp::SymbolInfo::SymbolInfo()’: symbolmaps.h:137:25: error: ‘nullopt’ was not declared in this scope; did you mean ‘std::nullopt’? 137 | SymbolInfo() : type(nullopt), pos(1, 1) {} | ^
~~ | std::nulloptIt seems that the change to common.h for 2.86 included an option for non-old cplusplus only in the HAVE_LSP part.
Following fixes the build and passes my limited testing:
diff -Naur a/common.h b/common.h --- a/common.h 2023-06-07 02:59:39.000000000 +0100 +++ b/common.h 2023-06-13 19:57:51.333429562 +0100 @@ -38,6 +38,11 @@ using nonstd::optional; using nonstd::nullopt; using nonstd::make_optional; +#else +#include
+using std::optional;
+using std::nullopt;
+using std::make_optional;
endif
endif