Skip to content

Commit ae52466

Browse files
pedro-ricardokrvajal
authored andcommitted
Minor release for version 2.0.2 (#99)
### Check List - [x] Merge #108 for fix on issue #106 - [x] Correct CI error - [x] Merge #101 - [x] Merge #107 for fix on issue #100 - [x] Merge #98 for fix on issue #97 - [x] Update changelog - [x] Update Package.json
1 parent 47da2d1 commit ae52466

File tree

4 files changed

+48
-14
lines changed

4 files changed

+48
-14
lines changed

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
77

88
## [Unreleased]
99

10+
## [2.0.2] - 2018-11-28
11+
12+
### Changed
13+
14+
- Fixed wrong language on gfortran messages (#101)
15+
16+
### Added
17+
18+
- Extensions `.for`, `.FOR` and `.fpp` added to fixed-form highlight (#97)
19+
- Extend syntax highlighting (#106,#109)
20+
- Comments enable on fixed-form (#100)
21+
1022
## [2.0.1] - 2018-10-18
1123

1224
### Changed

package.json

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
"name": "linter-gfortran",
33
"displayName": "Modern Fortran",
44
"description": "Modern Fortran language support, including syntax highlighting and error detection.",
5-
"version": "2.0.1",
5+
"version": "2.0.2",
66
"publisher": "krvajalm",
77
"engines": {
8-
"vscode": "^1.25.x"
8+
"vscode": "^1.30.x"
99
},
1010
"icon": "images/icon.png",
1111
"repository": {
@@ -51,8 +51,12 @@
5151
".F",
5252
".f77",
5353
".F77",
54+
".for",
55+
".FOR",
56+
".fpp",
5457
".FPP"
55-
]
58+
],
59+
"configuration": "./language-configuration.json"
5660
}
5761
],
5862
"grammars": [

src/features/linter-provider.ts

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,19 @@ export default class FortranLintingProvider {
2525
let argList = this.constructArgumentList(textDocument);
2626

2727
let filePath = path.parse(textDocument.fileName).dir;
28-
let childProcess = cp.spawn(command, argList, { cwd: filePath });
28+
29+
/*
30+
* reset localization settings to traditional C English behavior in case
31+
* gfortran is set up to use the system provided localization information,
32+
* so errorRegex can nevertheless be used to filter out errors and warnings
33+
*
34+
* see also: https://gcc.gnu.org/onlinedocs/gcc/Environment-Variables.html
35+
*/
36+
const env = {
37+
...process.env,
38+
LC_ALL: 'C'
39+
};
40+
let childProcess = cp.spawn(command, argList, { cwd: filePath, env: env });
2941

3042
if (childProcess.pid) {
3143
childProcess.stdout.on("data", (data: Buffer) => {

syntaxes/fortran_free-form.tmLanguage.json

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2059,7 +2059,7 @@
20592059
"derived-type-component-type-specification": {
20602060
"comment": "Introduced in the Fortran 1995 standard.",
20612061
"name": "meta.specification.type.fortran",
2062-
"begin": "(?ix)(?=\\b(?:character|class|complex|double\\s*precision|integer|logical|real|type)\\b(?![^'\";!\\n]*\\bfunction\\b))",
2062+
"begin": "(?ix)(?=\\b(?:character|class|complex|double\\s*precision|double\\s*complex|integer|logical|real|type)\\b(?![^'\";!\\n]*\\bfunction\\b))",
20632063
"end": "(?=[;!\\n])",
20642064
"patterns": [
20652065
{
@@ -4064,7 +4064,7 @@
40644064
},
40654065
"type-specification-statements": {
40664066
"name": "meta.specification.type.fortran",
4067-
"begin": "(?ix)(?=\\b(?:character|class|complex|double\\s*precision|integer|logical|real|type)\\b(?![^'\";!\\n]*\\bfunction\\b))",
4067+
"begin": "(?ix)(?=\\b(?:character|class|complex|double\\s*precision|double\\s*complex|integer|logical|real|type)\\b(?![^'\";!\\n]*\\bfunction\\b))",
40684068
"end": "(?=[\\);!\\n])",
40694069
"patterns": [
40704070
{
@@ -4570,7 +4570,7 @@
45704570
"derived-type": {
45714571
"comment": "Introduced in the Fortran 1995 standard.",
45724572
"name": "meta.specification.type.derived.fortran",
4573-
"match": "(?i)\\b(?:(class)|(type))\\s*(\\()\\s*([a-z]\\w*)(\\))",
4573+
"match": "(?i)\\b(?:(class)|(type))\\s*(\\()\\s*(([a-z]\\w*)|\\*)\\s*(\\))",
45744574
"captures": {
45754575
"1": {
45764576
"name": "storage.type.class.fortran"
@@ -4635,7 +4635,7 @@
46354635
"comment": "Introduced in the Fortran 1977 standard.",
46364636
"patterns": [
46374637
{
4638-
"begin": "(?i)\\b(?:(complex)|(double\\s*precision)|(integer)|(real))\\s*(?=\\()",
4638+
"begin": "(?i)\\b(?:(complex)|(double\\s*precision)|(double\\s*complex)|(integer)|(real))\\s*(?=\\()",
46394639
"beginCaptures": {
46404640
"1": {
46414641
"name": "storage.type.complex.fortran"
@@ -4644,12 +4644,15 @@
46444644
"name": "storage.type.double.fortran"
46454645
},
46464646
"3": {
4647-
"name": "storage.type.integer.fortran"
4647+
"name": "storage.type.doublecomplex.fortran"
46484648
},
46494649
"4": {
4650-
"name": "storage.type.real.fortran"
4650+
"name": "storage.type.integer.fortran"
46514651
},
46524652
"5": {
4653+
"name": "storage.type.real.fortran"
4654+
},
4655+
"6": {
46534656
"name": "punctuation.parentheses.left.fortran"
46544657
}
46554658
},
@@ -4667,7 +4670,7 @@
46674670
]
46684671
},
46694672
{
4670-
"match": "(?ix)\\b(?:(complex)|(double\\s*precision)|(integer)|(real))\\b(?:\\s*(\\*)\\s*(\\d*))?",
4673+
"match": "(?ix)\\b(?:(complex)|(double\\s*precision)|(double\\s*complex)|(integer)|(real))\\b(?:\\s*(\\*)\\s*(\\d*))?",
46714674
"captures": {
46724675
"1": {
46734676
"name": "storage.type.complex.fortran"
@@ -4676,15 +4679,18 @@
46764679
"name": "storage.type.double.fortran"
46774680
},
46784681
"3": {
4679-
"name": "storage.type.integer.fortran"
4682+
"name": "storage.type.doublecomplex.fortran"
46804683
},
46814684
"4": {
4682-
"name": "storage.type.real.fortran"
4685+
"name": "storage.type.integer.fortran"
46834686
},
46844687
"5": {
4685-
"name": "keyword.operator.multiplication.fortran"
4688+
"name": "storage.type.real.fortran"
46864689
},
46874690
"6": {
4691+
"name": "keyword.operator.multiplication.fortran"
4692+
},
4693+
"7": {
46884694
"name": "constant.numeric.fortran"
46894695
}
46904696
}

0 commit comments

Comments
 (0)