mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-20 16:49:06 +01:00
Emmet: Show error when failed to eval math expression Fixes #31281
This commit is contained in:
@@ -25,6 +25,7 @@ export function evaluateMathExpression() {
|
||||
const result = String(evaluate(stream, true));
|
||||
editBuilder.replace(new vscode.Range(stream.pos, pos), result);
|
||||
} catch (err) {
|
||||
vscode.window.showErrorMessage('Could not evaluate expression');
|
||||
// Ignore error since most likely it’s because of non-math expression
|
||||
console.warn('Math evaluation error', err);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user