Skip to content

Commit 15f1411

Browse files
author
Akos Kitta
committed
Removed unused code.
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
1 parent c8e2240 commit 15f1411

File tree

1 file changed

+1
-30
lines changed

1 file changed

+1
-30
lines changed

arduino-ide-extension/src/common/protocol/core-service.ts

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
import { ApplicationError } from '@theia/core';
2-
import URI from '@theia/core/lib/common/uri';
3-
import {
4-
Location,
5-
Range,
6-
} from '@theia/core/shared/vscode-languageserver-protocol';
2+
import { Location } from '@theia/core/shared/vscode-languageserver-protocol';
73
import { BoardUserField } from '.';
84
import { Board, Port } from '../../common/protocol/boards-service';
95
import { ErrorInfo as CliErrorInfo } from '../../node/cli-error-parser';
@@ -28,31 +24,6 @@ export namespace CoreError {
2824
const { message, location } = error;
2925
return !!message && !!location;
3026
}
31-
export function toString({ location, message }: Compiler): string {
32-
const {
33-
uri,
34-
range: {
35-
start: { line, character },
36-
},
37-
} = location;
38-
return `${new URI(uri)
39-
.withFragment(`L${line},${character}`)
40-
.toString()} => '${message}'`;
41-
}
42-
export function sameAs(left: Compiler, right: Compiler): boolean {
43-
const sameRange = (left: Range, right: Range) =>
44-
left.start.line === right.start.line &&
45-
left.start.character === right.start.character &&
46-
left.end.line === right.end.line &&
47-
left.end.character === right.end.character;
48-
const sameLocation = (left: Location, right: Location) =>
49-
left.uri === right.uri && sameRange(left.range, right.range);
50-
return (
51-
left.message === right.message &&
52-
left.details === right.details &&
53-
sameLocation(left.location, right.location)
54-
);
55-
}
5627
}
5728
export const Codes = {
5829
Verify: 4001,

0 commit comments

Comments
 (0)