Compare commits

...
66 Commits
Author SHA1 Message Date
Sean McManus 03933b0a74 Merge pull request #12277 from microsoft/seanmcm/1_20_5_release
Merge for 1.20.5
2024-05-07 20:26:45 -07:00
[email protected] fc8eb8632f [Auto] Localization - Translated Strings (#12236) 2024-05-03 16:06:02 -07:00
Sean McManus f6722bc8ff Update version and changelog for 1.20.5 (#12264)
* Update version and changelog for 1.20.5
2024-05-03 15:30:48 -07:00
Sean McManus 894db52405 Fix macOS version check. (#12276) 2024-05-03 15:29:46 -07:00
Sean McManus abf384619d Merge branch 'insiders' into seanmcm/1_20_5_release 2024-05-03 15:29:34 -07:00
Sean McManus fd482d2169 Merge pull request #12274 from microsoft/seanmcm/1_20_4_cherrypick
Updates for 1.20.4 (#12273)
2024-05-02 11:16:42 -07:00
Sean McManus 2fafd831e5 Updates for 1.20.4 (#12273)
* Don't use the crash handler on macOS < 19.
* Update version and changelog.
2024-05-02 10:14:49 -07:00
Sean McManus 1ceae9d4ed Merge pull request #12266 from microsoft/seanmcm/1_20_3_cherryPicks
Cherry-picks for 1.20.3
2024-04-30 16:18:52 -07:00
Sean McManus d4d5d4551f Update version and changelog for 1.20.3 (#12245)
* Update version and changelog for 1.20.3
2024-04-30 13:11:53 -07:00
Sean McManus 0ef77b5616 Improvements to crash call stack logging. (#12247)
* Updates to crash call stack logging.
* Move crash logging to its own channel.
2024-04-30 13:11:10 -07:00
Sean McManus efdc8e90f6 Merge pull request #12235 from microsoft/seanmcm/1_20_2_cherryPicks2
Cherry-picks for 1.20.2
2024-04-19 17:17:01 -07:00
Sean McManus 9f020e9258 Update changelog for 1.20.2 (2nd time) (#12228)
* Update changelog
2024-04-19 16:57:13 -07:00
Bob Brown c058568767 rename the property again (#12233)
* rename the property again

* fail
2024-04-19 16:57:00 -07:00
browntarik 8809e69e91 Remove redundant variable resolution in handleSquiggles and fix error messaging for env and delimited paths under include paths in c_cpp_properties.json (#12188)
* remove redundant variable resolution

* fix lint

* remove resolveVariable redundancies

* change when resolve and split happens

* fix lint

* Resolve error checking for environment vars and delimited paths

* remove "path" from error messaging

* Adjust error messaging

* remove stray comment

* refactor error messaging + minor fix

* resolve lint

* Fix multi path squiggle regression

* Remove resolvedPath redundancies

* Refactor error messaging and squiggling

* Revert and improve error squiggling behavior

* fix linting

* properly proccess glob patterns + minor fixes

* fix comment positions

* Refactor error message + minor fix

* Fix telemetry metric + minor fix
2024-04-19 16:56:46 -07:00
Sean McManus 7af5c40dd0 Handle multiple cpptools-srv crashes. (#12225) 2024-04-19 16:56:33 -07:00
Sean McManus 1d2bd10691 Merge pull request #12223 from microsoft/main
Fix SettingsTracking treating numerical loggingLevel as invalid. (#12…
2024-04-18 15:11:30 -07:00
Sean McManus dac96fe852 Merge pull request #12209 from microsoft/main
Merge for 1.20.2
2024-04-16 18:43:48 -07:00
Sean McManus a1487e5e79 Merge pull request #12185 from microsoft/main
Merge for 1.20.1
2024-04-09 17:07:29 -07:00
Sean McManus 6f19496172 Merge pull request #12138 from microsoft/main
Merge for 1.20.0
2024-03-26 14:12:18 -07:00
Colen Garoutte-Carson ad5d6de4ea Merge pull request #12123 from microsoft/coleng/cherry_pick_1.19.9.x2 2024-03-19 16:40:47 -07:00
Colen Garoutte-Carson 153e232f2d Update changelog for 1.19.9 again (#12122) 2024-03-19 16:16:21 -07:00
Colen Garoutte-Carson bcd4a7f025 Merge pull request #12118 from microsoft/coleng/cherry_pick_1.19.9 2024-03-18 15:00:41 -07:00
Colen Garoutte-Carson 3c3d463a81 Update changelog 1.19.9 (#12117) 2024-03-18 13:22:40 -07:00
Colen Garoutte-Carson 92691929ed Merge pull request #12100 from microsoft/coleng/merge_release_1.19.8.try2 2024-03-13 17:16:25 -07:00
Colen Garoutte-Carson 86a41c9021 Update changelog for 1.19.8 again (#12099) 2024-03-13 17:12:21 -07:00
Colen Garoutte-Carson a71c90c140 Merge pull request #12093 from microsoft/coleng/cherry_pick_1.19.8 2024-03-12 19:16:35 -07:00
Colen Garoutte-Carson 1d28851ef7 Update changelog for 1.19.8 (#12092) 2024-03-12 19:11:20 -07:00
Colen Garoutte-Carson 1aced54699 Merge pull request #12090 from microsoft/coleng/cherry_pick_3_11_2024 2024-03-11 14:17:04 -07:00
Bob Brown a8cf39c8b4 Prevent the status bar from updating too quickly (#12088) 2024-03-11 13:32:50 -07:00
Colen Garoutte-Carson e037b95926 Merge pull request #12087 from microsoft/coleng/cherry_pick_to_release_again 2024-03-08 15:09:53 -08:00
Colen Garoutte-Carson af7f6ce52e Update changelog again for 1.19.7 (#12086) 2024-03-08 15:01:37 -08:00
Colen Garoutte-Carson 9a18982440 Merge pull request #12083 from microsoft/coleng/cherry_pick_release_1.19.7 2024-03-08 11:09:55 -08:00
Colen Garoutte-Carson 35bf4c8b0f Update changelog for 1.19.7 (#12081) 2024-03-08 10:32:50 -08:00
Colen Garoutte-Carson 23446558cf Merge pull request #12065 from microsoft/main 2024-03-05 18:22:19 -08:00
Colen Garoutte-Carson 76ccb791ff Merge pull request #11947 from microsoft/main 2024-02-09 17:16:17 -08:00
Colen Garoutte-Carson a5a5735089 Merge pull request #11942 from microsoft/main 2024-02-08 17:07:45 -08:00
Sean McManus 5077edf585 Merge pull request #11886 from microsoft/main
Merge for 1.19.2 (2nd time)
2024-01-19 18:08:55 -08:00
Colen Garoutte-Carson f38926f8b1 Merge pull request #11874 from microsoft/main 2024-01-16 17:41:23 -08:00
Sean McManus 30de9bcc27 Merge pull request #11725 from microsoft/main
Update for 1.19.1 (#11724)
2023-11-21 17:12:17 -08:00
Sean McManus 100e2e0828 Merge pull request #11699 from microsoft/main
Merge for 1.19.0
2023-11-16 18:39:02 -08:00
Sean McManus e3b41771c6 Merge pull request #11639 from microsoft/main
Merge for 1.18.2 (2nd time)
2023-11-08 12:34:50 -08:00
Sean McManus 3f7f3090f6 Merge pull request #11633 from microsoft/main
Merge for 1.18.2
2023-11-07 15:59:34 -08:00
Sean McManus 4149493f2c Merge pull request #11607 from microsoft/main
Merge for 1.18.1
2023-11-01 17:55:01 -07:00
Sean McManus 43aad3f65c Merge pull request #11528 from microsoft/main
Update changelog (2nd time) (#11527)
2023-10-12 17:21:18 -07:00
Sean McManus bedcacb0a1 Merge pull request #11526 from microsoft/main
Merge for 1.18.0
2023-10-12 14:58:49 -07:00
Sean McManus a5f8f84b43 Merge pull request #11303 from microsoft/main
Merge for 1.17.1
2023-08-08 17:51:04 -07:00
Sean McManus e53b190380 Merge pull request #11253 from microsoft/main
Merge (again) for 1.17.0
2023-07-26 16:56:43 -07:00
Michelle Matias 1846fd4001 Merge pull request #11250 from microsoft/main 2023-07-26 14:15:17 -07:00
Colen Garoutte-Carson 62e09945e3 Merge pull request #11241 from microsoft/main 2023-07-24 17:32:28 -07:00
Michelle Matias c9b0db02fd Merge pull request #11230 from microsoft/main
Merge 1.17.0
2023-07-21 14:08:21 -07:00
Michelle Matias 51da619eec Merge pull request #11099 from microsoft/main
1.16.1 pre-release
2023-06-15 21:19:13 -07:00
Michelle Matias 3eb50568e9 Merge pull request #10986 from microsoft/main
[Auto] Localization - Translated Strings (#10889)
2023-05-22 13:53:52 -07:00
Michelle Matias 866b145645 Merge pull request #10975 from microsoft/main
1.16.0 pre-release
2023-05-19 15:52:02 -07:00
Sean McManus 9762fe5397 Merge pull request #10862 from microsoft/main
Merge for 1.15.3 (2nd time)
2023-04-21 19:00:16 -07:00
Sean McManus 377896c30a Merge pull request #10846 from microsoft/main
Merge for 1.15.3
2023-04-20 18:55:05 -07:00
Michelle Matias 98f13a6f11 Merge pull request #10815 from microsoft/main
Don't put the compiler selection in the global settings if using the …
2023-04-12 17:57:26 -07:00
Michelle Matias 0d85aea687 Merge pull request #10813 from microsoft/main
Revert walkthrough doc links until walkthrough is published (#10812)
2023-04-12 15:51:05 -07:00
Sean McManus 25d2b76514 Merge pull request #10811 from microsoft/main
Merge for 1.15.2
2023-04-12 11:03:43 -07:00
Sean McManus 42dfef3f6b Merge pull request #10728 from microsoft/main
Merge for 1.15.1
2023-03-22 11:43:15 -07:00
Sean McManus 1ce1e9cd71 Merge pull request #10716 from microsoft/main
Update changelog for 1.15.1. (#10708)
2023-03-21 09:53:45 -07:00
Sean McManus 65163966d5 Merge pull request #10679 from microsoft/main
Merge for 1.15.0
2023-03-15 17:17:35 -07:00
Sean McManus edf8e0a155 Merge pull request #10504 from microsoft/main
Merge for 1.14.2 (2nd time)
2023-02-09 16:30:37 -08:00
Sean McManus 4083075476 Merge pull request #10501 from microsoft/main
Merge for 1.14.2
2023-02-09 14:26:59 -08:00
Michelle Matias b745ebc218 Merge pull request #10453 from microsoft/main
1.14.1 pre-release merge
2023-02-01 14:29:00 -08:00
Michelle Matias b69d17a0f5 Merge pull request #10378 from microsoft/seanmcm/1_14_0_insiders
Merge for 1.14.0
2023-01-11 20:00:38 -08:00
Sean McManus be8b6fb693 Merge branch 'main' into seanmcm/1_14_0_insiders 2023-01-11 19:07:54 -08:00
33 changed files with 237 additions and 94 deletions
+13 -13
View File
@@ -1,38 +1,38 @@
# C/C++ for Visual Studio Code Changelog
## Version 1.20.2: April 17, 2024
### Bug Fixes
* Fix duplicate URIs in calls to provideConfigurations. [#12177](https://github.com/microsoft/vscode-cpptools/issues/12177)
* Fix a crash and deadlock with a high `C_Cpp.loggingLevel`. [#12194](https://github.com/microsoft/vscode-cpptools/issues/12194)
* Fix handling of `-iquote` for code analysis and `#include` completions. [#12198](https://github.com/microsoft/vscode-cpptools/issues/12198)
## Version 1.20.1: April 9, 2024
### Bug Fixes
* Fix 'Add #include' code actions for code scoped by a namespace or class. [#11541](https://github.com/microsoft/vscode-cpptools/issues/11541)
* Fix the IntelliSense server not starting when a completion, signature help, or document highlight occurs from external commands. [#12143](https://github.com/microsoft/vscode-cpptools/issues/12143)
* Fix the IntelliSense configuration not falling back to the `c_cpp_properties.json` configuration for a file not handled by a configuration provider. [#12144](https://github.com/microsoft/vscode-cpptools/issues/12144)
## Version 1.20.0: March 26, 2024
## Version 1.20.5: May 6, 2024
### Enhancements
* Add support for C++ modules IFC version 0.43. [#10843](https://github.com/microsoft/vscode-cpptools/issues/10843)
* Add support for `${userHome}` in `c_cpp_properties.json`. [#11756](https://github.com/microsoft/vscode-cpptools/issues/11756)
* Reduce the default max workspace symbol search results and add `C_Cpp.maxSymbolSearchResults`. [PR #12131](https://github.com/microsoft/vscode-cpptools/pull/12131)
* Update `clang-format`/`clang-tidy` to 18.1.2. [PR #12135](https://github.com/microsoft/vscode-cpptools/pull/12135)
* Log `cpptools` and `cpptools-srv` crash call stacks in the 'C/C++ Crash Call Stacks' Output channel for bug reporting (on x64 Linux and x64/arm64 Mac).
* Increase the fuzzy symbol character limit from 16 to 28.
* Update the IntelliSense engine.
### Bug Fixes
* Fix an IntelliSense parsing issue. [#6183](https://github.com/microsoft/vscode-cpptools/issues/6183)
* Fix 'Copy Declaration / Definition' code not being formatted. [#10956](https://github.com/microsoft/vscode-cpptools/issues/10956)
* Fix semantic colorization of certain macro arguments. [#11416](https://github.com/microsoft/vscode-cpptools/issues/11416)
* Fix 'Add #include' code actions for code scoped by a namespace or class. [#11541](https://github.com/microsoft/vscode-cpptools/issues/11541)
* Fix 'Create Declaration / Definition' not working if the cursor isn't on the function name. [#11834](https://github.com/microsoft/vscode-cpptools/issues/11834)
* Fix duplicate 'Add #include' code actions. [#11989](https://github.com/microsoft/vscode-cpptools/issues/11989)
* Fix directories being incorrectly recursively traversed in certain cases. [#11993](https://github.com/microsoft/vscode-cpptools/issues/11993)
* Fix `forcedInclude` resolution for relative paths. [PR #12035](https://github.com/microsoft/vscode-cpptools/pull/12035)
* Fix 'Add Configuration...' in `launch.json` when `editor.suggest.showSnippets` is `false`. [#12059](https://github.com/microsoft/vscode-cpptools/issues/12059)
* Fix `c_cpp_properties.json` warnings for `includePath`s with `**` wildcard glob patterns. [#12070](https://github.com/microsoft/vscode-cpptools/issues/12070)
* Fix non-existent relative path variables not showing a warning in `c_cpp_properties.json` (and other related issues). [#12089](https://github.com/microsoft/vscode-cpptools/issues/12089)
* Fix call stacks for `cpptools` and `cpptools-srv` not being available on Linux. [#12091](https://github.com/microsoft/vscode-cpptools/issues/12091)
* Fix IntelliSense processes shutting down immediately if not enough memory is detected. [#12126](https://github.com/microsoft/vscode-cpptools/issues/12126)
* Fix code analysis aborting after encountering an excluded file (instead of just skipping it). [#12127](https://github.com/microsoft/vscode-cpptools/issues/12127)
* Fix `"Cannot open source"` errors on missing includes not appearing if `C_Cpp.errorSquiggles` is `enabled`. [#12134](https://github.com/microsoft/vscode-cpptools/issues/12134)
* Fix the IntelliSense server not starting when a completion, signature help, or document highlight occurs from external commands. [#12143](https://github.com/microsoft/vscode-cpptools/issues/12143)
* Fix the IntelliSense configuration not falling back to the `c_cpp_properties.json` configuration for a file not handled by a configuration provider. [#12144](https://github.com/microsoft/vscode-cpptools/issues/12144)
* Fix duplicate URIs in calls to provideConfigurations. [#12177](https://github.com/microsoft/vscode-cpptools/issues/12177)
* Fix a crash and deadlock with a high `C_Cpp.loggingLevel`. [#12194](https://github.com/microsoft/vscode-cpptools/issues/12194)
* Fix handling of `-iquote` for code analysis and `#include` completions. [#12198](https://github.com/microsoft/vscode-cpptools/issues/12198)
* Fix a crash during startup. [#12237](https://github.com/microsoft/vscode-cpptools/issues/12237)
* Fix IntelliSense configuration on Windows ARM64. [#12253](https://github.com/microsoft/vscode-cpptools/issues/12253)
* Fix a `cpptools` process crash and deadlock during shutdown.
## Version 1.19.9: March 20, 2024
@@ -16,5 +16,7 @@
"path.is.not.a.file": "路径不是文件: {0}",
"path.is.not.a.directory": "路径不是目录: {0}",
"duplicate.name": "{0} 重复。配置名称应是唯一的。",
"cannot.find2": "无法找到“{0}”。"
"cannot.find2": "无法找到“{0}”。",
"multiple.paths.not.allowed": "不允许使用多个路径。",
"paths.are.not.directories": "路径不是目录: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++ 诊断",
"c.cpp.crash.call.stacks.title": "C/C++ 故障调用堆栈",
"c.cpp.crash.call.stacks.description": "C/C++ 扩展进程已崩溃。崩溃进程名称、日期/时间、信号和调用堆栈如下 - 将它包含在 {0} 处的 bug 报告中会很有帮助。",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++ 调试协议",
"c.cpp.warnings": "C/C++ 配置警告"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "路徑不是檔案: {0}",
"path.is.not.a.directory": "路徑不是目錄: {0}",
"duplicate.name": "{0} 重複。組態名稱應該是唯一的。",
"cannot.find2": "找不到 \"{0}\"。"
"cannot.find2": "找不到 \"{0}\"。",
"multiple.paths.not.allowed": "不允許使用多個路徑。",
"paths.are.not.directories": "路徑不是目錄: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++ 診斷",
"c.cpp.crash.call.stacks.title": "C/C++ 損毀呼叫堆疊",
"c.cpp.crash.call.stacks.description": "C/C++ 延伸模組程序已損毀。損毀的程序名稱、日期/時間、訊號和呼叫堆疊如下 -- 在 {0} 的錯誤報告中包含該資訊會很有幫助。",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++ 偵錯通訊協定",
"c.cpp.warnings": "C/C++ 設定警告"
+5
View File
@@ -373,6 +373,11 @@
"c_cpp.taskDefinitions.name.description": "Název úlohy.",
"c_cpp.taskDefinitions.command.description": "Cesta ke kompilátoru nebo skriptu, který provádí kompilaci.",
"c_cpp.taskDefinitions.args.description": "Další argumenty, které se mají předat kompilátoru nebo kompilačnímu skriptu.",
"c_cpp.taskDefinitions.args.value.description": "Skutečná hodnota argumentu.",
"c_cpp.taskDefinitions.args.quoting.description": "Způsob, jakým by měla být hodnota argumentu uvedena v uvozovkách",
"c_cpp.taskDefinitions.args.quoting.escape.description": "Uvodí znaky pomocí řídicího znaku prostředí (například pomocí znaku \\ v Bashi).",
"c_cpp.taskDefinitions.args.quoting.strong.description": "Uzavře argument do silných uvozovek prostředí (například ' pomocí znaku Bash).",
"c_cpp.taskDefinitions.args.quoting.weak.description": "Uzavře argument do jednoduchých uvozovek prostředí (například \" pomocí znaku Bash).",
"c_cpp.taskDefinitions.options.description": "Další možnosti příkazu.",
"c_cpp.taskDefinitions.options.cwd.description": "The current working directory of the executed program or script. If omitted Code's current workspace root is used.",
"c_cpp.taskDefinitions.detail.description": "Další podrobnosti o úloze.",
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Cesta není soubor: {0}",
"path.is.not.a.directory": "Cesta není adresář: {0}",
"duplicate.name": "{0} je duplicitní. Název konfigurace by měl být jedinečný.",
"cannot.find2": "Nejde najít {0}."
"cannot.find2": "Nejde najít {0}.",
"multiple.paths.not.allowed": "Více cest není povoleno.",
"paths.are.not.directories": "Cesty nejsou adresáře: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnostika C/C++",
"c.cpp.crash.call.stacks.title": "Zásobníky volání chyb C/C++",
"c.cpp.crash.call.stacks.description": "Došlo k chybovému ukončení procesu rozšíření C/C++. Název chybového procesu, datum a čas, signál a zásobník volání jsou níže. Bylo by užitečné je zahrnout do zprávy o chybě na {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Protokol ladění C/C++",
"c.cpp.warnings": "Upozornění konfigurace C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Der Pfad ist keine Datei: {0}",
"path.is.not.a.directory": "Der Pfad ist kein Verzeichnis: {0}",
"duplicate.name": "\"{0}\" ist ein Duplikat. Der Konfigurationsname muss eindeutig sein.",
"cannot.find2": "\"{0}\" wurde nicht gefunden."
"cannot.find2": "\"{0}\" wurde nicht gefunden.",
"multiple.paths.not.allowed": "Mehrere Pfade sind nicht zulässig.",
"paths.are.not.directories": "Pfade sind keine Verzeichnisse: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++-Diagnose",
"c.cpp.crash.call.stacks.title": "C/C++-Absturzaufruflisten",
"c.cpp.crash.call.stacks.description": "Ein C/C++-Erweiterungsprozess ist abgestürzt. Der Name, das Datum/die Uhrzeit, das Signal und die Aufrufliste des abstürzenden Prozesses sind unten aufgeführt. Es wäre hilfreich, dies in einen Fehlerbericht unter {0} aufzunehmen.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++-Debugprotokoll",
"c.cpp.warnings": "C/C++-Konfigurationswarnungen"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "La ruta de acceso no es un archivo: {0}",
"path.is.not.a.directory": "La ruta de acceso no es un directorio: {0}",
"duplicate.name": "{0} es un duplicado. El nombre de la configuración debe ser único.",
"cannot.find2": "No se encuentra \"{0}\"."
"cannot.find2": "No se encuentra \"{0}\".",
"multiple.paths.not.allowed": "No se permiten varias rutas de acceso.",
"paths.are.not.directories": "Las rutas de acceso no son directorios: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnósticos de C/C++",
"c.cpp.crash.call.stacks.title": "Pilas de llamadas de bloqueo de C/C++",
"c.cpp.crash.call.stacks.description": "Se ha bloqueado un proceso de extensión de C/C++. A continuación se muestran el nombre del proceso de bloqueo, la fecha y hora, la señal y la pila de llamadas; sería útil incluirlo en un informe de errores en {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Protocolo de depuración de C/C++",
"c.cpp.warnings": "Advertencias de configuración de C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Le chemin n'est pas un fichier : {0}",
"path.is.not.a.directory": "Le chemin n'est pas un répertoire : {0}",
"duplicate.name": "{0} est dupliqué. Le nom de configuration doit être unique.",
"cannot.find2": "\"{0}\" est introuvable."
"cannot.find2": "\"{0}\" est introuvable.",
"multiple.paths.not.allowed": "Il est interdit dutiliser plusieurs chemin daccès.",
"paths.are.not.directories": "Les chemins daccès ne sont pas des répertoires : {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnostics C/C++",
"c.cpp.crash.call.stacks.title": "Piles dappels sur incident C/C++",
"c.cpp.crash.call.stacks.description": "Un processus dextension C/C++ sest arrêté. Le nom du processus de blocage, la date/lheure, le signal et la pile des appels sont ci-dessous : il serait utile de linclure dans un rapport de bogues à {0}.",
"c.cpp.ssh.channel": "{0} : SSH",
"c.cpp.debug.protocol": "Protocole de débogage C/C++",
"c.cpp.warnings": "Avertissements de configuration C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Il percorso non è un file: {0}",
"path.is.not.a.directory": "Il percorso non è una directory: {0}",
"duplicate.name": "{0} è duplicato. Il nome della configurazione deve essere univoco.",
"cannot.find2": "Non è possibile trovare \"{0}\"."
"cannot.find2": "Non è possibile trovare \"{0}\".",
"multiple.paths.not.allowed": "Più percorsi non sono consentiti.",
"paths.are.not.directories": "I percorsi non sono directory: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnostica C/C++",
"c.cpp.crash.call.stacks.title": "Stack di chiamate di arresto anomalo del sistema in C/C++",
"c.cpp.crash.call.stacks.description": "Un processo di estensione C/C++ si è arrestato in modo anomalo. Il nome del processo di arresto anomalo, la data/ora, il segnale e lo stack delle chiamate sono riportati di seguito. Sarebbe utile includerli in un report sui bug in {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Protocollo di debug C/C++",
"c.cpp.warnings": "Avvisi di configurazione C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "パスがファイルではありません: {0}",
"path.is.not.a.directory": "パスがディレクトリではありません: {0}",
"duplicate.name": "{0} が重複しています。構成名は一意である必要があります。",
"cannot.find2": "\"{0}\" が見つかりません。"
"cannot.find2": "\"{0}\" が見つかりません。",
"multiple.paths.not.allowed": "複数のパスは使用できません。",
"paths.are.not.directories": "パスはディレクトリではありません: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++ 診断",
"c.cpp.crash.call.stacks.title": "C/C++ クラッシュ呼び出し履歴",
"c.cpp.crash.call.stacks.description": "C/C++ 拡張プロセスがクラッシュしました。クラッシュ プロセス名、日付/時刻、シグナル、および呼び出し履歴は以下のとおりです -- これは、{0} のバグ レポートに含めるのに役立ちます。",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++ デバッグ プロトコル",
"c.cpp.warnings": "C/C++ 構成の警告"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "경로가 파일이 아닙니다. {0}",
"path.is.not.a.directory": "경로가 디렉터리가 아닙니다. {0}",
"duplicate.name": "{0}은(는) 중복됩니다. 구성 이름은 고유해야 합니다.",
"cannot.find2": "\"{0}\"을(를) 찾을 수 없습니다."
"cannot.find2": "\"{0}\"을(를) 찾을 수 없습니다.",
"multiple.paths.not.allowed": "여러 경로는 허용되지 않습니다.",
"paths.are.not.directories": "경로는 디렉터리가 아닙니다. {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++ 진단",
"c.cpp.crash.call.stacks.title": "C/C++ 충돌 호출 스택",
"c.cpp.crash.call.stacks.description": "C/C++ 확장 프로세스에 충돌이 발생했습니다. 충돌하는 프로세스 이름, 날짜/시간, 신호, 호출 스택이 아래에 나열되어 있습니다. 이를 버그 보고서({0})에 포함하면 도움이 될 수 있습니다.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++ 디버그 프로토콜",
"c.cpp.warnings": "C/C++ 구성 경고"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Ścieżka nie jest plikiem: {0}",
"path.is.not.a.directory": "Ścieżka nie jest katalogiem: {0}",
"duplicate.name": "Element {0} jest duplikatem. Nazwa konfiguracji musi być unikatowa.",
"cannot.find2": "Nie można znaleźć elementu „{0}”."
"cannot.find2": "Nie można znaleźć elementu „{0}”.",
"multiple.paths.not.allowed": "Wiele ścieżek jest niedozwolonych.",
"paths.are.not.directories": "Ścieżki nie są katalogami: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnostyka języka C/C++",
"c.cpp.crash.call.stacks.title": "Stosy wywołań awaryjnych języka C/C++",
"c.cpp.crash.call.stacks.description": "Proces rozszerzenia C/C++ uległ awarii. Nazwa procesu powodującego awarię, data/godzina, sygnał i stos wywołań znajdują się poniżej — pomocne byłoby uwzględnienie jej w raporcie o usterce pod adresem {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Protokół debugowania języka C/C++",
"c.cpp.warnings": "Ostrzeżenia dotyczące konfiguracji języka C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "O caminho não é um arquivo: {0}",
"path.is.not.a.directory": "O caminho não é um diretório: {0}",
"duplicate.name": "{0} é uma duplicata. O nome da configuração deve ser exclusivo.",
"cannot.find2": "Não é possível localizar \"{0}\"."
"cannot.find2": "Não é possível localizar \"{0}\".",
"multiple.paths.not.allowed": "Vários caminhos não são permitidos.",
"paths.are.not.directories": "Os caminhos não são diretórios: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Diagnóstico de C/C++",
"c.cpp.crash.call.stacks.title": "Pilhas de Chamadas de Falha do C/C++",
"c.cpp.crash.call.stacks.description": "Um processo de extensão C/C++ falhou. O nome, data/hora, sinal e pilha de chamadas do processo de falha estão abaixo. Seria útil incluí-los em um relatório de bugs em {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Protocolo de Depuração de C/C++",
"c.cpp.warnings": "Avisos de Configuração de C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Путь не является файлом: {0}",
"path.is.not.a.directory": "Путь не является каталогом: {0}",
"duplicate.name": "{0} является дубликатом. Имя конфигурации должно быть уникальным.",
"cannot.find2": "Не удается найти \"{0}\"."
"cannot.find2": "Не удается найти \"{0}\".",
"multiple.paths.not.allowed": "Запрещено использовать несколько путей.",
"paths.are.not.directories": "Пути не являются каталогами: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "Диагностика C/C++",
"c.cpp.crash.call.stacks.title": "Стеки вызовов с аварийным завершением C/C++",
"c.cpp.crash.call.stacks.description": "Процесс расширения C/C++ завершился аварийно. Ниже указаны имя, дата и время, сигнал и стек вызовов для процесса с аварийным завершением. Их будет полезно включить в отчет об ошибке на странице {0}.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "Протокол отладки C/C++",
"c.cpp.warnings": "Предупреждения конфигурации C/C++"
@@ -16,5 +16,7 @@
"path.is.not.a.file": "Yol bir dosya değil: {0}",
"path.is.not.a.directory": "Yol bir dizin değil: {0}",
"duplicate.name": "{0} yineleniyor. Yapılandırma adı benzersiz olmalıdır.",
"cannot.find2": "\"{0}\" bulunamıyor."
"cannot.find2": "\"{0}\" bulunamıyor.",
"multiple.paths.not.allowed": "Birden fazla yola izin verilmez.",
"paths.are.not.directories": "Yollar dizin değil: {0}"
}
+2
View File
@@ -5,6 +5,8 @@
// Do not edit this file. It is machine generated.
{
"c.cpp.diagnostics": "C/C++ Tanılaması",
"c.cpp.crash.call.stacks.title": "C/C++ Kilitlenme Çağrısı Yığınları",
"c.cpp.crash.call.stacks.description": "C/C++ uzantı işlemi kilitlendi. Kilitlenen işlem adı, tarih/saat, sinyal ve çağrı yığını aşağıdadır; bunu {0} adresindeki bir hata raporuna eklemek işe yarar.",
"c.cpp.ssh.channel": "{0}: SSH",
"c.cpp.debug.protocol": "C/C++ Hata Ayıklama Protokolü",
"c.cpp.warnings": "C/C++ Yapılandırma Uyarıları"
+1 -1
View File
@@ -2,7 +2,7 @@
"name": "cpptools",
"displayName": "C/C++",
"description": "C/C++ IntelliSense, debugging, and code browsing.",
"version": "1.20.2-main",
"version": "1.20.5-main",
"publisher": "ms-vscode",
"icon": "LanguageCCPP_color_128x.png",
"readme": "README.md",
+2 -2
View File
@@ -2001,8 +2001,8 @@ export class DefaultClient implements Client {
}
try {
DefaultClient.isStarted.reset();
const status = await this.provideCustomConfigurationAsync(docUri, requestFile, replaceExisting, provider);
telemetry.logLanguageServerEvent('provideCustomConfiguration', { providerId, status });
const resultCode = await this.provideCustomConfigurationAsync(docUri, requestFile, replaceExisting, provider);
telemetry.logLanguageServerEvent('provideCustomConfiguration', { providerId, resultCode });
} finally {
onFinished();
DefaultClient.isStarted.resolve();
+85 -40
View File
@@ -1838,9 +1838,9 @@ export class CppProperties {
curText = curText.substring(0, nextNameStart2);
}
if (this.prevSquiggleMetrics.get(currentConfiguration.name) === undefined) {
this.prevSquiggleMetrics.set(currentConfiguration.name, { PathNonExistent: 0, PathNotAFile: 0, PathNotADirectory: 0, CompilerPathMissingQuotes: 0, CompilerModeMismatch: 0 });
this.prevSquiggleMetrics.set(currentConfiguration.name, { PathNonExistent: 0, PathNotAFile: 0, PathNotADirectory: 0, CompilerPathMissingQuotes: 0, CompilerModeMismatch: 0, MultiplePathsNotAllowed: 0 });
}
const newSquiggleMetrics: { [key: string]: number } = { PathNonExistent: 0, PathNotAFile: 0, PathNotADirectory: 0, CompilerPathMissingQuotes: 0, CompilerModeMismatch: 0 };
const newSquiggleMetrics: { [key: string]: number } = { PathNonExistent: 0, PathNotAFile: 0, PathNotADirectory: 0, CompilerPathMissingQuotes: 0, CompilerModeMismatch: 0, MultiplePathsNotAllowed: 0 };
const isWindows: boolean = os.platform() === 'win32';
// TODO: Add other squiggles.
@@ -1867,7 +1867,7 @@ export class CppProperties {
}
// Check for path-related squiggles.
let paths: string[] = [];
const paths: string[] = [];
let compilerPath: string | undefined;
for (const pathArray of [ currentConfiguration.browse ? currentConfiguration.browse.path : undefined,
currentConfiguration.includePath, currentConfiguration.macFrameworkPath ]) {
@@ -1895,10 +1895,7 @@ export class CppProperties {
compilerPath = currentConfiguration.compilerPath;
}
// Resolve and split any environment variables
paths = this.resolveAndSplit(paths, undefined, this.ExtendedEnvironment);
compilerPath = util.resolveVariables(compilerPath, this.ExtendedEnvironment).trim();
compilerPath = this.resolvePath(compilerPath);
compilerPath = this.resolvePath(compilerPath).trim();
// Get the start/end for properties that are file-only.
const forcedIncludeStart: number = curText.search(/\s*\"forcedInclude\"\s*:\s*\[/);
@@ -1961,8 +1958,7 @@ export class CppProperties {
let dotConfigMessage: string | undefined;
dotConfigPath = currentConfiguration.dotConfig;
dotConfigPath = util.resolveVariables(dotConfigPath, this.ExtendedEnvironment).trim();
dotConfigPath = this.resolvePath(dotConfigPath);
dotConfigPath = this.resolvePath(dotConfigPath).trim();
// does not try resolve if the dotConfig property is empty
dotConfigPath = dotConfigPath !== '' ? dotConfigPath : undefined;
@@ -2001,25 +1997,6 @@ export class CppProperties {
continue;
}
let resolvedPath: string = this.resolvePath(curPath);
if (!resolvedPath) {
continue;
}
let pathExists: boolean = true;
if (this.rootUri) {
const checkPathExists: any = util.checkPathExistsSync(resolvedPath, this.rootUri.fsPath + path.sep, isWindows, false);
pathExists = checkPathExists.pathExists;
resolvedPath = checkPathExists.path;
}
// Normalize path separators.
if (path.sep === "/") {
resolvedPath = resolvedPath.replace(/\\/g, path.sep);
} else {
resolvedPath = resolvedPath.replace(/\//g, path.sep);
}
// Iterate through the text and apply squiggles.
// Escape the path string for literal use in a regular expression
// Need to escape any quotes to match the original text
let escapedPath: string = curPath.replace(/"/g, '\\"');
@@ -2030,6 +2007,42 @@ export class CppProperties {
const pattern: RegExp = new RegExp(`"[^"]*?(?<="|;)${escapedPath}(?="|;).*?"`, "g");
const configMatches: string[] | null = curText.match(pattern);
const expandedPaths: string[] = this.resolveAndSplit([curPath], undefined, this.ExtendedEnvironment, true, true);
const incorrectExpandedPaths: string[] = [];
if (expandedPaths.length <= 0) {
continue;
}
if (this.rootUri) {
for (const [index, expandedPath] of expandedPaths.entries()) {
if (expandedPath.includes("${workspaceFolder}")) {
expandedPaths[index] = this.resolvePath(expandedPath, false);
} else {
expandedPaths[index] = this.resolvePath(expandedPath);
}
const checkPathExists: any = util.checkPathExistsSync(expandedPaths[index], this.rootUri.fsPath + path.sep, isWindows, false);
if (!checkPathExists.pathExists) {
// If there are multiple paths, store any non-existing paths to squiggle later on.
incorrectExpandedPaths.push(expandedPaths[index]);
}
}
}
const pathExists: boolean = incorrectExpandedPaths.length === 0;
for (const [index, expandedPath] of expandedPaths.entries()) {
// Normalize path separators.
if (path.sep === "/") {
expandedPaths[index] = expandedPath.replace(/\\/g, path.sep);
} else {
expandedPaths[index] = expandedPath.replace(/\//g, path.sep);
}
}
// Iterate through the text and apply squiggles.
let globPath: boolean = false;
const asteriskPosition = curPath.indexOf("*");
if (asteriskPosition !== -1) {
@@ -2041,6 +2054,7 @@ export class CppProperties {
}
}
}
if (configMatches && !globPath) {
let curOffset: number = 0;
let endOffset: number = 0;
@@ -2050,29 +2064,57 @@ export class CppProperties {
if (curOffset >= compilerPathStart && curOffset <= compilerPathEnd) {
continue;
}
let message: string;
let message: string = "";
if (!pathExists) {
if (curOffset >= forcedIncludeStart && curOffset <= forcedeIncludeEnd
&& !path.isAbsolute(resolvedPath)) {
&& !path.isAbsolute(expandedPaths[0])) {
continue; // Skip the error, because it could be resolved recursively.
}
message = localize('cannot.find2', "Cannot find \"{0}\".", resolvedPath);
let badPath = "";
if (incorrectExpandedPaths.length > 0) {
badPath = incorrectExpandedPaths.map(s => `"${s}"`).join(', ');
} else {
badPath = `"${expandedPaths[0]}"`;
}
message = localize('cannot.find2', "Cannot find {0}", badPath);
newSquiggleMetrics.PathNonExistent++;
} else {
// Check for file versus path mismatches.
if ((curOffset >= forcedIncludeStart && curOffset <= forcedeIncludeEnd) ||
(curOffset >= compileCommandsStart && curOffset <= compileCommandsEnd)) {
if (util.checkFileExistsSync(resolvedPath)) {
continue;
(curOffset >= compileCommandsStart && curOffset <= compileCommandsEnd)) {
if (expandedPaths.length > 1) {
message = localize("multiple.paths.not.allowed", "Multiple paths are not allowed.");
newSquiggleMetrics.MultiplePathsNotAllowed++;
} else {
const resolvedPath = this.resolvePath(expandedPaths[0]);
if (util.checkFileExistsSync(resolvedPath)) {
continue;
}
message = localize("path.is.not.a.file", "Path is not a file: {0}", expandedPaths[0]);
newSquiggleMetrics.PathNotAFile++;
}
message = localize("path.is.not.a.file", "Path is not a file: {0}", resolvedPath);
newSquiggleMetrics.PathNotAFile++;
} else {
if (util.checkDirectoryExistsSync(resolvedPath)) {
const mismatchedPaths: string[] = [];
for (const expandedPath of expandedPaths) {
const resolvedPath = this.resolvePath(expandedPath);
if (!util.checkDirectoryExistsSync(resolvedPath)) {
mismatchedPaths.push(expandedPath);
}
}
let badPath = "";
if (mismatchedPaths.length > 1) {
badPath = mismatchedPaths.map(s => `"${s}"`).join(', ');
message = localize('paths.are.not.directories', "Paths are not directories: {0}", badPath);
newSquiggleMetrics.PathNotADirectory++;
} else if (mismatchedPaths.length === 1) {
badPath = `"${mismatchedPaths[0]}"`;
message = localize('path.is.not.a.directory', "Path is not a directory: {0}", badPath);
newSquiggleMetrics.PathNotADirectory++;
} else {
continue;
}
message = localize("path.is.not.a.directory", "Path is not a directory: {0}", resolvedPath);
newSquiggleMetrics.PathNotADirectory++;
}
}
const diagnostic: vscode.Diagnostic = new vscode.Diagnostic(
@@ -2092,7 +2134,7 @@ export class CppProperties {
endOffset = curOffset + curMatch.length;
let message: string;
if (!pathExists) {
message = localize('cannot.find2', "Cannot find \"{0}\".", resolvedPath);
message = localize('cannot.find2', "Cannot find \"{0}\".", expandedPaths[0]);
newSquiggleMetrics.PathNonExistent++;
const diagnostic: vscode.Diagnostic = new vscode.Diagnostic(
new vscode.Range(document.positionAt(envTextStartOffSet + curOffset),
@@ -2128,6 +2170,9 @@ export class CppProperties {
if (newSquiggleMetrics.CompilerModeMismatch !== this.prevSquiggleMetrics.get(currentConfiguration.name)?.CompilerModeMismatch) {
changedSquiggleMetrics.CompilerModeMismatch = newSquiggleMetrics.CompilerModeMismatch;
}
if (newSquiggleMetrics.MultiplePathsNotAllowed !== this.prevSquiggleMetrics.get(currentConfiguration.name)?.MultiplePathsNotAllowed) {
changedSquiggleMetrics.MultiplePathsNotAllowed = newSquiggleMetrics.MultiplePathsNotAllowed;
}
if (Object.keys(changedSquiggleMetrics).length > 0) {
telemetry.logLanguageServerEvent("ConfigSquiggles", undefined, changedSquiggleMetrics);
}
+55 -25
View File
@@ -17,6 +17,7 @@ import { TargetPopulation } from 'vscode-tas-client';
import * as which from 'which';
import { logAndReturn } from '../Utility/Async/returns';
import * as util from '../common';
import { getCrashCallStacksChannel } from '../logger';
import { PlatformInformation } from '../platform';
import * as telemetry from '../telemetry';
import { Client, DefaultClient, DoxygenCodeActionCommandArguments, openFileVersions } from './client';
@@ -36,7 +37,9 @@ const localize: nls.LocalizeFunc = nls.loadMessageBundle();
export const CppSourceStr: string = "C/C++";
export const configPrefix: string = "C/C++: ";
let prevCrashFile: string;
let prevMacCrashFile: string;
let prevCppCrashFile: string;
let prevCppCrashCallStackData: string = "";
export let clients: ClientCollection;
let activeDocument: vscode.TextDocument | undefined;
let ui: LanguageStatusUI;
@@ -914,7 +917,7 @@ function onShowRefCommand(arg?: TreeNode): void {
function reportMacCrashes(): void {
if (process.platform === "darwin") {
prevCrashFile = "";
prevMacCrashFile = "";
const home: string = os.homedir();
const crashFolder: string = path.resolve(home, "Library/Logs/DiagnosticReports");
fs.stat(crashFolder, (err) => {
@@ -932,10 +935,10 @@ function reportMacCrashes(): void {
if (event !== "rename") {
return;
}
if (!filename || filename === prevCrashFile) {
if (!filename || filename === prevMacCrashFile) {
return;
}
prevCrashFile = filename;
prevMacCrashFile = filename;
if (!filename.startsWith("cpptools")) {
return;
}
@@ -959,12 +962,24 @@ function reportMacCrashes(): void {
}
export function usesCrashHandler(): boolean {
return process.platform !== "win32" && (process.platform === "darwin" || os.arch() === "x64");
if (os.platform() === "darwin") {
if (os.arch() === "arm64") {
return true;
} else {
const releaseParts: string[] = os.release().split(".");
if (releaseParts.length >= 1) {
// Avoid potentially intereferring with the older macOS crash handler.
return parseInt(releaseParts[0]) >= 19;
}
return true;
}
}
return os.platform() !== "win32" && os.arch() === "x64";
}
export function watchForCrashes(crashDirectory: string): void {
if (crashDirectory !== "") {
prevCrashFile = "";
prevCppCrashFile = "";
fs.stat(crashDirectory, (err) => {
const crashObject: Record<string, string> = {};
if (err?.code) {
@@ -980,17 +995,19 @@ export function watchForCrashes(crashDirectory: string): void {
if (event !== "rename") {
return;
}
if (!filename || filename === prevCrashFile) {
if (!filename || filename === prevCppCrashFile) {
return;
}
prevCrashFile = filename;
prevCppCrashFile = filename;
if (!filename.startsWith("cpptools")) {
return;
}
const crashDate: Date = new Date();
// Wait 5 seconds to allow time for the crash log to finish being written.
setTimeout(() => {
fs.readFile(path.resolve(crashDirectory, filename), 'utf8', (err, data) => {
void handleCrashFileRead(crashDirectory, filename, err, data);
void handleCrashFileRead(crashDirectory, filename, crashDate, err, data);
});
}, 5000);
});
@@ -1115,7 +1132,7 @@ function handleMacCrashFileRead(err: NodeJS.ErrnoException | undefined | null, d
logMacCrashTelemetry(data);
}
async function handleCrashFileRead(crashDirectory: string, crashFile: string, err: NodeJS.ErrnoException | undefined | null, data: string): Promise<void> {
async function handleCrashFileRead(crashDirectory: string, crashFile: string, crashDate: Date, err: NodeJS.ErrnoException | undefined | null, data: string): Promise<void> {
if (err) {
if (err.code === "ENOENT") {
return; // ignore known issue
@@ -1125,23 +1142,23 @@ async function handleCrashFileRead(crashDirectory: string, crashFile: string, er
const lines: string[] = data.split("\n");
let addressData: string = ".\n.";
data = crashFile + "\n";
const isCppToolsSrv: boolean = crashFile.startsWith("cpptools-srv");
const telemetryHeader: string = (isCppToolsSrv ? "cpptools-srv.txt" : crashFile) + "\n";
const filtPath: string | null = which.sync("c++filt", { nothrow: true });
const isMac: boolean = process.platform === "darwin";
const startStr: string = isMac ? " _" : "<";
const offsetStr: string = isMac ? " + " : "+";
const endOffsetStr: string = isMac ? " " : " <";
const dotStr: string = "…";
data += lines[0]; // signal type
const signalType: string = lines[0];
let crashCallStack: string = "";
for (let lineNum: number = 2; lineNum < lines.length - 3; ++lineNum) { // skip first/last lines
if (lineNum > 1) {
data += "\n";
addressData += "\n";
}
crashCallStack += "\n";
addressData += "\n";
const line: string = lines[lineNum];
const startPos: number = line.indexOf(startStr);
if (startPos === -1 || line[startPos + (isMac ? 1 : 4)] === "+") {
data += dotStr;
crashCallStack += dotStr;
const startAddressPos: number = line.indexOf("0x");
const endAddressPos: number = line.indexOf(endOffsetStr, startAddressPos + 2);
if (startAddressPos === -1 || endAddressPos === -1 || startAddressPos >= endAddressPos) {
@@ -1153,7 +1170,7 @@ async function handleCrashFileRead(crashDirectory: string, crashFile: string, er
}
const offsetPos: number = line.indexOf(offsetStr, startPos + startStr.length);
if (offsetPos === -1) {
data += "Missing offsetStr";
crashCallStack += "Missing offsetStr";
continue; // unexpected
}
const startPos2: number = startPos + 1;
@@ -1173,36 +1190,49 @@ async function handleCrashFileRead(crashDirectory: string, crashFile: string, er
funcStr = funcStr.replace(/, std::allocator<std::string>/g, "");
}
}
data += funcStr + offsetStr;
crashCallStack += funcStr + offsetStr;
const offsetPos2: number = offsetPos + offsetStr.length;
if (isMac) {
data += line.substring(offsetPos2);
crashCallStack += line.substring(offsetPos2);
const startAddressPos: number = line.indexOf("0x");
if (startAddressPos === -1 || startAddressPos >= startPos) {
// unexpected
data += "<Missing 0x>";
crashCallStack += "<Missing 0x>";
continue;
}
addressData += `${line.substring(startAddressPos, startPos)}`;
} else {
const endPos: number = line.indexOf(">", offsetPos2);
if (endPos === -1) {
data += "<Missing > >";
crashCallStack += "<Missing > >";
continue; // unexpected
}
data += line.substring(offsetPos2, endPos);
crashCallStack += line.substring(offsetPos2, endPos);
}
}
if (crashCallStack !== prevCppCrashCallStackData) {
prevCppCrashCallStackData = crashCallStack;
const settings: vscode.WorkspaceConfiguration = vscode.workspace.getConfiguration("C_Cpp", null);
if (lines.length >= 6 && util.getNumericLoggingLevel(settings.get<string>("loggingLevel")) >= 1) {
const out: vscode.OutputChannel = getCrashCallStacksChannel();
out.appendLine(`\n${isCppToolsSrv ? "cpptools-srv" : "cpptools"}\n${crashDate.toLocaleString()}\n${signalType}${crashCallStack}`);
}
}
data = telemetryHeader + signalType + crashCallStack;
if (data.length > 8192) { // The API has an 8k limit.
data = data.substring(0, 8191) + "…";
}
console.log(`Crash call stack:\n${data}`);
logCppCrashTelemetry(data, addressData);
await util.deleteFile(path.resolve(crashDirectory, crashFile)).catch(logAndReturn.undefined);
void util.deleteDirectory(crashDirectory).catch(logAndReturn.undefined);
if (crashFile === "cpptools.txt") {
void util.deleteDirectory(crashDirectory).catch(logAndReturn.undefined);
}
}
export function deactivate(): Thenable<void> {
+11
View File
@@ -74,6 +74,7 @@ export class Logger {
export let outputChannel: vscode.OutputChannel | undefined;
export let diagnosticsChannel: vscode.OutputChannel | undefined;
export let crashCallStacksChannel: vscode.OutputChannel | undefined;
export let debugChannel: vscode.OutputChannel | undefined;
export let warningChannel: vscode.OutputChannel | undefined;
export let sshChannel: vscode.OutputChannel | undefined;
@@ -98,6 +99,16 @@ export function getDiagnosticsChannel(): vscode.OutputChannel {
return diagnosticsChannel;
}
export function getCrashCallStacksChannel(): vscode.OutputChannel {
if (!crashCallStacksChannel) {
crashCallStacksChannel = vscode.window.createOutputChannel(localize("c.cpp.crash.call.stacks.title", "C/C++ Crash Call Stacks"));
crashCallStacksChannel.appendLine(localize({ key: "c.cpp.crash.call.stacks.description", comment: ["{0} is a URL."] },
"A C/C++ extension process has crashed. The crashing process name, date/time, signal, and call stack are below -- it would be helpful to include that in a bug report at {0}.",
"https://github.com/Microsoft/vscode-cpptools/issues"));
}
return crashCallStacksChannel;
}
export function getSshChannel(): vscode.OutputChannel {
if (!sshChannel) {
sshChannel = vscode.window.createOutputChannel(localize("c.cpp.ssh.channel", "{0}: SSH", "Cpptools"));